Hi,
I've been attempting to replicate the simulation done in viewtopic.php?t=4287. I want to be able to simulate the electric field and potential in the air around the capacitor in the fringe field.
I have created my geometry and created the mesh using gmsh. Then in elmer I've defined the necessary equations, materials, and boundary conditions. After running the solver and viewing it in Paraview, I notice that the potentials in the air don't show up as a gradient like in the previous post I was following.
I've attached the files I used to get these results and a reference image of the example I'm basing my learning from. Any help would be appreciated!
3D Electrostatic Simulation
3D Electrostatic Simulation
- Attachments
-
- elmer.zip
- (101.99 KiB) Downloaded 47 times
-
- example.png (93.56 KiB) Viewed 982 times
-
- potential.png (13.79 KiB) Viewed 982 times
-
- Posts: 2301
- Joined: 25 Jan 2019, 01:28
- Antispam: Yes
Re: 3D Electrostatic Simulation
This took a while to solve, keep running both your case and the other case getting different results and not finding any differences. Then I used your sif with the other case mesh at it worked, but not vice versa. Problem must be in the mesh, but at first look everything seemed OK, however your mesh was coarse, I refined it but that did not fix the problem.
I realized that the two plate volumes in your step file were not used to cut out the air volume. This means the air volume is not around the plates it is through the plates, and they do not share nodes at the boundary. This doesn't work. The plate volumes have to be used to cut the air volume while retaining the plate volumes. They then share boundaries and nodes.
I fixed this in gmsh, and retained the mesh refinement steps, and the results look good. I also used physical groups to name the volumes and combine the boundary surfaces. The steps are captured in the geo file. You possibly could have done this in the tool you used to create the step file.
I realized that the two plate volumes in your step file were not used to cut out the air volume. This means the air volume is not around the plates it is through the plates, and they do not share nodes at the boundary. This doesn't work. The plate volumes have to be used to cut the air volume while retaining the plate volumes. They then share boundaries and nodes.
I fixed this in gmsh, and retained the mesh refinement steps, and the results look good. I also used physical groups to name the volumes and combine the boundary surfaces. The steps are captured in the geo file. You possibly could have done this in the tool you used to create the step file.
-
- Posts: 2301
- Joined: 25 Jan 2019, 01:28
- Antispam: Yes
Re: 3D Electrostatic Simulation
This document has good tutorials Chapter 9 about making bodies in Salome or gmsh
https://www.nic.funet.fi/pub/sci/physic ... dElmer.pdf
https://www.nic.funet.fi/pub/sci/physic ... dElmer.pdf
Re: 3D Electrostatic Simulation
Hello Kevin,
Good detective work!
Issues from a non-conforming mesh due to lack of proper boolean difference/fragment commands seems to come up on a regular basis.
Is there some method or algorithm to detect non-conforming meshes? Maybe create a solver that would highlight non-conformance?
Rich.
Good detective work!
Issues from a non-conforming mesh due to lack of proper boolean difference/fragment commands seems to come up on a regular basis.
Is there some method or algorithm to detect non-conforming meshes? Maybe create a solver that would highlight non-conformance?
Rich.
-
- Posts: 2301
- Joined: 25 Jan 2019, 01:28
- Antispam: Yes
Re: 3D Electrostatic Simulation
I know that ABAQUS reports the number of free bodies in a model. Not sure what algorithm it uses. I suppose you can check all of the nodes on the boundary of a body, if none of those nodes are used in another body, than that body is free.
-
- Site Admin
- Posts: 4823
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: 3D Electrostatic Simulation
You can try
It has not been parallelized. The intended use is exactly this - to check that the mesh is in one piece.
-Peter
Code: Select all
Simulation :: Calculate Mesh Pieces = Logical True
-Peter
Re: 3D Electrostatic Simulation
Hello Peter,
The attached archives demonstrates the use of 'Calculate Mesh Pieces', using the gmsh example from GetStartedElmer.pdf.
The good example lists:
The attached archives demonstrates the use of 'Calculate Mesh Pieces', using the gmsh example from GetStartedElmer.pdf.
The good example lists:
The bad example listsCalculateMeshPieces: Number of non-body nodes in mesh is 0
CalculateMeshPieces: Mesh consists of single body!
Rich.CalculateMeshPieces: Number of non-body nodes in mesh is 0
CalculateMeshPieces: Number of separate pieces in mesh is 2
- Attachments
-
- mesh-pieces.zip
- (131.81 KiB) Downloaded 28 times
Re: 3D Electrostatic Simulation
Hello,
As a follow up to the archive with two examples, it helps to increase Max Output Level from 5 to 10 or 15.
With Max Output Level = 15, this is the output in the solver log:
Rich.
As a follow up to the archive with two examples, it helps to increase Max Output Level from 5 to 10 or 15.
With Max Output Level = 15, this is the output in the solver log:
The seg fault only happens with an example with more than one mesh, so it turns a meshing error into a fatal error, which is convenient.CalculateMeshPieces: Number of non-body nodes in mesh is 0
CalculateMeshPieces: Mesh coloring loops: 3
CalculateMeshPieces: Number of separate pieces in mesh is 2
VariableAddVector: Adding variable > Mesh Piece < with 1 components
VariableAddVector: Allocating field of size: 644
VariableAdd: Adding variable > Mesh Piece < of size 644
Program received signal SIGSEGV: Segmentation fault - invalid memory reference.
Rich.
-
- Site Admin
- Posts: 4823
- Joined: 22 Aug 2009, 11:57
- Antispam: Yes
- Location: Espoo, Finland
- Contact:
Re: 3D Electrostatic Simulation
Hi Rich
Thanx for the "convenient" thumbs up and extremely elegant test cases! I rather see controlled stop so I fixed this. This allows one to visualize the blocks.
For those interested: the algo is such that you 1st label each node with their own node index. Then you start going through the elements and always label every node in the element with the minimum label index. When you continue until no changes take place you end up with either one or few different indeces. Visually this would be like a crawling cellular automate where the smallest index would travel though elements. If elements are not connected the crawling stops. In the end you count separate values and renumber them from 1.
-Peter
PS. For electrostatic simulation there is some work on curved problems and capacitance computation. You can have a look at test cases CurvedBoundaryCylH and *P that demostrate how to accurately compute capacitance between two cocentric cylinders.
Thanx for the "convenient" thumbs up and extremely elegant test cases! I rather see controlled stop so I fixed this. This allows one to visualize the blocks.
For those interested: the algo is such that you 1st label each node with their own node index. Then you start going through the elements and always label every node in the element with the minimum label index. When you continue until no changes take place you end up with either one or few different indeces. Visually this would be like a crawling cellular automate where the smallest index would travel though elements. If elements are not connected the crawling stops. In the end you count separate values and renumber them from 1.
-Peter
PS. For electrostatic simulation there is some work on curved problems and capacitance computation. You can have a look at test cases CurvedBoundaryCylH and *P that demostrate how to accurately compute capacitance between two cocentric cylinders.
Re: 3D Electrostatic Simulation
Hello Peter,
Thanks for fixing the seg fault. Here is the solver log for the case previously called 'bad' or Overlapping Volumes:
Also thanks for describing the method used to check for separate mesh pieces.
Rich.
Thanks for fixing the seg fault. Here is the solver log for the case previously called 'bad' or Overlapping Volumes:
The solver then continued to a solution.CalculateMeshPieces: Number of non-body nodes in mesh is 0
CalculateMeshPieces: Mesh coloring loops: 3
CalculateMeshPieces: Number of separate pieces in mesh is 2
CalculateMeshPieces: Creating variable showing the non-connected domains: mesh piece
Also thanks for describing the method used to check for separate mesh pieces.
Rich.