Dear Joel,

The way I interpret what you've written here, you're asking two different 
questions. In the first statement, it sounds like you have a mesh that you 
wish to increase the size of at some arbitrary time, and the second you 
know the final bounds *a priori*.

Let me start with your second viewpoint, which is easiest. You could use 
GridGenerator::subdivided_hyper_cube 
<https://www.dealii.org/developer/doxygen/deal.II/namespaceGridGenerator.html#adc5d7022d456db0356f11427473f4f76>
 or GridGenerator::subdivided_hyper_rectangle 
<https://www.dealii.org/developer/doxygen/deal.II/namespaceGridGenerator.html#ac76417d7404b75cf53c732f456e6e971>
 to 
specify any regular discretisation of a Cartesian-aligned volume. So, yes, 
given that you know the edge length and the size of the elements, you could 
compute the necessary number of elements in each dimension. If this doesn't 
give you the exact dimensions of the green box, then you can just move the 
vertices around 
<https://www.dealii.org/developer/doxygen/deal.II/step_49.html#grid_3Movingvertices>
 
as necessary.

Achieving your goal from the first viewpoint requires more work. To 
"increase" the size of the grid entails joining triangulations of *zero 
refinement 
levels* (i.e. no mesh refinement). So you would need to first create a 
coarse grid (1 for the green box (which I interpret as being something that 
you have initially) and then 4 more that share the edges and another 4 that 
share its vertices, then join them 
<https://www.dealii.org/developer/doxygen/deal.II/step_49.html#grid_2Mergingtriangulations>.
 
Since you have to join equally coarse meshes, all of these meshes probably 
need to created as "discretised" GridGenerator::subdivided_hyper_rectangle 
<https://www.dealii.org/developer/doxygen/deal.II/namespaceGridGenerator.html#ac76417d7404b75cf53c732f456e6e971>s
 
in the first place.

A third option would be to use a hp::DoFHandler 
<https://www.dealii.org/developer/doxygen/deal.II/step_46.html> and use 
FE_Nothing 
<https://www.dealii.org/developer/doxygen/deal.II/classFE__Nothing.html> 
elements in the region outside the green box. You could then "grow" the 
mesh by activating these elements at any time.

I hope that this has been useful to you. Apologies in advance if I don't 
respond to any further messages - from tomorrow I'll be away from my PC for 
a while.

Regards,
J-P

On Thursday, August 4, 2016 at 3:33:29 PM UTC+2, Joel Davidsson wrote:
>
> Dear all,
>
> Is there some way that one can refine the mesh in the following way, see 
> attached file: I looking for a way to increase the size of the grid but 
> keeping the original nodes fixed. If you look in the attached file, you see 
> that an extra "layer" has formed around the original mesh marked in green. 
> In this way, the size of the individual element does not change.
>
> Another way of looking at it. If I specify a volume and a size of the 
> smallest element, can I fill this volume with these elements?
>
> Best,
> Joel
>

-- 
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 dealii+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to