<< JunoMatrix.mesa >> <<>> <> << Tools for coordinate transformations and matrix algebra.>> DIRECTORY JunoStorage USING [Coords, Point, Frame]; JunoMatrix: DEFINITIONS = BEGIN OPEN Stor: JunoStorage; Point: TYPE = Stor.Point; Coords: TYPE = Stor.Coords; Matrix: TYPE = ARRAY [1..3] OF ARRAY [1..3] OF REAL; Frame: TYPE = Stor.Frame; Identity: PROC [m: REF Matrix _ NIL] RETURNS [mid: REF Matrix]; <> <> GetFrameMatrix: PROC [frame: Frame, m: REF Matrix _ NIL] RETURNS [mr: REF Matrix]; <> <> <> InvertMatrix: PROC [m: REF Matrix, work: REF Matrix _ NIL] RETURNS [mInv: REF Matrix, singular: BOOL]; <> <> MultiplyMatrix: PUBLIC PROC [ma, mb: REF Matrix, mc: REF Matrix _ NIL] RETURNS [mr: REF Matrix]; <> <> ComputeTransform: PROC [src, dest: Frame, mm: REF Matrix _ NIL] RETURNS [mat: REF Matrix, singular: BOOL]; <> <> <> MapCoords: PROC [coords: Coords, mat: REF Matrix] RETURNS [cMap: Coords]; <> END.