Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update README.md
  • Loading branch information
ltd13002 committed Dec 14, 2017
1 parent 3fbaa55 commit 381161f
Showing 1 changed file with 28 additions and 1 deletion.
29 changes: 28 additions & 1 deletion README.md
Expand Up @@ -110,7 +110,8 @@ pw_se = pw-se;
T = zeros(1,length(n));
ea = zeros(1,length(n));
for i = 1:length(n)
[T(i), ea(i)] = tension_sol(P,n(i));
[T(i), ea(i)] = tension_sol(P,n(i));
end
```
```matlab
Expand Down Expand Up @@ -172,3 +173,29 @@ end
|30|0.0602|0.15%|
|35|0.0602|0.09%|
|40|0.0603|0.06%|


# Part G
```matlab
P = linspace(.001,.01,10);
n = 20;
T = zeros(1,length(P));
wmax = zeros(1,length(P));
for i = 1:length(P)
T(i) = tension_sol(P(i),n);
w = membrane_solution(T(i),P(i),n);
wmax(i) = max(w);
end
clf
setDefaults
x = wmax;
y = P';
Z = [x.^3]';
a = Z\y;
x_fcn = linspace(min(x),max(x));
plot(x,y,'o',x_fcn,a.*x_fcn)
title('Pressure vs. Maximum Deflection')
xlabel('Max w')
ylabel('Pressure vs.. Max Deflection')
```
![](

0 comments on commit 381161f

Please sign in to comment.