Restructuring Code. Removed some small classes which provided only 1 function, like parameter. Now each class calls it own parameters and stores them as static const.
Merged function containers. Added HDF5 output and reworked Logger class into Base class and 2 derived classes ASCI_Logger and H5_Logger
This commit is contained in:
@@ -10,8 +10,6 @@
|
||||
#define simulation_hpp
|
||||
|
||||
|
||||
#include "parameter.hpp"
|
||||
#include "constants.hpp"
|
||||
#include "katrin.hpp"
|
||||
#include "electron.hpp"
|
||||
#include "logger.hpp"
|
||||
@@ -19,22 +17,26 @@
|
||||
#include <deque>
|
||||
|
||||
|
||||
class Simulation: private Parameter, private Constants {
|
||||
class Simulation {
|
||||
public:
|
||||
Simulation();
|
||||
|
||||
|
||||
void doit();
|
||||
private:
|
||||
void do_statusUpdate();
|
||||
void move_electron(Electron *moveElectron, Logger *Log);
|
||||
void move_electron(Electron *moveElectron, H5_Logger *Log);
|
||||
void do_interaction(Electron *interactElectron);
|
||||
bool check_NumberInteractions(int &numberInteractionsThisElectron);
|
||||
|
||||
Katrin Kat;
|
||||
Logger Log;
|
||||
H5_Logger Log;
|
||||
|
||||
ranlib::Uniform<double> rngUni;
|
||||
ranlib::NormalUnit<double> rngNormal;
|
||||
|
||||
int numberTotalElectrons;
|
||||
int numberDecays;
|
||||
|
||||
std::deque<Electron> electronQue;
|
||||
Electron *actionElectronPtr;
|
||||
|
||||
@@ -42,6 +44,11 @@ private:
|
||||
int updater_numberOfPrevious;
|
||||
int updater_fraction;
|
||||
|
||||
static const long int seed;
|
||||
static const long int numberTotalDecays;
|
||||
|
||||
static const int propagationMethod;
|
||||
static const int maxInteractions;
|
||||
public:
|
||||
void doTC6();
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user