FastFieldSolvers Forum
FastFieldSolvers Forum
Home | Profile | Register | Active Topics | Members | Search | FAQ
Username:
Password:
Save Password
 All Forums
 FastFieldSolvers
 FasterCap and FastCap2
 Tesselation Strategy
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

sdattalo

USA
2 Posts

Posted - Oct 03 2019 :  18:58:53  Show Profile  Reply with Quote

~15 years ago I used FastCap and the biggest challenge I found was how to properly tesselate a model. Intuitively, you would want the charge density per panel to be constant. And since charges repel toward the edges of objects, you typically want the panels on the edges to be smaller than the ones in the interior. For example, if you have two closely spaced coplanar square plates, then the tesselation along the edges near the gap between the plates would be finer than the tesselation in the center of the plates.

FasterCap mostly obviates the need for manual tesselation. However when the aspect ratio of a conductor is large or there is a significant size disparity between objects, it seems that some sort of manual tesselation is still needed (I'm basing this on the Bus example and empirical experimentation). But I could be wrong...

Consider this simple example. It consists of two plates. One is a 0.1mX0.1m square and the other is 0.1mX0.01m rectangle 1mm above the square:


0 A 0.1mX0.1m plate with 0.01mX0.1m rectangle 0.001m above
* auto-generated
Q 0 0 0 0  0.1 0 0   0.1 0.1 0   0 0.1 0
Q 1 0 0.045000000000000005 0.001  0.1 0.045000000000000005 0.001   0.1 0.055 0.001   0 0.055 0.001


And the capacitance matrix is:


 1.692533010393579e-11  -1.3109472221548975e-11
-1.3139773278290896e-11  1.3252619335968535e-11


And here's the same thing except that the narrow rectangle has been manually tesselated.


0 A 0.1mX0.1m plate with 0.01mX0.1m rectangle 0.001m above
* auto-generated
Q 0 0 0 0  0.1 0 0   0.1 0.1 0   0 0.1 0
Q 1 0.0 0.045000000000000005 0.001  0.01 0.045000000000000005 0.001   0.01 0.055 0.001   0.0 0.055 0.001
Q 1 0.01 0.045000000000000005 0.001  0.02 0.045000000000000005 0.001   0.02 0.055 0.001   0.01 0.055 0.001
Q 1 0.02 0.045000000000000005 0.001  0.03 0.045000000000000005 0.001   0.03 0.055 0.001   0.02 0.055 0.001
Q 1 0.03 0.045000000000000005 0.001  0.04 0.045000000000000005 0.001   0.04 0.055 0.001   0.03 0.055 0.001
Q 1 0.04 0.045000000000000005 0.001  0.05 0.045000000000000005 0.001   0.05 0.055 0.001   0.04 0.055 0.001
Q 1 0.05 0.045000000000000005 0.001  0.060000000000000005 0.045000000000000005 0.001   0.060000000000000005 0.055 0.001   0.05 0.055 0.001
Q 1 0.06 0.045000000000000005 0.001  0.06999999999999999 0.045000000000000005 0.001   0.06999999999999999 0.055 0.001   0.06 0.055 0.001
Q 1 0.07 0.045000000000000005 0.001  0.08 0.045000000000000005 0.001   0.08 0.055 0.001   0.07 0.055 0.001
Q 1 0.08 0.045000000000000005 0.001  0.09 0.045000000000000005 0.001   0.09 0.055 0.001   0.08 0.055 0.001
Q 1 0.09 0.045000000000000005 0.001  0.09999999999999999 0.045000000000000005 0.001   0.09999999999999999 0.055 0.001   0.09 0.055 0.001


And the output is

 1.637919591766101e-11 -1.2554323883396026e-11
-1.258950741355236e-11  1.2776059334652919e-11


There's about 5% difference in the two. Not much in terms of absolute values, but the differences are more pronounced when you consider the rectangle's free-space capacitance. If you save the FasterCap output you can see the difference in the auto-tesselation. I can't attach the post script images, but I would say that for this contrived example that the manual tesselation constrains FasterCap; the automatic tesselation is better.

Finally the question:
Under what conditions should we constrain the panels? The only one I saw in the forum was for small-angle triangles. Are there others?

Enrico

425 Posts

Posted - Oct 08 2019 :  19:10:45  Show Profile  Reply with Quote
Dear sdattalo,

I believe you swapped the two results, but it does not matter much. The ultimate reason why you are seeing two different results is because:

  • in the first case (i.e. the unrefined rectangle) the simulation refinement cycle stops at iteration #6 when you have 1386 panels (1.638e-11/-1.25e-11)

  • in the second case, the simulation refinement cycle stops at iteration #3 when you have only 368 panels (1.69e-11/-1.31e-11)


Why is this so? Actually the single FasterCap run (for each refinement cycle) is done for a certain mesh relative refinement value (-m). The next cycle is run decreasing -m, getting a more refined geometry, and checking the Frobenius norm of the difference of the two Maxwell capacitance matrices. If this norm is below the threshold, the simulation stops. So while for a certain -m and -d set of values the simulation is accurate within the limits of the constant charge density per resulting number of panels and compression of the internal potential matrix (plus of course the GMRES accuracy), the comparison between cycles using the resulting Maxwell capacitance matrices may lead to FasterCap ending up in some local minimum.

The more correct strategy for error estimation would be a comparison of the charge per panel with an error estimator in the proper Sobolev space, but this is expensive as it requires at least the knowledge of the topology of the model i.e. what are the panels sharing the boundary. As you know, FasterCap / FastCap accept instead a set of panels w/o any topological information, and for a large number of panels reconstructing the topology would be very costly, if possible (there might be degenerate situations as well).

However, even if this is not the reason for the two different results, please note that you are right in saying that pre-refinement of the structure constraints in a way what FasterCap can do. In fact, FasterCap in any case will build super-panels by joining simple panels, but the resulting super-panels cannot fully mimic the original, non refined structure, and therefore are a bit less efficient than leaving FasterCap managing the discretization on its own.

Finally let me also point out that for your structure, where you have high geometrical ratios (in particular, the spacing between the plate and the rectangle) you should decrease the -d parameter.

Bottom line: for comparing results, please be sure you are always considering the same number of panels, and remember to tune -d (you can understand -d needs lowering when for the same -m, even coarse, the results change significantly when you lower -d. But do not be tempted to go too low with -d otherwise you end up with uncompressed matrices!)

Best Regards,
Enrico


Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
FastFieldSolvers Forum © 2020 FastFieldSolvers S.R.L. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.06