In this article (the sixth in the online course Electric and magnetic field calculations with finite-element methods), we’ll make several calculations to understand the effect of element size on solution accuracy. To expand our technique toolbox, we’ll automate steps in the analysis procedure.
We’ll continue with the solution discussed in the previous two articles. The best way to start a project is with a clear statement of the goal. In this case, we want to check the accuracy of numerical estimates of the electric field Er(r) at locations in the dielectric as a function of element size. Specifically, we’ll check field interpolations near the inner electrode (r = 5.0 cm), near the outer electrode (r = 15.0 cm) and at the center of the gap (r = 10.0 cm) for the following choices of element size: 0.1 cm, 0.2 cm, 0.3 cm, 0.4 cm and 0.5 cm.
As mentioned in previous articles, good supporting software (text editors, file managers, image editors,…) is essential for effective technical work. In this case, we’ll use a spreadsheet created with OpenOffice Calc. Figure 1 shows the upper section of the sheet. Parameters at the top include the inner and outer radii, the applied voltage and the theoretical value for the capacitance per length. The section beneath lists the radial positions for the calculations. Note that the inner radius is slightly larger than Ri and the outer radius smaller than Ro. Remember that the electrode boundaries are a set of straight lines that approximate sections of circles. We have to include a little slack to make sure that the test points lie within the dielectric region for all choices of element size. We may as well let the spreadsheet do the mathematical work. The cells for the x-y coordinates of the measurement points on a 45° line contain the formula r/√2. Similarly, the cells for the theoretical values contain the equations for Er(r) and φ(r) discussed in the previous articles.
Figure 1. Top section of a Calc spreadsheet: solution setup.
The next section (listed below) demonstrates another use of a spreadsheet. We can use the program to prepare input scripts automatically. In this case, we’ll generate an analysis script — a set of instructions to EStat for standard calculations to carry out for each of the solutions:
* Coaxial cylinders analysis script
POINT 3.53624 3.53624
POINT 7.07107 7.07107
POINT 10.60589 10.60589
The spreadsheet has supplied the coordinates. To use the section information, simply copy and paste it into a text file COAXIALCYLINDERS.SCR (SCRipt). The commands listed perform the following actions. Open the EStat output file COAXIALCYLINDERS.EOU and write the results of calculations to the text file COAXIALCYLINDERS.DAT. Make three point interpolations at the desired locations. Also, calculate volume-integral quantities over Region 1 to find the capacitance per length.
We can quickly change the element size by directly editing the Mesh input script. Figure 2 shows the file displayed in the Context editor with syntax highlighting installed for our programs. The red arrows show the quantities to be modified. Given a modified Mesh input script, there are three steps to regenerate the solution and to update values in the data file COAXIALCYLINDERS.DAT:
- Run Mesh, load COAXIALCYLINDERS.MIN, process the mesh and save the result.
- Run EStat, load COAXIALCYLINDERS.EIN and run the solution.
- In EStat, run the analysis script COAXIALCYLINDERS.SCR.
With only five solutions, the procedure wouldn’t take long. On the other hand, it takes only a few seconds to set up a batch file that handles everything automatically.
Figure 2. File COAXIALCYLINDERS displayed in Context.
In the Tricomp Program Launcher, press the Create task button to bring up the dialog of Fig. 3. Supply the file prefix COAXIALCYLINDERS and activate the Beep at completion box. We need to define the three steps of the solution. Clicking a cell in the first column raises of popup menu (inset) that shows your installed Field Precision programs as well as useful batch commands. Create the three tasks shown to run Mesh and then to run EStat in the solution and analysis modes. When you press OK, the program creates the file COAXIALCYLINDERS.BAT in the working directory. Here’s the content:
REM TriComp batch file, Field Precision
START /B /WAIT C:\fieldp_basic\tricomp\mesh.exe COAXIALCYLINDERS
START /B /WAIT C:\fieldp_basic\tricomp\estat.exe COAXIALCYLINDERS.EIN
START /B /WAIT C:\fieldp_basic\tricomp\estat.exe COAXIALCYLINDERS.SCR
START /B /WAIT C:\fieldp_basic\tricomp\NOTIFY.EXE
IF EXIST COAXIALCYLINDERS.ACTIVE ERASE COAXIALCYLINDERS.ACTIVE
Figure 3. Create task dialog in tc.exe.
Note that most Field Precision programs can be run from the command line with the input file as a parameter. The /WAIT option ensures that a program does not start before the previous program completes it action. Under batch file control, a full solution consists of the following operations:
- Edit and save COAXIALCYLINDERS.MIN with the desired element size.
- Press Run task in the program launcher and choose COAXIALCYLINDERS.BAT.
- Open the resulting file COAXIALCYLINDERS.DAT and extract values of interest
Figure 4. Bottom section of a Calc spreadsheet: solution analysis.
I performed the solutions and copied/pasted values to create the sections of the spreadsheet shown in Fig. 4. I set up formulas in the spreadsheet to determine the relative errors in electric-field values. For a visual reference, Fig. 5 shows the mesh for element sizes of 0.2 and 0.5 cm. We can now consider some implications of the results:
- For a size 0.1 cm the mesh had 35336 elements. The mesh with size 0.5 cm had only 1412 elements. Therefore, the solution with the fine mesh requires about 25 times as much computational work.
- The error in the electric field calculation at the center of the gap (r = 10.0 cm) was infinitesimal for element size 0.1 cm (0.0009%) and acceptable for many applications at 0.5 cm (0.0289%).
- The errors in electrical field near the electrodes were higher, as we would expect when representing a curved surface with a set of line segments. The relative error was higher on the inner electrode because there were fewer segments. For the 0.5 cm elements, the error of 2.7% on the inner electrode could be an issue for some applications.
Figure 5. Mesh geometries for small and large elements.
In general, I have found that inexperienced code users often employ far more elements than is necessary. For the determination of electric field values in the dielectric volume (removed from electrodes), the accuracy with the fine mesh of Fig. 5 may not justify the extra computational work. If you have concerns about mesh resolution, the standard procedure is to do two calculations with different mesh sizes and to check whether values in critical regions differ by more than the accuracy requirement. Note that there are two techniques to increase accuracy without greatly increasing the number of elements:
- Variable mesh resolution.
- Boundary method to generate a microscopic solution within a macroscopic solution.
These topics will be discussed in future articles.
We’ve covered a lot of ground in the last three articles by following a relatively simple electrostatic solution.
- Organizing simulation data and using a file manager.
- Defining region boundaries with the Mesh Drawing Editor.
- Employing symmetry boundaries to reduce the size of a calculation.
- Using a spreadsheet to plan and to analyze calculations.
- Understanding the set of input and output files for an electrostatic solution.
- Creating program input scripts in interactive dialogs and modifying them with a text editor.
- Generating and inspecting standard mesh definition files with Mesh.
- Defining run-control and material parameters for EStat solutions.
- Running Mesh and EStat interactively or from the Windows command prompt.
- Automatically controlling EStat with analysis scripts.
- Creating batch files for automatic run control with the task generator of the TriComp Program Launcher.
- Gaining insights into the relationship between element size and interpolation accuracy.
In the next article, we’ll turn our attention to 2D magnet-field calculations.
 Over the long existence of Open Office (starting from Star Office), I have been amazed that people will pay over $100 per computer for Microsoft Office when they can get a free product that will serve all their needs with considerably less aggravation. I suspect that the computer experience of the most people is governed more by anxiety than logic. The commercial program offers the same sense of security that you’d get from having the Mob protect your candy store. At any rate, here is a link to get OpenOffice 4.1.1: http://www.openoffice.org/
