Guest User

Untitled

a guest
Jan 23rd, 2018
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.50 KB | None | 0 0
  1. p[x_] = 7.95775*10^-6/(6.25*10^-10 + x^2) /. x -> 10 - x
  2.  
  3. eq1 = D[M[x], {x, 2}] == p[x]
  4.  
  5. soln1 = NDSolve[{eq1, M[0] == 0, M[20] == 0}, M, {x, 0, 20}]
  6.  
  7. Plot[-M[x] /. soln1[[1]], {x, 0, 20}, PlotRange -> {0, 6}, FrameLabel -> {"x", "M[x]"}, PlotLabel -> "Bending moment", GridLines -> Automatic, Frame -> True]
  8.  
  9. V[x_] = -D[M[x] /. soln1[[1]], {x, 1}]
  10.  
  11. Plot[V[x], {x, 0, 20}, PlotRange -> {-0.75, 0.75}, FrameLabel -> {"x", "V[x]"}, PlotLabel -> "Shear force", GridLines -> Automatic, Frame -> True]
Add Comment
Please, Sign In to add comment