# Magnetic field due to a current

1. Feb 1, 2010

### fluidistic

1. The problem statement, all variables and given/known data
I set up myself to derive the formula of the magnetic field due to a current I carried by an infinite wire. At a point P situated at a distance d from the wire.

2. Relevant equations
Ampere's law and Biot-Savart's law.

3. The attempt at a solution
With Ampere's law, it's simple: $$\oint \vec B d\vec l = \mu _0 I$$, thus $$B=\frac{\mu _0 I}{2 \pi d}$$ and its direction is easy to figure out thanks to the right hand rule.
I'm having problems with Biot and Savart's law.
$$d\vec B =\frac{\mu _0}{4\pi} I d\vec l \times \frac{\vec r}{r^3}\Rightarrow \vec B=\frac{\mu _0}{4 \pi} \oint I d\vec l \times \frac{\vec r}{r^3}$$, thus $$B=\frac{\mu _0 I}{4 \pi d}$$. I don't see how I can get a factor 2 in this result, to make it coincide with the anterior result.

Aside question: If I understand well, an infinitesimal length dl of the wire contributes to the magnetic field only in an orthogonal plane to it, right? So that it doesn't contribute to points out of this plane, right?

Thanks for all.

2. Feb 1, 2010

### dacruick

How can you do a closed integral if the wire is from - infinity to + infinity. I think that there could be a factor of two also in that integral. because your wire is infinitely long, any point d could be said to be in the middle of the wire. So you would want to take the integral from -infinity to +infinity, which could be equal to twice the integral from 0 to infinity.

And I'm pretty sure the magnitude depends on the radial distance from the wire, and always acts orthogonal to that radial vector

3. Feb 1, 2010

### fluidistic

Because as I implied, I believe that the only part of the wire that contributes to the magnetic field at point P is the orthogonal projection of P into the wire. In other words, almost all the wire doesn't create the magnetic field at point P.
I wanted to know if I'm right on this.

I'm also sure of that! Look at my formula. The d is the distance from the wire to the point P.

4. Feb 1, 2010

### dacruick

if only one part of the wire contributes you shouldnt be doing an integral at all right?

5. Feb 1, 2010

### fluidistic

Hmm ok... I'm (very) confused.