00001 #ifdef CH_LANG_CC 00002 /* 00003 * _______ __ 00004 * / ___/ / ___ __ _ / / ___ 00005 * / /__/ _ \/ _ \/ V \/ _ \/ _ \ 00006 * \___/_//_/\___/_/_/_/_.__/\___/ 00007 * Please refer to Copyright.txt, in Chombo's root directory. 00008 */ 00009 #endif 00010 00011 #ifndef _EBLOHICENTER_H_ 00012 #define _EBLOHICENTER_H_ 00013 00014 #include "Box.H" 00015 #include "ProblemDomain.H" 00016 #include "NamespaceHeader.H" 00017 00018 /// 00019 /** 00020 divide a box into its centered-diff boxes, its 00021 one-sided boxes and tell whether the one sided boxes are there. 00022 The one-sided boxes are one wide at most. 00023 All Boxes are intersected with the domain. 00024 InBox should be the size of the domain of computation 00025 (the size of the gradient box). 00026 */ 00027 extern void getLHCBoxes(Box& a_loBox, 00028 Box& a_hiBox, 00029 Box& a_centerBox, 00030 int& a_haslo, 00031 int& a_hashi, 00032 const Box& a_inBox, 00033 const ProblemDomain& a_dProblem, 00034 const int& a_dir); 00035 00036 /// 00037 /** 00038 Divide a box, a_inBox, into a box where centered differences can be used, 00039 a_centerBox, and boxes where one-sided difference can be used, a_loBox and 00040 a_hiBox based on the current problem domain, a_domain, and the difference 00041 direction, a_dir. The union of these computation boxes are returned as 00042 a_entireBox. The one-sided difference boxes are one wide at most and if 00043 they have been defined then the corresponding flag, a_hasLo or a_hasHi, is 00044 set to one, otherwise it is zero. All boxes lie within the domain, 00045 a_domain. 00046 */ 00047 extern void eblohicenter(Box& a_loBox, 00048 int& a_hasLo, 00049 Box& a_hiBox, 00050 int& a_hasHi, 00051 Box& a_centerBox, 00052 Box& a_entireBox, 00053 const Box& a_inBox, 00054 const ProblemDomain& a_domain, 00055 const int& a_dir); 00056 00057 /// 00058 /** 00059 This function is used when in direction a_dir a 2 point stencil of cell- 00060 centered data is being used to compute something at the cell face between 00061 the cell centers of the stencil. The data for the stencil is valid in 00062 a_inBox. It uses a_inBox to compute a box (face-centered in a_dir) where 00063 the full stencil can be used, a_centerBox, and boxes (face-centered in 00064 a_dir) where a 1 point stencil can be used, a_loBox and a_hiBox based on 00065 the current problem domain, a_domain, and the stencil direction, a_dir. 00066 The union of these 1 and 2 point stencel boxes is returned as a_entireBox 00067 (face-centered in a_dir). The 1 point stencil boxes are one wide, at most, 00068 and if they have been defined then the corresponding flag, a_hasLo or 00069 a_hasHi, is set to one, otherwise these flags are zero. All output boxes 00070 lie within the domain. 00071 */ 00072 extern void eblohicenterFace(Box& a_loBox, 00073 int& a_hasLo, 00074 Box& a_hiBox, 00075 int& a_hasHi, 00076 Box& a_centerBox, 00077 Box& a_entireBox, 00078 const Box& a_inBox, 00079 const ProblemDomain& a_domain, 00080 const int& a_dir); 00081 00082 #include "NamespaceFooter.H" 00083 #endif