Vectorized N-Body Equation
Version 2.0.0.0 (22,9 KB) von
Dmitry Savransky
Fully vectorized n-body equations of motion in second and first order form, along with C MEX implementations of an RKN 12-10 integrator.
nbodyVect provides fully vectorized n-body gravitational equations for use with any built-in (or compatible) MATLAB ode solver. Version 2 of the code also provides event functions for detecting collisions and conjunctions, as well as 3 C implementations of the RKN1210 integrator from Dormand et al. (1987), based on the original MATLAB implementation by Rody Oldenhuis.
The MEX functions have been tested on Windows and macOS/Linux and should compile with no issue if a compatible compiler is installed (see https://www.mathworks.com/help/matlab/call-mex-files-1.html for details).
nbodyRKN_c and nbodyRKN_c_Events can be compiled on their own, e.g.:
mex nbodyRKN_c
nbodyRKN_c_Conj requires linking to levmar (https://users.ics.forth.gr/~lourakis/levmar/) - see file header for compilation notes.
Script nbodyVect_test provides a basic test of integrator functionality.
Zitieren als
Dmitry Savransky (2024). Vectorized N-Body Equation (https://www.mathworks.com/matlabcentral/fileexchange/27820-vectorized-n-body-equation), MATLAB Central File Exchange. Abgerufen.
Kompatibilität der MATLAB-Version
Erstellt mit
R2023a
Kompatibel mit R2016b und späteren Versionen
Plattform-Kompatibilität
Windows macOS LinuxKategorien
- Industries > Aerospace and Defense > Propulsion Systems >
- Sciences > Physics > Gravitation, Cosmology & Astrophysics >
Mehr zu Propulsion Systems finden Sie in Help Center und MATLAB Answers
Tags
Quellenangaben
Inspiriert von: rkn86, RKN1210 - A 12th/10th order Runge-Kutta-Nyström integrator
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Live Editor erkunden
Erstellen Sie Skripte mit Code, Ausgabe und formatiertem Text in einem einzigen ausführbaren Dokument.
Version | Veröffentlicht | Versionshinweise | |
---|---|---|---|
2.0.0.0 | Adding conjunction/collision detection and C integrator implementations. |
||
1.0.0.0 |