aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorschnetter <>2001-08-26 11:58:00 +0000
committerschnetter <>2001-08-26 11:58:00 +0000
commite93ba7bbf376b2ac42eca2d298e5bf08d9abf902 (patch)
treeaf318f4aaafee2dda9a0565c886b6ae4a0470d7e
parentc93aafce1700484798d804c0e17834c79aae97fa (diff)
1. Added interface for AMR. Carpet still contains no clusterer, but
1. Added interface for AMR. Carpet still contains no clusterer, but the application can now determine where to refine. 2. Made scalars (again) available all the time. This allows the scheduler to use scalars. darcs-hash:20010826115851-07bb3-eca06f09fe49430522d9770bdf5ff2e99f7578a6.gz
-rw-r--r--Carpet/Carpet/src/Recompose.cc97
-rw-r--r--Carpet/Carpet/src/SetupGH.cc14
-rw-r--r--Carpet/Carpet/src/carpet_public.hh26
-rw-r--r--Carpet/Carpet/src/helpers.cc38
-rw-r--r--Carpet/CarpetLib/src/defs.cc5
-rw-r--r--CarpetExtra/HydroToy/param.ccl8
-rw-r--r--CarpetExtra/HydroToy/schedule.ccl13
-rw-r--r--CarpetExtra/IDSpaceTimeToy/param.ccl6
-rw-r--r--CarpetExtra/IDSpaceTimeToy/src/InitialData.F774
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par8
-rw-r--r--CarpetExtra/SpaceTimeToy/param.ccl6
-rw-r--r--CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F776
17 files changed, 198 insertions, 73 deletions
diff --git a/Carpet/Carpet/src/Recompose.cc b/Carpet/Carpet/src/Recompose.cc
index 3357a4297..8d3d590b9 100644
--- a/Carpet/Carpet/src/Recompose.cc
+++ b/Carpet/Carpet/src/Recompose.cc
@@ -12,7 +12,7 @@
#include "carpet.hh"
-static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/Recompose.cc,v 1.4 2001/08/17 19:24:03 schnetter Exp $";
+static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/Recompose.cc,v 1.5 2001/08/26 13:58:51 schnetter Exp $";
@@ -22,8 +22,24 @@ namespace Carpet {
- static void Recompose_gh (cGH* cgh, gh<dim>* hh);
- static void Recompose_ga (cGH* cgh, gh<dim>* hh);
+ static bool do_recompose = false;
+ static gh<dim>::rexts next_bbsss;
+ static gh<dim>::rprocs next_pss;
+
+
+
+ static void Adapt (cGH* cgh, int reflevels, gh<dim>* hh);
+
+
+
+ void RegisterRecomposeRegions (const gh<dim>::rexts& bbsss,
+ const gh<dim>::rprocs& pss)
+ {
+ // save the region information for the next regridding
+ next_bbsss = bbsss;
+ next_pss = pss;
+ do_recompose = true;
+ }
@@ -34,17 +50,47 @@ namespace Carpet {
assert (component == -1);
Checkpoint ("%*sRecompose", 2*reflevel, "");
- Recompose_gh (cgh, hh);
+ // Check whether to recompose
+ if (!do_recompose) return;
- // Recompose only grid functions, and not grid arrays
- Recompose_ga (cgh, hh0);
+ // Recompose
+ hh->recompose (next_bbsss, next_pss);
+ if (verbose && CCTK_MyProc(cgh)==0) {
+ cout << endl;
+ cout << "New bounding boxes:" << endl;
+ for (int rl=0; rl<hh->reflevels(); ++rl) {
+ for (int c=0; c<hh->components(rl); ++c) {
+ for (int ml=0; ml<hh->mglevels(rl,c); ++ml) {
+ cout << " rl " << rl << " c " << c << " ml " << ml
+ << " bbox " << hh->extents[rl][c][ml] << endl;
+ }
+ }
+ }
+ cout << endl;
+ cout << "New processor distribution:" << endl;
+ for (int rl=0; rl<hh->reflevels(); ++rl) {
+ for (int c=0; c<hh->components(rl); ++c) {
+ cout << " rl " << rl << " c " << c
+ << " processor " << hh->processors[rl][c] << endl;
+ }
+ }
+ cout << endl;
+ }
+
+ // Don't recompose to these regions any more
+ do_recompose = false;
+
+ // Adapt grid scalars
+ Adapt (cgh, hh->reflevels(), hh0);
+
+ // Adapt grid arrays
for (int group=0; group<CCTK_NumGroups(); ++group) {
switch (CCTK_GroupTypeI(group)) {
case CCTK_SCALAR:
break;
case CCTK_ARRAY:
- Recompose_ga (cgh, arrdata[group].hh);
+ Adapt (cgh, hh->reflevels(), arrdata[group].hh);
case CCTK_GF:
break;
default:
@@ -55,13 +101,12 @@ namespace Carpet {
- static void Recompose_gh (cGH* cgh, gh<dim>* hh)
+ static void Adapt (cGH* cgh, const int reflevels, gh<dim>* hh)
{
DECLARE_CCTK_PARAMETERS;
const int nprocs = CCTK_nProcs(cgh);
- const int reflevels = max_refinement_levels; // arbitrary value
- const int mglevels = 1; // arbitrary value
+ const int mglevels = 1; // for now
vector<vector<bbox<int,dim> > > bbss(reflevels);
// note: what this routine calls "ub" is "ub+str" elsewhere
vect<int,dim> rstr = hh->baseextent.stride();
@@ -72,20 +117,16 @@ namespace Carpet {
// save old values
const vect<int,dim> oldrlb = rlb;
const vect<int,dim> oldrub = rub;
- const vect<int,dim> oldrstr = rstr;
- // calculate extent and centre
+ // calculate extent
const vect<int,dim> rextent = rub - rlb;
- const vect<int,dim> rcentre = rlb + (rextent / 2 / rstr) * rstr;
// calculate new extent
assert (all(rextent % hh->reffact == 0));
const vect<int,dim> newrextent = rextent / hh->reffact;
// refined boxes have smaller stride
assert (all(rstr%hh->reffact == 0));
rstr /= hh->reffact;
- // refine (arbitrarily) around the center only
- rlb = rcentre - (newrextent/2 / rstr) * rstr;
-// // refine (arbitrarily) around the lower boundary only
-// rlb = rlb;
+ // refine around the lower boundary only
+ rlb = rlb;
rub = rlb + newrextent;
// require rub<oldrub because we really want rub-rstr<=oldrub-oldstr
assert (all(rlb >= oldrlb && rub < oldrub));
@@ -122,24 +163,25 @@ namespace Carpet {
- static void Recompose_ga (cGH* cgh, gh<dim>* hh)
+ void MakeRegions_RefineCentre (cGH* cgh, const int reflevels,
+ gh<dim>::rexts& bbsss, gh<dim>::rprocs& pss)
{
DECLARE_CCTK_PARAMETERS;
const int nprocs = CCTK_nProcs(cgh);
- const int reflevels = max_refinement_levels; // arbitrary value
const int mglevels = 1; // arbitrary value
+
vector<vector<bbox<int,dim> > > bbss(reflevels);
// note: what this routine calls "ub" is "ub+str" elsewhere
vect<int,dim> rstr = hh->baseextent.stride();
vect<int,dim> rlb = hh->baseextent.lower();
vect<int,dim> rub = hh->baseextent.upper() + rstr;
+
for (int rl=0; rl<reflevels; ++rl) {
if (rl>0) {
// save old values
const vect<int,dim> oldrlb = rlb;
const vect<int,dim> oldrub = rub;
- const vect<int,dim> oldrstr = rstr;
// calculate extent and centre
const vect<int,dim> rextent = rub - rlb;
const vect<int,dim> rcentre = rlb + (rextent / 2 / rstr) * rstr;
@@ -149,10 +191,10 @@ namespace Carpet {
// refined boxes have smaller stride
assert (all(rstr%hh->reffact == 0));
rstr /= hh->reffact;
-// // refine (arbitrarily) around the center only
-// rlb = rcentre - (newrextent/2 / rstr) * rstr;
- // refine (arbitrarily) around the lower boundary only
- rlb = rlb;
+ // refine (arbitrarily) around the center only
+ rlb = rcentre - (newrextent/2 / rstr) * rstr;
+// // refine (arbitrarily) around the lower boundary only
+// rlb = rlb;
rub = rlb + newrextent;
// require rub<oldrub because we really want rub-rstr<=oldrub-oldstr
assert (all(rlb >= oldrlb && rub < oldrub));
@@ -173,9 +215,9 @@ namespace Carpet {
}
bbss[rl] = bbs;
}
- vector<vector<vector<bbox<int,dim> > > > bbsss
- = hh->make_multigrid_boxes(bbss, mglevels);
- vector<vector<int> > pss(bbss.size());
+ bbsss = hh->make_multigrid_boxes(bbss, mglevels);
+
+ pss.resize(bbss.size());
for (int rl=0; rl<reflevels; ++rl) {
pss[rl] = vector<int>(bbss[rl].size());
// make sure all processors have the same number of components
@@ -184,7 +226,6 @@ namespace Carpet {
pss[rl][c] = c % nprocs; // distribute among processors
}
}
- hh->recompose(bbsss, pss);
}
} // namespace Carpet
diff --git a/Carpet/Carpet/src/SetupGH.cc b/Carpet/Carpet/src/SetupGH.cc
index a9000952b..7ae52773e 100644
--- a/Carpet/Carpet/src/SetupGH.cc
+++ b/Carpet/Carpet/src/SetupGH.cc
@@ -10,7 +10,7 @@
#include "carpet.hh"
-static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/SetupGH.cc,v 1.5 2001/08/17 19:15:59 schnetter Exp $";
+static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/SetupGH.cc,v 1.6 2001/08/26 13:59:00 schnetter Exp $";
@@ -227,6 +227,12 @@ namespace Carpet {
mglevel = 0;
component = -1;
+ // Invent a refinement structure
+ gh<dim>::rexts bbsss;
+ gh<dim>::rprocs pss;
+ MakeRegions_RefineCentre (cgh, maxreflevels, bbsss, pss);
+ RegisterRecomposeRegions (bbsss, pss);
+
// Recompose grid hierarchy
Recompose (cgh);
@@ -242,9 +248,9 @@ namespace Carpet {
set_component (cgh, -1);
// Enable storage for all groups if desired
- // XXX
- if (true || enable_all_storage) {
- for (int group=0; group<CCTK_NumGroups(); ++group) {
+ for (int group=0; group<CCTK_NumGroups(); ++group) {
+ // XXX
+ if (true || enable_all_storage || CCTK_GroupTypeI(group)==CCTK_SCALAR) {
EnableGroupStorage (cgh, CCTK_GroupName(group));
}
}
diff --git a/Carpet/Carpet/src/carpet_public.hh b/Carpet/Carpet/src/carpet_public.hh
index 5c12b3ce3..7b75869e1 100644
--- a/Carpet/Carpet/src/carpet_public.hh
+++ b/Carpet/Carpet/src/carpet_public.hh
@@ -1,4 +1,4 @@
-// $Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/carpet_public.hh,v 1.1 2001/07/09 09:00:14 schnetter Exp $
+// $Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/carpet_public.hh,v 1.2 2001/08/26 13:59:08 schnetter Exp $
// It is assumed that the number of components of all arrays is equal
// to the number of components of the grid functions, and that their
@@ -88,6 +88,8 @@ namespace Carpet {
#include "carpet_public.h"
}
+
+
// Registered functions
void* SetupGH (tFleshConfig* fc, int convLevel, cGH* cgh);
@@ -113,6 +115,15 @@ namespace Carpet {
+ // Functions for recomposing the grid hierarchy
+ void RegisterRecomposeRegions (const gh<dim>::rexts& bbsss,
+ const gh<dim>::rprocs& pss);
+
+ void MakeRegions_RefineCentre (cGH* cgh, int reflevels,
+ gh<dim>::rexts& bbsss, gh<dim>::rprocs& pss);
+
+
+
// Helper functions
void set_reflevel (cGH* cgh, int rl);
void set_mglevel (cGH* cgh, int ml);
@@ -162,12 +173,13 @@ namespace Carpet {
// Component iterator
-#define BEGIN_COMPONENT_LOOP(cgh) \
- do { \
- int _cl; \
- assert (component==-1); \
- set_component ((cgh), 0); \
- for (;;) { \
+#define BEGIN_COMPONENT_LOOP(cgh) \
+ do { \
+ int _cl; \
+ assert (reflevel>=0 && reflevel<hh->reflevels()); \
+ assert (component==-1); \
+ set_component ((cgh), 0); \
+ for (;;) { \
{
#define END_COMPONENT_LOOP(cgh) \
} \
diff --git a/Carpet/Carpet/src/helpers.cc b/Carpet/Carpet/src/helpers.cc
index c19ec197f..5207ebd62 100644
--- a/Carpet/Carpet/src/helpers.cc
+++ b/Carpet/Carpet/src/helpers.cc
@@ -11,7 +11,7 @@
#include "carpet.hh"
-static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/helpers.cc,v 1.4 2001/08/23 17:52:58 schnetter Exp $";
+static const char* rcsid = "$Header: /home/eschnett/C/carpet/Carpet/Carpet/Carpet/src/helpers.cc,v 1.5 2001/08/26 13:59:15 schnetter Exp $";
@@ -182,9 +182,12 @@ namespace Carpet {
void set_component (cGH* cgh, const int c)
{
+ assert (reflevel>=0 && reflevel<hh->reflevels());
assert (c==-1 || (c>=0 && c<hh->components(reflevel)));
component = c;
-
+ assert (component==-1
+ || (mglevel>=0 && mglevel<hh->mglevels(reflevel,component)));
+
if (component == -1) {
// Global mode -- no component is active
@@ -218,8 +221,35 @@ namespace Carpet {
const int var = n - CCTK_FirstVarIndexI(group);
assert (var>=0);
- // Scalars, arrays, and grid functions cannot be accessed
- cgh->data[n][tl] = 0;
+ if (CCTK_GroupTypeI(group) != CCTK_SCALAR) {
+ // Arrays and grid functions cannot be accessed
+
+ cgh->data[n][tl] = 0;
+
+ } else {
+ // Scalars can be accessed
+
+ if (CCTK_QueryGroupStorageI(cgh, group)) {
+ // Group has storage
+
+ assert (group<(int)arrdata.size());
+ assert (var<(int)arrdata[group].data.size());
+ assert (arrdata[group].data[var]);
+ const int c = CCTK_MyProc(cgh);
+ assert (hh->is_local(reflevel,c));
+ cgh->data[n][tl]
+ = ((*arrdata[group].data[var])
+ (-tl, reflevel, c, mglevel)->storage());
+ assert (cgh->data[n][tl]);
+
+ } else {
+ // Group has no storage
+
+ cgh->data[n][tl] = 0;
+
+ } // if ! has storage
+
+ } // if group type is SCALAR
} // for tl
} // for n
diff --git a/Carpet/CarpetLib/src/defs.cc b/Carpet/CarpetLib/src/defs.cc
index ac868e5a9..f862195d3 100644
--- a/Carpet/CarpetLib/src/defs.cc
+++ b/Carpet/CarpetLib/src/defs.cc
@@ -5,7 +5,7 @@
copyright : (C) 2000 by Erik Schnetter
email : schnetter@astro.psu.edu
- $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/defs.cc,v 1.7 2001/07/04 12:29:51 schnetter Exp $
+ $Header: /home/eschnett/C/carpet/Carpet/Carpet/CarpetLib/src/defs.cc,v 1.8 2001/08/26 13:59:31 schnetter Exp $
***************************************************************************/
@@ -79,7 +79,10 @@ ostream& output (ostream& os, const vector<T>& v) {
template ostream& output (ostream& os, const list<bbox<int,3> >& l);
template ostream& output (ostream& os, const set<bbox<int,3> >& s);
template ostream& output (ostream& os, const set<bboxset<int,3> >& s);
+template ostream& output (ostream& os, const vector<int>& v);
+template ostream& output (ostream& os, const vector<bbox<int,3> >& v);
template ostream& output (ostream& os, const vector<list<bbox<int,3> > >& v);
+template ostream& output (ostream& os, const vector<vector<int> >& v);
template ostream& output (ostream& os, const vector<vector<bbox<int,3> > >& v);
template ostream& output (ostream& os, const vector<vector<vector<bbox<int,3> > > >& v);
#endif
diff --git a/CarpetExtra/HydroToy/param.ccl b/CarpetExtra/HydroToy/param.ccl
index 2760c29dd..d27dbef12 100644
--- a/CarpetExtra/HydroToy/param.ccl
+++ b/CarpetExtra/HydroToy/param.ccl
@@ -1,5 +1,11 @@
# Parameter definitions for thorn HydroToy
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/HydroToy/param.ccl,v 1.2 2001/03/21 22:57:40 eschnett Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/HydroToy/param.ccl,v 1.3 2001/08/26 13:59:38 schnetter Exp $
+
+restricted:
+
+BOOLEAN hydrotoy_active "Activate or deactivate the HydroToy thorn"
+{
+} "yes"
private:
diff --git a/CarpetExtra/HydroToy/schedule.ccl b/CarpetExtra/HydroToy/schedule.ccl
index 319793a1d..aa8716cb0 100644
--- a/CarpetExtra/HydroToy/schedule.ccl
+++ b/CarpetExtra/HydroToy/schedule.ccl
@@ -1,5 +1,9 @@
# Schedule definitions for thorn HydroToy
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/HydroToy/schedule.ccl,v 1.1 2001/03/18 22:37:09 eschnett Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/HydroToy/schedule.ccl,v 1.2 2001/08/26 13:59:40 schnetter Exp $
+
+if (hydrotoy_active) {
+
+
STORAGE: hydroevolve
@@ -29,10 +33,13 @@ schedule HydroToy_EulerPredictor at EVOL
SYNC: hydroevolve
} "Euler predictor step"
-schedule HydroToy_EulerCorrector at EVOL \
- after HydroToy_EulerPredictor
+schedule HydroToy_EulerCorrector at EVOL after HydroToy_EulerPredictor
{
LANG: Fortran
STORAGE: hydrotemps
SYNC: hydroevolve
} "Euler corrector step"
+
+
+
+}
diff --git a/CarpetExtra/IDSpaceTimeToy/param.ccl b/CarpetExtra/IDSpaceTimeToy/param.ccl
index 8a708604c..706bad6d7 100644
--- a/CarpetExtra/IDSpaceTimeToy/param.ccl
+++ b/CarpetExtra/IDSpaceTimeToy/param.ccl
@@ -1,10 +1,14 @@
# Parameter definitions for thorn IDSpaceTimeToy
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/IDSpaceTimeToy/param.ccl,v 1.1 2001/03/17 16:05:49 eschnett Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/IDSpaceTimeToy/param.ccl,v 1.2 2001/08/26 13:59:41 schnetter Exp $
shares: grid
USES KEYWORD type
+shares: hydrotoy
+
+USES BOOLEAN hydrotoy_active
+
restricted:
KEYWORD initial_data "Type of initial data"
diff --git a/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77 b/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77
index 5582ed669..4fe16680d 100644
--- a/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77
+++ b/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77
@@ -1,5 +1,5 @@
c -*-Fortran-*-
-c $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77,v 1.4 2001/03/26 02:28:54 eschnett Exp $
+c $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/IDSpaceTimeToy/src/InitialData.F77,v 1.5 2001/08/26 13:59:47 schnetter Exp $
#include "cctk.h"
#include "cctk_Parameters.h"
@@ -124,7 +124,7 @@ c Use kx,ky,kz as number of modes in each direction.
end if
- if (cctk_isthornactive("hydrotoy").eq.1) then
+ if (hydrotoy_active.eq.1) then
do k=1,cctk_lsh(3)
do j=1,cctk_lsh(2)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par
index 481e1f24d..0bcc7a94e 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par,v 1.3 2001/04/23 08:10:20 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic.par,v 1.4 2001/08/26 13:59:52 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy HydroToy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 120
@@ -52,6 +52,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par
index 95b1884e9..b55dcbd75 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par,v 1.5 2001/04/23 08:10:21 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse.par,v 1.6 2001/08/26 13:59:53 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy Hydrotoy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 60
@@ -52,6 +52,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par
index df1ab595d..45be9dba9 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par,v 1.5 2001/04/23 08:10:21 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl2.par,v 1.6 2001/08/26 13:59:54 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy Hydrotoy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 120
@@ -56,6 +56,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par
index ec078235d..5a15f3e71 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par,v 1.6 2001/04/23 08:10:21 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_coarse_rl3.par,v 1.7 2001/08/26 13:59:54 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy Hydrotoy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 240
@@ -56,6 +56,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par
index 14175ee15..1114944af 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par,v 1.5 2001/04/23 08:10:21 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl2.par,v 1.6 2001/08/26 13:59:55 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy Hydrotoy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 240
@@ -56,6 +56,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par
index 6dfb5e485..8ccee9f95 100644
--- a/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par
+++ b/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par
@@ -7,12 +7,12 @@
# @enddesc
# @@*/
#
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par,v 1.4 2001/04/23 08:10:21 schnetter Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/par/spacetimetoy_periodic_rl3.par,v 1.5 2001/08/26 13:59:56 schnetter Exp $
-ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy"
+ActiveThorns = "Boundary IOBasic IOUtil Time Cart3d Carpet CarpetIOASCII CarpetIOFlexIO CarpetLib CarpetSlab IDSpaceTimeToy SpaceTimeToy Hydrotoy"
Carpet::poison_new_timelevels = yes
-Carpet::check_for_poison = yes
+#Carpet::check_for_poison = yes
Carpet::checksum_timelevels = yes
Cactus::cctk_itlast = 480
@@ -56,6 +56,8 @@ IOFlexIO::out3D_format = IEEE
SpaceTimeToy::icn_iterations = 2
SpaceTimeToy::bound = radiation
+HydroToy::hydrotoy_active = no
+
IDSpaceTimeToy::initial_data = plane
IDSpaceTimeToy::kx = 0.222222222222222 # 2 / ((32-2) * 0.3)
IDSpaceTimeToy::ky = 0.151515151515152 # 2 / ((46-2) * 0.3)
diff --git a/CarpetExtra/SpaceTimeToy/param.ccl b/CarpetExtra/SpaceTimeToy/param.ccl
index d48df8cff..0213a9f61 100644
--- a/CarpetExtra/SpaceTimeToy/param.ccl
+++ b/CarpetExtra/SpaceTimeToy/param.ccl
@@ -1,5 +1,9 @@
# Parameter definitions for thorn SpaceTimeToy
-# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/param.ccl,v 1.2 2001/03/21 22:57:40 eschnett Exp $
+# $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/param.ccl,v 1.3 2001/08/26 13:59:49 schnetter Exp $
+
+shares: hydrotoy
+
+USES BOOLEAN hydrotoy_active
private:
diff --git a/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77 b/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77
index a5d8eab8c..304837390 100644
--- a/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77
+++ b/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77
@@ -1,5 +1,5 @@
c -*-Fortran-*-
-c $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77,v 1.8 2001/04/23 08:10:22 schnetter Exp $
+c $Header: /home/eschnett/C/carpet/Carpet/CarpetExtra/SpaceTimeToy/src/SpaceTimeToy.F77,v 1.9 2001/08/26 13:59:58 schnetter Exp $
#include "cctk.h"
#include "cctk_Parameters.h"
@@ -29,7 +29,7 @@ c Copy
end do
end do
- if (cctk_isthornactive("hydrotoy").eq.1) then
+ if (hydrotoy_active.eq.1) then
do k=1,cctk_lsh(3)
do j=1,cctk_lsh(2)
@@ -103,7 +103,7 @@ c Average
end do
end do
- if (cctk_isthornactive("hydrotoy").eq.1) then
+ if (hydrotoy_active.eq.1) then
do k=1,cctk_lsh(3)
do j=1,cctk_lsh(2)