[ET Trac] [Einstein Toolkit] #1811: simplify CarpetLib's data.cc file
Einstein Toolkit
trac-noreply at einsteintoolkit.org
Mon Aug 24 08:55:00 CDT 2015
#1811: simplify CarpetLib's data.cc file
----------------------+-----------------------------------------------------
Reporter: rhaas | Owner: eschnett
Type: task | Status: new
Priority: optional | Milestone:
Component: Carpet | Version: development version
Keywords: |
----------------------+-----------------------------------------------------
CarpetLib's data.cc file contains a number of very large and complex
switch statements inside of its {{{transfer_prolongate}}} and
{{{transfer_restrict}}} routines (the prolongate one is about 500 lines
long and is only one half of an {{{#if CAPRET_DIM}}} preprocessor if
statement). The two switch statements also have to be kept in sync with
each other whenever a new transport operator is added.
It may be good to instead define some type of "operator package" object
that contains the list of prolongation, restrict, time interpolation
operators that correspond to a particular choice of transport operator and
refinement centering as chosen in the parameter file and interface.ccl.
This way the complex logic could be collected in only a single place. This
would be useful since we seem to plan to add more new transport operators
to Carpet.
--
Ticket URL: <https://trac.einsteintoolkit.org/ticket/1811>
Einstein Toolkit <http://einsteintoolkit.org>
The Einstein Toolkit
More information about the Trac
mailing list