We could create a generic NDArray storage class. Matrix could contain such
a class rather than inherit from it.

On Sat, May 12, 2012 at 8:10 AM, Aaron Meurer <[email protected]> wrote:

> I agree that they should be separate.  A Tuple represents a generic
> container object, whereas a Matrix is a specific kind of object with
> certain algebraic properties.  The fact that Tuple is only Basic
> whereas ImmutableMatrix is also Expr showcases this fact (I know this
> brings us back to the "meaning of Expr" discussion).
>
> A Tuple might be thought of mathematically as an element of a
> cartesian product set.  As Joachim noted, it could contain anything:
> mathematical expressions, boolean expressions, sets, other tuples,
> etc.  A Matrix has properties like a*(x, y, z) = (a*x, a*y, a*z).
> This doesn't make sense if x, y, and z are all booleans, for example.
>
> Another thing:  if we define a nxm matrix by ((x11, x12, ..., x1m),
> ..., (xn1, xn2, ..., xnm)), then this could be seen as a column of row
> vectors.  So we see that depending on the context, we must consider a
> tuple to be a row matrix or a column matrix.
>
> If anything, ImmutableMatrix should subclass from Tuple, not the other
> way around, since the latter is a more generic class.
>
> What specific special cases are there in the code by the way?
>
> Aaron Meurer
>
> On Sat, May 12, 2012 at 5:21 AM, [email protected]
> <[email protected]> wrote:
> > Here is the issue http://code.google.com/p/sympy/issues/detail?id=3263
> >
> > --
> > You received this message because you are subscribed to the Google
> Groups "sympy" group.
> > To post to this group, send email to [email protected].
> > To unsubscribe from this group, send email to
> [email protected].
> > For more options, visit this group at
> http://groups.google.com/group/sympy?hl=en.
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "sympy" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/sympy?hl=en.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sympy" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/sympy?hl=en.

Reply via email to