[cig-commits] commit: Make restrictResidual and restrictSolution work with p and v

Mercurial hg at geodynamics.org
Fri Feb 25 14:14:09 PST 2011


changeset:   35:1de270f5a15e
user:        Walter Landry <wlandry at caltech.edu>
date:        Sat Jan 08 06:14:56 2011 -0800
files:       StokesFACOps.h StokesFACOps/StokesFACOps.C StokesFACOps/deallocateOperatorState.C StokesFACOps/initializeOperatorState.C StokesFACOps/restrictResidual.C StokesFACOps/restrictSolution.C StokesFACOps/xeqScheduleRRestriction.C StokesFACOps/xeqScheduleURestriction.C
description:
Make restrictResidual and restrictSolution work with p and v


diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps.h
--- a/StokesFACOps.h	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps.h	Sat Jan 08 06:14:56 2011 -0800
@@ -607,10 +607,10 @@ private:
     *        d_prolongation_refine_schedules
     *   <li> xeqScheduleURestriction():
     *        d_restriction_coarsen_operator,
-    *        d_urestriction_coarsen_schedules.
+    *        urestriction_coarsen_schedules.
     *   <li> xeqScheduleRRestriction():
-    *        d_restriction_coarsen_operator,
-    *        d_rrestriction_coarsen_schedules.
+    *        restriction_coarsen_operator,
+    *        rrestriction_coarsen_schedules.
     *   <li> xeqScheduleFluxCoarsen():
     *        d_flux_coarsen_operator,
     *        d_flux_coarsen_schedules.
@@ -640,10 +640,8 @@ private:
     * @return coarsening schedule for restriction
     */
    void
-   xeqScheduleURestriction(
-      int dst_id,
-      int src_id,
-      int dest_ln);
+   xeqScheduleURestriction(int p_dst, int p_src, int v_dst, int v_src,
+                           int dest_ln);
 
    /*!
     * @brief Execute schedule for restricting residual to the specified
@@ -654,10 +652,8 @@ private:
     * @return coarsening schedule for restriction
     */
    void
