Computer-aided-design of flywheels