MATLAB: Differentiated system of equations with input at one of the variables

differentiated system of equations

Hello, i have an expression which i need to perform derivatives on it so every derivative will be stored as an expression , and then i need to solve a system of equations where every expression equals zero, with x=1 as an input.
i have tried to write down a code,pseudo matlab code to demonstrate. how can i accomplish this solving ?
maybe we could use
******************
syms y(t) a
eqn = diff(y,t,2) == a*y;
ySol(t) = dsolve(eqn)
***********************
Thanks
sym a,b,c,d,x
y=a*x^3+b*x^2+c*x+d*sin(x)
y_1=diff(y,x)
y_2=diff(y,x,2)
y_3=diff(y,x,3)
x=1
sol = solve(y_1,y_2,y_3)

Best Answer

syms a b c d
x=1;
f_1=a*x^3+b*x^2+c*x+d;
f_2=3*a*x^2+2*b*x+c;
f_3=6*a*x+2*b;
f_4=6*a;
eqns=[f_1==0,f_2==0,f_3==0,f_4==0];
vars=[a b c d ];
[sol_a,sol_b,sol_c,sol_d]=solve(eqns,vars);
Best wishes
Torsten.