User Tools

Site Tools


bok:eng:mbse:sysml:bdd-ibd_f

Variants

Generalization Sets

Simplest form of variation is with the use of generalization sets. By default a generalization set is overlapping and incomplete. See below example.

To create a generalization set do…

  • Right click generalization edge → Advanced → Generalization Set → New

Disjoint is the opposite to Overlapping. Disjoint is the example of either a person is Female or Male, the person can not be both Female and Male. In the Employment generalization set it is Overlapping because somebody can be both a Manager and an Employee. Complete is the opposite to Incomplete. For Gender generalization set there are no other possibilities to Female and Male, therefore the set is Complete. However in the Employment generalization set there are other possibilities to Manager and Employee (e.g. Unemployed, Freelancer) and therefore Incomplete.

Inheriting and Redefining

Generalisation allows the child class to inherit properties (including parts) from the parent class. See the below example.

mass is a property of Image Sensor which is a general class for Low Mass Sensor and High Mass Sensor. Assuming that the parent block has the generic property already then after including the generalization edge on the child block:

  • Right click Low Mass Sensor → Features → Parts/Properties
  • Select Show Owned/Inherited
  • The mass property (owned by Image Sensor) will appear

[If you want to redefine the parent's property - choose this if you want to modify the parent's property]

  • Right click property (don't select it) → Redefine
  • In Model Tree select the property now under Low Mass Sensor → Redefined/Subsetted → Redefined → Add..
  • Chose the mass property that is under Image Sensor
  • Now the {redefines Image Sensor::mass} appears in the Low Mass Sensor. In the Parts/Properties you will see a mass property owned by the parent class and the mass property (which is redefined) owned by the child class
  • You can set an initial value for the redefined property or chose another less general type. This will not influence the property in the parent class

[If you want to inherit the parent's property - choose this if you want to copy the parent's property]

  • Select the property. Prior to selection the mass property was owned by Image Sensor, now it is owned by Low Mass Sensor
  • Now the property appears in the Low Mass Sensor block
  • If the property in the parent class is modified (e.g. a value is assigned or the Type is changed, this will be reflect in the child class as well (this is not true if you chose to Redefine the property)

Bound Reference

Generalisation alone is a simple and effective method to introduce variations. However it may the case that the variation is nested deeply within the block (e.g. a different image sensor provide variation to the whole camera) and the prior method would require the modeler to map out the entire tree to arrive at the part that is the cause of the variation. In this case the modeler can chose to use Bound References which are tailored to the task.

Include a Bound Reference into the ibd as shown below and add a binding connector between the bound reference and the part that is the source of variation. See below for an example.

Give the Bound Reference the same name and type. Also in the SysML 1.5 tab in the boundEnd find the property of the part (in this case sensor: Image Sensor [1])

Don't know why add the boundEnd property

To redefine the bounded property in the child classes (Camera Y and Camera Z are the child of Camera in this case) follow the instructions in Inheriting and Redefining. Select the more specific Type of the Image Sensor.

Property Specific Types

Don't know how to do this

Configurations with ID'd Blocks

Assuming that a structure is defined and variants are typed (see below)

Then configurations are possible of the top level structure (or any level) as long as there exists one property which has a value unique to identify the configuration. In the below case this is serial number:String. In the Element Properties→Property the ID box is ticked.

I'm guessing that the unique identifier needs to be ID=TRUE.

Note that properties/values are redefined whilst parts that are made more specific (cam:Camera) are typed by a child type (Indoor Camera, Outdoor Camera) are subsetted. To subset a property follow the same procedure to redefine only in Redefined/Subsetted tab Add… from the Subsetted section.

Configurations with Instances

If the modeler only wants to change values to create a variant then can use Instances. Firstly I have added two properties to Camera (see below):

In a new BBD drag Alfred System block on the canvas and instead of selecting Link chose Instance (Object). After insertion of instance (note that the color is different and the name field is underlined) then assign a name to the Instance (e.g. Work Days) then right click → Features → Parts/Properties. Now the properties can not be further redefined. Select the property ind_camera:Indoor Camera. The property appears as ^/ind_camera:Indoor Camera. Give the property an identifying name. If it is renamed (e.g. Alred1) then it will appears are ^Alfred1/ind_camera:Indoor Camera

Do same for Indoor Camera, except this time select operating cycle:String.

After insertion of operating cycle:String notice that the name is dropped and appears as :String only. Whilst choosing the property, in Element Properties→Property→Initial: Define a new string and assign a recognizable name (in the below case: “opcycle”).

It appears that I can not insert Instance properties within an existing Instance object.

bok/eng/mbse/sysml/bdd-ibd_f.txt · Last modified: 2020/07/07 22:17 by anwlur