A solenoid (coil) is an arrangement with a steel or iron core in shown in Fig; in which long conductor is coiled with numeral turns approximate to create a coil. The axial distance of conductor is far over the diameter of turns. The part around that the conductor is wound is termed as core of the solenoid. Core could also be air or could also be some magnetic material.
When such conductor is excited by the supply in order that it transmits a current then it creates a magnetic field of force that acts through the coil on its axis and additionally around the coil. Instead of victimization a straight core to twist the conductor, a circular core can also be accustomed wound the conductor. In such case the ensuing coil (Solenoid) is termed Toroid. Use of magnetic material for
the core creates sturdy magnet. This can be as a result of current carrying conductor produces its own flux. Additionally to the present, the core behaves sort of a magnet due to magnetic induction, producing its own flux. The direction of 2 fluxes is same due to that resultant magnetic field of force becomes additional sturdy.
The pattern of the flux around the coil is shown within the above Fig.
The rules to see the direction of flux and poles of the magnet formed:
The Right hand thumb rule
Hold the coil (Solenoid) within the right hand such that curled fingers point within the direction of current through the curled conductor, then the extended thumb on the axis of the coil point to the North Pole of the coil or point the direction of flux lines within the core. This can be shown in Fig.
In the event of toroid, the core is circular and therefore victimization right thumb rules, the direction of flux within the core, due to current carrying conductor are often determined. This can be shown within the Fig(a) and (b) below. In the Fig(a), similar to direction of winding, the flux set within the core is anticlockwise whereas within the Fig (b) due to direction of winding, the direction of flux set within the core is clockwise. The winding is also known as magnetizing winding or magnetizing coil because it magnetizes the core.

Corkscrew rule:
If alignment of the screw is placed on the axis of the coil (solenoid) and if screw is turned within the direction of current, then it movements in the direction of the N-pole or within the direction of the field of force within the coil.
End rule:
If coil is discovered from anyone end then its polarity are often set by noting direction of the current.

Consider coil (solenoid) shown within the Fig.
If it's seen from the top A, current can seem to flow in clockwise direction, in order that end behaves as S-pole of the magnet. Whereas as seen from the end B, current seems to flow in anticlockwise direction then that end which is B, behaves as N-pole of the magnet.
Generally right hand thumb rule is employed to see direction of flux and nature of the poles shaped. Victimization such construct of an electromagnet, numerous magnetic circuits are often obtained.