Astah SysML Tutorial
Block Definition Diagram
Let's draw the sample Block Definition Diagram below which details the specification of Units and ValueTypes employed in the SUV design.
(Figure B2 from OMG SysML Specification v1.2 - P.162)
First, create a Block Definition Diagram [Diagram] - [Block Definition Diagram] from the Main Menu or right-click the root project in the Structure Tree and select [Create Diagram] - [Add Block Definition Diagram]. Then a blank Block Definition Diagram opens in the Diagram Editor.
On the top of the Diagram Editor, there is a list of icons called "tool bar" that has a menu to create models with.
To find out which icon does what, move your mouse over each icon, it will tell you what the icon is for in a tool tip.
First, create the [Automotive Value Types] package. To create a Package, select [Package] in the tool bar and then click the diagram.
A package will be added in the diagram, name it "Automotive Value Types" and then hit the Enter key to complete.
Now let's create Value Types that are shown in pink in the sample diagram. Select the Value Type button in the tool bar.
Because you want to place the Value Types inside the [Automotive Value Types] Package, click directly on the package then the Value Type, it will be placed inside of it.
Then type the name directly in. Now create the other 5 Value Types in the same way.
TIP 1 - Moving model elements: You can move around the model elements by simply dragging them. To rename the model elements, just double-click its name.
TIP 2 - Continuously create the same model elements: When you want to add same model elements continuously, hold the [Shift] key down and keep clicking the diagram editor.
Now let's draw the Generalization between the Value Types. To create one, select [Generalization] in the tool bar then click two Value Types to connect.
Select [Generalization], then click "Accel" ValueType and then "Real". The Generalization is created as below.
Create the Generalizations from the other 4 Value Types to "Real" in the same way. You will then have the diagram like the one below.
To make all the Generalization lines together, select them all and then go to [Edit] - [Shared Style] - [Vertical].
All the lines will then be in one solid line like the figure below.
Now let's create the Units that are shown in blue. The way to create Units is exactly the same as ValueTypes. First, create the "Automotive Units" Package that holds all of the Units. Then select [Unit] in the tool bar which you can find from the drop-button of ValueType. Click inside of the "Automotive Units" package and name them.
Now your diagram should look like this.
Next, create QuantityKinds. This time let's create them from the Structure Tree. Right-click the [Automotive Value Types] Package and then select [Create Model] - [Add QuantityKind].
All the QuantityKind will be made under the [Automotive Value Types].
After all the QuantityKind is made, set each QuantityKind to the Units. To do so, select the Unit in the diagram and go to the [Base] tab of its property view, open the drop-down list and set each Unit to QuantityKind. Below is the figure setting "Time" QuantityKind to the "sec" Unit.
After the QuantityKind is set in the Property View, the QuantityKind information appears within the Units in the diagram.
You have now completed the first Block Definition Diagram, name this diagram "ModelingDomain". To do this, select the "Block Definition Diagram0" in the Structure tree and type in the [Base] tab of its Property view.
For more practice, let's draw another Block Definition Diagram and create Blocks to define the fuel flow properties of the "PowerSubsystem".
(From P.179 Figure.B.23 of OMG SysML 1.2)
First, let's create the "HSUV" Block and then create a Block Definition Diagram for it. To create a new Block, right-click the root topic and select [Create Model] - [Add Block].
Name the new Block "HSUV". Now create a new Block Definition Diagram under this HSUV Block. Right-click this Block and select [Create Diagram] - [Add Block Definition Diagram].
The new Block Definition Diagram will open; name the diagram "PowerSubsystem Fuel Flow Definition".
Create the 5 Blocks that are shown in yellow in the sample diagram. Select a Block in the tool menu and then click on the diagram.
Name them "PowerSubsystem", "Fuel", "FuelTankAssembly" and "InternalCombustionEngine". After all the Blocks are made, make the associations between them. Creating an Association is same as when you created the Generalization before. Select the Association from the tool menu and then click the two Blocks you want to connect. Let's draw one between the "PowerSubsystem" and "FuelTankAssembly" Blocks. The association is a Composition, so select the "Composition" from the tool bar.
Click "PowerSubsystem" and then "FuelTankAssembly" and create another one - click "PowerSubsystem" and then "InternalCombustionEngine".
To make these Compositions in one line like the sample diagram, select both Composition lines and then select [Line Style] - [Line (Right Angle)] from the Pop-up menu.
The Composition line will look like the ones below.
TIPS3 - How to set the property for Associations: there are a few ways to make the Association type. Here's how to set it to Compositions as an example.
1: From Pop-up menus: Right-click the Association line and set it to Composite from "Aggregation".
2: From the Property View: Select the Association Line in the diagram and go to its Property View. Open [Association End A/B] tab and specify it in the "Aggregation" field.
Now let's set the name for the Association End. Select the Composition line and go to its Property View and open [Association End A/B] tab and put "ft" for "FuelTankAssembly" End and "ice" for "InternalCombustionEngine" End. When you are on this [Association End A/B] tab, make sure that the Target is the end block you want to name for.
Now add the Flow Properties to the "FuelTankAssembly", "InternalCombustionEngine" and "FuelFlow" Blocks. There are four ways to do so.
- From the Block's Pop-up menu [Add Element] - [Add Flow Property]
- By clicking the blue cross of the "flow properties" compartment of the Block
- From [FlowProperty] of the Block's property view
- From the Block's Pop-up menu in the Structure Tree
Add the Flow Properties in any way you'd like. Type its Name, specify the Type and FlowDirection in its property view.
Next add Ports to these Blocks. Click the [Port] button from the tool bar and click on the "FuelTankAssembly" Block.
Go to the [Base] tab of Port's Property view and name it "FuelTankFitting" then set the Type as "FuelFlow".
"FuelFlow" goes both directions, so two arrows would appear inside the port on the diagram.
Add another "ICEFuelFitting" Port to the "InternalCombustionEngine" just like the one you just created.
Last, add the Values to the "Fuel" Block (The blue Block in the diagram). To add the Values, click the blue cross button in the "values" compartment. Then type the two Values as shown in the sample diagram. When you type "Temp" and "Press" it asks you to create a new Type, click [Yes] both times.