Control of a Rotary Inverted Pendulum (Furuta Pendulum)