using Odeint to solve two first-order differential equations with a vector as input
<p>I have a system of two differential equations:</p>

<ol>
<li><code>dri/dt=tan(al)</code></li>
<li><code>dal/dt=(vz-C_alz)/C_aln</code></li>
</ol>

<p>with <code>vz</code> is as known as a expression which only depends on <code>l</code>, <code>C_alz</code> and <code>C_aln</code> are two expressions of variable <code>ri</code> and <code>al</code> (These mathematical expressions are showed in the code below). Now i want to use Odeint in python to solve these two differential equations with two known initial value <code>ri(0)=2.5, al(0)=0.1</code>, and get <code>ri(l)</code> and <code>al(l)</code> in range of <code>l</code>[0, 36, 100]`</p>

<pre><code>from sympy import sqrt, sin, cos, tan, atan
import matplotlib.pyplot as pl
import numpy as np
from scipy.integrate import odeint

def func(w,l):
    ri, al = w    
    C_aln= 0.0240566430653894*ri*sin(al + 11) - 3.8*sqrt((-sin(al + 11) + 1)/(1 + 3.8*sqrt(2)/ri))*(-ri**2/2401 + 1)*cos(al + 11)/(-sin(al + 11) + 1)
    C_alz= -484*ri**2/1097257 + (-0.00633069554352353*ri*sqrt((-sin(al + 11) + 1)/(1 + 3.8*sqrt(2)/ri)) - 0.0240566430653894*cos(al + 11) + 14.44*sqrt(2)*sqrt((-sin(al + 11) + 1)/(1 + 3.8*sqrt(2)/ri))*(-ri**2/2401 + 1)/(ri**2*(1 + 3.8*sqrt(2)/ri)))*tan(al) + 1
    vz=(-0.00420681454754192*l**2 + 0.180893025544303*l - 0.960117265980565)*(-0.00633069554352353*sqrt((sin(atan(0.00420681454754192*l**2 - 0.180893025544303*l + 0.960117265980565) - 11) + 1)/(1 + 3.8*sqrt(2)/(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417)))*(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417) + 14.44*sqrt(2)*sqrt((sin(atan(0.00420681454754192*l**2 - 0.180893025544303*l + 0.960117265980565) - 11) + 1)/(1 + 3.8*sqrt(2)/(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417)))*(-(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417)**2/2401 + 1)/((1 + 3.8*sqrt(2)/(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417))*(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417)**2) - 0.0240566430653894*cos(atan(0.00420681454754192*l**2 - 0.180893025544303*l + 0.960117265980565) - 11)) - 484*(-0.00140227151584731*l**3 + 0.0904465127721514*l**2 - 0.960117265980565*l + 5.26992086596417)**2/1097257 + 1
    f=[tan(al), (vz-C_alz)/C_aln]
    return f

init = [2.5, 0.1]
l = np.linspace(0,36,100)
sol=odeint(func, init, l)
pl.figure(1)
pl.plot(l, sol[:,0], color='b')
pl.legend()
pl.show()
</code></pre>

<p>My problems are: </p>

<p>only the first three numerical value of <code>ri</code> can be calculated, the other value are zero.</p>

<p>at the same time I get a error message:</p>

<pre><code>Excess work done on this call (perhaps wrong Dfun type).
Run with full_output = 1 to get quantitative information.
</code></pre>

<p>anybody can answer my questions:</p>

<ol>
<li>have Iused the odeint in code correctly ?(I am quite sure the mathematical
expressions are correct)</li>
<li>what is wrong with my calculated result and graphic, how  can I make the output not full? I have tried to change the parameter of odeint, for example change mxstep, but it doesn't work.</li>
</ol>