-   xeqScheduleRRestriction(
-      int dst_id,
-      int src_id,
-      int dest_ln);
+   xeqScheduleRRestriction(int p_dst, int p_src, int v_dst, int v_src,
+                           int dest_ln);
 
    /*!
     * @brief Execute schedule for coarsening flux to the specified
@@ -931,16 +927,26 @@ private:
    d_prolongation_refine_schedules;
 
    //! @brief Solution restriction (coarsening) operator.
-   tbox::Pointer<xfer::CoarsenOperator> d_urestriction_coarsen_operator;
-   tbox::Pointer<xfer::CoarsenAlgorithm> d_urestriction_coarsen_algorithm;
+   tbox::Pointer<xfer::CoarsenOperator> p_urestriction_coarsen_operator;
+   tbox::Pointer<xfer::CoarsenAlgorithm> p_urestriction_coarsen_algorithm;
    tbox::Array<tbox::Pointer<xfer::CoarsenSchedule> >
-   d_urestriction_coarsen_schedules;
+   p_urestriction_coarsen_schedules;
+
+   tbox::Pointer<xfer::CoarsenOperator> v_urestriction_coarsen_operator;
+   tbox::Pointer<xfer::CoarsenAlgorithm> v_urestriction_coarsen_algorithm;
+   tbox::Array<tbox::Pointer<xfer::CoarsenSchedule> >
+   v_urestriction_coarsen_schedules;
 
    //! @brief Residual restriction (coarsening) operator.
-   tbox::Pointer<xfer::CoarsenOperator> d_rrestriction_coarsen_operator;
-   tbox::Pointer<xfer::CoarsenAlgorithm> d_rrestriction_coarsen_algorithm;
+   tbox::Pointer<xfer::CoarsenOperator> p_rrestriction_coarsen_operator;
+   tbox::Pointer<xfer::CoarsenAlgorithm> p_rrestriction_coarsen_algorithm;
    tbox::Array<tbox::Pointer<xfer::CoarsenSchedule> >
-   d_rrestriction_coarsen_schedules;
+   p_rrestriction_coarsen_schedules;
+
+   tbox::Pointer<xfer::CoarsenOperator> v_rrestriction_coarsen_operator;
+   tbox::Pointer<xfer::CoarsenAlgorithm> v_rrestriction_coarsen_algorithm;
+   tbox::Array<tbox::Pointer<xfer::CoarsenSchedule> >
+   v_rrestriction_coarsen_schedules;
 
    //! @brief Coarsen operator for outerflux-to-flux
    tbox::Pointer<xfer::CoarsenOperator> d_flux_coarsen_operator;
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/StokesFACOps.C
--- a/StokesFACOps/StokesFACOps.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/StokesFACOps.C	Sat Jan 08 06:14:56 2011 -0800
@@ -115,12 +115,18 @@ namespace SAMRAI {
       d_prolongation_refine_operator(),
       d_prolongation_refine_algorithm(),
       d_prolongation_refine_schedules(),
-      d_urestriction_coarsen_operator(),
-      d_urestriction_coarsen_algorithm(),
-      d_urestriction_coarsen_schedules(),
-      d_rrestriction_coarsen_operator(),
-      d_rrestriction_coarsen_algorithm(),
-      d_rrestriction_coarsen_schedules(),
+      p_urestriction_coarsen_operator(),
+      p_urestriction_coarsen_algorithm(),
+      p_urestriction_coarsen_schedules(),
+      v_urestriction_coarsen_operator(),
+      v_urestriction_coarsen_algorithm(),
+      v_urestriction_coarsen_schedules(),
+      p_rrestriction_coarsen_operator(),
+      p_rrestriction_coarsen_algorithm(),
+      p_rrestriction_coarsen_schedules(),
+      v_rrestriction_coarsen_operator(),
+      v_rrestriction_coarsen_algorithm(),
+      v_rrestriction_coarsen_schedules(),
       d_flux_coarsen_operator(),
       d_flux_coarsen_algorithm(),
       d_flux_coarsen_schedules(),
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/deallocateOperatorState.C
--- a/StokesFACOps/deallocateOperatorState.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/deallocateOperatorState.C	Sat Jan 08 06:14:56 2011 -0800
@@ -70,11 +70,17 @@ namespace SAMRAI {
         d_prolongation_refine_algorithm.setNull();
         d_prolongation_refine_schedules.setNull();
 
-        d_urestriction_coarsen_algorithm.setNull();
-        d_urestriction_coarsen_schedules.setNull();
+        p_urestriction_coarsen_algorithm.setNull();
+        p_urestriction_coarsen_schedules.setNull();
 
-        d_rrestriction_coarsen_algorithm.setNull();
-        d_rrestriction_coarsen_schedules.setNull();
+        v_urestriction_coarsen_algorithm.setNull();
+        v_urestriction_coarsen_schedules.setNull();
+
+        p_rrestriction_coarsen_algorithm.setNull();
+        p_rrestriction_coarsen_schedules.setNull();
+
+        v_rrestriction_coarsen_algorithm.setNull();
+        v_rrestriction_coarsen_schedules.setNull();
 
         d_flux_coarsen_algorithm.setNull();
         d_flux_coarsen_schedules.setNull();
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/initializeOperatorState.C
--- a/StokesFACOps/initializeOperatorState.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/initializeOperatorState.C	Sat Jan 08 06:14:56 2011 -0800
@@ -234,8 +234,14 @@ void SAMRAI::solv::StokesFACOps::initial
                                    d_prolongation_method);
 
   vdb->mapIndexToVariable(d_cell_scratch_id, variable);
-  d_urestriction_coarsen_operator =
-    d_rrestriction_coarsen_operator =
+  p_urestriction_coarsen_operator =
+    p_rrestriction_coarsen_operator =
+    geometry->lookupCoarsenOperator(variable,
+                                    "CONSERVATIVE_COARSEN");
+
+  vdb->mapIndexToVariable(d_side_scratch_id, variable);
+  v_urestriction_coarsen_operator =
+    v_rrestriction_coarsen_operator =
     geometry->lookupCoarsenOperator(variable,
                                     "CONSERVATIVE_COARSEN");
 
@@ -271,13 +277,21 @@ void SAMRAI::solv::StokesFACOps::initial
     TBOX_ERROR(d_object_name
                << ": Cannot find prolongation refine operator");
   }
-  if (!d_urestriction_coarsen_operator) {
+  if (!p_urestriction_coarsen_operator) {
     TBOX_ERROR(d_object_name
-               << ": Cannot find restriction coarsening operator");
+               << ": Cannot find p restriction coarsening operator");
   }
-  if (!d_rrestriction_coarsen_operator) {
+  if (!v_urestriction_coarsen_operator) {
     TBOX_ERROR(d_object_name
-               << ": Cannot find restriction coarsening operator");
+               << ": Cannot find v restriction coarsening operator");
+  }
+  if (!p_rrestriction_coarsen_operator) {
+    TBOX_ERROR(d_object_name
+               << ": Cannot find p restriction coarsening operator");
+  }
+  if (!v_rrestriction_coarsen_operator) {
+    TBOX_ERROR(d_object_name
+               << ": Cannot find v restriction coarsening operator");
   }
   if (!d_flux_coarsen_operator) {
     TBOX_ERROR(d_object_name
@@ -316,13 +330,17 @@ void SAMRAI::solv::StokesFACOps::initial
   v_ghostfill_refine_schedules.resizeArray(d_ln_max + 1);
   p_nocoarse_refine_schedules.resizeArray(d_ln_max + 1);
   v_nocoarse_refine_schedules.resizeArray(d_ln_max + 1);
-  d_urestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
-  d_rrestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
+  p_urestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
+  p_rrestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
+  v_urestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
+  v_rrestriction_coarsen_schedules.resizeArray(d_ln_max + 1);
   d_flux_coarsen_schedules.resizeArray(d_ln_max + 1);
 
   d_prolongation_refine_algorithm = new xfer::RefineAlgorithm(d_dim);
-  d_urestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
-  d_rrestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
+  p_urestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
+  p_rrestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
+  v_urestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
+  v_rrestriction_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
   d_flux_coarsen_algorithm = new xfer::CoarsenAlgorithm(d_dim);
   p_ghostfill_refine_algorithm = new xfer::RefineAlgorithm(d_dim);
   v_ghostfill_refine_algorithm = new xfer::RefineAlgorithm(d_dim);
@@ -334,14 +352,22 @@ void SAMRAI::solv::StokesFACOps::initial
                    solution.getComponentDescriptorIndex(0),
                    d_cell_scratch_id,
                    d_prolongation_refine_operator);
-  d_urestriction_coarsen_algorithm->
+  p_urestriction_coarsen_algorithm->
     registerCoarsen(solution.getComponentDescriptorIndex(0),
                     solution.getComponentDescriptorIndex(0),
-                    d_urestriction_coarsen_operator);
-  d_rrestriction_coarsen_algorithm->
+                    p_urestriction_coarsen_operator);
+  p_rrestriction_coarsen_algorithm->
     registerCoarsen(rhs.getComponentDescriptorIndex(0),
                     rhs.getComponentDescriptorIndex(0),
-                    d_rrestriction_coarsen_operator);
+                    p_rrestriction_coarsen_operator);
+  v_urestriction_coarsen_algorithm->
+    registerCoarsen(solution.getComponentDescriptorIndex(1),
+                    solution.getComponentDescriptorIndex(1),
+                    v_urestriction_coarsen_operator);
+  v_rrestriction_coarsen_algorithm->
+    registerCoarsen(rhs.getComponentDescriptorIndex(1),
+                    rhs.getComponentDescriptorIndex(1),
+                    v_rrestriction_coarsen_operator);
   p_ghostfill_refine_algorithm->
     registerRefine(solution.getComponentDescriptorIndex(0),
                    solution.getComponentDescriptorIndex(0),
@@ -425,21 +451,38 @@ void SAMRAI::solv::StokesFACOps::initial
     }
   }
   for (int dest_ln = d_ln_min; dest_ln < d_ln_max; ++dest_ln) {
-    d_urestriction_coarsen_schedules[dest_ln] =
-      d_urestriction_coarsen_algorithm->
+    p_urestriction_coarsen_schedules[dest_ln] =
+      p_urestriction_coarsen_algorithm->
       createSchedule(d_hierarchy->getPatchLevel(dest_ln),
                      d_hierarchy->getPatchLevel(dest_ln + 1));
-    if (!d_urestriction_coarsen_schedules[dest_ln]) {
+    if (!p_urestriction_coarsen_schedules[dest_ln]) {
       TBOX_ERROR(d_object_name
-                 << ": Cannot create a coarsen schedule for U restriction!\n");
+                 << ": Cannot create a coarsen schedule for U p restriction!\n");
     }
-    d_rrestriction_coarsen_schedules[dest_ln] =
-      d_rrestriction_coarsen_algorithm->
+    p_rrestriction_coarsen_schedules[dest_ln] =
+      p_rrestriction_coarsen_algorithm->
       createSchedule(d_hierarchy->getPatchLevel(dest_ln),
                      d_hierarchy->getPatchLevel(dest_ln + 1));
-    if (!d_rrestriction_coarsen_schedules[dest_ln]) {
+    if (!p_rrestriction_coarsen_schedules[dest_ln]) {
       TBOX_ERROR(d_object_name
-                 << ": Cannot create a coarsen schedule for R restriction!\n");
+                 << ": Cannot create a coarsen schedule for R p restriction!\n");
+    }
+
+    v_urestriction_coarsen_schedules[dest_ln] =
+      v_urestriction_coarsen_algorithm->
+      createSchedule(d_hierarchy->getPatchLevel(dest_ln),
+                     d_hierarchy->getPatchLevel(dest_ln + 1));
+    if (!v_urestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR(d_object_name
+                 << ": Cannot create a coarsen schedule for U v restriction!\n");
+    }
+    v_rrestriction_coarsen_schedules[dest_ln] =
+      v_rrestriction_coarsen_algorithm->
+      createSchedule(d_hierarchy->getPatchLevel(dest_ln),
+                     d_hierarchy->getPatchLevel(dest_ln + 1));
+    if (!v_rrestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR(d_object_name
+                 << ": Cannot create a coarsen schedule for R v restriction!\n");
     }
     d_flux_coarsen_schedules[dest_ln] =
       d_flux_coarsen_algorithm->
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/restrictResidual.C
--- a/StokesFACOps/restrictResidual.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/restrictResidual.C	Sat Jan 08 06:14:56 2011 -0800
@@ -40,28 +40,24 @@
 #include "SAMRAI/xfer/RefineSchedule.h"
 #include "SAMRAI/xfer/PatchLevelFullFillPattern.h"
 
-namespace SAMRAI {
-  namespace solv {
-
-    /*
+/*
 ********************************************************************
 * FACOperatorStrategy virtual restrictresidual function.     *
 ********************************************************************
 */
 