2) Batch files are one of the most useful features of Windows, but many users do not realize they exist. These articles review how to apply batch files: Discovering your inner DOS, Part 1 and Part 2.
 Contact us : firstname.lastname@example.org.
 Field Precision home page: www.fieldp.com.
In this fifth section of the online course Electric and magnetic field calculations with finite-element methods, we’ll use the mesh file discussed in the previous section to build a field solution. To get started, run EStat from the TriComp program launcher. Click the “1″ tool and choose the Mesh file COAXIALCYLINDERS.MOU. The program determines the defined regions in the mesh and displays the dialog of Fig. 1. The values shown are appropriate to the solution parameters discussed in the previous article. Fill in the fields and click OK, accepting the output file name COAXIALCYLINDERS.EIN (EStat INput).
Figure 1. Dialog to create the EStat input script.
To understand the action of the dialog, choose the File/Edit script (EIN) menu command and load the file in the editor. Here is the content:
* File: CoaxialCylinders.EIN
Mesh = CoaxialCylinders
Geometry = Rect
DUnit = 1.0000E+02
ResTarget = 5.0000E-08
MaxCycle = 5000
* Region 1: DIELECTRIC
Epsi(1) = 1.0000E+00
* Region 2: INNERELECTRODE
Potential(2) = 1.0000E+02
* Region 3: OUTERBOUNDARY
Potential(3) = 0.0000E+00
You’ll recognize many of the entries. The ResTarget and MaxCycle parameters that control the solution accuracy are described in the EStat manual. The default values are fine for this application.
Exit the editor and click on the “2″ tool. After you choose COAXIALCYLINDERS.EIN, EStat generates and solves the finite-element equations in less than a second. Larger meshes will take longer, but generally the run time of any practical solution is less than a minute. The program creates the files COAXIALCYLINDERS.ELS (a diagnostic listing file that you can inspect with an editor) and COAXIALCYLINDERS.EOU (a record of the mesh coordinates and potential values at the nodes).
To see the results, press the “3″ tool and choose COAXIALCYLINDERS.EOU. You can generate interesting plots in the Analysis menu (Fig. 2). There are also useful tools like the movable field probe shown in the figure. For this discussion, let’s concentrate on hard numbers. First, let’s check the absolute accuracy of the solution with a single point calculation. At radius r = 10.0 cm, the formulas in the previous article give the values:
Er(r) = 910.23923 V/m
φ(r) = 36.90703 V
Numerical interpolations in EStat involve the collection of potential values from surrounding nodes. On symmetry boundaries, there are only half the available nodes, so the accuracy is not optimal. We should use an internal point for a good comparison. On a 45° line, the position r = 10.0 cm corresponds to x = y = 7.071068 cm. Click the Point calculation tool. We can specify the location by moving the mouse inside the solution volume and clicking the left button. This method is not accurate enough for this comparison. Instead, press the F1 key after clicking the Point calculation tool to enter coordinates manually. Set the x-y values as 7.071068 and click OK. Several calculated quantities are displayed at the bottom (Fig. 2). The calculated values of potential (36.90767 V) and electric field (910.23111 V/m) agree with the theoretical value to within a few thousands of a percent.
Figure 2. Filled-contour plot of potential with results of a point calculation displayed.
Rather than copy numbers from the screen, why not let EStat write them for us? Click on the Open data record command and accept the default name COAXIALCYLINDERS.DAT. Now, every time you do an interactive calculation, the results are recorded in the text file. For example, choose the menu command Analysis/Volume integrals. You can inspect the resulting file with an external editor. To use the internal EStat editor, click the Close data record command first (two instances of a file cannot be open in the same program). Here is the field-energy calculation (volume integrals of the field-energy-density):
Global integral: 1.708936E-07
The field inside the inner electrode (Region 2) is numerically zero. We can use the field energy in the dielectric (Region 1) to find the capacitance per length. Because the calculation covers only the first quadrant, we need to multiply by a factor of 4.0 to find the field energy per length of coaxial cylinders at 100 V, Ue = 6.835744E-7 J/m. The equation C = 2*Ue/100^2 gives c = 1.367149E-10 F/m, within 0.8% of the theoretical value cited in the previous article (c = 1.3567E-10 F/m).
To understand the effects of element size, we want to compare accuracy at several radii for different choices of element dimensions. The procedure would be tedious if we had to run the Point calculation tool and type coordinates for each datum. In the next article, we’ll automate the analysis procedure.
 Contact us : email@example.com.
 Field Precision home page: www.fieldp.com.
