#Solution of Problem Set 2.6 Problem no 18

reset()
#resets the initial values
x = var('x')
y = function ('y',x)
ics=[1,3,-4]
eq=x^2*(diff(y,x,2 ))+3*x*diff(y,x)+ y==0
show(eq)

print " The General solution of the above equation is "
p=desolve(eq,y,show_method=True)
show(p[0])
print " The method of solution is",p[1]
print
print "The Particular solution for the above equation when"
print
print "y(",ics[0],") =",ics[1],"and Dy(",ics[0],") =", ics[2] ,
print "is"
print
p=desolve(eq,y,ics)
print "y =" ,p
print
plot(p,(x,0.15,1.2))

SageDays/Kreyszig-2.6-18 (last edited 2010-08-12 10:01:34 by RahulPalkar)