Accrete is planetary system generation program by simulation of protoplanetary disk accretion. While this particular version is not an accurate modelling tool, it can be used for procedural generation of plausible planetary system for game development or education. During last 50 years this code was reimplemented many times with many improvements (good overview here, also brief history below).
```rust use accrete;
fn main() { let planets = accrete::run(None, None, None, None, None, None, false); } ``` Simple way to variate output is to change stellar mass. This accrete implementation is capable of generating planetary system for any stellar mass, but better (most realistic) results achieved for main sequence star class with primary star mass of 0.6 - 1.3 solar masses.
planets_limit - Limit number of planets. Default: None
stellar_mass - Primary star mass in solar masses. Default: random f64 in a range of 0.6-1.3 (corresponds main sequence spectral classes of F-G-K)
dustdensitycoeff - "A" in Dole's paper, recommended range according to Dole's paper is 0.00125-0.0015, aslo noted that binary stars produced by increasing coeff of dust density in cloud (Formation of Planetary Systems by Aggregation: A Computer Simulation by Stephen H. Dole). Default: 0.0015
k - The dust-to-gas ratio 50-100 (dust/gas = K), gas = hydrogen and helium, dust = other. Recommended range: 50.0-100.0 Default: 50.0
cloudeccentricity - Initial dust cloud cloudeccentricity. Recommended range: 0.15-0.25. Default: 0.20
b - Crit_mass coeff is used as threshold for planet to become gas giant. Recommended range: 1.0e-5 - 1.2e-5 Default: 1.2e-5
to_json - Output as JSON string. Default: false
Accrete's origin dates back to the late 60's when Stephen H. Dole published "Formation of Planetary Systems by Aggregation: A Computer Simulation". Almost a decade later Carl Sagan and Richard Isaacson refined Dole's model -- which shortly thereafter was also implemented in FORTRAN, and again elaborately and academically published by Martin Fogg in his paper "Extra-Solar Planetary Systems". The late 80's came and Matt Burdick brought this priceless program to the masses (via Turbo Pascal and C). Since then, many versions of Accrete have popped up around the internet, adding varying degrees of planetary specifics – the most notable (and ingenious) being Jim Burrow's implementation StarGen.(c)