seapodym-parallel
Fish dynamics models with parameter estimations
Loading...
Searching...
No Matches
SeapodymCohortDependencyAnalyzer.h
1#include <map>
2#include <set>
3#include <array>
4
5#ifndef SEAPODYM_COHORT_DEPENDENCY_ANALYZER
6#define SEAPODYM_COHORT_DEPENDENCY_ANALYZER
7
28
29private:
30
31 // number of age groups
32 int numAgeGroups;
33
34 // number of time steps
35 int numTimeSteps;
36
37 // total number of cohorts
38 int numIds;
39
40 // cohort Id: starting step index
41 std::map<int, int> stepBegMap;
42
43 // cohort Id: ending step index + 1
44 std::map<int, int> stepEndMap;
45
46 // cohort Id: {(taskId, step), ...}
47 std::map<int, std::set<std::array<int, 2>>> dependencyMap;
48
49public:
50
57 SeapodymCohortDependencyAnalyzer(int numAgeGroups, int numTimeSteps);
58
65 int getNumberOfCohorts() const;
66
73 int getNumberOfCohortSteps() const;
74
81 std::map<int, int> getStepBegMap() const;
82
89 std::map<int, int> getStepEndMap() const;
90
99 std::map<int, std::set<std::array<int, 2>>> getDependencyMap() const;
100
101};
102
103#endif // SEAPODYM_COHORT_DEPENDENCY_ANALYZER
std::map< int, std::set< std::array< int, 2 > > > getDependencyMap() const
Definition SeapodymCohortDependencyAnalyzer.cpp:64
int getNumberOfCohorts() const
Definition SeapodymCohortDependencyAnalyzer.cpp:44
SeapodymCohortDependencyAnalyzer(int numAgeGroups, int numTimeSteps)
Definition SeapodymCohortDependencyAnalyzer.cpp:3
std::map< int, int > getStepEndMap() const
Definition SeapodymCohortDependencyAnalyzer.cpp:59
int getNumberOfCohortSteps() const
Definition SeapodymCohortDependencyAnalyzer.cpp:49
std::map< int, int > getStepBegMap() const
Definition SeapodymCohortDependencyAnalyzer.cpp:54