This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.


Companion matrix of a linear homogeneous ordinary differential equation

MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.

MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.


ode::companionSystem(Ly, y(x), <R>)


ode::companionSystem(Ly, y(x)) returns the companion matrix associated to Ly. If the optional argument R is given, the elements of the matrix are in R.


Example 1

We compute the companion matrix of the following differential equation:

Ly := 4*x^2*diff(y(x),x$3)+diff(y(x),x$2)+4*x*diff(y(x),x)-y(x)

ode::companionSystem(Ly, y(x))



A linear homogeneous ordinary differential equation.


The dependent function of Ly.


A field of functions or numbers of characteristic zero, default is Dom::ExpressionField(normal).

Return Values

Object of type Dom::Matrix.

Was this topic helpful?