How to compute Lie derivative?

50 views
Skip to first unread message

Narheem

unread,
Mar 23, 2016, 3:15:40 PM3/23/16
to sympy

Hi;

Could anyone help me to compute the lie derivative of the function h:R^3-->R with respect to the vector-valued function f:R^5-->R^3 below?

f(x,y,L,u,v) = [x + u;
y + v;
L]

and

h(x,y,L) = sqrt((y-x)^2 + (L)^2)
 

Thank you in advance.

import sympy as sym

x
, y, L, u , v = sym.symbols('x y L u v')
X
= sym.Matrix([[x],[y], [L], [u], [v]])

# f(x,y,L,u,v) : R^5-->R^3
f
= sym.Matrix([[ x + u], [ y + v ], [L]])

# h(x,y,L) : R^3-->R^1
h
= sym.Matrix([[ sym.sqrt(L**2 + (y - x)**2) ]])

# L1hf : first-order lie derivative of h wrt f
L1hf
= sym.diffgeom.LieDerivative(f,h) # ???
Enter code here...


Francesco Bonazzi

unread,
Mar 26, 2016, 6:17:34 AM3/26/16
to sympy
You have to declare variables as sympy.diffgeom objects.

Narheem

unread,
Mar 27, 2016, 3:15:15 AM3/27/16
to sympy
Thank you for reply.
I'm a python newbie; could you tell me how i can do that? Could you provide a piece of code, please?
Reply all
Reply to author
Forward
0 new messages