Files
kraken/ChrisTest/ChrisMatrix/ChrisMatrix.krak

38 lines
647 B
Plaintext

import vector:*;
import io:*;
typedef ChrisMatrix(Destructable)
{
/***************
* Member Data
**************/
|double**| data;
|int| rowSize;
|int| columnSize;
/**************************
* Constructor/Destructor
*************************/
|double***| construct()
{
rowSize = 0;
colSize = 0;
//data = NULL; Will this work?
return this;
}
|bool| Initialize(|int| m, |int| n)
{
data = malloc(sizeof(double*)*m);
for(|int| i = 0; i < m; i++)
{
data[i] = malloc(sizeof(double)*n);
}
rowSize = m;
colSize = n;
}//end itialize function
}//end Matrix class