CellSize(mesh) equivalent in c++

Asked by Patrick Riesen

dear all

I'm updating my code to the newest dolfin components (c++ code)

i used a defined function for the cell size

h = new CellSize(mesh);

in python, i noticed that this function still exists but what is the equivalent in c++ for the recent dolfin?

best regards,
patrick

Question information

Language:
English Edit question
Status:
Answered
For:
DOLFIN Edit question
Assignee:
No assignee Edit question
Last query:
Last reply:
Revision history for this message
Patrick Riesen (priesen) said :
#1

sorry to bother again but
I could not find any c++ class for CellSize in the recent dolfin 1.2 release.
Was this renamed or removed?

How can I get a function for the cell sizes in my c++ code?

Or can/should I define it in a ufl-form?

happy easter,
patrick

Revision history for this message
Garth Wells (garth-wells) said :
#2

On 29 March 2013 08:11, Patrick Riesen
<email address hidden> wrote:
> Question #225050 on DOLFIN changed:
> https://answers.launchpad.net/dolfin/+question/225050
>
> Patrick Riesen gave more information on the question:
> sorry to bother again but
> I could not find any c++ class for CellSize in the recent dolfin 1.2 release.
> Was this renamed or removed?
>
> How can I get a function for the cell sizes in my c++ code?
>
> Or can/should I define it in a ufl-form?
>

Yes and yes. Look at

    demo/undocumented/dg-advection-diffusion/cpp/AdvectionDiffusion.ufl

If you want access from the C++ side, you could build a MeshFunction
using one of the functions in Cell.

Garth

> happy easter,
> patrick
>
> --
> You received this question notification because you are a member of
> DOLFIN Team, which is an answer contact for DOLFIN.

Can you help with this problem?

Provide an answer of your own, or ask Patrick Riesen for more information if necessary.

To post a message you must log in.