We develop a new powerful method to reproduce in silico single-molecule manipulation experiments. We demonstrate that flexible polymers such as DNA can be simulated using rigid body dynamics thanks to an original implementation of Langevin dynamics in an open source library called Open Dynamics Engine. We moreover implement a global thermostat which accelerates the simulation sampling by two orders of magnitude. We reproduce force-extension as well as rotation-extension curves of reference experimental studies. Finally, we extend the model to simulations where the control parameter is no longer the torsional strain but instead the torque, and predict the expected behavior for this case which is particularly challenging theoretically and experimentally. 