Exercise 13.1 - NX to SysML

Objectives

The new learning objective of this exercise is to generate a SysML model from a NX CAD assembly structure.

Preparation

This exercise assumes the student has

  • Cameo System Modeler 18.0 - 19.0 (or MagicDraw with SysML plug-in) installed correctly on his or her machine with a valid license for use,

  • Syndeia 3.3 installed as a plugin for Cameo/MagicDraw with a valid license for use

  • Syndeia NX interface, correctly installed with a valid license for use,

  • Siemens NX 11.0 or later, installed correctly on his or her machine with a valid license for use.
    The NX CAD model used in this illustration is the Toycar model that is provided. It is also available with NX installation. It is located under:  <NX_Installation>\ UGOPEN\SampleNXOpenApplications\Java\parts, e.g. C:\Program Files\Siemens\NX 9.0\UGOPEN\SampleNXOpenApplications\Java\parts
    It should be copied to your local file system where it is available through a local repository link (see Video 1.2 for adding a repository link).

Exercise

  1. Create a new MagicDraw project. Add the Syndeia profile and an empty package (Toycar in this example) to your SysML model.

  2. Launch the Syndeia Dashboard from the Toycar package. Select a Syndeia Cloud project if necessary. Go to the Connection Manager tab, expand the SysML model in the left column and your local repository (DZ Local in our example) in the right. Find the NX CAD model (.prt) file, using a repository link pointing to the section of your local file system where the CAD model is located

  3. Expand the prt file to view the NX model structure. This will initialize a NX session if this is the first time you are accessing NX models after creating/opening your SysML project. Once the NX session is initialized, you will see an assembly icon (for NX assemblies) or a part icon (for NX piece parts) under the prt file, as shown for the toycar_assy assembly model under toycar_assy.prt file in Figure 1 below.

    Figure 1 NX model loads when a NX prt file is expanded 

  4. Expand the NX model to view the assembly structure, as shown in Figure 2. You can also expand any other NX prt file to view the part/assembly structure, as shown for the toycar_axle_assy.prt file below.

    Figure 2 Expand the NX model to view the assembly structure

  5. Right-click the prt file of the NX CAD model in the right column and select Open. This will open the CAD model in NX, as shown in Figure 3 below.

    Figure 3 Syndeia opens the NX CAD model from the Dashboard

  6. Select Model Transform connection type in the middle panel and drag-and-drop the NX model ( toycar_assy, not toycar_assy.prt) from the right column to the Toycar SysML package in the left column, as shown in Figure 4. Select Yes at the prompt.

    Figure 4 Drag and drop the NX model to a SysML package

  7. This generates a SysML block structure from NX assembly structure, as shown in Figure 5. Notice the generation of block value properties and part properties corresponding to mass properties and assembly components respectively in the CAD model.

    Figure 5 SysML block structure generated (LHS) from the NX model structure (RHS)

  8. Create a SysML block diagram in the SysML tool and display the toycar_assy block and its the part and value properties, as shown in Figure 6 below. Now, you can see the details of the block structure generated from NX assembly structure by Syndeia. The toycar_assy block has 4 part properties—3 shown in the parts compartment and 1 shown in an expanded form (FRONT_AXLE). The semantic mapping from NX CAD assembly structure to SysML block structure is as follows:\

    1. NX part or assembly -> SysML block

    2. NX part or assembly mass properties -> SysML block value properties

    3. NX assembly component -> SysML block part property with an association block

    4. NX part feature -> SysML block and part property (optional)

    5. NX feature expression -> SysML value property (optional)

      Figure 6 SysML BDD showing the block structure generated from NX assembly structure

  9. Syndeia generates a SysML block corresponding to every NX CAD part or sub-assembly in the root assembly structure. It applies the <<NX_Part>> stereotype to identify NX parts (piece parts or assemblies) and sets the base unit for the part (e.g. mm) in the unit stereotype tag. The mass properties of the part or assembly are generated as value properties. This includes mass, volume, density, surface area, center of gravity, and the coordinates of the lower left corner and upper right corner of the geometric bounding box of that part/assembly. The units for mass properties are assigned to the unit stereotype applied to the value property, e.g. unit for mass is kg (as shown in Figure 7).

    Figure 7 SysML blocks are generated for every NX part/assembly in the assembly structure

  10. A CAD assembly is made of up of components, each of which are usages of a part (or sub-assembly) in the context of that assembly. Syndeia generates two important elements for assembly components. First, it creates a part property relationship (FRONT_AXLE) from the parent assembly block (toycar_assy) to the child part or sub-assembly block (toycar_axle_assy). Second, it creates an association block for the composition (part property) relationship that stores information regarding the placement of the component in the assembly, specifically the transformation from the child part (or sub-assembly) co-ordinate system to the parent assembly (or global) co-ordinate system. Syndeia applies the <<NX_Component>> stereotype to association blocks, as shown in Figure 6. The transformation that places the component in the assembly is expressed in terms of a translation vector and a 3x3 rotation matrix, as shown in Figure 6.

  11. In the drag-and-drop operations, Syndeia generates connections between SysML blocks and the NX CAD parts/assemblies. You can view the connections organized by the SysML model in the Connection Browser tab or as a flat list in the Connection Search tab. Users can invoke compare and sync operations by right-clicking on one or more connections.

    • Compare Source & Target compares the mass properties between the SysML blocks and NX parts/assemblies.

    • Sync Target -> Source updates the mass properties in the SysML block from the NX part/assembly

    • Sync Source -> Target is not supported. This use case is not a high priority for system engineers since they usually do not modify existing CAD models directly. Mass properties in a CAD model are computed from the geometry and hence they are read-only properties. 

  12. Syndeia provides additional options to bring features on CAD parts and expressions/parameters on features to the SysML model. You can check or uncheck the following NX settings in the Settings tab—Get features of NX parts and Get expressions (parameters) of NX parts—and select Apply, as shown in Figure 8.

    Figure 8 Syndeia provides additional options to bring features and expressions (parameters) from NX

  13. If these settings are applied, then dragging a NX model to a SysML package (as shown in previous steps) will also generate SysML blocks corresponding to part features, and block value properties corresponding to feature expressions/parameters. The NX_Part_Feature stereotype is applied to each block corresponding to a part feature. As shown in Figure 9, the toycar_body block has 7 features—4 shown in the parts compartment and 3 shown in the expanded form. A SysML block, e.g. Extrude(4), was generated for each feature under the toycar_body block and a part property relationship was created from the toycar_body block to each of the feature blocks. The Extrude(4) feature block has 2 value properties indicating the extrusion depth of 23 mm.

    Figure 9 Feature blocks and expression value properties generated from a NX part