See bvp4c() for boundary condition problems. Something like this
EI = 1.3e7;
q0 = 30e3;
T = 20e3;
L = 4;
xmesh = linspace(0, L, 100);
odeFun = @(x, y) [y(2);
1./EI*(1+y(2).^2).^(3/2)*(1/6*q0*(L*x-x.^3/L)+T*y(1))];
bcFun = @(yl, yr) [yl(1)-0;
yr(1)-0];
guess = bvpinit(xmesh, [0; 0]);
y_sol = bvp4c(odeFun, bcFun, guess);
plot(y_sol.x, y_sol.y);
legend({'$y$', '$\dot{y}$'}, 'Location', 'best', 'FontSize', 16, 'Interpreter', 'latex');
Best Answer