functional double-pendulum