From: Jean-Paul Pelteret Date: Tue, 19 Jul 2022 21:33:59 +0000 (+0200) Subject: Update tutorials to use cell->as_dof_handler_iterator() X-Git-Tag: v9.5.0-rc1~1071^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e7a5a014b26f2180401ba38b229c280f4aa844a9;p=dealii.git Update tutorials to use cell->as_dof_handler_iterator() --- diff --git a/examples/step-32/step-32.cc b/examples/step-32/step-32.cc index 309c0064ba..a66bda791a 100644 --- a/examples/step-32/step-32.cc +++ b/examples/step-32/step-32.cc @@ -2218,8 +2218,8 @@ namespace Step32 scratch.stokes_fe_values.reinit(cell); - typename DoFHandler::active_cell_iterator temperature_cell( - &triangulation, cell->level(), cell->index(), &temperature_dof_handler); + const typename DoFHandler::active_cell_iterator temperature_cell = + cell->as_dof_handler_iterator(temperature_dof_handler); scratch.temperature_fe_values.reinit(temperature_cell); if (rebuild_stokes_matrix) @@ -2485,8 +2485,8 @@ namespace Step32 scratch.temperature_fe_values.reinit(cell); - typename DoFHandler::active_cell_iterator stokes_cell( - &triangulation, cell->level(), cell->index(), &stokes_dof_handler); + typename DoFHandler::active_cell_iterator stokes_cell = + cell->as_dof_handler_iterator(stokes_dof_handler); scratch.stokes_fe_values.reinit(stokes_cell); scratch.temperature_fe_values.get_function_values( diff --git a/examples/step-51/step-51.cc b/examples/step-51/step-51.cc index 60ec5c8901..648cdc1392 100644 --- a/examples/step-51/step-51.cc +++ b/examples/step-51/step-51.cc @@ -698,10 +698,8 @@ namespace Step51 PerTaskData & task_data) { // Construct iterator for dof_handler_local for FEValues reinit function. - typename DoFHandler::active_cell_iterator loc_cell(&triangulation, - cell->level(), - cell->index(), - &dof_handler_local); + const typename DoFHandler::active_cell_iterator loc_cell = + cell->as_dof_handler_iterator(dof_handler_local); const unsigned int n_q_points = scratch.fe_values_local.get_quadrature().size(); @@ -1128,10 +1126,8 @@ namespace Step51 PostProcessScratchData & scratch, unsigned int &) { - typename DoFHandler::active_cell_iterator loc_cell(&triangulation, - cell->level(), - cell->index(), - &dof_handler_local); + const typename DoFHandler::active_cell_iterator loc_cell = + cell->as_dof_handler_iterator(dof_handler_local); scratch.fe_values_local.reinit(loc_cell); scratch.fe_values.reinit(cell);