Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
cjc13016 committed Dec 15, 2017
2 parents 0b75eb4 + 3daf399 commit a6aa124
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ Using the given pressure range, the tension is found at each different pressure
```matlab
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
% This creates a plot for the max_w vs a given pressure
clear
P = linspace(0.001,0.01,10); % Assign the range of pressures used to find T
Expand All @@ -221,25 +222,35 @@ P = linspace(0.001,0.01,10);
clear
P = linspace(0.001,0.01,10);
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
clear
P = linspace(0.001,0.01,10);
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
for i = 1:length(P)
func = @(T) SE_diff(T,P(i),10);
[root(i),fx,ea,iter] = bisect_final_project(func,0.001,1,.1);
end
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
% Each value of w is calculated using each root and pressure value
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
for i = 1:length(root)
w = membrane_solution(root(i),P(i),10);
w1(:,i) = w;
end
<<<<<<< HEAD
<<<<<<< HEAD
<<<<<<< HEAD
w_max = max(w1); % in order to get the w_max we take the maximum w value from each column of the w vector
Expand All @@ -250,12 +261,17 @@ plot(w_max,P,w_max,Y,'or') % plot the w_max vs. the Pressure and include a cubic
=======
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
w_max = max(w1);
coefficients = polyfit(w_max,P,3);
Y = polyval(coefficients,w_max);
plot(w_max,P,w_max,Y,'or')
<<<<<<< HEAD
<<<<<<< HEAD
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
=======
>>>>>>> 3daf399f8af002d376801f3e913283aac67f17f2
Expand Down

0 comments on commit a6aa124

Please sign in to comment.