# Mesh generation

**URL:** <https://community.freefem.org/t/mesh-generation/551>\
**Category:** General Discussion\
**Created:** [August 27, 2020, 6:23pm UTC](https://community.freefem.org/t/mesh-generation/551 "2020-08-27T18:23:53Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![mordechaiy](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Post date:** [August 27, 2020, 6:23pm UTC](https://community.freefem.org/t/mesh-generation/551/1 "2020-08-27T18:23:54Z")

</div>

Hello,

I wanted to ask please,

1. Is it possible in FreeFem++ to generate a uniform mesh while using the commands “border” and “buildmesh”? I looked at the FreeFem++ tutorial but, didn’t find an example.  
I know that the command “mesh Th= square (n,n)” will generate a uniform mesh for the rectangle but, I don’t know if I can add a subdomain after using the square command.  
Which, lead me to my second question
2. Is it possible in FreeFem++ to add a subdomain after using the command “square”?

Tanks,  
Mordechai.

---

<div class="post-metadata">

**Author:** ![prj](https://avatars.discourse-cdn.com/v4/letter/p/ecae2f/32.png) [@prj](https://community.freefem.org/u/prj)\
**Post date:** [August 27, 2020, 6:52pm UTC](https://community.freefem.org/t/mesh-generation/551/2 "2020-08-27T18:52:09Z")

</div>

About 2., you can definitely add a subdomain. Here is [one](https://github.com/FreeFem/FreeFem-sources/blob/develop/examples/hpddm/stokes-2d-PETSc.edp#L21) example, using the operator `+`. Just make sure that your meshes are conforming.

---

<div class="post-metadata">

**Author:** ![mordechaiy](https://avatars.discourse-cdn.com/v4/letter/m/cc9497/32.png) [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Post date:** [August 27, 2020, 7:05pm UTC](https://community.freefem.org/t/mesh-generation/551/3 "2020-08-27T19:05:33Z")

</div>

Thank you very much!
