Go to the documentation of this file.
   22 #include "libmesh/libmesh.h" 
   24 #include "libmesh/equation_systems.h" 
   25 #include "libmesh/mesh.h" 
   26 #include "libmesh/namebased_io.h" 
   28 int main(
int argc, 
char ** argv)
 
   37   if (argc < 3 || argc > 4)
 
   39       (
"Usage: " << argv[0] <<
 
   40        " inputmesh [inputsolution] outputplot");
 
   43   START_LOG(
"mesh.read()", 
"main");
 
   45   STOP_LOG(
"mesh.read()", 
"main");
 
   51       START_LOG(
"es.read()", 
"main");
 
   52       std::string solnname = argv[2];
 
   59       STOP_LOG(
"es.read()", 
"main");
 
   60       libMesh::out << 
"Loaded solution " << solnname << std::endl;
 
   64   START_LOG(
"write_equation_systems()", 
"main");
 
   65   std::string outputname(argv[argc-1]);
 
   66   if ((outputname.find(
".xda") != std::string::npos) ||
 
   67       (outputname.find(
".xdr") != std::string::npos))
 
   70       es.write(
"soln-"+outputname);
 
   74   STOP_LOG(
"write_equation_systems()", 
"main");
 
   76   libMesh::out << 
"Wrote output " << outputname << std::endl;
 
  
The Mesh class is a thin wrapper, around the ReplicatedMesh class by default.
 
virtual void read(const std::string &name, void *mesh_data=nullptr, bool skip_renumber_nodes_and_elements=false, bool skip_find_neighbors=false)=0
Interfaces for reading/writing a mesh to/from a file.
 
virtual void write(const std::string &name)=0
 
The libMesh namespace provides an interface to certain functionality in the library.
 
int main(int argc, char **argv)
 
void init(triangulateio &t)
Initializes the fields of t to nullptr/0 as necessary.
 
The LibMeshInit class, when constructed, initializes the dependent libraries (e.g.
 
This is the EquationSystems class.
 
void print_info(std::ostream &os=libMesh::out) const
Prints relevant information about the mesh.
 
virtual void write_equation_systems(const std::string &filename, const EquationSystems &es, const std::set< std::string > *system_names=nullptr) override
This method implements writing a mesh with data to a specified file where the data is taken from the ...
 
This class supports simple reads and writes in any libMesh-supported format, by dispatching to one of...