# General Discussion

**URL:** https://community.freefem.org/c/general-discussion/7.md?page=67

[Latest](https://community.freefem.org/latest.md) · [Categories](https://community.freefem.org/categories.md)

**Page:** 68

---

## [High memory usage in vector space problems using PETSc](https://community.freefem.org/t/high-memory-usage-in-vector-space-problems-using-petsc/617)

<div class="topic-metadata">

**Author:** [@mojtaba.barzegari](https://community.freefem.org/u/mojtaba.barzegari)\
**Replies:** 2\
**Last updated:** [October 18, 2020, 3:14pm UTC](https://community.freefem.org/t/high-memory-usage-in-vector-space-problems-using-petsc/617 "2020-10-18T15:14:57Z")

</div>

Hi, During the development of simple Stokes and Navier-Stokes solvers using the PETSc interface in FF, I noticed that the suggested combination of GMRES KSP type and LU preconditioner (with MUMPS) utilizes a tremendous …

---

## [Backward problem to the 2D wave eqaution](https://community.freefem.org/t/backward-problem-to-the-2d-wave-eqaution/618)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 0\
**Last updated:** [October 17, 2020, 7:20pm UTC](https://community.freefem.org/t/backward-problem-to-the-2d-wave-eqaution/618 "2020-10-17T19:20:11Z")

</div>

Hi, I am solving the 2D wave equation on a square with a hole with uniform mesh, where the number of partitions in each direction is 128. Since I used “trunc” command in my code the (Degrees of Freedom) DOF in this doma…

---

## [Inlet boundary conditions](https://community.freefem.org/t/inlet-boundary-conditions/613)

<div class="topic-metadata">

**Author:** [@sgkkr](https://community.freefem.org/u/sgkkr)\
**Replies:** 0\
**Last updated:** [October 12, 2020, 1:57pm UTC](https://community.freefem.org/t/inlet-boundary-conditions/613 "2020-10-12T13:57:28Z")

</div>

I have a sparse values of the velocity field at the inlet of channel. I would like to interpolate the velocity field at the inlet over the fine grid mesh. I am using the interpolate command from FreeFem++ to use the info…

---

## [VTK output problem](https://community.freefem.org/t/vtk-output-problem/606)

<div class="topic-metadata">

**Author:** [@WenW](https://community.freefem.org/u/WenW)\
**Replies:** 4\
**Last updated:** [October 12, 2020, 11:54am UTC](https://community.freefem.org/t/vtk-output-problem/606 "2020-10-12T11:54:49Z")

</div>

Dear developers, I started to use freefeem recently. I am running a code on my computer (win10), but the generated vtk file cannot be read correctly by paraview. However, when I run the same code on another machine (als…

---

## [Scattered field](https://community.freefem.org/t/scattered-field/611)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 0\
**Last updated:** [October 11, 2020, 10:19am UTC](https://community.freefem.org/t/scattered-field/611 "2020-10-11T10:19:18Z")

</div>

Hi every one, I am trying to simulate a scatter field for the 2d wave equation using FF++. the code runs but the result is that the scattered field is always zero which clearly not true, it is zero until t=11, then wa…

---

## [What the differences between BDM1 spaces and \[P1,P1\] spaces?](https://community.freefem.org/t/what-the-differences-between-bdm1-spaces-and-p1-p1-spaces/607)

<div class="topic-metadata">

**Author:** [@SunFan](https://community.freefem.org/u/SunFan)\
**Replies:** 0\
**Last updated:** [October 9, 2020, 3:21am UTC](https://community.freefem.org/t/what-the-differences-between-bdm1-spaces-and-p1-p1-spaces/607 "2020-10-09T03:21:04Z")

</div>

For 3d simulations, we want to use BDDF spaces, but FreeFem++ do not have this type of spaces, only have RT03d. So we can see the definition of BDM1 or BDDF1 spaces is that the vector belongs to P1^2, so why we can not u…

---

## [Composition of functions](https://community.freefem.org/t/composition-of-functions/603)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 3\
**Last updated:** [October 6, 2020, 9:17pm UTC](https://community.freefem.org/t/composition-of-functions/603 "2020-10-06T21:17:56Z")

</div>

Hi everyone, I would like to ask please, I defined the following functions : h1(z)=(abs(z)-1)^2\*(1+2\*abs(z)), for -1\<z\<1 otherwise h1(z)=0. z(x,y)=((x-x0)\*cos(theta)+(y-y0)sin(theta)+ct)/lambda. and would like to co…

---

## [Edge03d Finite Element Assembly](https://community.freefem.org/t/edge03d-finite-element-assembly/600)

<div class="topic-metadata">

**Author:** [@novelnj](https://community.freefem.org/u/novelnj)\
**Replies:** 4\
**Last updated:** [October 6, 2020, 7:53pm UTC](https://community.freefem.org/t/edge03d-finite-element-assembly/600 "2020-10-06T19:53:22Z")

</div>

Hello, I am solving a electromagnetic numerical problem. I can construct the 3d Nedelec finite element with degree 1 (Edge03d) and the system matrix K. What I want to know is how the matrix K is been constructed in this…

---

## [Non-overlapping mesh](https://community.freefem.org/t/non-overlapping-mesh/593)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 4\
**Last updated:** [October 6, 2020, 6:03pm UTC](https://community.freefem.org/t/non-overlapping-mesh/593 "2020-10-06T18:03:04Z")

</div>

Hi to all, I created in FF+ a domain which is a square \[0,3\]x\[0,3\], using the command “square”, then I add a subdomain \[0.9,2.1\]x\[0.9,2.1\] using the “+” operator. Finally a subtracted a subdomain \[1.05,1.95\]x\[1.05,1.95\]…

---

## [Define a function](https://community.freefem.org/t/define-a-function/601)

<div class="topic-metadata">

**Author:** [@Aicha](https://community.freefem.org/u/Aicha)\
**Replies:** 1\
**Last updated:** [October 6, 2020, 2:43pm UTC](https://community.freefem.org/t/define-a-function/601 "2020-10-06T14:43:10Z")

</div>

Hi,

---

## [Resolve two pde with FF++](https://community.freefem.org/t/resolve-two-pde-with-ff/599)

<div class="topic-metadata">

**Author:** [@Aicha](https://community.freefem.org/u/Aicha)\
**Replies:** 2\
**Last updated:** [October 5, 2020, 6:03pm UTC](https://community.freefem.org/t/resolve-two-pde-with-ff/599 "2020-10-05T18:03:42Z")

</div>

Hi, i havethe two following problems: (we add periodic boundary conditions to the two problems. I have the following code FF++ to calculate the approximate solutions of two problems and compare the curves of solutionsr…

---

## [How to export data?](https://community.freefem.org/t/how-to-export-data/597)

<div class="topic-metadata">

**Author:** [@dajopez](https://community.freefem.org/u/dajopez)\
**Replies:** 2\
**Last updated:** [October 4, 2020, 4:15am UTC](https://community.freefem.org/t/how-to-export-data/597 "2020-10-04T04:15:44Z")

</div>

So I have calulated a bunch of matrices with data, and I want to graph them/perform analysis. How do I export it into a data file? Thanks.

---

## [Global node numbering on a face of the cube](https://community.freefem.org/t/global-node-numbering-on-a-face-of-the-cube/595)

<div class="topic-metadata">

**Author:** [@pdapte1999](https://community.freefem.org/u/pdapte1999)\
**Replies:** 0\
**Last updated:** [September 25, 2020, 7:20am UTC](https://community.freefem.org/t/global-node-numbering-on-a-face-of-the-cube/595 "2020-09-25T07:20:48Z")

</div>

Dear all, I have used ‘cube.idp’ and extracted the global mass and stiffness matrices using the code given below. Now I need the global numbering of nodes on one of the faces of the cube. Can anyone help me out how to g…

---

## [FreeFEM stalls after some time (probably) due to some exception](https://community.freefem.org/t/freefem-stalls-after-some-time-probably-due-to-some-exception/586)

<div class="topic-metadata">

**Author:** [@UgisL](https://community.freefem.org/u/UgisL)\
**Replies:** 3\
**Last updated:** [September 23, 2020, 5:04am UTC](https://community.freefem.org/t/freefem-stalls-after-some-time-probably-due-to-some-exception/586 "2020-09-23T05:04:36Z")

</div>

Hi everyone, I have encountered a strange issue which I have troubles of finding solution for. I am solving a coupled Cahn-Hilliard/Navier-Stokes system and stepping over time. The strange thing is that for a while the …

---

## [Coupled high order PDE](https://community.freefem.org/t/coupled-high-order-pde/577)

<div class="topic-metadata">

**Author:** [@alexwems1](https://community.freefem.org/u/alexwems1)\
**Replies:** 2\
**Last updated:** [September 23, 2020, 1:45am UTC](https://community.freefem.org/t/coupled-high-order-pde/577 "2020-09-23T01:45:25Z")

</div>

Hi, Can I have some help to solve this PDEs system. I am having a lot of troubles with this. This are the equations: ! If you wanna see more about, you can watch this document. https://docs.google.com/document/d/1ix\_8…

---

## [Import the mesh from Gmsh including multi domains](https://community.freefem.org/t/import-the-mesh-from-gmsh-including-multi-domains/590)

<div class="topic-metadata">

**Author:** [@Fakhraddin](https://community.freefem.org/u/Fakhraddin)\
**Replies:** 1\
**Last updated:** [September 22, 2020, 2:20pm UTC](https://community.freefem.org/t/import-the-mesh-from-gmsh-including-multi-domains/590 "2020-09-22T14:20:05Z")

</div>

Dear All, I am trying to import a 2D mesh from Gmsh containing 2 subdomains (physical groups) and their interfaces. I labeled the subdomains as “fluid” and “solid” in Gmsh. I’m using the command: mesh Th=gmshload(“Bone.…

---

## [P1+P0 for pressure](https://community.freefem.org/t/p1-p0-for-pressure/196)

<div class="topic-metadata">

**Author:** [@amina](https://community.freefem.org/u/amina)\
**Replies:** 5\
**Last updated:** [September 21, 2020, 8:08am UTC](https://community.freefem.org/t/p1-p0-for-pressure/196 "2020-09-21T08:08:21Z")

</div>

Dear all, I’m trying to implement an augmented Taylor-Hood method for mixed problems with a discontinuous pression finite element of the type P1+P0 (and not P1dc). That anyone have a clue? I tried fespace Vh(Th, P1+P0…

---

## [C++ functions in FreeFem++](https://community.freefem.org/t/c-functions-in-freefem/535)

<div class="topic-metadata">

**Author:** [@AbdelhakTouiti](https://community.freefem.org/u/AbdelhakTouiti)\
**Replies:** 2\
**Last updated:** [September 21, 2020, 11:02am UTC](https://community.freefem.org/t/c-functions-in-freefem/535 "2020-09-21T11:02:06Z")

</div>

How could I add my own C++ functions to FreeFem++??

---

## [Error in a simple mesh generation from FreeFem++?](https://community.freefem.org/t/error-in-a-simple-mesh-generation-from-freefem/585)

<div class="topic-metadata">

**Author:** [@rgrunbla](https://community.freefem.org/u/rgrunbla)\
**Replies:** 4\
**Last updated:** [September 20, 2020, 7:35am UTC](https://community.freefem.org/t/error-in-a-simple-mesh-generation-from-freefem/585 "2020-09-20T07:35:21Z")

</div>

Hi there, I’m trying to generate a mesh using FreeFem++ and the docker image (because packaging is broken right now on my OS). While it works online using https://freefem.org/tryit (see the attached screenshot), it doe…

---

## [Exact Dirichlet BC](https://community.freefem.org/t/exact-dirichlet-bc/52)

<div class="topic-metadata">

**Author:** [@fotios.kasolis](https://community.freefem.org/u/fotios.kasolis)\
**Replies:** 3\
**Last updated:** [September 18, 2020, 7:01am UTC](https://community.freefem.org/t/exact-dirichlet-bc/52 "2020-09-18T07:01:15Z")

</div>

Hallo all, The code below substitutes the penalized Dirichlet BC with an exact one, while preserving the symmetry of A. With this approach I face the following issue; the introduced zeros increase the nnz of A. Is there…

---

## [Lagrange Multipliers and Adaptive Meshing](https://community.freefem.org/t/lagrange-multipliers-and-adaptive-meshing/582)

<div class="topic-metadata">

**Author:** [@kevinmo08](https://community.freefem.org/u/kevinmo08)\
**Replies:** 1\
**Last updated:** [September 16, 2020, 4:53am UTC](https://community.freefem.org/t/lagrange-multipliers-and-adaptive-meshing/582 "2020-09-16T04:53:07Z")

</div>

Hi all, I am confused as to how to implement adaptive meshing for a lagrange multiplier problem. The code example for the lagrange multiplier is here https://doc.freefem.org/examples/finite-element.html#examplelagrangem…

---

## [Boundary condition on half edge](https://community.freefem.org/t/boundary-condition-on-half-edge/571)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 17\
**Last updated:** [September 16, 2020, 4:39am UTC](https://community.freefem.org/t/boundary-condition-on-half-edge/571 "2020-09-16T04:39:34Z")

</div>

Hello to every one, I would like to ask please, Suppose I created a square using the “square” command, and I want to define on a certain edge of this square that on half-edge Dirichlet boundary condition, u=0, and in t…

---

## [Example code not working](https://community.freefem.org/t/example-code-not-working/580)

<div class="topic-metadata">

**Author:** [@aszaboa](https://community.freefem.org/u/aszaboa)\
**Replies:** 6\
**Last updated:** [September 15, 2020, 3:08pm UTC](https://community.freefem.org/t/example-code-not-working/580 "2020-09-15T15:08:34Z")

</div>

Dear @prj, I would like to use the ‘Augmented Lagrangian Preconditioner for Large-Scale Hydrodynamic Stability Analysis’ method based on your codes. However, when I try to run the codes, the base-flow calculation runs f…

---

## [Bad orientation](https://community.freefem.org/t/bad-orientation/411)

<div class="topic-metadata">

**Author:** [@JAlonso](https://community.freefem.org/u/JAlonso)\
**Replies:** 15\
**Last updated:** [September 12, 2020, 8:25pm UTC](https://community.freefem.org/t/bad-orientation/411 "2020-09-12T20:25:19Z")

</div>

Dear colleages, I am trying to solve a 3D problem on a thick slice with a pentagonal hole. I have used gmsh to build up the mesh with the following code cl1=0.5; Mesh.Format=30; Point(1)={-1,0,0,cl1}; Point(2)={1,0…

---

## [Adaptmesh in 3D](https://community.freefem.org/t/adaptmesh-in-3d/578)

<div class="topic-metadata">

**Author:** [@Romuald](https://community.freefem.org/u/Romuald)\
**Replies:** 2\
**Last updated:** [September 9, 2020, 7:18am UTC](https://community.freefem.org/t/adaptmesh-in-3d/578 "2020-09-09T07:18:39Z")

</div>

Hi is anyone aware of a way to perform a mesh adaptation in 3D like in 2D with Adaptmesh? Thanks, Romuald

---

## [Wave equation in a square](https://community.freefem.org/t/wave-equation-in-a-square/575)

<div class="topic-metadata">

**Author:** [@mordechaiy](https://community.freefem.org/u/mordechaiy)\
**Replies:** 2\
**Last updated:** [September 8, 2020, 5:17pm UTC](https://community.freefem.org/t/wave-equation-in-a-square/575 "2020-09-08T17:17:32Z")

</div>

Hi to every one, I would like to ask please, I written a code in FreeFem++ on the 2D wave equation in a square wherein at a certain edge I imposed on half-edge of the square Dirichlet boundary condition u=0 and in oth…

---

## [Cannot get example to work](https://community.freefem.org/t/cannot-get-example-to-work/574)

<div class="topic-metadata">

**Author:** [@dajopez](https://community.freefem.org/u/dajopez)\
**Replies:** 1\
**Last updated:** [September 8, 2020, 4:11am UTC](https://community.freefem.org/t/cannot-get-example-to-work/574 "2020-09-08T04:11:37Z")

</div>

I am trying to mess with example code, but when I copy and paste into the online compiler it throws an error. It doesn’t like Line 40 int k = EigenValue(OP, B, sym=true, sigma=sigma, value=ev, vector=eV, tol=1e-10, max…

---

## [Smoluchowski / Diffusion Drift Equation Help and Adaptive Meshing](https://community.freefem.org/t/smoluchowski-diffusion-drift-equation-help-and-adaptive-meshing/573)

<div class="topic-metadata">

**Author:** [@kevinmo08](https://community.freefem.org/u/kevinmo08)\
**Replies:** 0\
**Last updated:** [September 6, 2020, 8:30pm UTC](https://community.freefem.org/t/smoluchowski-diffusion-drift-equation-help-and-adaptive-meshing/573 "2020-09-06T20:30:19Z")

</div>

Dear All, I am trying to solve the diffusion equation between two parallel plates in the x direction. This problem is complicated by the fact that these diffusive particles are “active”, so they are orientable and have …

---

## [Building a 2D mesh with 3D borders and getting "Error points border points to close"](https://community.freefem.org/t/building-a-2d-mesh-with-3d-borders-and-getting-error-points-border-points-to-close/570)

<div class="topic-metadata">

**Author:** [@Romuald](https://community.freefem.org/u/Romuald)\
**Replies:** 1\
**Last updated:** [September 5, 2020, 3:42pm UTC](https://community.freefem.org/t/building-a-2d-mesh-with-3d-borders-and-getting-error-points-border-points-to-close/570 "2020-09-05T15:42:08Z")

</div>

Hi, I am trying to learn about getting a 3D volume mesh by assembling several surface meshes built with meshS. First I am building 3D borders to describe the contours of a surface to be meshed with mesh and then meshS.…

---

## [Simulation accuracy](https://community.freefem.org/t/simulation-accuracy/562)

<div class="topic-metadata">

**Author:** [@Vincent](https://community.freefem.org/u/Vincent)\
**Replies:** 2\
**Last updated:** [September 5, 2020, 5:58am UTC](https://community.freefem.org/t/simulation-accuracy/562 "2020-09-05T05:58:47Z")

</div>

Hello, I would like to ask about the accuracy that FreeFem++ can simulate? Can the simulation accuracy reach 10^(-5)?

[Previous page](https://community.freefem.org/c/general-discussion/7.md?page=66)

[Next page](https://community.freefem.org/c/general-discussion/7.md?page=68)
