#include "grins_config.h"
#include <iostream>
#include "grins/simulation.h"
#include "grins/simulation_builder.h"
#include "libmesh/parallel.h"
Go to the source code of this file.
|
libMesh::Real | initial_values (const libMesh::Point &p, const libMesh::Parameters ¶ms, const std::string &system_name, const std::string &unknown_name) |
|
int | main (int argc, char *argv[]) |
|
libMesh::Real initial_values |
( |
const libMesh::Point & |
p, |
|
|
const libMesh::Parameters & |
params, |
|
|
const std::string & |
system_name, |
|
|
const std::string & |
unknown_name |
|
) |
| |
Definition at line 122 of file 3d_low_mach_jacobians.C.
Referenced by main().
125 libMesh::Real value = 0.0;
127 if( unknown_name ==
"T" )
128 value = params.get<libMesh::Real>(
"T_init");
130 else if( unknown_name ==
"p0" )
131 value = params.get<libMesh::Real>(
"p0_init");
int main |
( |
int |
argc, |
|
|
char * |
argv[] |
|
) |
| |
Definition at line 46 of file 3d_low_mach_jacobians.C.
References initial_values().
48 #ifdef GRINS_USE_GRVY_TIMERS
49 GRVY::GRVY_Timer_Class grvy_timer;
50 grvy_timer.Init(
"GRINS Timer");
57 std::cerr <<
"Error: Must specify libMesh input file." << std::endl;
62 std::string libMesh_input_filename = argv[1];
65 GetPot libMesh_inputfile( libMesh_input_filename );
67 #ifdef GRINS_USE_GRVY_TIMERS
68 grvy_timer.BeginTimer(
"Initialize Solver");
72 libMesh::LibMeshInit libmesh_init(argc, argv);
78 libmesh_init.comm() );
81 std::string restart_file = libMesh_inputfile(
"restart-options/restart_file",
"none" );
83 if( restart_file ==
"none" )
86 std::string system_name = libMesh_inputfile(
"screen-options/system_name",
"GRINS" );
87 std::tr1::shared_ptr<libMesh::EquationSystems> es = grins.get_equation_system();
88 const libMesh::System& system = es->get_system(system_name);
90 libMesh::Parameters ¶ms = es->parameters;
91 libMesh::Real T_init = libMesh_inputfile(
"Physics/LowMachNavierStokes/T0", 0.0);
92 libMesh::Real p0_init = libMesh_inputfile(
"Physics/LowMachNavierStokes/p0", 0.0);
94 libMesh::Real& dummy_T = params.set<libMesh::Real>(
"T_init");
97 libMesh::Real& dummy_p0 = params.set<libMesh::Real>(
"p0_init");
103 #ifdef GRINS_USE_GRVY_TIMERS
104 grvy_timer.EndTimer(
"Initialize Solver");
107 grins.attach_grvy_timer( &grvy_timer );
112 #ifdef GRINS_USE_GRVY_TIMERS
113 grvy_timer.Finalize();
115 if( Parallel::Communicator_World.rank() == 0 ) grvy_timer.Summarize();
libMesh::Real initial_values(const libMesh::Point &p, const libMesh::Parameters ¶ms, const std::string &system_name, const std::string &unknown_name)