
Figure 1: 0.5MM-2.0MM 0.01mH-100mH solenoid coils.
Solenoid coils are built using the presence of a magnetic field around a wire. It is wound in a spiral shape to strengthen the magnetic field, i.e., the highest magnetic field strength is achieved with the smallest amount of space. In addition, replacing ordinary wires with wires coated with a layer of insulating paint is also to save space.
To sum the working principle of the solenoid coil in a word: electricity generates magnetism. This will be explained in detail as follows.
The Working Principles of Solenoid Coil
The direction of the magnetic field can be determined according to the "Right Hand Rule", also known as "Ampere's Rule One": hold the straight wire with your right hand and point your thumb in the direction of the current; the direction in which the remaining four fingers bend is the direction of the magnetic field line. In effect, the magnetic field produced by this straight wire is similar to the effect of placing a ring of small magnets around the wire with NS poles end-to-end.
If a long metal wire is wound in one direction on a hollow cylinder, the formed object is called a solenoid. If you energize this solenoid, each turn of the solenoid will generate a magnetic field. Then, at the position between two adjacent turns, the total magnetic field cancels out due to the opposite direction of the magnetic field. Inside and outside the solenoid, the magnetic fields generated by each turn of the coil are superimposed on each other, resulting in the final shape of the magnetic field.
It can be concluded that the shape of the magnetic field outside the solenoid is the same as that produced by a magnet. The magnetic field inside the solenoid just forms a closed magnetic field line with the external magnetic field.

Figure 2: Electromagnetic waves in solenoid coil.
What’s more, to generate a strong magnetic field, in addition to winding as many coils as possible, two opposite solenoids are placed close together so that their N and S poles are opposite. Besides, pure iron (called a yoke) can be placed in the middle of the wire package to gather the magnetic field lines and enhance the magnetic field in the middle of the wire package.
Related Info
Classifications of Programmable Logic ControllerAdvantages and Disadvantages of the PLC
What are the 5 PLC Programming Languages
What is a Programmable Logic Controller?
How do Programmable Logic Controllers Work?