EulerLagrange - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


JetCalculus[EulerLagrange] - calculate the Euler-Lagrange equations for a Lagrangian

Calling Sequences

     EulerLagrange(L)

     EulerLagrange(λ )

     EulerLagrange(ω)

Parameters

     L         - a function on a jet space defining the Lagrange function for a variational problem (single or multiple integral)

     λ         - a differential bi-form on a jet space defining the Lagrangian form for a variational problem (single or multiple integral)

     ω         - a differential bi-form of vertical degree > 0

 

Description

Examples

Description

• 

Let π:EM be a fiber bundle, with base dimension n and fiber dimension m and let πk:JkE  M  be the k-th jet bundle. Introduce local coordinates (xi, uα, uiα, uijα, ..., uij ℓα, ...) where, as usual, if s:ME is a section and σ=jksx:ME is the k-jet of s, then

uij  ℓασ = k sα xxi xixℓ    and 1ijℓ dimM.

A function L on JkE defines the action integral or fundamental integral,

Is = M Ljks dx1 dx2 dxn ,

for a k-th order multiple integral problem in the calculus of variations. The Euler-Lagrange equations EαL =0 are the system of m, 2kthorder partial differential equations for the extremals s of the action integral Is. The general formula for the components of the Euler-Lagrange operator are

EαL = L uαDiL uiα+DijL   uijα  +1k DijℓL        uijℓα,

where Di is the total derivative with respect to xi. In the special case of a single integral variational problem, this formula can be written as

 

EαL = L uαddxL u.α+d2dx2L   u..α  

while for a double integral problem, we have

 

EαL = L uαDxL uxα   DyL uyα+DxxL    uxxα + DxyL    uxyα + DyyL    uyyα .

See Gelfand and Fomin for an excellent introduction to the calculus of variations.

 

• 

For the first calling sequence, EulerLagrange(L) returns the list of functions E1L, E2L, ... , EmL on J2kE.

• 

The differential forms on the jet spaces JkE can be bi-graded by their horizontal and vertical/contact degree. A differential form of horizontal degree n and vertical degree 0 is called a Lagrangian form or Lagrangian bi-form. In terms of local coordinates on JkE, a Lagrangian bi-form λ can be expressed as

λ = L ( xi, uα, uiα, uijα, ..., uij  ℓα) Dx1 Dx2  Dxn .

The associated Euler-Lagrange form Eλ is a differential bi-form of horizontal degree n and vertical degree 1. It is defined in terms of the usual Euler-Lagrange expressions EαL by

Eλ = EαLΘα Dx1Dx2   Dxn    where    Θα = duα  uiα dxi

 For geometrical aspects of the calculus of variations, the representation of the Euler-Lagrange equations as the components of a differential bi-form is very useful.

• 

The third calling sequence EulerLagrange(ω) returns a list of m differential bi-forms of vertical degree 1 less than the vertical degree of ω. Here the partial derivatives with respect to the jets of dependent variables uij  α in the usual formula for the Euler-Lagrange operator acting on functions are replaced by interior products of the corresponding vector fields, that is,

Eαω =  ι αω Di   ι αiω +Dij  ιαijω   +1k Dijℓ  ιαij ℓ ω      where    ι αij denotes the interior product with the vector field             uijα

• 

 The command EulerLagrange is part of the DifferentialGeometry:-JetCalculus package.  It can be used in the form EulerLagrange(...) only after executing the commands with(DifferentialGeometry) and with(JetCalculus), but can always be used by executing DifferentialGeometry:-JetCalculus:-EulerLagrange(...).

Examples

withDifferentialGeometry:withJetCalculus:

 

Example 1.

Create a space of 1 independent variable and 3 dependent variables.

DGsetupt,u,v,w,E,2:

 

Define the standard Lagrangian L from mechanics as the difference between the kinetic and potential energy.

E > 

L12u12+v12+w12Vu,v,w

Lu122+v122+w122Vu,v,w

(2.1)

 

Calculate the Euler-Lagrange equations for L.

E > 

ELEulerLagrangeL

ELVuu1,1,Vvv1,1,Vww1,1

(2.2)

 

The convert/DGdiff command will change this output from jet space notation to standard differential equations notation.

E > 

convertEL,DGdiff

D1Vut,vt,wtut,t,D2Vut,vt,wtvt,t,D3Vut,vt,wtwt,t

(2.3)

 

Here are the same calculations done with differential forms.

E > 

λL&multDt

λu122+v122+w122Vu,v,wDt

(2.4)
E > 

EulerLagrangeλ

Vu+u1,1DtCu+Vv+v1,1DtCv+Vw+w1,1DtCw

(2.5)

 

Example 2.

Create a space of 1 independent variable and 1 dependent variable.

E > 

DGsetupx,u,E,2:

 