-    void StokesFACOps::restrictResidual(
-                                        const SAMRAIVectorReal<double>& s,
-                                        SAMRAIVectorReal<double>& d,
-                                        int dest_ln) {
+void SAMRAI::solv::StokesFACOps::restrictResidual
+(const SAMRAIVectorReal<double>& s,
+ SAMRAIVectorReal<double>& d,
+ int dest_ln)
+{
+  t_restrict_residual->start();
 
-      t_restrict_residual->start();
+  xeqScheduleRRestriction(d.getComponentDescriptorIndex(0),
+                          s.getComponentDescriptorIndex(0),
+                          d.getComponentDescriptorIndex(1),
+                          s.getComponentDescriptorIndex(1),
+                          dest_ln);
 
-      xeqScheduleRRestriction(d.getComponentDescriptorIndex(0),
-                              s.getComponentDescriptorIndex(0),
-                              dest_ln);
-
-      t_restrict_residual->stop();
-    }
-
-  }
+  t_restrict_residual->stop();
 }
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/restrictSolution.C
--- a/StokesFACOps/restrictSolution.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/restrictSolution.C	Sat Jan 08 06:14:56 2011 -0800
@@ -40,10 +40,7 @@
 #include "SAMRAI/xfer/RefineSchedule.h"
 #include "SAMRAI/xfer/PatchLevelFullFillPattern.h"
 
