



According to the Biot-Savart law, magnetic field dB at point P due to current element idl in the above diagram is given by:
B = ∫(μo/4π)idlcosθ /x2 = (μo/4π)∫idlcosθ /x2……………….(i)
dB = (μo/4π)idl sin(90°-θ) /x2 = (μo/4π)idlcosθ /x2
Considering triangle ABN, cosθ = AN/dl Hence, AN = dl cosθ
Considering triangle ANP: sin(dθ)˜dθ = AN/x Hence, AN = x(dθ)
Using the value of AN from the above 2 equations:
dlcosθ = xdθ……………………..(ii)
Considering triangle AOP:cosθ = r/x
x = r/cosθ…………………(iii)
Using the values of dlcosθ from eq.(ii) and x from eq.(iii) in eq.(i):
B = ∫(μo/4π)ixdθ/x2 = ∫(μo/4π)idθ/x = ∫(μo/4π)i(cosθ)dx/r
B = (μo/4π)(sinθ2 + sinθ1)
For infinitely long wire (θ1 = 90° θ2 = 90°):The above equation becomes B = μoi/(2πr)