Calculate the Euler-Lagrange equations for an arbitrary second order Lagrangian.

E > 

L2Fx,u,u1,u1,1:

E > 

PDEtoolsdeclareFx,u,u1,u1,1,quiet

E > 

Eul1EulerLagrangeL2

Eul1FuFx,u1Fu,u1u1Fu1,u1u1,1Fu1,u1,1u1,1,1+Fx,x,u1,1+Fx,u,u1,1u1+Fx,u1,u1,1u1,1+Fx,u1,1,u1,1u1,1,1+Fu,u,u1,1u1+Fu,u1,u1,1u1,1+Fu,u1,1,u1,1u1,1,1+Fx,u,u1,1u1+Fu,u1,u1,1u1+Fu1,u1,u1,1u1,1+Fu1,u1,1,u1,1u1,1,1+Fu,u1,1+Fx,u1,u1,1u1,1+Fu,u1,1,u1,1u1+Fu1,u1,1,u1,1u1,1+Fu1,1,u1,1,u1,1u1,1,1+Fu1,u1,1+Fx,u1,1,u1,1u1,1,1+Fu1,1,u1,1u1,1,1,1

(2.6)

 

Compare with the usual formula for the Euler-Lagrange expression in terms of the total derivatives (calculated using TotalDiff) of the partial derivative of L with respect to the jet coordinates u0, u1, u1,1.

E > 

P0,P1,P2diffL2,u,diffL2,u1,diffL2,u1,1

P0,P1,P2Fu,Fu1,Fu1,1

(2.7)
E > 

Eul2P0TotalDiffP1,1+TotalDiffP2,1,1

Eul2FuFx,u1Fu,u1u1Fu1,u1u1,1Fu1,u1,1u1,1,1+Fx,x,u1,1+Fx,u,u1,1u1+Fx,u1,u1,1u1,1+Fx,u1,1,u1,1u1,1,1+Fu,u,u1,1u1+Fu,u1,u1,1u1,1+Fu,u1,1,u1,1u1,1,1+Fx,u,u1,1u1+Fu,u1,u1,1u1+Fu1,u1,u1,1u1,1+Fu1,u1,1,u1,1u1,1,1+Fu,u1,1+Fx,u1,u1,1u1,1+Fu,u1,1,u1,1u1+Fu1,u1,1,u1,1u1,1+Fu1,1,u1,1,u1,1u1,1,1+Fu1,u1,1+Fx,u1,1,u1,1u1,1,1+Fu1,1,u1,1u1,1,1,1

(2.8)
E > 

Eul2Eul11

0

(2.9)

 

Here are the same calculations again using an alternative jet space notation. See Preferences for details.

E > 

PreferencesJetNotation,JetNotation2

JetNotation1

(2.10)
E > 

DGsetupx,u,E,2:

 

Calculate the Euler-Lagrange equations for an arbitrary second order Lagrangian.

E > 

L2Fx,u0,u1,u2:

E > 

PDEtoolsdeclareFx,u,u1,u2,quiet

E > 

Eul1EulerLagrangeL2

Eul1Fu0Fx,u1Fu0,u1u1Fu1,u1u2Fu1,u2u3+Fx,x,u2+Fx,u0,u2u1+Fx,u1,u2u2+Fx,u2,u2u3+Fu0,u0,u2u1+Fu0,u1,u2u2+Fu0,u2,u2u3+Fx,u0,u2u1+Fu0,u1,u2u1+Fu1,u1,u2u2+Fu1,u2,u2u3+Fu0,u2+Fx,u1,u2u2+Fu0,u2,u2u1+Fu1,u2,u2u2+Fu2,u2,u2u3+Fu1,u2+Fx,u2,u2u3+Fu2,u2u4

(2.11)
E > 

PreferencesJetNotation,JetNotation1

JetNotation2

(2.12)
E > 

Example 3.

Create a space of 3 independent variables and 1 dependent variable. Derive the Laplace's equation from its variational principle.

E > 

DGsetupx,y,z,u,E,1:

E > 

L312u12+u22+u32

L3u122+u222+u322

(2.13)
E > 

E3EulerLagrangeL3

E3u1,1u2,2u3,3

(2.14)
E > 

convertE31,DGdiff

ux,xuy,yuz,z

(2.15)

 

Repeat this computation using differential forms.

E > 

λ3evalDGL3Dx&wDy&wDz

λ3u122+u222+u322DxDyDz

(2.16)
E > 

EulerLagrangeλ3

u1,1+u2,2+u3,3DxDyDzCu

(2.17)

 

Example 4.

Create a space of 3 independent variables and 3 dependent variables. Derive 3-dimensional Maxwell equations from the variational principle.

E > 

DGsetupx,y,t,A_x,A_y,A_t,M,1:

 

