Multiplicity of "relatedElements" in Relationship

21 views
Skip to first unread message

Robert Hairgrove

unread,
Mar 15, 2024, 7:19:22 AMMar 15
to UML Forum
It is obvious to me that a Relationship or a DirectedRelationship must contain at least two relatedElements, even if they can be the same element as in a loop edge of a directed or undirected graph.

However, the multiplicity of "relatedElement" is given as "1..*" in Element of Figure 7.1 on page 63 of the UML 2.5.1 standard document.

Can anyone describe a scenario where a relationship would have more than two related elements? I am guessing that someone will point out the inheritance (generality relationship) depicted between Element, Relationship and Comment whose arrows merge into one at the Element end. However, I understand this notation to be more of a convenience in understanding the graphical notation, but in reality depicts two separate Relationships: one between Relationship and Element, and another between Comment and Element, and not a single Relationship with three relatedElements.

For my understanding of graph theory, an edge (i.e. Relationship in UML) must have exactly two, no more and no less, related elements. If it is a loop edge, i.e. an element related to itself, then the two relatedElements would be the same; otherwise, they are different, and the DirectedRelationship would impose an ordering such that "source" and "target" are identifiable as such.
Reply all
Reply to author
Forward
0 new messages