MathGroup Archive 2000

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Mathematica won't solve simple diff. eqn.--Correction

  • To: mathgroup at smc.vnet.net
  • Subject: [mg24754] Re: Mathematica won't solve simple diff. eqn.--Correction
  • From: Jens-Peer Kuska <kuska at informatik.uni-leipzig.de>
  • Date: Wed, 9 Aug 2000 02:32:18 -0400 (EDT)
  • Organization: Universitaet Leipzig
  • References: <399049D9.F4989AC1@sandia.gov>
  • Sender: owner-wri-mathgroup at wolfram.com

Hi,

because the system is singular and Mathematica does not 
use multiple derivatives of the equations to resolve
the singular matrix. You can do it by your self and with
the help of Mathematica

In[]:=deqn = {-4 i1'[t] + 8 i2'[t] - 25 i1[t] + 20 i2[t] == -80 + 
        720 E^(-5 t), -4 i1'[t] + 8 i2'[t] - 10 i1[t] + 40 i2[t] == 
      640 E^(-5 t)};

In[]:= deqn1 = Eliminate[
                 Join[deqn, Map[D[#, t] & , deqn, {2}]], {i2[t], i2'[t],
i2''[t]}]

Out[]:=
16 - 64/E^(5*t) - i1'[t] == 4*i1[t]

and the equations can be decoupled. The solution is obtained by

In[]:=s1=DSolve[deqn1, i1[t], t]

Out[]={{i1[t] -> (4*(16 + E^(5*t)))/E^(5*t) + C[1]/E^(4*t)}}

and similar for i2[t]

In[]:=deqn2 = Eliminate[
                Join[deqn, Map[D[#, t] & , deqn, {2}]], {i1[t], i1'[t],
i1''[t]}];
      s2=DSolve[deqn2, i2[t], t] /. C[1] -> C[2]

Out[]={{i2[t] -> (-52 + E^(5*t))/E^(5*t) + C[2]/E^(4*t)}}

It remains to determine the constants C[1] and C[2].

This is done by

In[]:=mysol = Flatten[Join[s1, s2]];
      cceqn=deqn /. Flatten[{#, D[#, t]} & /@ mysol] // FullSimplify;
      Solve[cceqn, {C[1], C[2]}]


Out[]={{C[1] -> (-4*C[2])/3}}

In[]:= mysol /. Flatten[ccsol] // InputForm

Out[]={i1[t] -> (4*(16 + E^(5*t)))/E^(5*t) - (4*C[2])/(3*E^(4*t)), 
       i2[t] -> (-52 + E^(5*t))/E^(5*t) + C[2]/E^(4*t)}


Since the two equations are linear depend you have  only one constant
for the initial conditions. How ever for the general case that you give
initial conditions for i1[t0] *and* i2[t0] no solution exists and
that is exactly what Mathematica reports when it returns the 
original equations in NDSolve[]. 

Hope that helps
  Jens

"Christopher R. Carlen" wrote:
> 
> I made a mistake in my original article, the relevant portion of which
> is:
> 
> "Christopher R. Carlen" wrote:
> >
> > Mathematica 4.0 and linear constant coefficient differential equations:
> >
> > I have the following system:
> >
> > -4 i1'[t] + 8 i2'[t] - 25 i1[t] + 20 i2[t] == 0
> > -4 i1'[t] + 8 i2'[t] - 10 i1[t] + 40 i2[t] == 0
> > i1[0]==0
> > i2[0]==0
> >
> > Which when I try to solve with DSolve, it fails.
> > The problem is that there is a solution to the above system, which I
> > have verified.  That solution is:
> >
> > i1[t_] = 4 + 64 E^(-5 t) - 68 E^(-4 t)
> > i2[t_] = 1 - 52 E^(-5 t) + 51 E^(-4 t)
> 
> The solutions shown are to the inhomogeneous system:
> 
> -4 i1'[t] + 8 i2'[t] - 25 i1[t] + 20 i2[t] == -80 + 720 E^(-5 t)
> -4 i1'[t] + 8 i2'[t] - 10 i1[t] + 40 i2[t] == 640 E^(-5 t)
> 
> When I do:
> 
> In:
> 
> DSolve[{-4 i1'[t] + 8 i2'[t] - 25 i1[t] + 20 i2[t] == -80 + 720 E^(-5
> t),
>  -4 i1'[t] + 8 i2'[t] - 10 i1[t] + 40 i2[t] == 640 E^(-5 t)}, {i1, i2},
> t ]
> 
> Mathematica4.0 simply outputs the DSolve statement with no result.
> 
> When I do:
> 
> In:
> 
> i1 = 4 + 64 Exp[-5 t] - 68 Exp[-4 t]
> i2 = 1 - 52 Exp[-5t] + 51 Exp[-4 t]
> 
> Simplify[ -4 D[i1, t] + 8 D[i2, t] - 25 i1 + 20 i2 == -80 + 720 Exp[-5
> t] ]
> Simplify[ -4 D[i1, t] + 8 D[i2, t] - 10 i1 + 40 i2 == 640 Exp[-5 t] ]
> 
> Out:
> 
> true
> true
> 
> indicates that the solutions are valid.
> 
> The question is then:
> 
> Why can't Mathematica solve the system?


  • Prev by Date: Re: Mathematica won't solve simple diff. eqn. system
  • Next by Date: RE: Package naming
  • Previous by thread: Re: Mathematica won't solve simple diff. eqn.--Correction
  • Next by thread: Re: Mathematica won't solve simple diff. eqn.--Correction