#include "grins_config.h"
#include <iostream>
#include "grins/simulation_builder.h"
#include "grins/simulation.h"
#include "libmesh/parallel.h"
Go to the source code of this file.
|
int | main (int argc, char *argv[]) |
|
int main |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
Definition at line 42 of file grins.C.
References GRINS_BUILD_VERSION, and GRINS::Simulation::run().
44 #ifdef GRINS_USE_GRVY_TIMERS
45 GRVY::GRVY_Timer_Class grvy_timer;
46 grvy_timer.Init(
"GRINS Timer");
53 std::cerr <<
"Error: Must specify libMesh input file." << std::endl;
58 std::string libMesh_input_filename = argv[1];
61 libMesh::LibMeshInit libmesh_init(argc, argv);
64 GetPot libMesh_inputfile( libMesh_input_filename );
66 GetPot command_line(argc,argv);
70 std::ifstream i(libMesh_input_filename.c_str());
73 std::cerr <<
"Error: Could not read from libMesh input file "
74 << libMesh_input_filename << std::endl;
79 #ifdef GRINS_USE_GRVY_TIMERS
80 grvy_timer.BeginTimer(
"Initialize Solver");
84 libMesh::out <<
"=========================================================="
87 <<
"libMesh Version: " << LIBMESH_BUILD_VERSION << std::endl
88 <<
"Running with command:\n";
90 for (
int i=0; i != argc; ++i)
91 libMesh::out << argv[i] <<
' ';
93 libMesh::out << std::endl
94 <<
"=========================================================="
102 libmesh_init.comm() );
104 #ifdef GRINS_USE_GRVY_TIMERS
105 grvy_timer.EndTimer(
"Initialize Solver");
108 grins.attach_grvy_timer( &grvy_timer );
113 #ifdef GRINS_USE_GRVY_TIMERS
114 grvy_timer.Finalize();
116 if( Parallel::Communicator_World.rank() == 0 ) grvy_timer.Summarize();
#define GRINS_BUILD_VERSION