what functionalDerivative returns is a 1*1 symfun, not a vector

3 次查看(过去 30 天)
Hi guys,
I am trying the codes
syms u(x) v(x)
H = u^2*diff(v,x)+v*diff(u,x,x);
D = functionalDerivative(H,[u v])
Actually, the D returned by functionalDerivative is a 1*1 symfun, but a 1 * 2 vector of symbolic functions.
So how to return a 1*2 vector?
Many thanks.

采纳的回答

Stephan
Stephan 2019-7-15
syms u(x) v(x)
H = u^2*diff(v,x)+v*diff(u,x,x);
D(1) = functionalDerivative(H,u)
D(2) = functionalDerivative(H,v)

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Formula Manipulation and Simplification 的更多信息

产品


版本

R2018b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by