Hey guys, I am unable to make my program get a result of w as a function of EI and L
syms w x EI A B C D Lx0=0;eqns = [EI*diff(w,3)==heaviside(x-x0)+A, EI*diff(w,2)==heaviside(x-x0)*(x-x0)+A*x+B, EI*diff(w)==heaviside(x-x0)*(x-x0)^2/2+A*x^2/2+B*x+C, EI*w==heaviside(x-x0)*(x-x0)^3/6+A*x^3/6+B*x^2/2+C*x+D, w(x==L/2)==0, diff(w(x==-L/2))==0];ctes = [A B C D];[A, B, C, D]=solve(eqns, ctes);w(x==0)
This is what I've coded. As you can see it is 4 equations and 2 boundary conditions (The 2 last ones) I want it to solve the 4 constants A, B, C and D, so I get the full result of the function w(x) with those Constants solved and then finally evaluate w for x=0 (in this case). But it is giving me this result:
ans = [ empty sym ]
I am pretty sure it is something about syntax in the equations definition, but I can't find it. Could you give it a look guys? I would really appreciate. This example should give the following solution w(x=0) = L^3/(192*EI)
Thank you very much!
Best Answer