by using Biot Savart Law, the calculation is very terrible. since it involve the cubic inverse distance. However, using vector potential is a way to make an analytic solution. first in cylindrical coordinate, the current density is:
the vector potential, without loss of generality, we set the field point on x-z plane and the vector potential is pointing direction.
Oh, shit, i am tired on typing equation by Latex. anyway,
the finial result can be obtained in J.D. Jackson’s book. and it take the form of Elliptic Integral.
where K(m) is the complete elliptic integral of first kind, and E(m) is the complete elliptic integral of second kind.
and using the derivative properties of elliptic integral, we can have the magnetic field in analytic form. Here is the PDF for the detail calculation. Field of Single Coil