here is a question:

http://i25.tinypic.com/fc8rqr.jpg

there is endless cylinder i which we only see its crossection in the photo.

its radius is [tex]R_1[] a distance d from the center a cylinder with radius [tex]R_2[]

along the cylinder flows current I in a uniform way inside the page(X).

1.what is the magnetic field in x>0 region?

2.what is the magnetic field in (0,$\displaystyle R_1$)?

i tried to solve it by amperes law

$\displaystyle \oint \vec{B}\vec{dl}=\mu_0 I$

0<r<d

$\displaystyle \oint \vec{B}\vec{dl}=\mu_0 I\\$

$\displaystyle I_0=I\frac{\pi r^2}{\pi R_1^2}=I\frac{ r^2}{R_1^2}\\$

$\displaystyle B =\mu_0 I\frac{ r^2}{R_1^2 2\pi r}\\$

have i done the first region correctly