I have a system of differential equations. I solve it with numerical dsolve:
sol := dsolve({First, Fourth, Second, Third, iA(0) = 0, iB(0) = 0, theta(0) = 0, (D(theta))(0) = 0}, numeric, vars,maxfun=100000):
First, Second, Third, Fourth --- are differential equations, then there are initail conditions, vars --- is a set of variables (in respect of time) I want to get. maxfun - is maximum number of evaluations made by dsolve to calculate derivatives.
So, I need to retrieve maximum time value, where vars are calculated. I tried setting range parameter but it takes too long to solve (and I need to call dsolve for a hundred or even more times). With maxfun=1e5 I get result in three or four seconds.
Any tricks can be done here? Maybe there is a way to set timestep between evaluations of derivatives?
Thanks in advance and sorry for my broken English.