All Projects → Scrawk → GPU-GEMS-NBody-Simulation

Scrawk / GPU-GEMS-NBody-Simulation

Licence: MIT License
A NBody simulation in Unity

Programming Languages

C#
18002 projects
ShaderLab
938 projects

Projects that are alternatives of or similar to GPU-GEMS-NBody-Simulation

magpylib
Python package for computation of magnetic fields of magnets, currents and moments.
Stars: ✭ 95 (+179.41%)
Mutual labels:  physics-simulation
mi-gen
Mass-Interaction Sound Synthesis Toolbox for Max/MSP's gen~
Stars: ✭ 50 (+47.06%)
Mutual labels:  physics-simulation
lettuce
Computational Fluid Dynamics based on PyTorch and the Lattice Boltzmann Method
Stars: ✭ 74 (+117.65%)
Mutual labels:  physics-simulation
featool-multiphysics
FEATool - "Physics Simulation Made Easy" (Fully Integrated FEA, FEniCS, OpenFOAM, SU2 Solver GUI & Multi-Physics Simulation Platform)
Stars: ✭ 190 (+458.82%)
Mutual labels:  physics-simulation
fdtd
A 3D electromagnetic FDTD simulator written in Python
Stars: ✭ 195 (+473.53%)
Mutual labels:  physics-simulation
metalens
Design, optimize, & simulate metasurface lenses (aka diffractive lenses), beam deflectors, gratings etc
Stars: ✭ 52 (+52.94%)
Mutual labels:  physics-simulation
bpp
The Bullet Physics Playground – Bullet Real-Time Physics Simulation.
Stars: ✭ 31 (-8.82%)
Mutual labels:  physics-simulation
TaichiGAME
GPU Accelerated Motion Engine based on Taichi Lang.
Stars: ✭ 35 (+2.94%)
Mutual labels:  physics-simulation
PySDM
Pythonic particle-based (super-droplet) warm-rain/aqueous-chemistry cloud microphysics package with box, parcel & 1D/2D prescribed-flow examples in Python, Julia and Matlab
Stars: ✭ 26 (-23.53%)
Mutual labels:  physics-simulation
N-body-numerical-simulation
Script written in Python to integrate the equations of motion of N particles interacting with each other gravitationally. The script computes the equations of motion and use scipy.integrate to integrate them. Then it uses matplotlib to visualize the solution.
Stars: ✭ 40 (+17.65%)
Mutual labels:  physics-simulation
kin-poly
Official implementation of NeurIPS 2021 paper: "Dynamics-Regulated Kinematic Policy for Egocentric Pose Estimation". This repo contains a copy of the code for "Universal Humanoid Controller" and "Kinematic Policy".
Stars: ✭ 32 (-5.88%)
Mutual labels:  physics-simulation
mujoco
Python wrapper for MuJoCo physics simulation.
Stars: ✭ 12 (-64.71%)
Mutual labels:  physics-simulation
GAMES103
notes and related materials for GAMES103
Stars: ✭ 21 (-38.24%)
Mutual labels:  physics-simulation
Robotics-Object-Pose-Estimation
A complete end-to-end demonstration in which we collect training data in Unity and use that data to train a deep neural network to predict the pose of a cube. This model is then deployed in a simulated robotic pick-and-place task.
Stars: ✭ 153 (+350%)
Mutual labels:  physics-simulation
brax
Massively parallel rigidbody physics simulation on accelerator hardware.
Stars: ✭ 1,208 (+3452.94%)
Mutual labels:  physics-simulation
FrisPy
Frisbee flight simulator written in Python.
Stars: ✭ 23 (-32.35%)
Mutual labels:  physics-simulation
opem
OPEM (Open Source PEM Fuel Cell Simulation Tool)
Stars: ✭ 107 (+214.71%)
Mutual labels:  physics-simulation
py-orbit
Core of Py-ORBIT code
Stars: ✭ 15 (-55.88%)
Mutual labels:  physics-simulation
python-algorithms-and-simulations
Different algorithms and simulations from gravity simulations to cellular automata, implemented in python.
Stars: ✭ 21 (-38.24%)
Mutual labels:  physics-simulation
HamiltonianSolver
Numerically solves equations of motion for a given Hamiltonian function
Stars: ✭ 51 (+50%)
Mutual labels:  physics-simulation

GPU-GEMS-NBody-Simulation

This project is based on the GPU Gems article NBody simulation in CUDA. Although Unity does not support CUDA it does support Direct Compute which is the Microsoft equivalent. Nbody simulation is a popular technique used to simulate particle systems such as star/galaxy motion, fluids, electrical forces and many more physical systems.

In some simulations a Euler model is used, where space is subdivided into discrete elements that represent the amount of a certain property like density in anyone location. The Euler model is common in GPU programming because it maps very well to how the GPU works. This method is not without its issues however. It suffers from numerical errors and the simulation is confined to the domain where space is subdivided, usually represented by a texture or buffer.

For some things a more natural approach is to use a particle system. This is where NBody simulations come in. They are not domain bound, are less prone to numerical errors and use less memory. While the math is relatively simple compared to a Euler simulation the method used to get the algorithm to map to the GPU makes for a more complicated shader. The shader requires some of the more advanced Direct compute features such as shared memory and thread synchronization. This make NBody simulations a good place to start learning more about Direct Compute.

NBody simulation

List of physics projects

Position-Based-Dynamics
PBD-Fluid-in-Unity
GPU-GEMS-NBody-Simulation
GPU-GEMS-2D-Fluid-Simulation
GPU-GEMS-3D-Fluid-Simulation
CyclonePhysicsEngine
2D-Deformable-body-in-Unity

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].