From 376ecd6f239e0fce431cd7a9fd487aa8a66bcf9c Mon Sep 17 00:00:00 2001 From: Ian Hinder Date: Wed, 21 Mar 2012 13:21:34 +0100 Subject: Add Jacobian gridfunctions to GenericFD 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. --- Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl | 12 ++++++++++++ Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl | 4 ++++ Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl | 5 +++++ 3 files changed, 21 insertions(+) (limited to 'Auxiliary') diff --git a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl index ccc3785..fa5dc00 100644 --- a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl +++ b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/interface.ccl @@ -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" diff --git a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl index 8e410f7..430b2da 100644 --- a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl +++ b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/param.ccl @@ -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" diff --git a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl index 05ca0e1..0b71ed3 100644 --- a/Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl +++ b/Auxiliary/Cactus/KrancNumericalTools/GenericFD/schedule.ccl @@ -3,3 +3,8 @@ # author: S. Husa # $Header$ + +if (allocate_genericfd_jacobian) +{ + STORAGE: jacobian, jacobian2 +} -- cgit v1.2.3