-namespace SAMRAI {
-  namespace solv {
-
-    /*
+/*
 ********************************************************************
 * FACOperatorStrategy virtual restrictSolution function.     *
 * After restricting solution, update ghost cells of the affected   *
@@ -51,32 +48,29 @@ namespace SAMRAI {
 ********************************************************************
 */
 
-    void StokesFACOps::restrictSolution(
-                                        const SAMRAIVectorReal<double>& s,
-                                        SAMRAIVectorReal<double>& d,
-                                        int dest_ln) {
+void SAMRAI::solv::StokesFACOps::restrictSolution
+(const SAMRAIVectorReal<double>& s,
+ SAMRAIVectorReal<double>& d,
+ int dest_ln)
+{
+  t_restrict_solution->start();
 
-      t_restrict_solution->start();
+  xeqScheduleURestriction(d.getComponentDescriptorIndex(0),
+                          s.getComponentDescriptorIndex(0),
+                          d.getComponentDescriptorIndex(1),
+                          s.getComponentDescriptorIndex(1),
+                          dest_ln);
 
-      xeqScheduleURestriction(d.getComponentDescriptorIndex(0),
-                              s.getComponentDescriptorIndex(0),
-                              dest_ln);
+  // d_bc_helper.setHomogeneousBc(false);
+  // d_bc_helper.setTargetDataId(d.getComponentDescriptorIndex(0));
 
-      d_bc_helper.setHomogeneousBc(false);
-      d_bc_helper.setTargetDataId(d.getComponentDescriptorIndex(0));
+  if (dest_ln == d_ln_min) {
+    xeqScheduleGhostFillNoCoarse(d.getComponentDescriptorIndex(0),
+                                 d.getComponentDescriptorIndex(1), dest_ln);
+  } else {
+    xeqScheduleGhostFill(d.getComponentDescriptorIndex(0),
+                         d.getComponentDescriptorIndex(1), dest_ln);
+  }
 
-      if (dest_ln == d_ln_min) {
-        // xeqScheduleGhostFillNoCoarse(d.getComponentDescriptorIndex(0),
-        //                              dest_ln);
-        abort();
-      } else {
-        // xeqScheduleGhostFill(d.getComponentDescriptorIndex(0),
-        //                      dest_ln);
-        abort();
-      }
-
-      t_restrict_solution->stop();
-    }
-
-  }
+  t_restrict_solution->stop();
 }
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/xeqScheduleRRestriction.C
--- a/StokesFACOps/xeqScheduleRRestriction.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/xeqScheduleRRestriction.C	Sat Jan 08 06:14:56 2011 -0800
@@ -40,28 +40,39 @@
 #include "SAMRAI/xfer/RefineSchedule.h"
 #include "SAMRAI/xfer/PatchLevelFullFillPattern.h"
 
-namespace SAMRAI {
-  namespace solv {
-
-    void
-    StokesFACOps::xeqScheduleRRestriction(
-                                          int dst_id,
-                                          int src_id,
-                                          int dest_ln)
-    {
-      if (!d_rrestriction_coarsen_schedules[dest_ln]) {
-        TBOX_ERROR("Expected schedule not found.");
-      }
-
-      xfer::CoarsenAlgorithm coarsener(d_dim);
-      coarsener.registerCoarsen(dst_id,
-                                src_id,
-                                d_rrestriction_coarsen_operator);
-      coarsener.resetSchedule(d_rrestriction_coarsen_schedules[dest_ln]);
-      d_rrestriction_coarsen_schedules[dest_ln]->coarsenData();
-      d_rrestriction_coarsen_algorithm->
-        resetSchedule(d_rrestriction_coarsen_schedules[dest_ln]);
+void SAMRAI::solv::StokesFACOps::xeqScheduleRRestriction(int p_dst, int p_src,
+                                                         int v_dst, int v_src,
+                                                         int dest_ln)
+{
+  /* p */
+  {
+    if (!p_rrestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR("Expected schedule not found.");
     }
 
+    xfer::CoarsenAlgorithm coarsener(d_dim);
+    coarsener.registerCoarsen(p_dst,
+                              p_src,
+                              p_rrestriction_coarsen_operator);
+    coarsener.resetSchedule(p_rrestriction_coarsen_schedules[dest_ln]);
+    p_rrestriction_coarsen_schedules[dest_ln]->coarsenData();
+    p_rrestriction_coarsen_algorithm->
+      resetSchedule(p_rrestriction_coarsen_schedules[dest_ln]);
+  }
+
+  /* v */
+  {
+    if (!v_rrestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR("Expected schedule not found.");
+    }
+
+    xfer::CoarsenAlgorithm coarsener(d_dim);
+    coarsener.registerCoarsen(v_dst,
+                              v_src,
+                              v_rrestriction_coarsen_operator);
+    coarsener.resetSchedule(v_rrestriction_coarsen_schedules[dest_ln]);
+    v_rrestriction_coarsen_schedules[dest_ln]->coarsenData();
+    v_rrestriction_coarsen_algorithm->
+      resetSchedule(v_rrestriction_coarsen_schedules[dest_ln]);
   }
 }
diff -r a2e84a92deb1 -r 1de270f5a15e StokesFACOps/xeqScheduleURestriction.C
--- a/StokesFACOps/xeqScheduleURestriction.C	Fri Jan 07 16:41:05 2011 -0800
+++ b/StokesFACOps/xeqScheduleURestriction.C	Sat Jan 08 06:14:56 2011 -0800
@@ -40,28 +40,35 @@
 #include "SAMRAI/xfer/RefineSchedule.h"
 #include "SAMRAI/xfer/PatchLevelFullFillPattern.h"
 
-namespace SAMRAI {
-  namespace solv {
-
-    void
-    StokesFACOps::xeqScheduleURestriction(
-                                          int dst_id,
-                                          int src_id,
-                                          int dest_ln)
-    {
-      if (!d_urestriction_coarsen_schedules[dest_ln]) {
-        TBOX_ERROR("Expected schedule not found.");
-      }
-
-      xfer::CoarsenAlgorithm coarsener(d_dim);
-      coarsener.registerCoarsen(dst_id,
-                                src_id,
-                                d_urestriction_coarsen_operator);
-      coarsener.resetSchedule(d_urestriction_coarsen_schedules[dest_ln]);
-      d_urestriction_coarsen_schedules[dest_ln]->coarsenData();
-      d_urestriction_coarsen_algorithm->
-        resetSchedule(d_urestriction_coarsen_schedules[dest_ln]);
+void SAMRAI::solv::StokesFACOps::xeqScheduleURestriction(int p_dst, int p_src,
+                                                         int v_dst, int v_src,
+                                                         int dest_ln)
+{
+  /* p */
+  {
+    if (!p_urestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR("Expected schedule not found.");
     }
 
+    xfer::CoarsenAlgorithm coarsener(d_dim);
+    coarsener.registerCoarsen(p_dst, p_src, p_urestriction_coarsen_operator);
+    coarsener.resetSchedule(p_urestriction_coarsen_schedules[dest_ln]);
+    p_urestriction_coarsen_schedules[dest_ln]->coarsenData();
+    p_urestriction_coarsen_algorithm->
+      resetSchedule(p_urestriction_coarsen_schedules[dest_ln]);
+  }
+
+  /* v */
+  {
+    if (!v_urestriction_coarsen_schedules[dest_ln]) {
+      TBOX_ERROR("Expected schedule not found.");
+    }
+
+    xfer::CoarsenAlgorithm coarsener(d_dim);
+    coarsener.registerCoarsen(v_dst, v_src, v_urestriction_coarsen_operator);
+    coarsener.resetSchedule(v_urestriction_coarsen_schedules[dest_ln]);
+    v_urestriction_coarsen_schedules[dest_ln]->coarsenData();
+    v_urestriction_coarsen_algorithm->
+      resetSchedule(v_urestriction_coarsen_schedules[dest_ln]);
   }
 }



More information about the CIG-COMMITS mailing list