an Elm solution for the rosettacode.org task : Animate a pendulum .

The source is on github. Demo embedded below: