Program Listing for File EpidemicSimulationSEIR.hpp

Return to documentation for file (include/networkit/simulation/EpidemicSimulationSEIR.hpp)

/*
 * EpidemicSimulationSEIR.hpp
 *
 *  Created on: 20.11.2015
 *      Author: Christian Staudt
 */

#ifndef NETWORKIT_SIMULATION_EPIDEMIC_SIMULATION_SEIR_HPP_
#define NETWORKIT_SIMULATION_EPIDEMIC_SIMULATION_SEIR_HPP_

#include <networkit/base/Algorithm.hpp>
#include <networkit/graph/Graph.hpp>

namespace NetworKit {

class EpidemicSimulationSEIR final : public Algorithm {
public:
    EpidemicSimulationSEIR(const Graph &G, count tMax, double transP, count eTime, count iTime,
                           node zero);

    void run() override;

    const std::vector<std::vector<count>> &getData() const;

private:
    const Graph *G;
    count tMax;
    double transP;
    count eTime;
    count iTime;
    node zero;
    enum class State { S, E, I, R, U }; // Susceptible, Exposed, Infectious, Removed, Undefined
    std::vector<State> state;
    std::vector<index> timestamp;
    std::vector<std::vector<count>> stats;
};

} /* namespace NetworKit */

#endif // NETWORKIT_SIMULATION_EPIDEMIC_SIMULATION_SEIR_HPP_