This torus has a set of toroidal electromagnetic coils wrapped around it, paired poloidal coils above and below it, and a solenoid running through the middle (see panel 1).
If you curl your right hand around the solenoid so that your fingers point in the direction of the current running through the loops, your thumb will point in the direction of the magnetic field.