Compute Equivalent Gauge (EAP_ComputeEquivalentGauge)

An opening ID is an entry point used to customize business logic. The ComputeEquivalentGauge business rule is available in the Electrical physical system design resources. You can call this rule when multiple cores of different cables are connected to the same cavity. It calculates an equivalent gauge based on the list of core gauges, according to the logic defined by you in the script.

Note: For more information about customization by business rules, see Customization by Business Rules.

This page discusses:

General Information

Invoke this business rule when you must compute the equivalent gauge of a cavity connected to several cores.

The computation is based on:

  • The list of cores connected to the cavity
  • The gauge attribute carried by each core in that list
The table below provides the information related to the definition of the business rule.

Definition Description
PLM Opening ID EAP_ComputeEquivalentGauge
Customization intent Computation
Execution context Client

Input Objects

The input objects must be of the following types:

  • ThisObject: object type in the business rule body.
  • ListOfCores: List of cores connected to the cavity
  • Parameters: context object parameters.

Context Object Parameters

The business rule must return the following output:

Parameter Name Type Read or Write Comments
EquivalentGauge String Write The final equivalent American Wire Gauge (AWG) value used for compatibility evaluation.

Sample

You can use this business rule during the creation of a configured harness:

Let InList(List)
Let Core(Elec3DCableCore)
Let Cable(Elec3DCable)
Let Sum(Real)
Let Count(Integer)
Let Size(Integer)
Let i(Integer)
InList = Parameters->GetAttributeObject("ListOfCores")
Sum = 0.0
Count = 0
Size = 0
If (InList <> NULL){
  Size = InList.Size()
  i = 1
  For i While i <= Size
  {
    Set Core = InList->GetItem(i)
    If (Core <> NULL)
    {
      Core->GetCable(Cable)
      If (Cable <> NULL)
      {
        Sum = Sum + StringToReal(Cable.V_Elec_Gauge)
        Count = Count + 1
      }
    }
    i = i + 1
  }
}
If (Count > 0)
{
  Parameters->SetAttributeString("EquivalentGauge", ToString(Sum / Count)) }
Else
{  
Parameters->SetAttributeString("EquivalentGauge", "")
}