gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
diff options
context:
space:
mode:
Diffstat
-rw-r--r--help.lua 2
-rw-r--r--help/vegas.lua 27
2 files changed, 28 insertions, 1 deletions
diff --git a/help.lua b/help.lua
index edd3aa7f..5a22080b 100644
--- a/help.lua
+++ b/help.lua
@@ -1,5 +1,5 @@
-local help_files = {'graphics', 'matrix', 'iter', 'integ', 'ode', 'nlfit'}
+local help_files = {'graphics', 'matrix', 'iter', 'integ', 'ode', 'nlfit', 'vegas'}
local function help_init( ... )
local REG = debug.getregistry()
diff --git a/help/vegas.lua b/help/vegas.lua
new file mode 100644
index 00000000..1e83289e
--- /dev/null
+++ b/help/vegas.lua
@@ -0,0 +1,27 @@
+local M = {
+ [num.monte_vegas] = [[
+num.monte_vegas(f, a, b[, calls, r, chi_dev])
+
+ Use the VEGAS Monte Carlo algorithm to integrate the function f
+ over the dim-dimensional hypercubic region defined by the lower and
+ upper limits in the vectors a and b. The integration uses a fixed
+ number of function calls "calls", and obtains random sampling points
+ using the random number generator r. The results of the
+ integration are based on a weighted average of five independent
+ samples. chi_dev 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. The function 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 improve the error.
+]],
+}
+
+return M
generated by cgit v1.2.3 (git 2.39.1) at 2025年09月15日 13:07:03 +0000

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