The process of mesh generation represents a significant fraction of the effort in building a finite-element solution. Many people have an aversion to the very idea of mesh generation, possibly from encountering quirky and unreliable old programs. Some producers of finite-element software may capitalize on this sentiment by claiming that their program does not require meshes. Because this claim is misleading, I want to clarify some issues in the article.
These are the two basic approaches:
- Volumetric meshes (our choice). The solution space is divided in small volumes (elements). In our programs, the elements are conformal triangles in 2D and generalized boxes (hexahedrons) in 3D. Nodes are the intersections of element faces. The quantity of interest (e.g., potential in electrostatics) is defined at the nodes, which extend throughout the solution volume.
- Boundary meshes. The boundaries between physical regions are divided into areas (surface elements). Nodes, the intersections of the elements, are confined to the boundaries. Quantities of interest are calculated in the intervening volumes by taking sums over values at the surface nodes.
There are two main questions:
- Are boundary approaches mathematically better than volume methods?
- Is it easier to create boundary meshes than volume meshes?
My answers are Not necessarily and No.
To amplify, first consider mathematical effectiveness. When the media between boundaries are simple, homogenous materials, boundary methods require much less storage because there are fewer nodes. This advantage vanishes with complex materials like saturable iron. If every portion of a material has a different self-consistent property, then there must be boundaries between each portion of the medium. In this case, a boundary mesh would require about as much storage as a volume mesh. Furthermore, volume meshes have a significant advantage over boundary meshes in applications where extensive field calculations are required (as in our charged-particle orbit tracking codes Trak and OmniTrak). Such calculations are easy with a volume mesh, which has available values everywhere. It’s simply a matter of collecting some local values near the point of interest and then making interpolations. On the other hand, each field calculation in a boundary-type solution involves a complex, weighted sum over a large number of surface nodes. As a result, each interpolation involves much more work.
Moving to the second issue, is it actually easier to generate a surface mesh than a volume mesh? The answer is no when you consider our mesh generation method. The 3D MetaMesh program initially fills the solution volume with a collection of box elements and then shifts nodes near boundaries to make the mesh conform to the surfaces. The initial fill procedure has no chance of error and involves negligible work. Almost all the effort is associated with the conformalization. The number of shifted nodes is about equal to the number of nodes that would be necessary to make a boundary mesh. In the end, the total number of operations are about the same.
To wrap up, although a volume mesh does require more storage, this is not a major drawback:
- A modern 64-bit with an installed memory of 8 GB or more can handle meshes with millions of nodes.
- The payoff for the extra stored values is high-efficiency field interpolation.
 Contact us : firstname.lastname@example.org.
 Field Precision home page: www.fieldp.com.
