This is the definition of ic2 from 
http://www.math.utexas.edu/pipermail/maxima/2009/015655.html

  312 ic2(soln,xa,ya,dya):=
  313    block([programmode:true,backsubst:true,singsolve:true,temp,
%k2,%k1],
  314       noteqn(xa), noteqn(ya), noteqn(dya),
  315       boundtest('%k1,%k1), boundtest('%k2,%k2),
  316       temp: lhs(soln) - rhs(soln),
  317       temp: maplist(lambda([zz], subst(zz,soln)),
  318               solve([subst([xa,ya],soln), subst([dya,xa],
  319                        lhs(dya)=-subst(0,lhs(dya),diff(temp,lhs(xa)))
  320                                  /diff(temp,lhs(ya)))],
  321                     [%k1,%k2])),
  322       if length(temp)=1 then return(first(temp)) else return
(temp))$

so after some tests maxima substitutes initial conditions, solves for
constants %k1, %k2 and substitutes these %k1, %k2 into general
solution. I am not very skilled in Sage (yet) but I guess that it is
not necessary to use ic2 in definition od desolve in Sage, but this
stuff can be programmed within Sage.

And another realted topic could be [Maxima] Patch to make ic2 work
even with i.c. 'y(x)= (fwd)

http://www.math.utexas.edu/pipermail/maxima/2009/015655.html

I have not enought skill in Python, Sage, hg and related thinks. Is
there any person interested in the problem, which sould like to try
this?

Robert Marik


On 3 říj, 16:22, Marshall Hampton <[email protected]> wrote:
> Yes, the parsing of output from maxima is currently pretty messed up.
> I think its fair to say that symbolic ODEs are a real weak point in
> Sage right now.  I'm not sure when I will have enough time to devote
> to really fixing this; my main interest is in using them to teach and
> I am not an expert on the CAS side of things.
>
> One place on trac this is addressed 
> is:http://trac.sagemath.org/sage_trac/ticket/6479
>
> but I think we need someone to do a total redesign at some point.
>
> -Marshall Hampton
>
> On Oct 3, 7:14 am, David Joyner <[email protected]> wrote:
>
> > This is a known bug. Marshall and I tried to fix it during a SageDays in
> > Seattle but failed to figure out the magic in Robert Bradshaw's code
> > for desolve. I think it is "easy to fix for those who know how to fix it
> > easily", but that rules me out:-)
>
> > On Sat, Oct 3, 2009 at 3:30 AM, [email protected] <[email protected]> wrote:
>
> > > Dear sage users and developers
>
> > > trying to solve y''+4y=0  with initial conditions y(0)=0 and y'(0)=0
>
> > > y=function('y',x)
> > > eq=diff(y,x,2)+4*y==0
> > > desolve(eq,y,ics=[0,0,0])
>
> > > sage returns y(0)*cos(2*x)  and not 0
>
> > > What is wrong? The help for the desolve command shows the same
> > > behavior on slighhtly more complicated example. I think that if I
> > > state initial condition at 0, then y(0) is known and I can use this
> > > knowledge and simplify answer - in my case into 0
>
> > > Thanks
>
> > > Robert
>
>
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---

Reply via email to