NewtonPhysics
From Micasim
| Project | OpenSim Physics |
|---|---|
| Project Lead | Rob Knop |
| Project Homepage | NewtonPhysics |
Overview
OpenSimulator is an open source virtual world server platform. The server is designed to be compatible with the Second Life communication protocols, so that you could use the same clients to connect to OpenSim as you do to Second Life. (In particular, they reference LibOpenMetaverse as their client implementation; because of perhaps excessive worries about BSD vs. GPL issues, they don't want anybody who's looked at the GPLed Second Life client code within 6 months to contribute to OpenSim.)
In practice, what this means it that OpenSim is an open source server that you can use to build Second Life-like environments. It's not yet as "smooth" or stable as Second Life, but it does a lot; indeed, the primary advantage Second Life has over it is that SL is where all of the people are. (And that's a huge advantage.) However, when it comes to flexibility for people like us who want to be able to play around with the server and have it do new things, the open source nature of OpenSim is a tremendous advantage.
OpenSim is designed to be very modular. By default, they use the Open Dynamics Engine as their Physics engine. However, if you implement the right interface, you can plug in other physics engines. NewtonPhysics is just one such engine. It replaces the "game physics" engine with an N-body code. Most "game physics" engines assume you're near the surface of the Earth (uniform gravitational field), don't consider the gravity of objects in the scene, and spend most of their time worrying about dealing with collisions. In terms of implementation, an N-body code is actually simpler than this! However, it does introduce its own challenges.
The goal of this is to produce an N-body code for small N (up to 100?) that, because it's the physics engine for moving around objects in a virtual world, comes with a pre-built real-time visualization engine.
History
When we started with MICA, we discussed the possibility that OpenSimulator, a virtual worlds server platform, could be modified to have a real physics engine that did N-body calculations. Shortly after the N-body workshop started, Adam Johnson and Jeff Ames were able to put together exactly such a Physics engine very quickly, demonstrating that it was easier to get started on it than most of us had believed. (Of course, it helps that Adam and Jeff are core OpenSimulator developers, and were already familiar with it!) Will Farr worked on it a bit more, adding some other integrators.
Nearly a year later, Rob Knop picked up the mantle of working on this engine, and cleaned it up so that it would work for small N, and also started working on scripts that would allow you to specify initial conditions for star velocities in-world.
- Installing OpenSim : How to install OpenSim
- Installing NewtonPhysics : Downloading the source code and installing the NewtonPhysics module to OpenSim
- Using NewtonPhysics : Once you've got it installed, some things you can try to do to play around with the n-body simulator in an OpenSim region.
- NewtonPhysics Code : A tour of the NewtonPhysics implementation

