summaryrefslogtreecommitdiff
path: root/1181/CH1/EX1.1/c1e1.sce
blob: 37cf0d30e739ebf0029f244308f30b077d9ed112 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
//Calculating shear stress 
clc;
mu=.048;
sg=.913;
V0= 0 ; //at y=0 
Vi=1.125; //at y=0.075 
//For Linear Velocity Distribution 
disp('For Linear Velocity Distribution')
K=1.125/0.075 ; // V=15y so dv/dy= 15
tau=mu*K; //tau= shear stress 
disp ( tau,'Shear stress (N/m2) = ')

// For parabolic velocity Distribution 
disp('For parabolic velocity Distribution')
disp ( 'V = A + By + Cy^2' )
// Boundary Conditions : V=0 at y=0 , V=1.125 at y=0.075 , dV/dy = 0 at y=0.075 
A=0 ;
A1= [ 0.075 0.075*0.075 ;1 0.15 ]
B1=[-1.125 ; 0 ]
[X,ker]=linsolve(A1,B1)
B=X(1,1);
C=X(2,1)
y = poly(0,'y');
V=poly([A B C ],'y','c');
disp(V,' V=');
V1= derivat(V)
disp(V1 , 'dV/dy = ')