diff options
author | Anton Khirnov <anton@khirnov.net> | 2014-09-11 13:08:16 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2014-09-11 13:08:16 +0200 |
commit | ab5d463760cd76ad1f24a149cf7f181cc54b82dc (patch) | |
tree | 88f709d4dc181c37d562a7cdd34ac535f67e42c0 | |
parent | 9a54962f3ff3d17daf2d29d311f063d88887b803 (diff) |
Cosmetics.
-rw-r--r-- | param.ccl | 8 | ||||
-rw-r--r-- | src/brill.c | 13 |
2 files changed, 14 insertions, 7 deletions
@@ -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 |