rsvs3D  0.0.0
Codes for the c++ implementation of the 3D RSVS
RSVSclass.cpp
1 
2 #include "RSVSclass.hpp"
3 
4 #include <memory>
5 
6 #include "RSVScalc.hpp"
7 #include "SnakeVelocities.hpp"
8 #include "triangulate.hpp"
9 
10 void integrate::RSVSclass::setVelocityEngine(const std::string &engine)
11 {
12  if (engine.compare("rsvs") == 0)
13  this->calcObj = std::make_shared<RSVScalc>();
14  else if (engine.compare("random-slow") == 0)
15  this->calcObj = std::make_shared<rsvs3d::VelocityFunction>(CalculateSnakeVel);
16  else if (engine.compare("random") == 0)
17  this->calcObj = std::make_shared<rsvs3d::VelocityFunction>(CalculateSnakeVelRand);
18  else if (engine.compare("unit") == 0)
19  this->calcObj = std::make_shared<rsvs3d::VelocityFunction>(CalculateSnakeVelUnit);
20  else if (engine.compare("unit-reflect") == 0)
21  this->calcObj = std::make_shared<rsvs3d::VelocityFunction>(CalculateSnakeVelUnitReflect);
22  else if (engine.compare("fast") == 0)
23  this->calcObj = std::make_shared<rsvs3d::VelocityFunction>(CalculateSnakeVelFast);
24  else
25  {
26  std::cerr << "Engine " << engine << std::endl;
27  RSVS3D_ERROR_ARGUMENT("Unknown engine option passed to the RSVS");
28  }
29 }
Provides the infrastructure for calculation of the RSVS equations.
Simple class containing all the information needed for the 3D-RSVS execution.
This file contains declarations of the valid velocity entries.
Provides a triangulation for snake and meshes.
#define RSVS3D_ERROR_ARGUMENT(M)
Throw a invalid_argument.
Definition: warning.hpp:148