Dear Prof. Wolfgang,
Thank you for your concern and
understanding.
Yes you are right. I tried something similar instead of copying the
triangulation.
I used *const SmartPointer<const Triangulation<dim> >* to transfer
triangulation between both thermal and the solid mechanics classes and
seemingly the objective of using same triangulation for both parts is full
filled also with same refinement and coarsening.
While for the sake of using different *dof_handler* for temperature and
solid mechanics, I currently have to define again the
temperature_dof_handler as well as the fe_temperature objects in the solid
mechanics (class) part to do something like following:
*dof_handler_temperature.distribute_dofs(fe_temperature);*
* cell_solid_mech = dof_handler.begin_active();*
* cell_temperature = dof_handler_temperature.begin_active();*
(for loop for *cell_solid_mech and **cell_temperature* )
* fe_values_solid_mech.reinit(cell_solid_mech);
fe_values_temperature.reinit(cell_temperature); cell_matrix =
0; cell_rhs = 0;
fe_values_temperature.get_function_values(temperature_solution,
temperature_solution_qpoint); *
*fe_values_solid_mech[displacement].get_function_symmetric_gradients(displacement_solution,
strain_tensor);*
So in this way, I am successful in using the common triangulation for both
parts but with different corresponding dof_handlers.
The only thing is that I was wondering if I might be using extra processing
and memory by defining the fe_temperature, dof_handler_temperature and
fe_values_temperature by defining them again in the solid mechanics
program. And if I am, then would there be any alternative method where I
can use the *const SmartPointer<const DoFHandler<dim> > *and *const
SmartPointer<const FE_Q<dim><dim> > *or something similar to return *
fe_temperature* and *dof_handler_temperature* from *HeatEquation* class to
*SolidMechanics* class (where they are being used for evaluating q_point
temperature as I mentioned above) ? Thank you!
On Sunday, August 4, 2019 at 11:54:58 PM UTC+2, Wolfgang Bangerth wrote:
>
> On 8/2/19 4:01 AM, Muhammad Mashhood wrote:
> >
> > considering the above scenario as well as the concerns, I would be
> grateful to
> > receive any suggestion from your side. Hope I am clear in my
> description.
> > Waiting for your kind response. Thank you in advance!
>
> Instead of copying triangulations, you always have the option of just
> creating
> the two objects the same, and then refining them in exactly the same way.
> Would that solve your problem?
>
> Best
> W.
>
>
> --
> ------------------------------------------------------------------------
> Wolfgang Bangerth email: [email protected]
> <javascript:>
> 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].
To view this discussion on the web visit
https://groups.google.com/d/msgid/dealii/91710d89-ac27-4df9-bbb3-1298853d705f%40googlegroups.com.