Constructor

NumCosmoMathMatrixnew_array

Declaration [src]

NcmMatrix*
ncm_matrix_new_array (
  GArray* a,
  const guint ncols
)

Description [src]

The number of rows is defined dividing the lenght of a by ncols. This function saves a internally and frees it when it is no longer necessary. The GArray a must not be freed.

Parameters

a

Type: An array of double

GArray of doubles to be converted into a NcmMatrix.

The data is owned by the caller of the function.
ncols

Type: const guint

Number of columns.

Return value

Type: NcmMatrix

A new NcmMatrix.

The caller of the function takes ownership of the data, and is responsible for freeing it.