egttools.numerical.numerical

The numerical module contains optimized functions and classes to simulate evolutionary dynamics in large populations. This module is written in C++.

Functions

calculate_nb_states

Calculates the number of states (combinations) of the members of a group in a subgroup.

calculate_state

This function converts a vector containing counts into an index.

calculate_strategies_distribution

Calculates the average frequency of each strategy available in the population given the stationary distribution.

replicator_equation

Calculates the gradient of the replicator dynamics given the current population state.

replicator_equation_n_player

Calculates the gradient of the replicator dynamics given the current population state.

sample_simplex

Transforms a state index into a vector.

sample_simplex_directly

Samples an N-dimensional point directly from the simplex.

sample_unit_simplex

Samples uniformly at random the unit simplex with nb_strategies dimensionse.

vectorized_replicator_equation_n_player

Calculates the gradient of the replicator dynamics given the current population state.

Classes

PairwiseComparison

A class containing methods to study analytically the evolutionary dynamics using the Pairwise comparison rule.

PairwiseComparisonNumerical

A class containing methods to study numerically the evolutionary dynamics using the Pairwise comparison rule.

Random

Random seed generator.