| Top |
Functions
Functions
ncm_topology_comoving_a0_lss ()
gdouble ncm_topology_comoving_a0_lss (guint n,gdouble alpha);
FIXME
ncm_topology_sigma_comoving_a0_lss ()
gdouble ncm_topology_sigma_comoving_a0_lss (guint n,gdouble alpha,gdouble sigma_alpha);
FIXME
ncm_sphPlm_test_theta ()
gdouble ncm_sphPlm_test_theta (gdouble theta,gint lmax,gint *lmin_data);
FIXME
ncm_numdiff_1 ()
gdouble ncm_numdiff_1 (gsl_function *F,const gdouble x,const gdouble ho,gdouble *err);
FIXME
ncm_numdiff_2 ()
gdouble ncm_numdiff_2 (gsl_function *F,gdouble *ofx,const gdouble x,const gdouble ho,gdouble *err);
FIXME
ncm_numdiff_2_err ()
gdouble ncm_numdiff_2_err (gsl_function *F,gdouble *ofx,const gdouble x,const gdouble ho,gdouble err,gdouble *ferr);
FIXME
ncm_sqrt1px_m1 ()
gdouble
ncm_sqrt1px_m1 (gdouble x);
Calculates $\sqrt{1+x}-1$ using the appropriated taylor series when $x \approx 1$.
ncm_cmp ()
gint ncm_cmp (gdouble x,gdouble y,gdouble reltol);
Compare x and y and return -1 if x < y, 0 if x == y and 1 if x > y,
all comparisons are done with precision prec
.
ncm_complex_dup ()
NcmComplex *
ncm_complex_dup (NcmComplex *c);
Allocates a new complex number and copy the contents of c
to it.
ncm_complex_free ()
void
ncm_complex_free (NcmComplex *c);
Frees c
, it should not be used on a statically allocated NcmComplex.
ncm_complex_clear ()
void
ncm_complex_clear (NcmComplex **c);
Frees *c
and sets *c
to NULL, it should not be used on a statically allocated NcmComplex.
NCM_TEST_GSL_RESULT()
#define NCM_TEST_GSL_RESULT(func,ret) if (ret != GSL_SUCCESS) g_error ("%s: %s", func, gsl_strerror (ret))
NCM_WRITE_INT32()
#define NCM_WRITE_INT32(_ff,_ii) G_STMT_START { gint32 _temp_i = GINT32_TO_BE ((_ii)); if (fwrite (&_temp_i, sizeof(gint32), (1), _ff) != 1) g_error ("NCM_WRITE_INT32: io error"); } G_STMT_END
NCM_WRITE_UINT32()
#define NCM_WRITE_UINT32(_ff,_ii) G_STMT_START { guint32 _temp_i = GUINT32_TO_BE ((_ii)); if (fwrite (&_temp_i, sizeof(guint32), (1), _ff) != 1) g_error ("NCM_WRITE_UINT32: io error"); } G_STMT_END
NCM_WRITE_INT64()
#define NCM_WRITE_INT64(_ff,_ii) G_STMT_START { gint64 _temp_i = GINT64_TO_BE ((_ii)); if (fwrite (&_temp_i, sizeof(gint64), (1), _ff) != 1) g_error ("NCM_WRITE_INT64: io error"); } G_STMT_END
NCM_WRITE_UINT64()
#define NCM_WRITE_UINT64(_ff,_ii) G_STMT_START { guint64 _temp_i = GUINT64_TO_BE ((_ii)); if (fwrite (&_temp_i, sizeof(guint64), (1), _ff) != 1) g_error ("NCM_WRITE_INT64: io error"); } G_STMT_END
NCM_WRITE_DOUBLE()
#define NCM_WRITE_DOUBLE(_ff,_ii) G_STMT_START { NcmDoubleInt64 _iii; _iii.x = _ii; _iii.i = GINT64_TO_BE ((_iii.i)); if (fwrite (&_iii.i, sizeof(gint64), (1), _ff) != 1) g_error ("NCM_WRITE_DOUBLE: io error"); } G_STMT_END
NCM_READ_INT32()
#define NCM_READ_INT32(_ff,_ii) G_STMT_START { gint32 _temp_i; if (fread (&_temp_i, sizeof(gint32), (1), _ff) != 1) g_error ("NCM_READ_INT32: io error"); _ii = GINT32_FROM_BE (_temp_i); } G_STMT_END
NCM_READ_UINT32()
#define NCM_READ_UINT32(_ff,_ii) G_STMT_START { guint32 _temp_i; if (fread (&_temp_i, sizeof(guint32), (1), _ff) != 1) g_error ("NCM_READ_UINT32: io error"); _ii = GUINT32_FROM_BE (_temp_i); } G_STMT_END
NCM_READ_INT64()
#define NCM_READ_INT64(_ff,_ii) G_STMT_START { gint64 _temp_i; if (fread (&_temp_i, sizeof(gint64), (1), _ff) != 1) g_error ("NCM_READ_INT64: io error"); _ii = GINT64_FROM_BE (_temp_i); } G_STMT_END
NCM_READ_UINT64()
#define NCM_READ_UINT64(_ff,_ii) G_STMT_START { guint64 _temp_i; if (fread (&_temp_i, sizeof(guint64), (1), _ff) != 1) g_error ("NCM_READ_UINT64: io error"); _ii = GUINT64_FROM_BE (_temp_i); } G_STMT_END
NCM_READ_DOUBLE()
#define NCM_READ_DOUBLE(_ff,_ii) G_STMT_START { NcmDoubleInt64 _iii; if (fread (&_iii.i, sizeof(gint64), (1), _ff) != 1) g_error ("NCM_READ_DOUBLE: io error"); _iii.i = GINT64_FROM_BE (_iii.i); _ii = _iii.x; } G_STMT_END
ncm_g_string_clear()
#define ncm_g_string_clear(s) G_STMT_START if (*(s) != NULL) { g_string_free (*(s), TRUE); *(s) = NULL; } G_STMT_END