aboutsummaryrefslogtreecommitdiff
path: root/src/algebra/fortran.spad.pamphlet
diff options
context:
space:
mode:
Diffstat (limited to 'src/algebra/fortran.spad.pamphlet')
-rw-r--r--src/algebra/fortran.spad.pamphlet14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/algebra/fortran.spad.pamphlet b/src/algebra/fortran.spad.pamphlet
index 92b1f238..f0c2cc29 100644
--- a/src/algebra/fortran.spad.pamphlet
+++ b/src/algebra/fortran.spad.pamphlet
@@ -974,7 +974,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
-- the first argument must be a symbol, which is either i,j or k
-- to specify the direction in which the concatenation is to take place
matrixConcat3D(dir : Symbol,mat1 : $,mat2 : $) : $ ==
- ^((dir = (i::Symbol)) or (dir = (j::Symbol)) or (dir = (k::Symbol)))_
+ not ((dir = (i::Symbol)) or (dir = (j::Symbol)) or (dir = (k::Symbol)))_
=> error "the axis of concatenation must be i,j or k"
mat1Dim := matrixDimensions(mat1)
mat2Dim := matrixDimensions(mat2)
@@ -990,7 +990,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
if (dir = (i::Symbol)) then
-- j,k dimensions must agree
- if (^((jDim1 = jDim2) and (kDim1=kDim2)))
+ if (not ((jDim1 = jDim2) and (kDim1=kDim2)))
then
error "jxk do not agree"
else
@@ -998,7 +998,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
if (dir = (j::Symbol)) then
-- i,k dimensions must agree
- if (^((iDim1 = iDim2) and (kDim1=kDim2)))
+ if (not ((iDim1 = iDim2) and (kDim1=kDim2)))
then
error "ixk do not agree"
else
@@ -1010,7 +1010,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
if (dir = (k::Symbol)) then
temp : (PA PA R)
-- i,j dimensions must agree
- if (^((iDim1 = iDim2) and (jDim1=jDim2)))
+ if (not ((iDim1 = iDim2) and (jDim1=jDim2)))
then
error "ixj do not agree"
else
@@ -1101,7 +1101,7 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
kLength2 := mat2Dims.3
-- check that the dimensions are the same
- (^(iLength1 = iLength2) or ^(jLength1 = jLength2) or ^(kLength1 = kLength2))_
+ (not (iLength1 = iLength2) or not (jLength1 = jLength2) or not(kLength1 = kLength2))_
=> error "error the matrices are different sizes"
sum : R
@@ -1133,10 +1133,10 @@ ThreeDimensionalMatrix(R) : Exports == Implementation where
--first check that the matrix is in the correct form
for subList in listRep repeat
- ^((#subList)$(L L R) = jLength) => error_
+ not((#subList)$(L L R) = jLength) => error_
"can not have an irregular shaped matrix"
for subSubList in subList repeat
- ^((#(subSubList))$(L R) = kLength) => error_
+ not((#(subSubList))$(L R) = kLength) => error_
"can not have an irregular shaped matrix"
row1 : (PA R) := new(kLength,((listRep.1).1).1)$(PA R)