In this example we use the package IntroToSymmetry.m to work out the point groups of the following form of the Fokker-Planck equation, 

Uxx+xUx-Ut=0.

The SolveDeterminingEquations function finds the translational invariance in t and U as well as the dilational invariance in U. Additional groups depending on exponentials have to be found by simplifying the determining equations and using Mathematica built-in functions to solve the simplified set.

Clear all symbols in the current context.

ClearAll[Evaluate[Context[]<>"*"]]

First read in the package which is located in User Home Folder/Library/Mathematica/Applications/SymmetryAnalysis.

Needs["SymmetryAnalysis`IntroToSymmetry`"]

Enter the input equation as a string. Don't include the == 0 at the end.

fpequation=
"D[u[x,t],x,x]+x*D[u[x,t],x]-D[u[x,t],t]";

The function u[x,t] is a solution of the equation and this constraint must be applied in the form of a rule to the invariance condition. Be careful to check signs.

rulesarray=
{"D[u[x,t],t]->D[u[x,t],x,x]+x*D[u[x,t],x]"};

Enter the list of independent variables.

independentvariables={"x","t"};

Enter the list of dependent variables.

dependentvariables={"u"};

Enter the list of function and/or constant names that must be preserved when the equation is converted to generic y1[x1,x2] variables.

frozennames={""};

Enter the maximum derivative order of the input equation(s).

p=2;

The maximum derivative order that the infinitesimals are assumed to depend on is specified by the input parameter r. This parameter is only nonzero when the user is looking for Lie contact groups or Lie-Bäcklund groups. For the usual case where one is searching for point groups set r=0.

r=0;

When searching for Lie-Bäcklund groups (r=1 or greater) one can, without loss of generality, leave the independent variables untransformed. The corresponding infinitesimals (the xse's) are set to zero by setting xseon=0. If one is searching for point groups then set xseon=1. The choice xseon=1 is also an option when looking for Lie-Bäcklund groups and this can be useful when looking for contact symmetries.

xseon=1;

When searching for Lie-Bäcklund groups it is necessary to differentiate the input equation with respect to each of the independent variables producing derivatives of order p+r. These higher order differential consequences are appended to the set of rules applied to the invariance condition. This process is carried out automatically when internalrules=1. For point groups the equation or equation system is the only rule or set of rules needed and one sets internalrules=0.

internalrules=0;

Now work out the determining equations of the Lie point group that leaves the equation  invariant. The output is available as a table of strings called zdeterminingequations.

Timing[FindDeterminingEquations[independentvariables,dependentvariables,frozennames,p,r,xseon,fpequation,rulesarray,internalrules]]

equationgenericvariables

invarconditiontable

ztableofrules

Here are the determining equations expressed in terms of z-variables. The equations in the table can be distinguished by the == 0 at the end of each item.

zdeterminingequations

How many determining equations are there?

Length[zdeterminingequations]

Now solve the determining equations in terms of multivariable polynomials of a selected order. The Mathematica function Solve uses Gaussian elimination to solve a large number of linear equations for the polynomial coefficients.The time roughly follows

time/timeref=((number of equations)/(number of equationsref))^n

where the exponent is between 2.4 and 2.7.The Mathematica function Timing outputs the time required for the SolveDeterminingEquations function to execute.

Timing[SolveDeterminingEquations[independentvariables,dependentvariables,r,xseon,
zdeterminingequations,order=5]]

Column[infinitesimalgroups]

This three-parameter group is correct but very incomplete. We need to try to simplify the determining equations.

Clear[xse1,xse2,eta1]

zdeterminingequationsexpressions=ToExpression[zdeterminingequations];

Column[zdeterminingequationsexpressions,{Left,Below}]

zdeterminingequationssimplified1=zdeterminingequationsexpressions/.
{D[xse1[z1,z2,z3],z3]->0,
D[xse1[z1,z2,z3],z1,z3]->0,
D[xse1[z1,z2,z3],z2,z3]->0,
D[xse1[z1,z2,z3],z3,z3]->0,
D[xse2[z1,z2,z3],z1]->0,
D[xse2[z1,z2,z3],z1,z1]->0,
D[xse2[z1,z2,z3],z2,z1]->0,
D[xse2[z1,z2,z3],z3,z1]->0,
D[xse2[z1,z2,z3],z3]->0,
D[xse2[z1,z2,z3],z1,z3]->0,
D[xse2[z1,z2,z3],z2,z3]->0,
D[xse2[z1,z2,z3],z3,z3]->0};

Column[zdeterminingequationssimplified1,{Left,Below}]

This system has the following solutions.

{xse1,xse2,eta1}={Exp[-t], 0, 0}
{xse1,xse2,eta1}={Exp[t], 0, -xuExp[t]}
{xse1,xse2,eta1}={-(x/2)Exp[2t], -(1/2)Exp[2t], (u/2)Exp[2t]+(ux^2/2)Exp[2t]}
{xse1,xse2,eta1}={(x/2)Exp[-2t], -(1/2)Exp[-2t], 0}

From the third to last equation we can see that the linearity implies that any solution of the Fokker-Planck equation can be added to eta1. Set up the list of infinitesimal groups.

infinitesimalgroups

infinitesimalgroupsfinal={{{0,1},{0}},{{0,0},{u}},{{Exp[-t],0},{0}},{{Exp[t],0},{-x*u*Exp[t]}},{{-(x/2)*Exp[2*t],-(1/2)*Exp[2*t]},{(u/2)*Exp[2*t]+(u*x^2/2)*Exp[2*t]}},{{(x/2)*Exp[-2*t],-(1/2)*Exp[-2*t]},{0}}}

The equation is invariant under the following six parameter group. In additional the equation admits an infinite dimensional group corresponding to a translation of the dependent variable by any solution of the equation.

Column[infinitesimalgroupsfinal]

Check the solution in the determining equations.

Clear[xse1,xse2,eta1]

xse1[z1_,z2_,z3_]:=a12*Exp[-z2]+a13*Exp[z2]-a14*(1/2)*z1*Exp[2*z2]+a15*(1/2)*z1*Exp[-2*z2]

xse2[z1_,z2_,z3_]:=a20-a14*(1/2)*Exp[2*z2]-a15*(1/2)*Exp[-2*z2]

eta1[z1_,z2_,z3_]:=b21*z3-a13*z1*z3*Exp[z2]+a14*((1/2)*z3*Exp[2*z2]+(1/2)*z1^2*z3*Exp[2*z2])

Simplify[ToExpression[zdeterminingequations]]

MakeCommutatorTable[independentvariables, dependentvariables,infinitesimalgroupsfinal]

MatrixForm[Simplify[commutatortable]]

MaxMemoryUsed[ ]