Skip to content

Latest commit

 

History

History
25 lines (17 loc) · 921 Bytes

README.md

File metadata and controls

25 lines (17 loc) · 921 Bytes

Inverted pendulum stabilization

After having watched this amazing video about the stabilization of an inverted pendulum, I wanted to replicate the result using the Euler method to approximate the equation of motion of the pendulum. The coordinate system follows this scheme.

ACHTUNG! This has been written by past-me in 2014, do not judge! I know that it is full of italian and that the parameter setting is awful, I know.

Run and replicate the result

docker run \
  -v $PWD:/src \
  -v ~/temp/docker-root/:/root: \
  -e DISPLAY=$DISPLAY \
  -v /tmp/.X11-unix:/tmp/.X11-unix \
  --user (id -u):(id -g) \
  --rm -it \
  rootproject/root bash

g++ -o pend vect2d.cc bar.cc pend.cpp `root-config --cflags --glibs`
./pend