eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'AbstractMatrix':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: AbstractMatrix


Inheritance:

   Object
   |
   +--Collection
      |
      +--SequenceableCollection
         |
         +--AbstractMultidimensionalArray
            |
            +--AbstractMatrix
               |
               +--Matrix
               |
               +--MatrixAccessor

Package:
stx:libbasic
Category:
Collections-MultiDimensional
Version:
rev: 1.4 date: 2021/11/08 22:13:18
user: cg
file: AbstractMatrix.st directory: libbasic
module: stx stc-classLibrary: libbasic
Author:
cg

Description:


documentation to be added.

class:
    <a short class summary here, describing what instances represent>

responsibilities:    
    <describing what my main role is>

collaborators:    
    <describing with whom and how I talk to>

API:
    <public api and main messages>
    
example:
    <a one-line examples on how to use - can also be in a separate example method>

implementation:
    <implementation points>


[instance variables:]

[class variables:]


Related information:



Instance protocol:

accessing
o  at: index
dimensions size ~~ 1 ifTrue:[self dimensionError].

o  at: index put: val
dimensions size ~~ 1 ifTrue:[self dimensionError].

o  subMatrix: aPoint
}

Usage example(s):

     (Matrix3_3 withAll:#(11 12 13 
                          21 22 23 
                          31 32 33))
        subMatrix:(1 @ 1)  

arithmetic
o  * aNumberOrMatrix
Answer the result of multiplying this matrix by a scalar.

Usage example(s):

     |m1 m2|

     m1 := (Matrix[2][2]) 
        contents:#(
            1 2
            5 1
        ).
     m1 * 10 

o  + aMatrix
Answer the result of adding 'aMatrix' to this matrix.

Usage example(s):

     |m1 m2|

     m1 := (Matrix[2][2]) 
        contents:#(
            1 2
            5 1
        ).
     m2 := (Matrix[2][2]) 
        contents:#(
            3 -1
            2 1
        ).
     m1 + m2

Usage example(s):

     |m1|

     m1 := (Matrix[2][2]) 
        contents:#(
            1 2
            5 1
        ).
     m1 + 1

o  - aMatrix
Answer the result of subtracting 'aMatrix' from this matrix.

Usage example(s):

     |m1 m2|

     m1 := (Matrix[2][2]) 
        contents:#(
            1 2
            5 1
        ).
     m2 := (Matrix[2][2]) 
        contents:#(
            3 -1
            2 1
        ).
     m1 - m2    

Usage example(s):

Modified (comment): / 28-02-2021 / 14:43:03 / cg

o  / aNumberOrMatrix
Answer the result of dividing this matrix by a scalar.

Usage example(s):

     |m1 m2|

     m1 := (Matrix[2][2]) 
        contents:#(
            1 2
            5 1
        ).
     m1 / 2    

double dispatching
o  differenceFromMatrix: aMatrix
Answer the result of subtracting the receiver from 'aMatrix'.
This is a slow fallback
(and even that may be tuned to avoid the repeated index computation
and useless bounds checks involved)

o  productFromMatrix: aMatrix
Answer the result of multiplying 'aMatrix' with this matrix.
This is a slow fallback
(and even that may be tuned to avoid the repeated index computation
and useless bounds checks involved)

o  sumFromMatrix: aMatrix
Answer the result of adding 'aMatrix' to this matrix.
This is a slow fallback
(and even that may be tuned to avoid the repeated index computation
and useless bounds checks involved)

matrix operations
o  determinant

o  minor: aPoint
Modified (format): / 10-03-2021 / 09:17:02 / cg

o  transposed
return a transposed matrix

Usage example(s):

     |m|

     m := (Matrix[3][2]) contents:#( 1 2
                                     3 4
                                     5 6).
     m transposed.  
     m transposed transposed. 

     m * m transposed.

queries
o  cofactor: aPoint
Modified (format): / 10-03-2021 / 09:16:48 / cg

o  columns
the number of columns

o  rows
the number of rows



ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Thu, 10 Oct 2024 12:24:08 GMT