GompertzModel.h 4.76 KB
 Ulrich Kemloh committed May 30, 2014 1 /**  Weichen committed Jul 04, 2014 2 3  * \file GompertzModel.h * \date Apr 15, 2014  Ulrich Kemloh committed Jun 17, 2015 4 5  * \version v0.7 * \copyright <2009-2015> Forschungszentrum Jülich GmbH. All rights reserved.  Mohcine Chraibi committed Nov 15, 2018 6  * \ingroup OperationalModels  Ulrich Kemloh committed May 30, 2014 7  *  Weichen committed Jul 04, 2014 8  * \section License  Ulrich Kemloh committed May 30, 2014 9 10 11  * This file is part of JuPedSim. * * JuPedSim is free software: you can redistribute it and/or modify  Weichen committed Jul 04, 2014 12  * it under the terms of the GNU Lesser General Public License as published by  Ulrich Kemloh committed May 30, 2014 13 14 15 16 17 18 19 20  * the Free Software Foundation, either version 3 of the License, or * any later version. * * JuPedSim is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. *  Weichen committed Jul 04, 2014 21 22  * You should have received a copy of the GNU Lesser General Public License * along with JuPedSim. If not, see .  Ulrich Kemloh committed May 30, 2014 23  *  Weichen committed Jul 04, 2014 24  * \section Description  Mohcine Chraibi committed Nov 15, 2018 25  * Implementation of classes for Gompertz Model  Weichen committed Jul 04, 2014 26 27  * **/  Ulrich Kemloh committed May 30, 2014 28 29 30 31 32 33 34 35  #ifndef GOMPERTZMODEL_H_ #define GOMPERTZMODEL_H_ #include #include "../geometry/Building.h"  Ulrich Kemloh committed Nov 05, 2014 36 #include "OperationalModel.h"  Ulrich Kemloh committed May 30, 2014 37 38 39 40 41 42  //forward declaration class Pedestrian; class DirectionStrategy;  Mohcine Chraibi committed Nov 15, 2018 43 44 45 46 47 48 49 50 51 /*! * \class GompertzModel * * \brief @todo * *\ingroup OperationalModels * * \author Mohcine Chraibi */  Ulrich Kemloh committed Nov 05, 2014 52 class GompertzModel : public OperationalModel {  Ulrich Kemloh committed May 30, 2014 53 54 55 56 57 58 59 60 61 62 63 64 65 66 private: /// Modellparameter double _nuPed; double _aPed; double _bPed; double _cPed; double _nuWall; double _aWall; double _bWall; double _cWall; /**  Mohcine Chraibi committed Jun 25, 2014 67  * Driving force \f$F_i =\frac{\mathbf{v_0}-\mathbf{v_i}}{\tau}\f$  Ulrich Kemloh committed May 30, 2014 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103  * This is a duplicate of @see GCFMModel::ForceDriv * @param ped Pointer to Pedestrians * @param room Pointer to Room * * * @return Point */ Point ForceDriv(Pedestrian* ped, Room* room) const; /** * Repulsive force between two pedestrians ped1 and ped2 according to * the Gompertz model (unpublished) * * @param ped1 Pointer to Pedestrian: First pedestrian * @param ped2 Pointer to Pedestrian: Second pedestrian * * @return Point */ Point ForceRepPed(Pedestrian* ped1, Pedestrian* ped2) const; /** * Repulsive force acting on pedestrian from the walls in * . The sum of all repulsive forces of the walls in is calculated * @see ForceRepWall * @param ped Pointer to Pedestrian * @param subroom Pointer to SubRoom * * @return Point */ Point ForceRepRoom(Pedestrian* ped, SubRoom* subroom) const; /** * Repulsive force between pedestrian and wall * * @param ped Pointer to Pedestrian * @param l reference to Wall * * @return Point */  Mohcine Chraibi committed Jul 17, 2015 104  Point ForceRepWall(Pedestrian* ped, const Line& l, const Point& centroid, bool inside) const;  Ulrich Kemloh committed May 30, 2014 105 106 107  public:  GrgrLmml committed May 03, 2016 108  GompertzModel(std::shared_ptr dir, double nuped, double aped, double bped, double cped,  Ulrich Kemloh committed May 30, 2014 109 110 111  double nuwall, double awall, double bwall, double cwall); virtual ~GompertzModel(void);  GrgrLmml committed May 03, 2016 112  std::shared_ptr GetDirection() const;  Ulrich Kemloh committed Oct 29, 2014 113   Ulrich Kemloh committed May 30, 2014 114 115 116 117 118 119  /** * Get the parameter for the strength of the ped-PED repulsive force * * @return double */ double GetNuPed() const;  Ulrich Kemloh committed Oct 29, 2014 120   Ulrich Kemloh committed May 30, 2014 121 122 123 124 125 126  /** * ToDO: What is this parameter doing? * * @return double */ double GetaPed() const;  Ulrich Kemloh committed Oct 29, 2014 127   Ulrich Kemloh committed May 30, 2014 128 129 130 131 132 133  /** * ToDO: What is this parameter doing? * * @return double */ double GetbPed() const;  Ulrich Kemloh committed Oct 29, 2014 134   Ulrich Kemloh committed May 30, 2014 135 136 137 138 139 140 141 142 143 144 145 146 147  /** * ToDO: What is this parameter doing? * * @return double */ double GetcPed() const; /** * Get the parameter for the strength of the ped-WALL repulsive force * * @return */ double GetNuWall() const;  Ulrich Kemloh committed Oct 29, 2014 148   Ulrich Kemloh committed May 30, 2014 149 150 151 152 153 154  /** * ToDO: What is this parameter doing? * * @return double */ double GetaWall() const;  Ulrich Kemloh committed Oct 29, 2014 155   Ulrich Kemloh committed May 30, 2014 156 157 158 159 160 161  /** * ToDO: What is this parameter doing? * * @return double */ double GetbWall() const;  Ulrich Kemloh committed Oct 29, 2014 162   Ulrich Kemloh committed May 30, 2014 163 164 165 166 167 168 169 170 171 172  /** * ToDO: What is this parameter doing? * * @return double */ double GetcWall() const; /** * @return all model parameters in a nicely formatted string */  Ulrich Kemloh committed Sep 22, 2015 173  virtual std::string GetDescription();  Ulrich Kemloh committed Oct 29, 2014 174 175 176 177 178  /** * initialize the phi angle * @param building */  Ulrich Kemloh committed Sep 22, 2015 179  virtual bool Init (Building* building);  Ulrich Kemloh committed Nov 05, 2014 180 181 182  /** * Compute the next simulation step  Ulrich Kemloh committed Nov 10, 2014 183 184 185 186  * Solve the differential equations and update the positions and velocities * @param current the actual time * @param deltaT the next timestep * @param building the geometry object  Ulrich Kemloh committed Nov 05, 2014 187  */  Ulrich Kemloh committed Sep 22, 2015 188  virtual void ComputeNextTimeStep(double current, double deltaT, Building* building, int periodic);  Ulrich Kemloh committed May 30, 2014 189 190 191 192 }; #endif /* GOMPERTZMODEL_H_ */