From f0460fe03fff8c5c567756149e39ff25a7663b1c Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Thu, 1 Oct 2015 12:10:55 +0200 Subject: Prepare for radial basis. --- brill_data.h | 74 +++++++++++++++++++++++------------------------------------- 1 file changed, 28 insertions(+), 46 deletions(-) (limited to 'brill_data.h') diff --git a/brill_data.h b/brill_data.h index e928db9..621998d 100644 --- a/brill_data.h +++ b/brill_data.h @@ -1,5 +1,5 @@ /* - * Copyright 2014 Anton Khirnov + * Copyright 2014-2015 Anton Khirnov * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -51,9 +51,26 @@ typedef struct BDContext { */ void *priv; - /******************************* - * options, set by the caller * - *******************************/ + /******************************** + * options, set by the caller * + ********************************/ + + /** + * A callback that will be used to print diagnostic messages. + * + * Defaults to fprintf(stderr, ...) + */ + void (*log_callback)(const struct BDContext *bd, int level, + const char *fmt, va_list); + + /** + * Arbitrary user data, e.g. to be used by the log callback. + */ + void *opaque; + + /******************************** + * initial data parameters * + ********************************/ /** * The choice of the q function in the exponent. @@ -72,54 +89,19 @@ typedef struct BDContext { */ unsigned int eppley_n; - /* the solver parameters */ - - /** - * The number of basis functions in the ρ direction. - * Defaults to 80. - */ - unsigned int nb_coeffs_rho; - /** - * The number of basis functions in the z direction. 0 means the same as - * nb_coeffs_rho. Defaults to 0. - * Using values other than 0 or nb_coeffs_rho is unsupported for now. - */ - unsigned int nb_coeffs_z; - - /** - * The difference between the number of collocation points and the number - * of basis functions in the rho direction. I.e. the number of collocation - * points used will be nb_coeffs_rho + overdet_rho. - * Defaults to 0; - */ - int overdet_rho; - /** - * Same as overdet_rho, but for the z direction. - */ - int overdet_z; - - /** - * The scaling factor used in the basis functions in the ρ direction. - * Defaults to 3. - */ - double basis_scale_factor_rho; - /** - * Same as basis_scale_factor_rho, but for the z direction - */ - double basis_scale_factor_z; + /******************************** + * solver options * + ********************************/ /** - * A callback that will be used to print diagnostic messages. - * - * Defaults to fprintf(stderr, ...) + * The number of basis functions in each direction. */ - void (*log_callback)(const struct BDContext *bd, int level, - const char *fmt, va_list); + unsigned int nb_coeffs[2]; /** - * Arbitrary user data, e.g. to be used by the log callback. + * The scaling factor used in the basis functions. */ - void *opaque; + double basis_scale_factor[2]; /********** * output * -- cgit v1.2.3