Learn about Webel's comprehensive SysMLv2 Workshop Seminar course!
Webel now has a SysMLv2 Online Self-Study course with self-test Quizzes!
Learn about the Webel Q&A online self-testing system for SysML v2/v1

ISSUE: SysMLv2.0 spec Annex example and multiple SysMLv2 PILOT GitHub samples: Inconsistent use of subsetted ISQ «attribute» (has multiplicity [*] in Cameo) without explicit multiplicity. According to SysML2.0 spec. rules would inherit multiplicity [*].

This page identifies a possible issue, inconsistency, concern, error, or bug!
One of the ways Webel IT Australia helps promote tools, technologies, and languages is by donating a lot of time identifying, tracking, and reporting potential issues, in order to help vendors and developers improve the tools and technologies. In some cases, we also offer workarounds and advice for users. All issues tracked on our public site are offered most constructively and with sincerest gratitude to the tool vendors and technology developers.
DISCLAIMER: Vendors do not officially endorse issue analysis by Webel IT Australia.
Icon class
icon_class
far fa-sticky-note
icon_class_computed
far fa-sticky-note
Note kind
Policy level
Specification keywords
SysMLv2 keywords
Keywords
Click on the image to view it full size

This analysis assumes that an ISQ quantity «attribute» has multiplicity [*] as it does in the Cameo SysMLv2 Plugin model libraries.


There are numerous examples in the SysMLv2 Annex example and the SysMLv2 PILOT GitHub samples of an «attribute» subsetting an ISQ quantity «attribute» but NOT providing an explicit multiplicity. The following are from the main Vehicle Example but there are many other similar ones:

part def Vehicle {
    attribute mass :> ISQ::mass;
    attribute dryMass:>ISQ::mass;
    attribute cargoMass:>ISQ::mass;
    attribute position:>ISQ::length;
    attribute velocity:>ISQ::speed;
    attribute acceleration:>ISQ::acceleration;
    attribute electricalPower:>ISQ::power;

That these are intended to have multiplicity [1..1] is suggested from how they are used elsewhere:

constraint {electricalPower<=500[W]}

Note there are other cases that DO provide an explicit multiplicity:

attribute elapseTime[1] :> ISQ::time;
attribute position[1] :> ISQ::distance;

The cases that don't provide a multiplicity seem to be relying on this rule:

But they do not in fact meet those extra conditions:

Since they DO subset an ISQ quantity «attribute» with an explicitly declared multiplicity [*] (at least in Cameo) they inherit the explicitly declared multiplicity [*].

And they don't meet the other conditions anyway:

Maybe this part is supposed to offer a loophole:

But that does not apply, taken literally, because there is an explicitly declared multiplicity [*] to inherit (even if [*] and [0..*] are the same).

Webel's advice is:

  1. Prefer using feature typing by an ISQ «attribute def» (noting the available ISQ «attribute» versions don’t cover all cases anyway).
  2. If you do use subsetting of an ISQ «attribute» always state the multiplicity!
Relates to
Related notes
Related notes (backlinks)
Related snippets (extracts)
Visit also
Visit also (backlinks)