On 03/02/2018 08:38 AM, 曾元圆 wrote:
3. In the member function: WeightedResidual<dim>::refine_grid(), you firstly
defined a Vector error_indicators whose dimension is n_active_cells of the
triangulation, then you call the function "estimate_error(error_indicators)"
to compute the error_indicators. But in the
function "estimate_error(Vector<float>& error_indicators)", I noticed that you
reinitialize the error_indicators by calling
"error_indicators.reinit(DualSolver<dim>::dof_handler.get_triangulation().n_active_cells());",
so why you do this? Since the PrimalSolver and DualSolver are both derived
from the base class and they share the same triangulation, then what is the
purpose of using DualSolver<dim>::dof_handler.get_triangulation to reinit
error_indicator?
Yes, this seems duplicative and unnecessary. The reinit call in
estimate_error() in line 2356 could be removed.
Do you want to try to submit a patch for this and become one of the authors of
deal.II? Or would you prefer me doing this? (We always appreciate newcomers'
patches, and this case would be no different -- and I think this would
actually make for a really nice first contribution!)
Best
Wolfgang
--
------------------------------------------------------------------------
Wolfgang Bangerth email: [email protected]
www: http://www.math.colostate.edu/~bangerth/
--
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see
https://groups.google.com/d/forum/dealii?hl=en
---
You received this message because you are subscribed to the Google Groups "deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.