summaryrefslogtreecommitdiff
path: root/1379/CH13/EX13.1.2/example13_2.sce
diff options
context:
space:
mode:
Diffstat (limited to '1379/CH13/EX13.1.2/example13_2.sce')
-rwxr-xr-x1379/CH13/EX13.1.2/example13_2.sce33
1 files changed, 33 insertions, 0 deletions
diff --git a/1379/CH13/EX13.1.2/example13_2.sce b/1379/CH13/EX13.1.2/example13_2.sce
new file mode 100755
index 000000000..5002fe99c
--- /dev/null
+++ b/1379/CH13/EX13.1.2/example13_2.sce
@@ -0,0 +1,33 @@
+
+
+//exapple 13.2
+clc; funcprot(0);
+// Initialization of Variable
+sigma=55*10^6;//maximum stress
+d=35.2/100;
+rhos=8890;//density of bronze
+rho=1105;//density of solution
+t=80/1000;//thickness
+tau=4.325/1000;
+pi=3.1428;
+//calculation
+//part1
+ri=d/2-t;//radius internal
+function [y ]= fround(x,n)
+// fround(x,n)
+// Round the floating point numbers x to n decimal places
+// x may be a vector or matrix// n is the integer number of places to round to
+y=round(x*10^n)/10^n;
+endfunction
+omega=sqrt((sigma*tau*2/d)/(.5*rho*(d^2/4-ri^2)+rhos*tau*d/2));
+N=60*omega/2/pi;
+disp(N,"The maximum safe speed allowed in rpm:");
+//part2
+P=.5*rho*(d^2/4-ri^2)*omega^2;
+P=fround(P/10^4,1)*10^4;
+//disp(P,"the power in N/m^2:");
+printf('the power in N/m^2: %3.2e\n', P);
+a=rho*omega^2*d/2;
+a=fround(a/10^6,1)*10^6;
+//disp(a,"pressure gradient in radial direction in N/m^3:")
+printf('pressure gradient in radial direction in N/m^3: %3.2e\n', a);