MATLAB: Derive an equation from a set of roots derivepolynomial the question asks me to set x as a symbolic variable then asks me to derive a equation of a polynomial with the roots x=-2 ,x=-.5, x=2, and x=4.5 Best Answer syms x r = [-2 , -.5 2 4.5]; % roots f = (x-r(1))*(x-r(2))*(x-r(3))*(x-r(4)) ;p = expand(f) Related SolutionsMATLAB: Positive roots only for cubic eqn ROOTS = roots([1, -5, -2, 24]); Wanted = ROOTS(ROOTS > 0) MATLAB: How to derive polynomial using given roots v = [-2 -0.5 2 4.5]x= sym('x')yourpoly = expand(prod(x-v)) Related QuestionSolve nonlinear equationsInteresting question: construct a polynomial and then evaluate itDerivative of symbolic funtion at a specific valueHow to represent the roots of a polynomial on a graph
Best Answer