Skip to content

Commit

Permalink
Add Jacobian gridfunctions to GenericFD
Browse files Browse the repository at this point in the history
Storage is disabled by default.  These are here so that benchmarks and tests can be run using multipatch thorns without having to have another thorn to provide the Jacobians.  We should probably have a function to initialize them as well.
  • Loading branch information
ianhinder committed Mar 21, 2012
1 parent 2ac302d commit 376ecd6
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 0 deletions.
12 changes: 12 additions & 0 deletions Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl
Expand Up @@ -45,3 +45,15 @@ USES FUNCTION MultiPatch_GetBoundarySpecification
CCTK_INT FUNCTION \
SymmetryTableHandleForGrid (CCTK_POINTER_TO_CONST IN cctkGH)
REQUIRES FUNCTION SymmetryTableHandleForGrid

CCTK_REAL jacobian type=GF timelevels=1 tags='checkpoint="no" prolongation="none"'
{
J11, J12, J13, J21, J22, J23, J31, J32, J33
} "Jacobian J_(ik) = da^i/dx^k of the coordinate transformation (a: local, x: global)"

CCTK_REAL jacobian2 type=GF timelevels=1 tags='checkpoint="no" prolongation="none"'
{
dJ111, dJ112, dJ113, dJ122, dJ123, dJ133,
dJ211, dJ212, dJ213, dJ222, dJ223, dJ233,
dJ311, dJ312, dJ313, dJ322, dJ323, dJ333,
} "Derivative of the Jacobian d^2[local]/d[global]^2"
4 changes: 4 additions & 0 deletions Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl
Expand Up @@ -47,3 +47,7 @@ CCTK_INT jacobian_identity_map "Map number on which the Jacobian should not be
{
-1:* :: "Any integer"
} -1

CCTK_BOOLEAN allocate_genericfd_jacobian "Allocate memory for the GenericFD Jacobian (used for benchmarks)"
{
} "no"
5 changes: 5 additions & 0 deletions Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl
Expand Up @@ -3,3 +3,8 @@
# author: S. Husa

# $Header$

if (allocate_genericfd_jacobian)
{
STORAGE: jacobian, jacobian2
}

0 comments on commit 376ecd6

Please sign in to comment.