Have a look at the TMatrixD constructors:
TMatrixD::TMatrixD(Int_t no_rows, Int_t no_cols,
const Double_t *elements, Option_t *option)
TMatrixD::TMatrixD(Int_t row_lwb, Int_t row_upb, Int_t col_lwb, Int_t col_upb,
const Double_t *elements, Option_t *option)
or the method
void SetElements(const Double_t *elements, Option_t *option);
where
// option="F": array elements contains the matrix stored column-wise
// like in Fortran, so a[i,j] = elements[i+no_rows*j],
// else it is supposed that array elements are stored row-wise
// a[i,j] = elements[i*no_cols+j]
and elements = &(matrix[0][0])
>
> Hi All;
>
> I have an 2D array, say
> Double_t matrix{6][6];
>
> Now, I want to make a TMatrix from that array;
>
> how can I do this?
> Thanks
>
This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:12 MET