Re: Simplifying a second order eq. system

• To: mathgroup at smc.vnet.net
• Subject: [mg45970] Re: [mg45928] Simplifying a second order eq. system
• From: Daniel Lichtblau <danl at wolfram.com>
• Date: Sat, 31 Jan 2004 05:20:33 -0500 (EST)
• References: <200401300915.EAA04894@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Gunnar Lindenblatt wrote:
> Hi,
>
> I just switched from another system to Mathematica
> 5. While all "complicated" operations (like importing Wave-Files, filtering,
> parameter fitting, plotting) just work fine, I still have problems with the
> "basics" like solving or even simplifying equations:
>
> For example, to get the telegraph equation by self-induction and capacitive
> coupling:
>
> (One can solve this problem on the space of a postage stamp...)
>
> In[1] := Remove["Global`*"]
>
> In[2] := myEqn1 = -Dt[u,x] == r i + l Dt[i,t]
>
> In[3] := myEqn2 = -Dt[i,x] == s u + c Dt[u,t]
>
>
>
> Direct approach: Using "Solve"
>
> In[4] := Solve[{myEqn1,myEqn2}, {Dt[u,{x,2}]}]
>
> results an empty set of solutions:
>
> {{}}
>
>
>
> Second try: Using "Reduce"
>
> In[5] := Reduce[{myEqn1,myEqn2}, {Dt[u,{x,2}]}]
>
> results:
>
> Reduce::nsmet: This system cannot be solved with the methods available to
> Reduce.
>
> Third try: Using "Eliminate"
>
> In[6] := Eliminate[{myEqn1,myEqn2}, {Dt[i,x],Dt[i,t]}]
>
> results:
>
> True
>
> That's fine! However, it does not really help me...
>
>
>
> (By the way, the result should be:
>
> Dt[u,{x,2}]== r s u + (r c + l s) Dt[u,t] + l c Dt[u,{t,2}])
>
> Any ideas? -- Perhaps this problem is too simple for Mathematica, so it
> rejects any help ;-)
>
> - Gunnar

This is a bit unclear to me (not to mention out of my computational
areas). I assume {x,t} are independent variables, ans {r,s,l,c} are
constants? If so, you then need to infer sufficiently many "differential
conditions" to reduce your expression. As I have no code to do that
automatically, I figured extending by all first derivatives should suffice.

I define a total derivative that automatically regards {r,s,l,c} as
constants.

myDt[a___] := Dt[a, Constants->{r,l,s,c}]

I then use your two differential polynomials, as well as two more that
enforce that {x,t} are independent.

derivexprs = {-myDt[u[x,t],x] - (r*i[x,t] + l*myDt[i[x,t],t]),
-myDt[i[x,t],x] - (s*u[x,t] + c*myDt[u[x,t],t]),
myDt[x,t], myDt[t,x]}

Now I extend by all first derivatives with respect to x and t.

prolongedderivexprs = Join[derivexprs,myDt[derivexprs,x],myDt[derivexprs,t]]

Next I find the variables, remove and reorder those that are (partial)
derivatives, remove total derivatives, and finally put them all back
together reordered in what I hope will be a useful manner.

sortedderivvars = Sort[derivvars,
totalderivvars = Cases[vars, _Dt];
remainingvars = Complement[vars, Join[derivvars,totalderivvars]];

sortedvars = Join[sortedderivvars,totalderivvars,remainingvars];

Next I form a Groebner basis of the set of polynomials and variables.
Strictly speaking this is not a differential Groebner basis, and it
performs no differentiations in the computation. That was why I earlier
extended by first derivatives.

diffgb = GroebnerBasis[prolongedderivexprs,sortedvars];

Finally we reduce the given expression according to this basis.

InputForm[Last[PolynomialReduce[myDt[u[x,t],{x,2}], diffgb, sortedvars]]]

Out[18]//InputForm=
r*s*u[x, t] + c*r*Derivative[0, 1][u][x, t] + l*s*Derivative[0, 1][u][x,
t] +
c*l*Derivative[0, 2][u][x, t]

Not really understanding the issues, I probably made this substantially
more complicated than necessary. But it may give an idea of how you
might proceed, particularly in cases where "by hand" methods do not suffice.

Daniel Lichtblau
Wolfram Research

```

• Prev by Date: AW: Re: Nasty bug in Integrate (version 5.0)
• Next by Date: Re: Re: Nasty bug in Integrate (version 5.0)
• Previous by thread: Re: Simplifying a second order eq. system tests=PRIORITY_NO_NAME version=2.55
• Next by thread: one liner for a function?