forked from sanshar/Block
-
Notifications
You must be signed in to change notification settings - Fork 3
/
main.C
45 lines (38 loc) · 1.24 KB
/
main.C
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
Developed by Sandeep Sharma, Roberto Olivares-Amaya and Garnet K.-L. Chan, 2012
Copyright (c) 2012, Garnet K.-L. Chan
This program is integrated in Molpro with the permission of
Sandeep Sharma, Garnet K.-L. Chan and Roberto Olivares-Amaya
*/
#ifndef SERIAL
#include <boost/mpi/environment.hpp>
#include <boost/mpi/communicator.hpp>
#include <boost/mpi.hpp>
#endif
#include <pario.h>
#include <cstdlib>
#include "dmrg_wrapper.h"
//#include "input.h"
//#include "global.h"
using namespace std;
int calldmrg(char*, char*);
#ifndef UNITTEST
int main(int argc, char* argv [])
{
#ifndef SERIAL
boost::mpi::environment env(argc, argv);
boost::mpi::communicator world;
if (world.rank() == 0) {
pout << "Runing with " << world.size() << " processors" << endl;
}
#endif
//This needs to be added
//SpinAdapted::dmrginp.initCumulTimer();
if (argc == 1 && mpigetrank() == 0) {
pout << "No command line argument found, expects an input file"<<endl;
abort();
}
char* output = 0;
return calldmrg(argv[1], output);
}
#endif