HFSS Creating Objects - HRG-Lab/hfss-tutorials GitHub Wiki
A new HFSS design file consists of an empty model space. HFSS will not solve for fields in the empty space, therefore it can be treated as a perfect electric conductor (PEC) since there are no fields inside it. In order to simulate something, you must model your design using 2- and 3-dimensional objects. Then, you assign materials to the objects such as FR4, Duroid 5880, PEC, Copper, Vacuum etc. This section will walk through the process of creating a microstrip line on a substrate with a region of air above it.
The substrate is modeled as a 3-D box in HFSS. Click 'Draw box' in the toolbar to enter the drawing mode (note the other 3-D shapes available in the toolbar). Now click in three different points in the model space to set the dimensions for the box. These points can be completely random, because we will define the exact dimensions next.
To the left of the model space you will see a list of all of the objects in your design. Expand the branch for the box you just created and double-click on ‘CreateBox’. This brings up the model position and dimension information for the box. For boxes, the Position refers to the x,y,z coordinates of one corner of the box. The XSize, YSize, and ZSize values are the dimensions in x, y, and z from the corner referenced by Position.
For this example, we want the substrate centered at the origin with the top surface on the XY-plane. We will use parameters to define all of the dimensions in our design so that we can easily make modifications later. Parameters are automatically created when you enter a string as a value.
First, enter a string as the value for XSize, we will use ‘subx’ in this example which stands for “substrate x dimension”, but you can choose whatever name makes sense to you. When you hit Enter you will be prompted to define your newly created parameter, this value can be changed later from your parameter list. Repeat this process for the YSize and ZSize.
Now you can use your substrate parameters to define the Position of the box. For the Position value, enter “-subx/2,-suby/2,0”, or the equivalent with the parameter names you chose. This sets the reference corner of the box such that it is centered in X and Y. If you set the ZSize to be a negative value of the substrate height, then the box will start at z=0 and extend down from there. If you consistently use parameters to define dimensions and positions then your design will automatically adjust each object if you change the value of a parameter. Click 'OK' to close the CreateBox window and keep your changes.
Now in the sidebar double-click on the name of the box you created (‘Box1’ by default) to bring up the properties window for the object. In this window you can change the name of the object, adjust the color and transparency, and assign a material to the object. First, change the name to ‘Substrate’ or whatever makes sense to you (this is to help you keep organized when you have several objects in your design). Next, click on the drop-down value for Material and click ‘Edit’. This brings up the HFSS materials library. You can use the search bar to find a particular material, or you can add a material if it is not already in the library.
The FR4 in the materials library has a relative permittivity of 4.4 which is different from the FR4 we have. To change this, highlight FR4_epoxy in the list and click on ‘View/Edit Materials …’. Then, change the value of the relative permittivity to 4.1 and click ‘OK’.
I typically change the transparency of substrates to 0.8 to make the traces on top easier to see, but that is up to the designer.
The top trace for a microstrip line is modeled as a 2-D rectangle in HFSS (could be modeled as a box if design is sensitive to metal thickness). Click 'Draw Rectangle' in the toolbar to enter the drawing mode (note the other 2-D shapes available in the toolbar). Now click in two different points in the model space to set the dimensions for the rectangle. These points can be completely random, because we will define the exact dimensions next.
In the object list, double-click 'CreateRectangle' under the rectangle you just created. The options here are similar to the cube except there are only 2 dimensions to define. There is also the option 'Axis' which defines the normal vector for the object, for this design Axis should be set to 'Z'. We first define the dimensions (using parameters) of the rectangle and then we set the position such that it is centered on the substrate. Notice how the position is defined as '-feed_line_width/2,-suby/2,0' and the Ysize is set to 'suby'. This ensures that if we change our 'suby' parameter, the feed line we just created will automatically resize to match the substrate dimension and remain centered. Click 'OK' to close the CreateRectangle window and keep your changes.
You can change the name, color, and transparency of the rectangle in the same way you did for the box, however, applying material properties to 2-D objects is different than for 3-D objects. This will be covered in a later step.
As mentioned before, the unassigned space in HFSS is treated as a perfect conductor. In order to truly model our microstrip line, we need to define a region of air above our substrate. This region is a 3-D box just like the substrate, but we will use the default "vacuum" material instead of assigning a material. Click on 'Draw Box' in the tool bar and click three different points to draw the box. Next, double-click on 'CreateBox' under the box you just created in the object list. The Xsize and Ysize properties should be the same as the substrate, and the Zsize should be some positive value that is about 10 times the height of the substrate (15 mm in this design). The position is also set using the substrate parameters such that the air box remains centered on the substrate. I typically make the air box completely transparent so that I can see the design inside.