Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Update README.md
  • Loading branch information
mam13081 committed Dec 13, 2017
1 parent a59d83a commit 629510f
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions README.md
Expand Up @@ -71,3 +71,34 @@ end
[w] = membrane_solution(0.006,0.001,10)
```
![](https://github.uconn.edu/ltd13002/ME3255_Final_Project/blob/master/Part%20D/PartDFigure.png)


# Part E
```matlab
function [pw_se,w]=SE_diff(T,P,n)
E = 1; %TPa Units may need to be changed
v = .31; %Poissons ratio
t = .3; %nm
h = 10/(n+1); %nm
w = membrane_solution(T,P,n);
z = zeros(n+2);
z(2:end-1,2:end-1) = reshape(w,[n n]);
num = n + 1;
wbar = zeros(num);
for i = 1:num
for j = 1:num
wbar(i,j) = mean([z(i,j),z(i+1,j),z(i,j+1),z(i+1,j+1)]);
end
end
pw = sum(sum(wbar.*h^2.*P));
dwdx = zeros(num);
dwdy = zeros(num);
for i = 1:num
for j = 1:num
dwdx(i,j) = mean([z(i+1,j)-z(i,j),z(i+1,j+1)-z(i,j+1)]);
dwdy(i,j) = mean([z(i,j+1)-z(i,j),z(i+1,j+1)-z(i+1,j)]);
end
end
se = E*t*h^2/(2*(1-v^2))*sum(sum(0.25.*dwdx.^4+.25.*dwdy.^4+0.5.*(dwdx.*dwdy).^2));
pw_se = pw-se;
```

0 comments on commit 629510f

Please sign in to comment.