/* * Read parameters from file. */ void McSimulation::readParameters(std::istream &in) { if (isInitialized_) { UTIL_THROW("Error: Called readParam when already initialized"); } // Record identity of parameter file paramFilePtr_ = ∈ // Read all species, analyzers, random number seed Simulation::readParameters(in); // Read the McSystem parameters: potential parameters, temperature etc. readParamComposite(in, system()); // Read Monte Carlo Moves assert(mcMoveManagerPtr_); readParamComposite(in, *mcMoveManagerPtr_); // Read Analyzers readParamComposite(in, analyzerManager()); // Parameters for writing restart files read<int>(in, "saveInterval", saveInterval_); if (saveInterval_ > 0) { read<std::string>(in, "saveFileName", saveFileName_); } isValid(); isInitialized_ = true; }
void System::readTetherMaster(std::istream &in) { if (simulation().hasTether()) { tetherMasterPtr_ = new TetherMaster(); readParamComposite(in, *tetherMasterPtr_); } }
void System::readLinkMaster(std::istream& in) { if (simulation().nLinkType() > 0) { linkMasterPtr_ = new LinkMaster(); readParamComposite(in, *linkMasterPtr_); } }
/* * Create EnergyEnsemble and BoundaryEnsemble */ void System::readEnsembles(std::istream &in) { readParamComposite(in, *energyEnsemblePtr_); readParamComposite(in, *boundaryEnsemblePtr_); }
void AtomicMaker::readParam(std::istream& in) { read<Boundary>(in, "boundary", boundary_); readParamComposite(in, random_); read<int>(in, "nMolecule", nMolecule_); }