Of course it is sometimes required to calculate. For instance adding two Number Properties to calculate a third. In the Perspectives Graphical Language calculation is modelled as follows. Here is the Role Diagram of an Exam Paper on which a Student has a Perspective:
The Exam Paper total Mark is a Calculated Property as in shown by the diamond icon. When this Calculated Property is double clicked the Calculated Property Diagram opens. This is the third type of Diagram besides the Context Diagram and the Role Diagram:
Initially only the Calculated Property is in the Diagram. Next other Properties that will be part of the calculation can be added to the Diagram. These Source Properties are added from the Project Browser:
The Toolbox of the Calculated Property Diagram only contains two items: Functions and the IN Relation. The Function has one or two inputs and one output. The inputs can be Source Properties or outputs of other Functions. In connectors are used to add inputs and outputs :
This is the set of types of Functions that can be chosen:
The Function and IN relation can be used to construct the calculation for the Exam Paper total Mark. The Add Function has two inputs and one output:
This results in the Prototype before the calculation (not saved):
And after the calculation (saved):
The Functions can be concatenated to create complex calculations. In this case outputs of Functions are inputs of other Functions.