1
$\begingroup$

How can I automatically obtain the characteristic equation of a second-order differential equation given any expression?

Assuming a second-order differential equation is given as follows:

x''[t] + x'[t] + 16 x[t] == 0
$\endgroup$

1 Answer 1

3
$\begingroup$

Your equation has wrong syntax. x^\[Prime]\[Prime]) should be written like: x'' (not back ticks and no superscript). Then we can get the characteristic equation by:

eq = x''[t] + Derivative[1][x][t] + 16 x[t] == 0;
eq /. {x[t] -> 1, x'[t] -> x, x''[t] -> x^2}

16 + x + x^2 == 0
$\endgroup$
3
  • $\begingroup$ Sir, thank you for your answer! Your answer has helped me. And I have corrected my expression writing in the original problem. $\endgroup$
    – chen chen
    May 4 at 7:42
  • 2
    $\begingroup$ Or, if higher derivatives are present {x[t] -> 1, Derivative[n_][x][t] :> x^n} $\endgroup$
    – rhermans
    May 4 at 8:10
  • $\begingroup$ @rhermansr Yep, thanks for your inspired ideas. $\endgroup$
    – chen chen
    May 4 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.