module Numeric.LAPACK.Matrix.Array.Basic where

import qualified Numeric.LAPACK.Matrix.Array as ArrMatrix
import qualified Numeric.LAPACK.Matrix.Basic as Basic
import qualified Numeric.LAPACK.Matrix.Extent as Extent
import Numeric.LAPACK.Matrix.Array (Full)


transpose ::
   (Extent.C vert, Extent.C horiz) =>
   Full vert horiz height width a -> Full horiz vert width height a
transpose = ArrMatrix.lift1 Basic.transpose

swapMultiply ::
   (Extent.C vertA, Extent.C vertB, Extent.C horizA, Extent.C horizB) =>
   (matrix ->
    Full horizA vertA widthA heightA a ->
    Full horizB vertB widthB heightB a) ->
   Full vertA horizA heightA widthA a ->
   matrix ->
   Full vertB horizB heightB widthB a
swapMultiply multiplyTrans a b = transpose $ multiplyTrans b $ transpose a