Calculated Fields
Calculated fields provide a means of performing an arithmetic operation (minimum, maximum, sum, average, median, variance, standard deviation, count) on a group of objects based on a selected field. Based on the object type of the group, a calculated field can be added to a case information display for a given object. The calculated field value that is displayed is then based on the calculated field parameters and how the object type in the calculated field relates to the given object.
For example, suppose that you want to find the largest line flow for all lines connected to a bus. A calculated field can be set up using the branch object type with a selected field of MVA (maximum) and the maximum operation can be performed on this field. This calculated field can then be associated with buses by adding this field to the bus case information display. The resulting values for this field will show the maximum MVA flow for all lines connected to a given bus. When determining the value, only the branches that have a terminal bus the same as the given bus will be considered, and the maximum MVA value for all of those branches will be reported.
Optionally, filters can be associated with calculated fields to further specify what objects should be considered in the calculation.
The calculated fields case information display can be accessed from the Model Explorer under Case Information and Auxiliary > Calculated Fields. Existing calculated fields can be modified by selecting Show Dialog from the case information toolbar, and new calculated fields can be added by selecting Records > Insert from the case information toolbar. Both actions will open the Calculated Field dialog shown below.
Calculated Field Dialog
Calculated Field Name
This is the name of the calculated field as it will appear when added to a case information display. Use the Save, Save As, Rename, and Delete buttons to create new calculated fields without exiting the dialog. Switch between existing calculated fields by choosing a name from the drop-down box.
Object Type
Type of object that will be included in the calculation. The type of object determines which objects this field can be used with. This information is displayed to the right of the Object Type option.
Field
Select the field to use in the calculation by selecting a field name from the drop-down box or by clicking the Find button to use advanced search options to locate the field. Check the Use Absolute Value box to use the absolute value of the field in the operation.
Operation
Select the type of operation to perform on the object fields.
Treat Blank Entries
Depending on the field selected, some objects may not have entries. Select to either treat these blank entries As zeros or to Ignore them in the calculation.
Objects to be included in the operation
This option determines if All objects of the selected type will be included in the calculation or if they will be filtered by Only objects that meet the filter below.
If choosing to apply a filter, the filter can be defined by using the same options available when defining an advanced filter. The Set Filter Same As button can be used to select an existing advanced filter whose actions should be applied to this filter.
Keep in mind that objects included in the calculation will first be determined by the object type. If for example branch is selected, then all branches will be considered. Setting a filter will limit the branches to only those branches that meet the filter. If the calculated field is used with buses, then the branches considered for a given bus will be only those branches that have a terminal bus the same as the given bus. If the calculated field is used with generators, then the branches considered for a given generator will be only those branches that have a terminal bus the same as the terminal bus of the given generator.