On this page:
Creating a New UCM
In HYPERSIM Ribbon Options, click the UCM button then New UCM. (UcmBuilder)
Editing a UCM
To edit a UCM, right-click the model in the design, then on UCM and on Edit (UcmBuilder).
Complete general information and in the Edition Menu select Tunable Parameters to add a parameter named R.
To add this parameter click the plus button.
The user can update the value and press Enter.
Warning: vectors must be in square brackets [val1 val2 val3 ... valN] and separated by a space.
In the Edition Menu select Control I/O, add 3 current parameters.
Then select Power Nodes and add one network connector.
Add one Calculated Parameter.
Preparatory
Inside the Global Code section, and be sure to include the file stdio.h
Initialization Of Parameters
It is important to initialize the admittance matrix and the calculated parameters.
int i = 0; int j = 0; G[0] = 1.0 / R[0]; G[1] = 1.0 / R[1]; G[2] = 1.0 / R[2]; /* Initialization of Yini and Yfill */ for (i = 0; i < 3; i++) { { ucmYini(i, j) = 0.0; ucmYfill(i, j) = 0; } } /* Calculate Yini and define Yfill */ ucmYini(T_a, T_a) = 1.0 * G[0]; ucmYini(T_b, T_b) = 1.0 * G[1]; ucmYini(T_c, T_c) = 1.0 * G[2]; ucmYfill(T_a, T_a) = 1; ucmYfill(T_b, T_b) = 1; ucmYfill(T_c, T_c) = 1;
Simulation
In the section After Voltage Calculation Code, add the code to calculate the output currents.
Once the editing is completed, save the UCM.
UCM Builder provides two definition files for the model. ucm_Resistor.def which is a simplified version of the model definition and another folder Resistor.xml which is more evolved.
The *.xml will replace the *.def format.
Design
The UCM is in the design but there are no pins yet because the UCM must be updated in order to display parameters according to edition information.
HYPERSIM detects and displays the modification.
Hypersim associates a generic view according to the UCM information and another generic view to select sensors.
UCM Generic View
UCM Sensor View
Once the UCM is ready, just drag and drop the other components, connect them together, and run the simulation.