Version 1 (modified by onnopaap, 14 years ago)

--

Base Templates CardinalityEnd1Min, CardinalityEnd1Max, CardinalityEnd1MinMax, CardinalityEnd2Min, CardinalityEnd2Max, and CardinalityEnd2MinMax

Are templates for expressing cardinality constraints on relations.

CardinalityEnd1MinMax(a, b) means that a is a relation and b and c are integers, and that
the first role of a has b as minimum, c as maximum cardinality. The other templates in this
group follow the same pattern.

CardinalityEnd1Min

Roles:
1 hasRelationship ClassOfRelationship
2 valMinimumCardinality INTEGER

CardinalityEnd1Max

Roles:
1 hasRelationship ClassOfRelationship
2 valMaximumCardinality INTEGER

CardinalityEnd1MinMax

Roles:
1 hasRelationship ClassOfRelationship
2 valMinimumCardinality INTEGER
3 valMaximumCardinality INTEGER

CardinalityEnd2Min

Roles:
1 hasRelationship ClassOfRelationship
2 valMinimumCardinality INTEGER

CardinalityEnd2Max

Roles:
1 hasRelationship ClassOfRelationship
2 valMaximumCardinality INTEGER

CardinalityEnd2MinMax

Roles:
1 hasRelationship ClassOfRelationship
2 valMinimumCardinality INTEGER
3 valMaximumCardinality INTEGER

Axiom:

CardinalityEnd1Min(x1, x2) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
exists u(CardinalityMin(u, x2) & hasEnd1Cardinality(x1, u)) .


Axiom:

CardinalityEnd1Max(x1, x2) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
exists u(CardinalityMax(u, x2) & hasEnd1Cardinality(x1, u)) .


Axiom:

CardinalityEnd1MinMax(x1, x2, x3) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
INTEGER(x3) &
exists u(CardinalityMinMax(u, x2, x3) &
hasEnd1Cardinality(x1, u)) .


Axiom:

CardinalityEnd2Min(x1, x2) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
exists u(CardinalityMin(u, x2)&
hasEnd2Cardinality(x1, u)) .


Axiom:

CardinalityEnd2Max(x1, x2) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
exists u(CardinalityMax(u, x2)&
hasEnd2Cardinality(x1, u)) .


Axiom:

CardinalityEnd2MinMax(x1, x2, x3) <->
ClassOfRelationship(x1) &
INTEGER(x2) &
INTEGER(x3) &
exists u(CardinalityMinMax(u, x2, x3)&
hasEnd2Cardinality(x1, u)) .


NOTE For unlimited minimum or maximum cardinalities, assign the values 0 and * cardinality,
respectively. See the definitions of templates CardinalityMin, etc., above.

NOTE What constitutes the first and second roles of a relation is stated in the table of prototemplates
(D.1, page 103).

NOTE Let R be a relation to which a cardinality n1 : m1 is assigned to the first role, and a cardinality
n2 : m2 to the second. This means that (1) each instance of the first role is R-related to at least
n2 and at most m2 distinct instances of the second role, and (2) each instance of the second role is
related to at least n1 and at most m1 distinct instances of the first role.

EXAMPLE The statement CardinalityEnd1MinMax(6 M8 bolt assembly, 6, 6) is suitable for expressing
an example of a constraint given in ISO 15926-2, clause 4.10.3, that “[t]he
class_of_relationship_with_signature ‘6 M8 bolt assembly’ has a cardinality such that each ‘6 of
M8 bolts’ is linked by exactly 6 relationships to different M8 bolts at all times”. The expansion of
this statement is shown in the following diagram.

Home
About PCA
Reference Data Services
Projects
Workgroups