Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
format
  • Loading branch information
nin13001 committed Dec 16, 2017
1 parent 94cc919 commit 33304d2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Expand Up @@ -45,6 +45,7 @@ membrane_solution3(0.006,0.001)
## Part C
**Problem**
Create a general central finite difference approximation of the gradient with n-by-n interior nodes of w for the given membrane solution in terms of P and T. [w]=membrane_solution(T,P,n); The output w should be a vector, but the solution represents a 2D data set w(x,y).

**Approach**
This part of the assignment was handled similarly to part A, as the only thing that changed from the two scripts was the ability of the user to input their own dimensions, which was done by altering the indexing in the function.
```
Expand Down Expand Up @@ -90,6 +91,7 @@ Create a function SE_diff that calculates the difference in strain energy (right
[pw_se,w]=SE_diff(T,P,n)

Use the solution from part c to calculate w, then do a numerical integral over the elements to calculate work done and strain energy.

**Approach**
The first thing I did was pull the solution from membrane_solution.m, after which the average displacement of each node was calculated. This was done through taking the displacement at each corner, after which it was all averaged. The same was done for the left and right points (boundary conditions).
```
Expand Down Expand Up @@ -127,6 +129,7 @@ pw_se = pw-se;
Use a root-finding method to calculate the tension in the membrane given a pressure, P=0.001 MPa, and n=[20:5:40] interior nodes.

Show that the error in tension is decreasing with a table

**Approach**
Using previous knowledge of bisecting functions, as well as the outputs of the SE_diff function, the script ran every single iteration for the different amounts of nodes. The script then saves the values as a vector T, from which it is able to compare and output error from rel_error.
```
Expand Down Expand Up @@ -181,8 +184,9 @@ ea = zeros(1,length(n));
## Part G
**Problem**
Plot the Pressure vs maximum deflection (P (y-axis) vs max(w) (x-axis)) for P=linspace(0.001,0.01,10). Use a root-finding method to determine tension, T, at each pressure. Use a cubic best-fit to find A, where, P(x)=A*dw^3. State how many interior nodes were used for the graph. Plot the data and best-fit curve in your README.

**Approach**
Utilizing the previous tension_sol results, the script runs all the iterations of pressure and tension. After this it also calculates the maximum deflection of every single iteration. The results are plotted as a linear regression, and plotted on the chart pictured below.
Utilizing the previous tension_sol results, the script runs all the iterations of pressure and tension. After this it also calculates the maximum deflection of every single iteration. The results are plotted as a linear regression, and plotted on the chart pictured below.
```
No = linspace(.001,.01,10);
n = 20;
Expand Down

0 comments on commit 33304d2

Please sign in to comment.