cell iterator for data post processor

31 views
Skip to first unread message

Prateek Sharma

unread,
Mar 20, 2018, 6:56:29 AM3/20/18
to deal.II User Group
Hello,

I want to calculate output data that are specific to each cell. Each cell has a different material property.

I am plotting the data using the function compute_derived_quantities_vector(..) under DataPostprocessor class. Is there any way to know which cell is currently being calculated by this function or can I access the cell iterator/pointer in this function?

A similar problem was discussed in this topic:
https://groups.google.com/forum/#!topic/dealii/QKuDndKojug

The link to the Git code for the above mentioned topic could also be helpful.

Thanks in advance,
Prateek

Wolfgang Bangerth

unread,
Mar 20, 2018, 9:11:33 AM3/20/18
to Prateek Sharma, deal.II user group

Prateek,

> I want to calculate output data that are specific to each cell. Each cell has
> a different material property.
>
> I am plotting the data using the function
> /compute_derived_quantities_vector(..) /under DataPostprocessor class. Is
> there any way to know which cell is currently being calculated by this
> function or can I access the cell iterator/pointer in this function?

If you compare the documentation between 8.4 and 8.5, you will see that the
DataPostprocessor class has been reorganized a bit:

https://www.dealii.org/8.4.0/doxygen/deal.II/classDataPostprocessor.html
https://www.dealii.org/8.5.0/doxygen/deal.II/classDataPostprocessor.html

In particular, the compute_derived_quantities_*() functions have been
deprecated (and indeed removed in the current development version). The
evaluate_*_field() functions take objects that are derived from
DataPostprocessorInputs::CommonInputs which has a way to access the cell:

https://www.dealii.org/8.5.0/doxygen/deal.II/structDataPostprocessorInputs_1_1CommonInputs.html

I think this is exactly what you are looking for.

Best
W.


--
------------------------------------------------------------------------
Wolfgang Bangerth email: bang...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/

Reply all
Reply to author
Forward
0 new messages