libmesh.h
Go to the documentation of this file.00001 // The libMesh Finite Element Library. 00002 // Copyright (C) 2002-2012 Benjamin S. Kirk, John W. Peterson, Roy H. Stogner 00003 00004 // This library is free software; you can redistribute it and/or 00005 // modify it under the terms of the GNU Lesser General Public 00006 // License as published by the Free Software Foundation; either 00007 // version 2.1 of the License, or (at your option) any later version. 00008 00009 // This library is distributed in the hope that it will be useful, 00010 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 // Lesser General Public License for more details. 00013 00014 // You should have received a copy of the GNU Lesser General Public 00015 // License along with this library; if not, write to the Free Software 00016 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00017 00018 00019 00020 #ifndef LIBMESH_LIBMESH_H 00021 #define LIBMESH_LIBMESH_H 00022 00023 00024 // Local includes 00025 #include "libmesh/libmesh_common.h" 00026 #include "libmesh/libmesh_base.h" 00027 #include "libmesh/enum_solver_package.h" 00028 00029 // C++ includes 00030 #include <string> 00031 #include <vector> 00032 00041 namespace libMesh 00042 { 00043 00044 00056 class LibMeshInit 00057 { 00058 public: 00059 #ifdef LIBMESH_HAVE_MPI 00060 00067 LibMeshInit(int & argc, char** & argv, 00068 MPI_Comm COMM_WORLD_IN=MPI_COMM_WORLD); 00069 #else 00070 LibMeshInit(int & argc, char** & argv); 00071 #endif 00072 00073 virtual ~LibMeshInit(); 00074 }; 00075 00076 00077 #ifndef LIBMESH_HAVE_MPI 00078 00087 void init (int & argc, char** & argv); 00088 00089 #else 00090 00100 void init (int & argc, char** & argv, 00101 MPI_Comm COMM_WORLD_IN=MPI_COMM_WORLD); 00102 00103 #endif 00104 00111 bool initialized (); 00112 00125 int close (); 00126 00133 bool closed (); 00134 00139 bool on_command_line (const std::string& arg); 00140 00146 template <typename T> 00147 T command_line_value (const std::string &, T); 00148 template <typename T> 00149 T command_line_value (const std::vector<std::string> &, T); 00150 00155 template <typename T> 00156 void command_line_vector (const std::string &, std::vector<T>&); 00157 00161 #ifdef LIBMESH_USE_COMPLEX_NUMBERS 00162 extern const Number imaginary; 00163 #endif 00164 00173 SolverPackage default_solver_package (); 00174 00178 const Real pi = 00179 static_cast<Real>(3.1415926535897932384626433832795029L); 00180 00184 const Number zero = 0.; 00185 00190 const unsigned int invalid_uint = static_cast<unsigned int>(-1); 00191 00192 } // namespace libMesh 00193 00194 #endif // LIBMESH_LIBMESH_H
Site Created By: libMesh Developers
Last modified: February 05 2013 19:54:47 UTC
Hosted By: