DC motors use direct current to produce rotational motion. These motors have two primary parts: the the stator and the armature. The stator is bolted to the motor housing and does not move. The stator can either be composed of permanent magnets, like in small DC electric hobby motors, or it can be composed of electromagnets. The armature is connected to the rotating shaft and also has an electromagnet. During normal operation the magnetic field of the armature and stator interact, forcing the armature and the main shaft to rotate.
Connect one side of the DC electric motor to the negative terminal on the variable DC power supply, using the #12 electrical wire.
Connect the other side of the DC motor to the center terminal on the variable resistor if the resistor has three terminals. Connect one of the other resistor terminals to the positive side of the power supply using the #12 electrical wire. Make sure the resistor can handle at least the same amount of power as the motor.
Set the power supply at the rated voltage of the motor and turn it on. The motor should start running. Change the resistance of the circuit by rotating the resistor shaft. The motor speed should change. This changes the voltage the motor sees at its terminals. Reducing that voltage reduces the magnetic field at the armature. The same principle holds true if the the voltage at the power supply is changed.
Choosing appropriate resistors is important. In addition to resistance, resistors are rated by their ability to dissipate heat. This is measured in watts. When choosing a variable resistor to be used with a DC motor, the resistor wattage rating should be at least equal to or higher than the wattage rating of the motor.