DOC: Fix Vegas documentation formatting - gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
diff options
context:
space:
mode:
authorFrancesco Abbate <francesco.bbt@gmail.com>2012年11月15日 22:36:03 +0100
committerFrancesco Abbate <francesco.bbt@gmail.com>2012年11月15日 22:37:10 +0100
commitbc80382eff34735e1d4a4fec89ab2919baf27c72 (patch)
treef9ea00d8c79a56029d4e75335cbdf4ea1754effd
parent9635051009f2a02363237ff9cc9d27b69bacb6d6 (diff)
downloadgsl-shell-bc80382eff34735e1d4a4fec89ab2919baf27c72.tar.gz
DOC: Fix Vegas documentation formatting
Diffstat
-rw-r--r--doc/user-manual/vegas.rst 18
1 files changed, 10 insertions, 8 deletions
diff --git a/doc/user-manual/vegas.rst b/doc/user-manual/vegas.rst
index f9f3d64f..fd3da750 100644
--- a/doc/user-manual/vegas.rst
+++ b/doc/user-manual/vegas.rst
@@ -52,6 +52,7 @@ Functions
.. module:: num
.. function:: vegas_prepare(spec)
+
Prepare a VEGAS Monte Carlo integrator, ``vegas_integ``. ``spec`` is a table which can contain the following fields:
*N* (required)
@@ -71,18 +72,19 @@ Functions
.. function:: vegas_integ(f, a, b[, calls, options])
- Use the VEGAS Monte Carlo algorithm to integrate the function ``f`` over the ``N``-dimensional hypercubic region defined by the lower and upper limits in the vectors ``a`` and ``b`` (assuming 1-based indexing). The integration uses a fixed number of function calls ``calls``, as opposed to a target precision. The optional ``options`` table can contain the fields
- *r*
- The VEGAS integrator obtains random sampling points using the :mod:`rng` random number generator ``r``. By default, the built-in math.random() of LuaJIT2 is used.
+ Use the VEGAS Monte Carlo algorithm to integrate the function ``f`` over the ``N``-dimensional hypercubic region defined by the lower and upper limits in the vectors ``a`` and ``b`` (assuming 1-based indexing). The integration uses a fixed number of function calls ``calls``, as opposed to a target precision. The optional ``options`` table can contain the fields
+
+ *r*
+ The VEGAS integrator obtains random sampling points using the :mod:`rng` random number generator ``r``. By default, the built-in math.random() of LuaJIT2 is used.
- *chidev* (default: 0.5)
- ``chidev`` is the tolerated deviation from 1 of the chi-squared per degree of freedom for the weighted average. This quantity must be consistent with 1 for the weighted average to be reliable.
+ *chidev* (default: 0.5)
+ ``chidev`` is the tolerated deviation from 1 of the chi-squared per degree of freedom for the weighted average. This quantity must be consistent with 1 for the weighted average to be reliable.
- *warmup* (default: 1e4)
- Number of function calls that is used to "warm up" the grid; i.e. to do a first estimate of the ideal probability distribution.
+ *warmup* (default: 1e4)
+ Number of function calls that is used to "warm up" the grid; i.e. to do a first estimate of the ideal probability distribution.
- It returns the result of the integration, the error estimate and the number of runs needed to reach the desired chi-squared. The fourth return value is a continuation function that takes a number of calls as an argument. This function can be invoked to recalculate the integral with a higher number of calls, to increase precision.
+ It returns the result of the integration, the error estimate and the number of runs needed to reach the desired chi-squared. The fourth return value is a continuation function that takes a number of calls as an argument. This function can be invoked to recalculate the integral with a higher number of calls, to increase precision.
The continuation function returns the new result, error and number of runs. Note that this function discards the previous results, but retains the optimized grid. Typically the continuation function is called with a multiple of the original number of calls, to reduce the error.
Usage example
generated by cgit v1.2.3 (git 2.39.1) at 2025年09月21日 04:39:46 +0000

AltStyle によって変換されたページ (->オリジナル) /