detools::transform
-- change
of variables for differential equationsdetools::transform
performs variable transformations in
differential equations.
detools::transform(de, indl, depl, mode, <, NewVars = varl> <ChangeOfVars
= cl>)
de |
- | the differential equation: an expression. |
indl |
- | the independent variable(s): a list of (indexed) identifiers. |
depl |
- | the dependent variable(s): a list of (indexed) identifiers. |
mode |
- | transformation mode: either the string
Ïndep" or "Dep" . |
NewVars |
- | lists the names of the new variables. |
ChangeOfVars |
- | defines the new variables. |
an expression.
detools::transform
performs variable transformations
in differential equations. It represents only an interface to methods
implemented in domains in Cat::DifferentialFunction
. So
the allowed transformations depend on the type of the differential
equation. For example, for linear equations only linear transformations
of either the dependent or the independent variables are
permitted.We transform the independent variables in a simple linear differential expression. Note that the new variables are given as linear functions of the old ones.
>> detools::transform(u([x]) + u([y]), [x, y], [u], NewVars = [X, Y], ChangeOfVars = [X = x + y, Y = x - y], "Indep")
2 u([X])
Now we transform the dependent variable. Here the old variable must be given as a linear function of the new one.
>> detools::transform(u([x]) + u([y]), [x, y], [u], NewVars = [U], ChangeOfVars = [u=3*U], "Dep")
3 U([x]) + 3 U([y])