Function

NumCosmoMathSpectralcompute_d_row

Declaration [src]

void
ncm_spectral_compute_d_row (
  gdouble* row_data,
  glong offset,
  gdouble coeff
)

Description [src]

Computes row k of the first derivative operator $\frac{d}{dx}$ that maps Chebyshev coefficients to Gegenbauer $C^{(2)}_k$ coefficients.

Input: Chebyshev $T_n(x)$ basis coefficients (columns) Output: $\langle C^{(2)}_k, f’ \rangle$ - projection of $f’$ (row k)

Mathematical formula: $$ \langle C^{(2)}k, f’ \rangle = c{k+1} - c_{k+3} $$ where $c_n$ are the input Chebyshev coefficients.

Adds to existing row data (for linear combinations of operators).

Matrix entries for row k: - column k+1: coeff * 1.0 - column k+3: coeff * (-1.0).

Parameters

row_data

Type: gdouble*

Row structure to update.

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

Type: glong

Row offset.

coeff

Type: gdouble

Coefficient to multiply all elements.