From 54deeff2dd0d8773854b227af2c90bce7410ba65 Mon Sep 17 00:00:00 2001 From: eschnett <> Date: Thu, 1 Mar 2001 12:40:00 +0000 Subject: Initial revision darcs-hash:20010301124010-f6438-fca5ed1e25f84efd816aa0d13fc23b58add7195d.gz --- Carpet/CarpetLib/src/th.hh | 70 ++++++++++++++++++++++++---------------------- 1 file changed, 37 insertions(+), 33 deletions(-) (limited to 'Carpet/CarpetLib/src/th.hh') diff --git a/Carpet/CarpetLib/src/th.hh b/Carpet/CarpetLib/src/th.hh index 12c77d782..6089e37cd 100644 --- a/Carpet/CarpetLib/src/th.hh +++ b/Carpet/CarpetLib/src/th.hh @@ -1,20 +1,34 @@ -// $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/th.hh,v 1.11 2004/03/23 19:30:14 schnetter Exp $ +/*************************************************************************** + th.hh - Time Hierarchy + information about time levels + ------------------- + begin : Sun Jun 11 2000 + copyright : (C) 2000 by Erik Schnetter + email : schnetter@astro.psu.edu + + $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/th.hh,v 1.1 2001/03/01 13:40:10 eschnett Exp $ + + ***************************************************************************/ + +/*************************************************************************** + * * + * This program is free software; you can redistribute it and/or modify * + * it under the terms of the GNU General Public License as published by * + * the Free Software Foundation; either version 2 of the License, or * + * (at your option) any later version. * + * * + ***************************************************************************/ #ifndef TH_HH #define TH_HH -#include - +#include #include #include -#include "cctk.h" - #include "defs.hh" #include "gh.hh" -using namespace std; - // Forward declaration @@ -33,18 +47,18 @@ class th { public: // should be readonly // Fields - gh& h; // hierarchy + gh &h; // hierarchy private: - CCTK_REAL delta; // time step - vector > times; // current times - vector > deltas; // time steps + int delta; // time step + vector > times; // current times + vector > deltas; // time steps public: // Constructors - th (gh& h, const CCTK_REAL basedelta); + th (gh& h, const int basedelta); // Destructors ~th (); @@ -53,52 +67,42 @@ public: void recompose (); // Time management - CCTK_REAL get_time (const int rl, const int ml) const { + int get_time (const int rl, const int ml) const { assert (rl>=0 && rl=0 && ml=0 && rl=0 && ml=0 && rl=0 && ml=0 && rl=0 && ml=0 && rl=0 && ml (ostream& os, const th& d); }; -template -inline ostream& operator<< (ostream& os, const th& t) { - t.output(os); - return os; -} - - +#if defined(TMPL_IMPLICIT) +# include "th.cc" +#endif #endif // TH_HH -- cgit v1.2.3