On 5 říj, 23:14, calcp...@aol.com wrote:
> Wow, this sounds like a big bug. I will be using Sage quite a bit in a
> Calculus I and II lab in the Spring. Is this going to be huge problem?
Do not think that this will be huge problem. You cal allwayas use
Maxima instead Sage. In notebook you can use something like
y=function('y',x)
k1,k2=var('k1 k2')
x0,y0,y1=0,1,2 # initial conditions y(x0)=y0 and y'(x0)=y1
eq=diff(y,x,2)+3*diff(y,x)-4*y==exp(x)
A=desolve(eq,y)
sols_k=solve([y0==A.subs(x=x0),y1==diff(A,x).subs(x=x0)],
[k1,k2],solution_dict=True)
A=A.subs(k1=sols_k[0][k1]).subs(k2=sols_k[0][k2])
A
I do not know why this approach does not work in desolvers.py. I
understand that it is necessary to use from .... import ..... to get
functions like diff, solve, var, I have to deslare variables k1, k2,
but solve command was still not able to solve the system when located
in desolvers.py
btw: if we use desolve command, then konstants k1, k2 apper in Sage,
but these constants are not declared using var. Is it O.K? The user
may want to use k1 for his own purpouses ....
Robert Marik
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sage-support
URL: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---