Define the Lagrangian.

M > 

L12A_t22+A_t2A_y312A_y3212A_t12+A_t1A_x312A_x32+12A_y12A_y1A_x2+12A_x22

L12A_t22+A_t2A_y312A_y3212A_t12+A_t1A_x312A_x32+12A_y12A_y1A_x2+12A_x22

(2.18)

 

Compute the Euler-Lagrange equations.

M > 

Maxwell1EulerLagrangeL

Maxwell1A_x2,2+A_y1,2A_t1,3+A_x3,3,A_x1,2A_y1,1A_t2,3+A_y3,3,A_t1,1A_x1,3+A_t2,2A_y2,3

(2.19)

 

Change notation to improve readability.

M > 

PDEtoolsdeclarequiet

M > 

Maxwell2mapconvert,Maxwell1,DGdiff

Maxwell2A_xy,y+A_yx,yA_tt,x+A_xt,t,A_xx,yA_yx,xA_tt,y+A_yt,t,A_tx,xA_xt,x+A_ty,yA_yt,y

(2.20)

Maxwell2:=A_xy,y+A_yx,y+A_xt,tA_tt,x,A_xx,yA_yx,x+A_yt,tA_tt,y,A_xt,x+A_tx,xA_yt,y+A_ty,y

 

Example 5.

In this example we apply the Euler-Lagrange operator to some contact forms. We start with the case of 1 independent variable and 1 dependent variable.

M > 

DGsetupx,u,E,3:

 

First we try a form ω1 of vertical degree 1.

E > 

ω1evalDGaxCu+bxCu1+cxCu1,1+dxCu1,1,1

ω1axCu+bxCu1+cxCu1,1+dxCu1,1,1

(2.21)
E > 

EulerLagrangeω1

axbx+cx,xdx,x,x

(2.22)

 

Try a form ω2 of vertical degree 2.

E > 

ω2evalDGaxCu&wCu1+bxCu&wCu1,1+cxCu1&wCu1,1

ω2axCuCu1+bxCuCu1,1+cxCu1Cu1,1

(2.23)
E > 

EulForm1EulerLagrangeω2

EulForm1bx,x+axCucx,x+2bx2axCu13cxCu1,12cxCu1,1,1

(2.24)

 

Here is the explicit formula for computing EulerLagrange(omega2).

E > 

P0HookD_u,ω2;P1HookD_u1,ω2;P2HookD_u1,1,ω2

P0axCu1+bxCu1,1

P1axCu+cxCu1,1

P2bxCucxCu1

(2.25)
E > 

EulForm2evalDGP0TotalDiffP1,1+TotalDiffP2,1,1

EulForm2bx,x+axCucx,x+2bx2axCu13cxCu1,12cxCu1,1,1

(2.26)
E > 

EulForm2&minusEulForm11

0Cu

(2.27)

 

Now we compute some simple examples in the case of 2 independent variables and 2 dependent variables.

E > 

DGsetupx,y,u,v,E,3:

 

Try a form ω3 of vertical degree 1.

E > 

ω3evalDGax,yCu+bx,yCv+cx,yCu1+dx,yCu2+ex,yCv1+fx,yCv2

ω3ax,yCu+bx,yCv+cx,yCu1+dx,yCu2+ex,yCv1+fx,yCv2

(2.28)
E > 

EulerLagrangeω3

ax,ycxdy,bx,yexfy

(2.29)

 

Try a form ω4 of vertical degree 2.

E > 

ω4evalDGax,yCu&wCv+bx,yCu1&wCv2

ω4ax,yCuCv+bx,yCu1Cv2

(2.30)
E > 

EulerLagrangeω4

ax,yCvbxCv2bx,yCv1,2,ax,yCu+byCu1+bx,yCu1,2

(2.31)

 

Try a form ω5 of vertical degree 3.

E > 

ω5evalDGax,yCu&wCu1&wCv1

ω5ax,yCuCu1Cv1

(2.32)
E > 

EulerLagrangeω5

axCuCv1+ax,yCuCv1,1+2ax,yCu1Cv1,axCuCu1ax,yCuCu1,1

(2.33)

 

The Euler-Lagrange operator of the horizontal exterior derivative of any form vanishes, for example:

E > 

ηHorizontalExteriorDerivativeu2,3Cu1&wCv2

ηu1,2,3DxCu1Cv2+u2,3DxCu1Cv1,2u2,3DxCv2Cu1,1+u2,2,3DyCu1Cv2+u2,3DyCu1Cv2,2u2,3DyCv2Cu1,2

(2.34)
E > 

EulerLagrangeη

0DxCu,0DxCu

(2.35)

See Also

DifferentialGeometry

JetCalculus

Prolong

Transformation

Pullback

DifferentialEquationData