From ab5d463760cd76ad1f24a149cf7f181cc54b82dc Mon Sep 17 00:00:00 2001 From: Anton Khirnov Date: Thu, 11 Sep 2014 13:08:16 +0200 Subject: Cosmetics. --- param.ccl | 8 ++++---- src/brill.c | 13 ++++++++++--- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/param.ccl b/param.ccl index 9724012..9b214da 100644 --- a/param.ccl +++ b/param.ccl @@ -1,4 +1,4 @@ -# Parameter definitions for thorn Trumpet +# Parameter definitions for thorn BrillData SHARES: ADMBase @@ -8,10 +8,10 @@ EXTENDS KEYWORD initial_data } RESTRICTED: -CCTK_REAL amplitude "amplitude" +CCTK_REAL amplitude "Wave amplitude A." { - : :: "" -} 1 + 0: :: "" +} 1.0 CCTK_INT basis_order_r "Number of the basis functions in the radial direction" { diff --git a/src/brill.c b/src/brill.c index b48980d..cc45587 100644 --- a/src/brill.c +++ b/src/brill.c @@ -45,7 +45,7 @@ typedef struct BasisSet { /* * The basis of even (n = 2 * idx) SB functions (Boyd 2000, Ch 17.9) * SB(x, n) = sin((n + 1) arccot(|x| / L)) - * They are symmetric wrt beginning and decay as 1/x in infinity. + * They are symmetric wrt origin and decay as 1/x in infinity. */ static CCTK_REAL scale_factor; @@ -232,10 +232,16 @@ static int solve_svd(gsl_matrix *mat, gsl_vector **px, gsl_vector **prhs) return 0; } -/* solve the equation +/* + * Solve the equation * Δψ + ¼ ψ (∂²q/∂r² + ∂²q/∂z²) = 0 * for the coefficients of spectral approximation of ψ: - * ψ(r, z) = ΣaᵢⱼTᵢ(r)Tⱼ(z) + * ψ(r, z) = 1 + ΣaᵢⱼTᵢ(r)Tⱼ(z) + * where i = { 0, ... , bd->nb_coeffs_x }; + * j = { 0, ... , bd->nb_coeffs_z }; + * q(r, z) and Tᵢ(x) are defined by bd->q_func, bd->laplace_q_func and + * bd->basis. + * * The cofficients are exported in bd->psi_coeffs */ static int brill_solve(BrillDataContext *bd) @@ -283,6 +289,7 @@ static int brill_solve(BrillDataContext *bd) else ret = solve_linear(mat, &coeffs, &rhs); + /* export the result to the caller */ bd->psi_coeffs = coeffs; #if ACC_TEST -- cgit v1.2.3