This article is the forth in the online course, Electric and magnetic field calculations with finite-element methods. In the previous article, we followed a prepared example without going into the detail of how the input files were prepared and how the mesh parameters were chosen. Now, we’re ready to build an example from scratch and learn something about how the geometry of the mesh affects the accuracy of the solution. The best approach to make comparisons is to model a system that has an analytic solution. A good choice with spatial variations of potential and electric field is a voltage applied between coaxial cylinders .
Figure 1. Alternative ways to model coaxial cylinders with a 2D code.
There are two ways to model coaxial cylinders with a 2D code. The first (Fig.1, top) is to use cylindrical coordinates z-r and to model the infinite length in z with Neumann conditions at the upper and lower z boundaries. (The Neumann condition specifies that the parallel component of electric field Ez is zero at the boundaries.) This approach, where the electrode boundaries are simply straight lines, would not exercise the conformal mesh capability. Instead, we will use planar coordinates (Fig.1, bottom) where the cross section lies in the x-y plane and the system extends infinitely in z. For specific parameters, we’ll take Ri = 5.0 cm, Ro = 15.0 cm and Vi = 100.0 V. The space between the cylinders is filled with polyethylene (εr = 2.7) and the outer electrode is grounded. Using formulas available in introductory electromagnetism texts, the radial variation of potential and electric field and the capacitance per unit length is given by:
Er(r) = 91.023923/r
φ(r) = 100.0*[ 1 - ln(r/5)/1.098612]
c = 1.3567E-10 F/m
To start, we’ll define the geometry for the numerical calculation. Run the Mesh and choose File/Create script/Create script graphics. Fill out the dialog entries as shown in Fig. 2. For the dimensions given, note that the solution volume covers only the first quadrant of the space. One technique we shall employ is symmetry boundaries — why calculate all four quadrants when the solution is the same in each one?
Figure 2. Dialog to start an interactive drawing session.
When you click OK, the program enters the drawing editor of Fig. 3. The display includes a menu at the top, a set of drawing tools beneath it, the main drawing area and a status bar at the bottom. We will define the following physical regions:
- Region 1. The polyethylene dielectric between the cylinders.
- Region 2. The inner boundary at 100.0 V.
- Region 3. The outer boundary at 0.0 V.
It is important to note that as we enter regions, the current one over-writes any shared elements or nodes of previous regions.
Figure 3. The Mesh drawing editor.
By default, the drawing editor is ready to add outline vectors for Region 1. Click the Line tool and move the mouse cursor into the drawing area. Note that the cursor changes to a cross and that there is an orange box showing the current coordinates. Snap mode is in effect by default, and the box moves in discrete steps to exact coordinate locations. Move the mouse cursor to drag the coordinate box to the origin [0.0, 0.0] and then click the left mouse button to set to start point of a line vector. Then move to the end of the x-axis [15.0, 0.0] and click the button again to set the end point. A line in the color of Region 1 appears along the bottom. The program remains in line entry mode. Draw another vector along the y-axis (from [0.0, 0.0] to [0.0, 15.0]). Right click the mouse to exit line entry mode. To add the circular outer edge of the region, choose the Arc/Start-end-center tool. Move the mouse to the following locations in sequence and click the left button: [15.0, 0.0], [0.0, 15.0], [0.0, 0.0]. You should see the arc vector of Fig. 3.
With the outline of Region 1 complete, we shall set the region properties. Choose Settings/Region properties to bring up the dialog of Fig. 4. Region 0 is a special place to store reference vectors that do appear in the output script. Fill in the name DIELECTRIC for Region 1 and check the Filled box. In this case, Mesh assigns not only the nodes of the boundary to Region 1, but also the elements enclosed. The Filled property applies to regions with non-zero volume. Exit the dialog.
Figure 4. Region properties dialog.
Next, we are going to create the inner electrode by over-writing a portion of the dielectric volume. Click the Start next region tool, Now, all vectors you enter will be associated with Region 2. Region 2 has the same shape as Region 1 except that the radius is 5.0 rather than 15.0. Use the same procedure except the first line should extend from [0.0, 0.0] to [5.0, 0.0] and so forth. When complete, go to Settings/Region properties. Assign the name INNERELECTRODE to Region 2 and set the Filled property. Exit the dialog.
To check the work so far, click the Toggle fill display tool to bring up the plot of Figure 5. The fill display mode is both a diagnostic and a visual aid. It checks that the vectors of filled regions define a closed surface and shows how the enclosed elements have been assigned. Click the tool again to return to the normal vector display.
Figure 5. Checking the integrity of filled Regions 1 and 2.
We conclude by defining Region 3. This region is not a filled volume but rather a set of fixed-potential nodes on the outer boundary. We call such a region an un-filled or line region. Click the Start next region tool and then the Arc/Start-End-Center tool. To over-write the outer boundary, move to the following coordinates in sequence and click the left mouse button: [15.0, 0.0], [0.0, 15.0], [0.0, 0.0]. The nodes on the outer edge of Region 1 are re-assigned to Region 3 (color-coded violet). Set the region name to OUTERBOUNDARY and do not check the Filled box. You may wonder whether it’s necessary to set special conditions on the dielectric boundaries on the bottom the left sides. A nice feature of finite-element solutions is that unspecified boundaries automatically assume the Neumann condition, exactly what we what. We’ll simply leave the boundaries alone.
Click the Export MIN tool to save a copy of the work and then exit the drawing editor. To see the result of the work, choose File/Edit file command and pick COAXIALCYLINDERS.MIN. Here is the content:
* File: CoaxialCylinders.MIN
0.00000 15.00000 0.20000
0.00000 15.00000 0.20000
REGION FILL DIELECTRIC
L 15.00000 0.00000 0.00000 0.00000
L 0.00000 0.00000 0.00000 15.00000
A 0.00000 15.00000 15.00000 0.00000 0.00000 0.00000
REGION FILL INNERELECTRODE
L 5.00000 0.00000 0.00000 0.00000
L 0.00000 0.00000 0.00000 5.00000
A 0.00000 5.00000 5.00000 0.00000 0.00000 0.00000
A 15.00000 0.00000 0.00000 15.00000 0.00000 0.00000
The region vectors and coordinates should look familiar. The commands at the top set the target element sizes. For now, we’ll accept the defaults.
The final step is generate a file describing the complete mesh (COAXIALCYLINDERS.MOU) from the region boundary specifications (COAXIALCYLINDERS.MIN). In the main Mesh menu, choose File/Load/Load script (MIN) and pick input you just created. Choose Process and then Plot-repair to view the result of Fig. 6. Is it a good mesh? Qualitatively, the answer is yes because the boundaries are relatively smooth and all features are well resolved (i.e., spatial variations extend over several elements). We shall make this conclusion more quantitative in future articles.
Figure 6. Completed mesh.
In the next installment, we will use the mesh for field calculations and comparisons.
 Contact us : email@example.com.
 Field Precision home page: www.fieldp.com.
