In case of Electric field we used gauss’s law to calculate the electric field for highly symmetric charge distributions; a similar law exists in magnetism, it is ampere’s law its states that:
\(oint{overrightarrow{B}centerdot overrightarrow{dell }}={{mu }_{o}}{{I}_{enclosed}}\)
The left hand side of ampere’s law \(oint{(Bcos theta )dell }\) means the sum up of the component of magnetic field B along the closed path length \(dell\) . In order to apply ampere’s law we consider a symmetrical closed curve around the current carrying wire (amperian loop).
The right side of equation is the net current enclosed within the closed path\(oint{dell }\).