summaryrefslogtreecommitdiff
path: root/1322/CH21/EX21.1/183ex1.sce
blob: aa7aa4ab5a26c59fc770111264fd526aed0745e7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20

//spiral spring example
clc;
clear;
close;
clf();
weight=linspace(0,0.5,6);
extension=[0 0.15 0.3 0.44 0.6 0.75];
plot2d(weight,extension,13);
xtitle("spiral spring example","vaues of L","values of E");
xgrid();
//Extension varies directly as the attached load
//let E=Extension,L=Load
//to find 'k',a pair of values is taken at point p
L=0.5;E=0.75;
plot(L,E,'r..');
legend("E=KL",'POINT P',2);
//substitute 'p' in E=K*L
K=E/L;
mprintf("the law is : \n E= %fL \n",K)