Some time ago I found an example of a class diagram (with a finite number of classes) so that any object diagram can be derived only with an infinite number of objects. I tried searching for this case, but couldn't find it. I don't think that such diagrams have any practical use, but I found it fascinating, because from university I thought that this isn't possible.
Can you give an example of a class diagram such that any object diagram will require an infinite number of objects?
The simplest example I can think of:
Since every Thing
must have at least one part
, the chain of parts goes on to infinity. There can be no loops in this chain, because
UML 2.5.1: Compositions may be linked in a directed acyclic graph