Mechanics of Defect Evolution Library
Loading...
Searching...
No Matches
DDomp.cpp
Go to the documentation of this file.
1/* This file is part of MODEL, the Mechanics Of Defect Evolution Library.
2 *
3 * Copyright (C) 2012 by Giacomo Po <gpo@ucla.edu>
4 *
5 * MODEL is distributed without any warranty under the
6 * GNU General Public License (GPL) v2 <http://www.gnu.org/licenses/>.
7 */
8// Define the non-singluar method used for calculations
9#define _MODEL_NON_SINGULAR_DD_ 1 // 0 classical theory, 1 Cai's regularization method, 2 Lazar's regularization method
10
11
12#ifdef _MODEL_PYBIND11_ // COMPILED WITH PYBIND11
13#include <pybind11/pybind11.h>
14#include <pybind11/embed.h>
15#endif
16#include <Eigen/src/Core/util/DisableStupidWarnings.h>
18
19using namespace model;
20
21int main (int argc, char* argv[])
22{
23
24#ifdef _MODEL_PYBIND11_ // COMPILED WITH PYBIND11
25 pybind11::scoped_interpreter guard{};
26#endif
27
28 const std::string folderName(argc>1? std::string(argv[1]) : "./");
29
30 try
31 {
32 DefectiveCrystalBase<3> ddBase(folderName);
33 DefectiveCrystalConfigIO<3> configIO(ddBase.simulationParameters.traitsIO.configFolder);
34 configIO.read(ddBase.simulationParameters.runID);
35 DefectiveCrystal<3> DC(ddBase);
36 DC.initializeConfiguration(configIO);
37 DC.runSteps();
38 }
39 catch (const std::exception& e)
40 {
41 std::cout<<e.what()<<std::endl;
42 }
43
44 return 0;
45}
void initializeConfiguration(const DefectiveCrystalConfigIO< dim > &configIO)
void argv
void b int argc
int e