Unit for matrix with unknown size #25
-
If I have a class diagram with: class ClassA{ m: Matrix}. If I know the size, I can assign a unit to the matrix with m : Unit[h][3,3]. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
By using the matrix class as an attribute type, as in the example here, a unit can be assigned to the attribute. However, the matrix class as an attribute type is not supported in the solution path generator (SPG). |
Beta Was this translation helpful? Give feedback.
By using the matrix class as an attribute type, as in the example here, a unit can be assigned to the attribute.
G+[(matrixTest:ClassA)] matrixTest.m = #[#[1,2,3],#[2,3,4],#[3,4,5]].unit("h")
However, the matrix class as an attribute type is not supported in the solution path generator (SPG).
An implementation of arbitrary matrices with Unit[h][,] is not planned, as the equation environment performs a unit check as well as a dimension check and this is not possible without knowledge of the use of the classes. Matrices with undefined dimensions are often used as data storage and not as equation variables.