[Developers] Interpolation timelevels

Ian Hawke hawke at aei.mpg.de
Fri Aug 20 04:29:25 CDT 2004


Hi,

A recent change was made to CactusEinstein/StaticConformal to give the
conformal factor 3 timelevels. The reason for this was due to Carpet, and
in general, interpolation using mesh refinement. If not all refinement
levels are aligned in time then the interpolator also needs to interpolate
in time; insufficient timelevels led to an error.

A commit today has changed this. CarpetInterp will now look for the tags
table entry "InterpNumTimelevels", an integer. This will specify the
maximum number of timelevels that should be used when doing this
interpolation in time. This means that the changes to StaticConformal can
be removed (and the new tag added). I attach the patch.

Unless somebody screams by this afternoon I will commit this today (it is
unlikely I'll be able to do so for two weeks after today).

A similar entry could be placed in the tags table of, e.g., CartGrid3D
coordinates, although why anybody would want to interpolate the coordinate
arrays is a mystery to me.

Ian
-------------- next part --------------
? SC.diff
? diff
Index: interface.ccl
===================================================================
RCS file: /cactusdevcvs/CactusEinstein/StaticConformal/interface.ccl,v
retrieving revision 1.8
diff -u -r1.8 interface.ccl
--- interface.ccl	5 Aug 2004 14:09:17 -0000	1.8
+++ interface.ccl	17 Aug 2004 11:44:06 -0000
@@ -8,12 +8,12 @@
 
 INT conformal_state type = SCALAR
 
-REAL confac TYPE = GF timelevels = 3 tags='tensortypealias="Scalar" Prolongation="None"'
+REAL confac TYPE = GF timelevels = 1 tags='tensortypealias="Scalar" Prolongation="None" InterpNumTimelevels=1'
 {
   psi
 } "Conformal factor"
 
-REAL confac_1derivs TYPE = GF timelevels = 3  tags='tensortypealias="U" Prolongation="None"'
+REAL confac_1derivs TYPE = GF timelevels = 1  tags='tensortypealias="U" Prolongation="None" InterpNumTimelevels=1'
 {
   psix, psiy, psiz
 } "First spatial derivatives of conformal factor divided by psi"
@@ -24,7 +24,7 @@
 #  psi_1, psi_2, psi_3
 #} "First spatial derivatives of conformal factor divided by psi"
 
-REAL confac_2derivs TYPE = GF timelevels = 3  tags='tensortypealias="dd_sym" Prolongation="None"'
+REAL confac_2derivs TYPE = GF timelevels = 1  tags='tensortypealias="dd_sym" Prolongation="None" InterpNumTimelevels=1'
 {
   psixx, psixy, psixz, psiyy, psiyz, psizz
 } "Second spatial derivatives of conformal factor divided by psi"
Index: schedule.ccl
===================================================================
RCS file: /cactusdevcvs/CactusEinstein/StaticConformal/schedule.ccl,v
retrieving revision 1.6
diff -u -r1.6 schedule.ccl
--- schedule.ccl	5 Aug 2004 14:25:39 -0000	1.6
+++ schedule.ccl	17 Aug 2004 11:44:06 -0000
@@ -17,8 +17,8 @@
 
 if(CCTK_Equals(metric_type,"static conformal"))
 {
-  if (conformal_timelevels==1)
-  {
+#   if (conformal_timelevels==1)
+#   {
 
     if(CCTK_Equals(conformal_storage, "factor"))
     {
@@ -35,29 +35,29 @@
       STORAGE: confac[1], confac_1derivs[1], confac_2derivs[1]
     }
 
-  }
-  else
-  {
-
-    if(CCTK_Equals(conformal_storage, "factor"))
-    {
-      STORAGE: confac[3]
-    }
-  
-    if(CCTK_Equals(conformal_storage, "factor+derivs"))
-    {
-      STORAGE: confac[3], confac_1derivs[3]
-    }
-  
-    if(CCTK_Equals(conformal_storage, "factor+derivs+2nd derivs"))
-    {
-      STORAGE: confac[3], confac_1derivs[3], confac_2derivs[3]
-    }
-
-    SCHEDULE StaticConformal_Evolve at CCTK_PRESTEP
-    {
-      LANG: C
-    } "Evolve the static conformal factor"
-
-  }
+#   }
+#   else
+#   {
+# 
+#     if(CCTK_Equals(conformal_storage, "factor"))
+#     {
+#       STORAGE: confac[3]
+#     }
+#   
+#     if(CCTK_Equals(conformal_storage, "factor+derivs"))
+#     {
+#       STORAGE: confac[3], confac_1derivs[3]
+#     }
+#   
+#     if(CCTK_Equals(conformal_storage, "factor+derivs+2nd derivs"))
+#     {
+#       STORAGE: confac[3], confac_1derivs[3], confac_2derivs[3]
+#     }
+# 
+#     SCHEDULE StaticConformal_Evolve at CCTK_PRESTEP
+#     {
+#       LANG: C
+#     } "Evolve the static conformal factor"
+# 
+#   }
 }
Index: src/make.code.defn
===================================================================
RCS file: /cactusdevcvs/CactusEinstein/StaticConformal/src/make.code.defn,v
retrieving revision 1.3
diff -u -r1.3 make.code.defn
--- src/make.code.defn	5 Aug 2004 14:09:17 -0000	1.3
+++ src/make.code.defn	17 Aug 2004 11:44:06 -0000
@@ -2,7 +2,8 @@
 # $Header: /cactusdevcvs/CactusEinstein/StaticConformal/src/make.code.defn,v 1.3 2004/08/05 14:09:17 schnetter Exp $
 
 # Source files in this directory
-SRCS = Initialise.c Evolve.c ConfPhys.c
+SRCS = Initialise.c ConfPhys.c
+#SRCS = Initialise.c Evolve.c ConfPhys.c
 
 # Subdirectories containing source files
 SUBDIRS = 


More information about the Developers mailing list