/* * Definition of class Mag_NS (magnetized neutron star exportation) * */ /* * Copyright (c) 2002 Eric Gourgoulhon * Copyright (c) 2009 Jerome Novak * * This file is part of LORENE. * * LORENE is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 * as published by the Free Software Foundation. * * LORENE is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with LORENE; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ #ifndef __MAG_NS_H_ #define __MAG_NS_H_ /* * $Id: mag_ns.h,v 1.3 2014/10/13 08:54:05 j_novak Exp $ * $Log: mag_ns.h,v $ * Revision 1.3 2014/10/13 08:54:05 j_novak * Lorene classes and functions now belong to the namespace Lorene. * * Revision 1.2 2014/10/06 15:13:25 j_novak * Modified #include directives to use c++ syntax. * * Revision 1.1 2009/11/19 16:15:21 j_novak * Export class for magnetized neutron stars. * * * * $Header: /cvsroot/Lorene/Export/C++/Include/mag_ns.h,v 1.3 2014/10/13 08:54:05 j_novak Exp $ * */ // Headers C #include #include #include using namespace std ; namespace Lorene { /** * Magnetized neutron star configuration on a Cartesian grid. * * A magnetized neutron star is constructed on a Cartesian grid from * data stored in a file resulting from a computation obtained from the * code magstar following the Bocquet et al. (1995) paper. * * Importation of Lorene data is performed by means of the constructor * {\tt Mag\_NS::Mag\_NS(int, const double*, const double*, const double*, const char*)}. * This constructor takes general arrays for the location of the Cartesian coordinates * $(x, y, z)$, i.e. it does not assume that the grid is a uniform one. Note also * that these arrays are 1-D, as well as all the metric fields, * in order to be use with any ordering of the 3-D storage. For the definitions of units, * see the file Lorene/C++/Include/unites.h * * This class is very simple, with all data members being public. * A typical example of use is the following one * * \begin{verbatim} * // Define the Cartesian grid by means of the arrays xg, yg, zg: * for (int i=0; i