From ac5ff75699f65be5a5d00dddd23ce12cd31affa5 Mon Sep 17 00:00:00 2001 From: Ping He Date: Sun, 30 Jun 2024 08:48:08 -0500 Subject: [PATCH] Fixed bugs in snapCenter. --- src/adjoint/DAFvSource/DAFvSourceHeatSource.C | 7 +++- src/adjoint/DAObjFunc/DAObjFuncLocation.C | 40 ++++++++++--------- src/adjoint/DAObjFunc/DAObjFuncMass.C | 30 ++++++++++---- src/adjoint/DAObjFunc/DAObjFuncMass.H | 3 ++ 4 files changed, 54 insertions(+), 26 deletions(-) diff --git a/src/adjoint/DAFvSource/DAFvSourceHeatSource.C b/src/adjoint/DAFvSource/DAFvSourceHeatSource.C index 975c1ed3..a3a7261d 100755 --- a/src/adjoint/DAFvSource/DAFvSourceHeatSource.C +++ b/src/adjoint/DAFvSource/DAFvSourceHeatSource.C @@ -121,6 +121,7 @@ DAFvSourceHeatSource::DAFvSourceHeatSource( if (snappedCenterCellI_[sourceName] >= 0) { foundCellI = 1; + //Pout << "snap source " << sourceName << " to center " << mesh_.C()[snappedCenterCellI_[sourceName]] << endl; } reduce(foundCellI, sumOp