This article is the third in the online course, Electric and magnetic field calculations with finite-element methods. In this section, we’ll run through the steps of a solution and analysis of a 2D electrostatic problem without going into detail. The goal is a quick demo of the capabilities of EStat. Subsequent articles will cover details of electrostatic theory and program techniques.
One of the outstanding features of Field Precision software is dual input — there are two options for supplying geometric and material data for solutions:
- Interactive: the standard method for modern finite-element programs where you fill in items in interactive dialogs. This option is useful for new users and for a quick setup of a new system.
- Text: the classic method using input scripts. This option allows experienced users to make changes to setups easily and facilitates automatic program operation under the control of external programs or batch files. Scripts also provide a permanent, accessible archive of setups.
In this demo, we will check out prepared input scripts before running them using the built-in text editors of Mesh and EStat. For serious work, it’s essential to have a good text editor (Special note: NotePad is not a good text editor). The following blog article describes how to obtain the ConText editor and how to add syntax color coding for our programs:
Before starting, we’ll need to make some provisions for data organization. A little effort in the beginning prevents lot of headaches later. Run FP File Organizer or your own file manager. Navigate to a location where you would like to create a general directory (folder) for your finite-element calculations and create the directory Simulations (I will use C:\Simulations). Create the sub-directories Electrostatics and Electrostatics/Practice. In the right-hand window, navigate to C:\fieldp_basic\tricomp\Examples\EStatExamples. We will copy an example to work with. Highlight the files with name ELECTRODIODE and copy them to the Practice directory. Figure 1 shows the resulting setup in FP File Organizer.
Figure 1. Set up a data directory and copy the examples.
Click on the desktop shortcut to run the TriComp program launcher tc.exe (Fig. 2). The Mesh and EStat buttons should be active as shown. If not, click the Program folder button and navigate to c:\fieldp_basic\tricomp. Click the Data folder button and navigate to c:\Simulations\Electrostatic\Practice. Subsequently, all input/output operations will target this folder.
Figure 2. The TriComp program launcher.
There are three fundamental steps in a finite-element solution:
- Define the geometry of the solution space and divide objects into small volumes (elements). The process is called meshing.
- Create and solve a large set of linear equations to approximate the governing partial differential equation (the Poisson equation for electrostatics). The goal is to determine the electrostatic potential on points of the mesh (nodes).
- Analyze the results — use the potential values to find physical quantities of interest (e.g., electric field, field energy, capacitance, …).
The first function is performed by the Mesh program (mesh.exe) and the second and third functions are performed by the EStat program (estat.exe). The reason why meshing is performed by a separate program is that the same mesh may be used for different types of solutions. Output from Mesh is compatible with PerMag (magnetic fields), TDiff (thermal transport) and all the other solution programs of the TriComp series. In other words, everything we learn about Mesh for electrostatics if also useful for the magnetic solutions we will discuss later.
Click the Mesh button to open the program. Initially, the screen is blank. Choose File/Edit file from the menu at the top. The selection dialog shows the four files in the data folder. Pick ELECTRONDIODE.MIN, where the MIN designates Mesh INput. The internal program editor shows the file contents (Fig. 3), a set of organized numbers. For now, note that there are REGION sections that represent the different physical objects in the solution space. Each region section contains a set of line or arc vectors that defines the region shape. The numbers are the coordinates of the vectors. There are two ways to create or to modify the content of MIN files:
- Use the Mesh Drawing Editor, a versatile interactive 2D CAD program.
- Use a text editor to change numbers directly.
We will discuss both options in following articles. For now, exit the editor with no changes.
Figure 3. Internal Mesh editor display.
Choose File/Load script(MIN) in the menu or use the Open-file tool on the left hand side of the toolbar to load the contents of the file ELECTRONDIODE.MIN. Then pick Process or click the tool with the green square. In response, Mesh analyzes the desired element sizes and the region vectors to create a set of small elements. To view the result, choose Plot/Repair from the menu or click the Plot/repair tool to show the display of Fig. 4. The solution volume has been divided into the regions listed in the script to represent physical objects (electrodes and dielectrics). The cross section has been divided into triangular areas. Note that the calculation represents a cylindrical system, a figure of revolution about the bottom boundary (r = 0). When first viewing a z-r plot, many users ask where’s the bottom? The answer is that there is no bottom. Negative values of radius r are undefined. On the other hand, a plot in a Cartesian slice plane like y = 0 would have both upper and lower components. In cylindrical solutions, elements are tori with triangular cross-sections that extend over the full range of azimuth (θ = 0° to 360°).
Figure 4. View of the full mesh.
Let’s take a closer look at the solution. Choose View/Zoom window or click on the Zoom window tool and specify the corners of a box by moving and left-clicking the mouse. Figure 5 shows a magnification with a better view of the element cross-sections. The inset at lower-right shows the view limits. Note that the triangles were flexed for a good fit on region boundaries. The motivation is to make high-accuracy calculations of surface fields. A mesh with customized element shapes is called a conformal mesh. To conclude work with Mesh, return to the main menu and choose File/Save mesh (MOU) or click the Save mesh tool. Go to FP File Organizer and press F3 to refresh the display. Two new files have been added to the folder:
- ELECTRONDIODE.MLS: a text listing file of diagnostic information that may be useful if there is a problem.
- ELECTRONDIODE.MOU: the main output file specifying element identity (region association) and coordinates of nodes (boundaries between elements). This file may be ported to any of the TriComp solution programs. The file is in text format, so you can inspect it with an editor.
Figure 5. Detailed view of a mesh section.
Next, run EStat from the program launcher. Choose File/Edit script (EIN) and pick the file ELECTRONDIODE.EIN. The editor shows the content
* File ElectronDiode.EIN
DUnit = 39.37
Geometry = Cylin
Epsi(1) = 1.0
Epsi(2) = 81.0
Epsi(3) = 2.7
Potential(4) = -500.0E3
Potential(5) = 0.0E3
Potential(6) = 0.0E3
The two general commands at the top specify that the dimensions from the Mesh file should be interpreted in inches and that the system has cylindrical symmetry. The other commands set the physical properties of regions of the solution volume. The first three regions are dielectrics (vacuum, purified water and Lucite) and the other regions are fixed-potential electrodes. Again, there are two options for creating EStat input scripts — supplying values in an interactive dialog or direct input with a text editor.
The tools labeled 1, 2 and 3 invoke the three main functions of EStat:
- Create the input script
- Perform the finite-element solution
- Analyze the results
Step 1 has already been performed, so click tool 2 and pick ELECTRODIODE.EIN. EStat reads the geometry data in ELECTRONDIODE.MOU, generates the set of finite-element coupled linear equations and solve them, all within a second. FP File Organizer shows that two new files have been created: ELECTRONDIODE.ELS (a diagnostic text listing file) and ELECTRONDIODE.EOU (the main solution file containing potential values at nodes). Click the 3 tool in EStat and pick ELECTRONDIODE.EOU. The program shifts to the Analysis menu and displays the default equipotential-line plot of Fig. 6. This type of plot is useful one for experienced users because it shows complete information. Section 7.5 of Finite-element Methods for Electromagnetics discusses how to interpret equipotential plots.
Figure 6. Equipotential line plot of the electrostatic solution.
There are many capabilities of the Analysis menu that you can explore. Let’s check out two of them. A plot of the magnitude of the electric field |E| is useful to pinpoint areas where breakdowns may occur in high-voltage systems. To create the plot, press Plots/Plot settings/Plot type in the menu and choose Element. Then press Plots/Plot settings/Plot quantity and pick |E|. The resulting plot (Fig. 7) shows that the peak field in the electron emission region is about 442 kV/cm and that the maximum field on the insulator vacuum surface is about 40 kV/cm. A second activity is to find the capacitance of the system downstream from the insulator. We can determine this quantity from the volume integral of electrostatic field energy density in the vacuum region. Press Analysis/Volume integral. EStat offers to open a data record file with the default name ELECTRONDIODE.DAT. Global information will appear on the screen, but we need to check the file for a detailed breakdown by regions.
Figure 7. Variation of electric field magnitude in the solution volume.
Press File/Close data record and then File/Edit files. Open ELECTRONDIODE.DAT. Here is the information of interest:
Global integral: 6.358995E+01
The capacitance of the vacuum volume (Region 1) can be determined from the equation Ue = C*V^2/2 as 2*5.5347/5E5^2 = 44.3 pF.
This completes the first electrostatic solution with EStat. An inspection of the final state of the data folder with FP File Organizer shows two important features of Field Precision programs:
- The compact input files ELECTRONDIODE.MIN and ELECTRONDIODE.EIN contain all information necessary to reconstruct the solution.
- All the data what we generated has been recorded in accessible files. For example, if you save the file ELECTRONDIODE.EOU, you can always go back later for additional analyses.
The purpose of the example was to give a brief overview of the program features. In following articles, we shall create solutions from scratch and learn about meshing and analysis techniques.
 Contact us : firstname.lastname@example.org.
 Field Precision home page: www.fieldp.com.