Skip to content

OtterCode/population-sim

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pop_sim

An Efficient, Fast, Large-Scale Population Simulator

PopSim uses deterministic statistical methods to allow you to simulate arbitrarily large or small populations. At the moment it simulates static birth and death rate curves. In the future it will allow you to add a timeline of events to simulate changes in birth/death rate, environmental carrying capacity, immigration, and catastrophic events.

    let mut pop = pop_sim::population::Population::new(vec![ ( 10_000, 10_000 ) ]);

    for _ in 0..1000 {
        pop = pop.advance_year();
        println!("Males: {:?}", pop.total_male());
        println!("Females: {:?}", pop.total_female());
    }

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published