Fix typos etc. in help. - gsl-shell.git - gsl-shell

index : gsl-shell.git
gsl-shell
summary refs log tree commit diff
diff options
context:
space:
mode:
authorLesley De Cruz <lesley.decruz+git@gmail.com>2012年09月06日 00:27:13 +0200
committerFrancesco Abbate <francesco.bbt@gmail.com>2012年09月06日 10:21:22 +0200
commit8df1fcf7d84ae800c27262f72d2338df6ef73e81 (patch)
treed4f0726e26068f22c5b65569429ed5876b81861a
parented05a344ef0340387a49c9ef84d66e092d8b657f (diff)
downloadgsl-shell-8df1fcf7d84ae800c27262f72d2338df6ef73e81.tar.gz
Fix typos etc. in help.
Diffstat
-rw-r--r--help/graphics.lua 141
-rw-r--r--help/integ.lua 2
-rw-r--r--help/iter.lua 8
-rw-r--r--help/matrix.lua 40
-rw-r--r--help/nlfit.lua 6
-rw-r--r--help/ode.lua 14
-rw-r--r--help/rng.lua 9
-rw-r--r--help/vegas.lua 39
8 files changed, 132 insertions, 127 deletions
diff --git a/help/graphics.lua b/help/graphics.lua
index 7e80641d..94e34629 100644
--- a/help/graphics.lua
+++ b/help/graphics.lua
@@ -12,9 +12,9 @@ local M = {
[graph.fxplot] = [[
graph.fxplot(f, xi, xs[, color, n])
- Produces a plot of the function f(x) for x going from xi to
- xs. The last optional parameter n is the number of sampling
- point to use and, if not given, a default value will be used. The
+ Produces a plot of the function f(x) for x going from xi to xs.
+ The last optional parameter n is the number of sampling points to
+ use and, if not given, a default value will be used. The
function returns the plot itself.
]],
[graph.fiplot] = [[
@@ -22,58 +22,58 @@ graph.fiplot(f, a, b[, color])
graph.fiplot(f, b)
Produces a plot of the function f(i) where 'i' is an integer
- variable going from a to b. In the second abbreviated form
- a take the default value of one. The function returns the plot
+ variable going from a to b. In the second abbreviated form a
+ takes the default value of one. The function returns the plot
itself.
]],
[graph.fibars] = [[
graph.fibars(f, a, b[, color, fill_ratio])
- Produces a bar plot of the function f(i) where i is an
- integer ranging from a to b. The parameter fill_ratio
- determine the width of the bars and is by default equal to 1. When
- a smaller value is provided for fill_ratio the bars will be
- drawn with a smaller width along the x axis.
+ Produces a bar plot of the function f(i) where i is an integer
+ ranging from a to b. The parameter fill_ratio determines the
+ width of the bars and is equal to 1 by default. When a smaller
+ value is provided for fill_ratio, the bars will be drawn with a
+ smaller width along the x axis.
]],
[graph.fxline] = [[
graph.fxline(f, xi, xs[, n])
- This function returns an graphical object of type Path
- given by the points (x, f(x)) for x going from xi to xs
- with n sampling point.
+ This function returns a graphical object of type Path given by
+ the points (x, f(x)) for x going from xi to xs with n sampling
+ points.
]],
[graph.filine] = [[
graph.filine(f, a, b)
graph.filine(f, b)
- This function returns an graphical object of type "Path"
- given by the points (i, f(i)) where 'i' is an integer variable
- going from a to b. It a is omitted values will be in
- the interval 1 .. b.
+ This function returns a graphical object of type Path given by
+ the points (i, f(i)) where 'i' is an integer variable going from
+ a to b. If a is omitted, values will be in the interval 1 .. b.
]],
[graph.xyline] = [[
graph.xyline(x, y)
- This function takes two column matrix of dimensions N as arguments
- and returns a graphical object of type "Path" given by the
- points (x[i], y[i]) where i goes from 1 to N.
+ This function takes two column matrices of dimension N as
+ arguments and returns a graphical object of type Path given by
+ the points (x[i], y[i]) where i goes from 1 to N.
]],
[graph.ipath] = [[
graph.ipath(f)
- This function takes an iterator function f and returns a "Path" given
- by the points (x, y) returned by the iterator f. The variant "ipathp"
- is able to treat the case when the function f fails and it does
- continue by calling the iterator again.
+ This function takes an iterator function f and returns a Path
+ given by the points (x, y) returned by the iterator f. The
+ variant "ipathp" can deal with the case where the function f
+ fails, in which case it continues by calling the iterator
+ function f again.
]],
[graph.ibars] = [[
graph.ibars(f)
This function takes an iterator function f and returns a Path
- object that draws many adjacent rectangular boxes corresponding to
- the points (x, y) returned by the iterator f.
+ object that draws adjacent rectangular boxes corresponding to the
+ points (x, y) returned by the iterator f.
]],
[graph.rgb] = [[
@@ -81,9 +81,10 @@ graph.rgb(r, g, b)
graph.rgba(r, g, b, a)
Returns a color specified by the given r, g, b values. These
- latters should be numbers in the interval [0, 1]. The second
- variant of the function let you specify an alpha value. This latter
- can range from 0 (completely transparent) to 1 (completely opaque).
+ values should be in the interval [0, 1]. The second variant of
+ the function lets you specify an alpha value. This alpha value
+ can range from 0 (completely transparent) to 1 (completely
+ opaque).
]],
[graph.rainbow] = [[
@@ -99,7 +100,7 @@ webcolor(n)
graph.window([layout])
Create a new empty window with the layout given by the optional
- layout string. If the argument is omitted the window will have a
+ layout string. If the argument is omitted, the window will have a
single drawing area that will cover the whole window.
]],
@@ -113,10 +114,11 @@ graph.window([layout])
[Window.attach] = [[
<window>:attach(plot, slot)
- Attach the given plot to the window's slot specified by the string
- slot. The string should be a list of comma separated integer number
- in the form 'n1,n2,...,nk'. For each of the mentioned integer the
- corresponding window partition will be chosen recursively.
+ Attach the given plot to the window's slot specified by the
+ string slot. This string should be a list of comma-separated
+ integer numbers in the form 'n1,n2,...,nk'. For each of the
+ specified integers, the corresponding window partition will be
+ chosen recursively.
]],
[graph.plot] = [[
@@ -124,21 +126,22 @@ graph.plot([title])
Create a new empty plot with an optional title. The plot is not
attached to any window and is therefore not visible. To show the
- plot on the screen use either the "show" plot's method or
- use the :meth:`~Window.attach` window's method to attach the plot to a
+ plot on the screen, one should either use the plot's "show"
+ method or the window's "attach" method to attach the plot to a
specific window.
]],
[graph.canvas] = [[
graph.canvas([title])
- Like the function above it does create a new empty plot with fixed
- limits. This latter kind of plot differs in that it will not update
- automatically its limits to fit the graphical objects. The method
- "limits" should be used instead to set the logical limits of
- plotting area. The other difference with the "graph.plot"
- function is that the property sync will be initialized to false.
- This kind of plot is generally better suited for animations.
+ Like the function graph.plot, this function creates a new empty
+ plot with fixed limits. It differs from "graph.plot" in that it
+ will not update its limits automatically to fit the graphical
+ objects. The method "limits" should be used instead to set the
+ logical limits of plotting area. The other difference with the
+ "graph.plot" function is that the property sync will be
+ initialized to false. This kind of plot is generally better
+ suited for animations.
]],
[Plot'add'] = [[
@@ -152,10 +155,10 @@ graph.canvas([title])
[Plot'addline'] = [[
<plot>:addline(obj, color[, post_trans, pre_trans])
- Add the graphical object obj to the plot to be rendered by a stroke
- transformation. In this way the object is shown as a line instead of
- as a filled polygon. It is equivalent to add a 'stroke' operations of
- one pixel size.
+ Add the graphical object obj to the plot to be rendered by a
+ stroke transformation. This way, the object is shown as a line
+ instead of as a filled polygon. It is equivalent to adding a
+ 'stroke' operation of one pixel size.
]],
[Plot'limits'] = [[
@@ -163,8 +166,8 @@ graph.canvas([title])
Set the logical limits of the area displayed by the plot to the
rectangle with lower-left corner (x1, y1) and upper-right corner
- (x2, y2). This method is used for plots with fixed limits obtained
- with the function "canvas".
+ (x2, y2). This method is used for plots with fixed limits,
+ obtained with the function "canvas".
]],
[Plot'show'] = [[
@@ -176,22 +179,22 @@ graph.canvas([title])
[Plot'clear'] = [[
<plot>:clear()
- Remove all the graphical elements into the current graphical layer.
+ Remove all the graphical elements from the current graphical layer.
]],
[Plot'flush'] = [[
<plot>:flush()
- All the pending operations on a plot are processed and all the
- windows attached to the plot are updated. This method is only
- useful when the attribute sync is set to false.
+ All pending operations on a plot are processed and all windows
+ attached to the plot are updated. This method is only useful when
+ the attribute "sync" is set to false.
]],
[Plot'pushlayer'] = [[
<plot>:pushlayer()
- Add a new graphical layer and into the plot so that it becomes the
- current one and all the elements added with methods "add" or
+ Add a new graphical layer to the plot, so that it becomes the
+ current one. All elements added using the methods "add" or
"addline" are associated with this new layer.
]],
@@ -206,8 +209,8 @@ graph.canvas([title])
<plot>:save(filename[, w, h])
Save the plot in a file in a bitmap image format. The first
- argument is the file name without extension while the other
- optional arguments are the width and the height in pixel of the
+ argument is the file name without extension, while the other
+ optional arguments are the width and the height in pixels of the
image. The format used is BMP on windows and PPM on Linux.
]],
@@ -222,11 +225,11 @@ graph.canvas([title])
[Plot'set_legend'] = [[
<plot>:set_legend(p[, placement])
- Add the plot p as a legend is the side area of the main plot.
- The argument placement is used to give the placement of the mini
- plot and should be on of the letters 'l', 'r', 'b', 't'. They
- stands for "left", "right", "bottom" and "top" respectively. By
- default the placement of the legend is on the right side.
+ Add the plot p as a legend in the side area of the main plot.
+ The argument placement indicates the placement of the mini plot
+ and should be one of the letters 'l', 'r', 'b', 't'. These stand
+ for "left", "right", "bottom" and "top" respectively. By default,
+ the placement of the legend is on the right side.
]],
[Plot'get_legend'] = [[
@@ -240,20 +243,20 @@ graph.canvas([title])
<plot>:legend(text, color, symbol[, trans])
Add to the plot a new legend item with the given text. The symbol
- used is determinated by the string symbol. Possible values are
+ used is determined by the string symbol. Possible values are
'line', 'square' or anything accepted by "graph.marker". The
optional trans parameter should be a graphical transform. If
- omitted the appropriate default is chosen based on the symbol type.
+ omitted, the appropriate default is chosen based on the symbol type.
]],
[Plot'set_categories'] = [[
<plot>:set_categories(axis, categories)
- Configure the given axis (a letter, 'x' or 'y') to use a custom set
- of labels specified by categories. This latter should be a list of
- that gives in a sequence, the values where the label should be
- placed and the label text itself. The coordinate refers to the plot
- system of coordinates.
+ Configure the given axis (a letter, 'x' or 'y') to use a custom
+ set of labels specified by categories. The latter should be a
+ table containing a sequence of the values where the label should
+ be placed and the label text itself. The coordinate refers to the
+ plot system of coordinates.
]],
--[[
diff --git a/help/integ.lua b/help/integ.lua
index eff6ec2e..80fdcd37 100644
--- a/help/integ.lua
+++ b/help/integ.lua
@@ -4,7 +4,7 @@ num.integ(f, a, b[, epsabs, epsrel])
Compute the definite integral of the function "f" in the interval
specified by "a" and "b" within the requested precision given by
- "epsabs" and "epsrel". This function always use the adaptive QAG
+ "epsabs" and "epsrel". This function always uses the adaptive QAG
algorithm internally.
]],
diff --git a/help/iter.lua b/help/iter.lua
index 33b4d0d0..c5c47ca8 100644
--- a/help/iter.lua
+++ b/help/iter.lua
@@ -4,10 +4,10 @@ local M = {
iter.sequence(f, a, b)
iter.sequence(f, b)
- Return an "iterator" that gives the value (or the values) returned
- by the evaluation of "f(i)" where "i" is an integer that goes from
- "a" to "b". In the second form, the generated values start from
- one.
+ Return an iterator that gives the value (or the values) returned
+ by the evaluation of "f(i)" where "i" is an integer that goes
+ from "a" to "b". In the second form, the generated values start
+ from one.
]],
[iter.sample] = [[
diff --git a/help/matrix.lua b/help/matrix.lua
index 49ee0b24..ca1361f2 100644
--- a/help/matrix.lua
+++ b/help/matrix.lua
@@ -3,11 +3,11 @@ local M = {
matrix.new(r, c[, finit])
Returns a new matrix of "r" rows and "c" columns. If "finit" is not
- given the matrix is initialized to 0. If "finit" is provided the
- function "finit(i, j)" is called for all the elements with the i
+ given, the matrix is initialized to 0. If "finit" is provided, the
+ function "finit(i, j)" is called for all elements, with the i
arguments equal to the row index and j equal to the column index.
- Then the value returned by the function is assigned to the matrix
- elements.
+ The value returned by the function is assigned to the respective
+ matrix elements.
]],
[matrix.cnew] = [[
@@ -23,13 +23,13 @@ matrix.def(t)
Convert the table t into a matrix. The table should be in the form
"{{row1_v1, row1_v2, ...}, {row2_v1, row2_v2, ...}, ...}" where
each term is a number. You should also ensure that all the lines
- contains the same number of elements.
+ contain the same number of elements.
]],
[matrix.vec] = [[
matrix.vec(t)
- Convert the table t into a column matrix. In GSL Shell column
+ Convert the table t into a column matrix. In GSL Shell, column
matrices are considered vectors. The table should be in the form
"{v1, v2, v3, ...}".
]],
@@ -37,7 +37,7 @@ matrix.vec(t)
[matrix.dim] = [[
matrix.dim(m)
- Returns two values, in the order, the number of rows and of columns of
+ Returns two values: the number of rows and the number of columns of
the matrix.
]],
@@ -56,13 +56,13 @@ matrix.transpose(m)
[matrix.hc] = [[
matrix.hc(m)
- Return the hermitian conjugate of the matrix.
+ Returns the hermitian conjugate of the matrix.
]],
[matrix.diag] = [[
matrix.diag(v)
- Given a column vector "v" of length "n" returns a diagonal
+ Given a column vector "v" of length "n", returns a diagonal
matrix whose diagonal elements are equal to the elements of "v".
]],
@@ -75,22 +75,22 @@ matrix.unit(n)
[matrix.set] = [[
matrix.set(a, b)
- Set the matrix "a" to be equal to the matrix "b". It raise an error
- if the dimensions of the matrices are different. Please note that
- it is different than the statement "a = b" because this latter
- simple make the variable "a" refer to the same matrix of "b". With
- the "set" function you set each element of an existing matrix "a"
- to the same value of the corresponding element of "b".
+ Set the matrix "a" to be equal to the matrix "b". An error is
+ raised if the dimensions of the matrices are different. Please note
+ that it is different from the statement "a = b" because the latter
+ simply makes the variable "a" refer to the same matrix as "b". With
+ the "set" function, you set each element of an existing matrix "a"
+ to the same value as the corresponding element of "b".
]],
[matrix.fset] = [[
matrix.fset(m, f)
- Set the elements of the matrix "m" to the value given by
- "f(i, j)" where "i" and "j" are, respectively, the row and column
- indexes of the matrix. Note that this function have the same
- semantic of the :func:`new` function with the difference that :func:`fset`
- operate on a matrix that already exists instead of creating a new one.
+ Set the elements of the matrix "m" to the value given by "f(i, j)"
+ where "i" and "j" are, respectively, the row and column indexes of
+ the matrix. Note that this function has the same semantics as the
+ "new" function, with the difference that "fset" operates on a
+ matrix that already exists instead of creating a new one.
]],
}
diff --git a/help/nlfit.lua b/help/nlfit.lua
index 5fe6153e..0d98fc05 100644
--- a/help/nlfit.lua
+++ b/help/nlfit.lua
@@ -33,15 +33,15 @@ num.nlinfit {n= <int>, p= <int>}
[NLFIT.iterate] = [[
<nlfit>:iterate()
- Advance the solver of a single step. It does return "continue" if
+ Advance the solver with a single step. It returns "continue" if
it did not reach the optimal point and "success" otherwise.
]],
[NLFIT.test] = [[
<nlfit>:test(eps_abs, eps_err)
- Check if the the search converged for the given absolute error
- eps_abs and relative error eps_rel.
+ Check if the search converged for the given absolute error eps_abs
+ and relative error eps_rel.
]],
}
diff --git a/help/ode.lua b/help/ode.lua
index adc12eac..25b6e2fc 100644
--- a/help/ode.lua
+++ b/help/ode.lua
@@ -12,8 +12,8 @@ num.ode {N= <int>, eps_abs= <num>, eps_rel= <num>}
Return an ODE object to numerically integrate an ordinary
differential equation. N is the dimension of the system and
- eps_abs, eps_rel are respectively the requested absolute and
- relative precision.
+ eps_abs, eps_rel are the requested absolute and relative
+ precision, respectively.
]]
}
@@ -24,7 +24,7 @@ if ODE then
Initialize the state of the solver to the time t0 with initial
values y0_1, y0_2, ..., y0_N. The second argument h0 is the initial
step size that the integrator will try. The function f is the
- function that defines the ODE system. It will be called like "f(t,
+ function that defines the ODE system. It will be called as "f(t,
y_1, y_2, ..., y_N)" where t is the time and y_1, y_2, ... are the
values of the N independent values conventionally denoted here by
y. The function f should return N values that correspond to values
@@ -40,16 +40,16 @@ if ODE then
internally by the solver and can be retrieved as properties with
the name "t" and "y" where the latter is a column matrix of size N.
The new values of t will be less than or equal to the value given
- t1. If the value s.t is less then t1 then the function can
- be called again to advance further the ODE system.
+ by t1. If the value <ode>.t is less than t1, then the function can be
+ called again to further advance the ODE system.
]]
M[ODE.evolve] = [[
evolve(t1, t_step)
- Returns a Lua iterator that advance the ODE system at each
+ Returns a Lua iterator that advances the ODE system at each
iteration of a step t_step until the value t1 is reached. The
- iterators returns the value t itself and all the system variables
+ iterator returns the value t itself and all the system variables
y0, y1, ... up to y_N.
]]
end
diff --git a/help/rng.lua b/help/rng.lua
index 1f7df002..9d4024ba 100644
--- a/help/rng.lua
+++ b/help/rng.lua
@@ -5,14 +5,13 @@ local M = {
rng.new([name])
This function returns a "random number generator" object of the
- specified type "name". If you do not specify a particular generator
- the default "taus2" generator will be used.
+ specified type "name". If you do not specify a particular
+ generator, the default "taus2" generator will be used.
]],
[rng.list] = [[
rng.list()
- Return an array with all the list of all the supported generator
- type.
+ Return an array with a list of all the supported generator types.
]],
[RNG.get] = [[
<rng>:get()
@@ -32,7 +31,7 @@ rng.list()
[RNG.set] = [[
<rng>:set(seed)
- This method set the seed of the generator to the given integer
+ This method sets the seed of the generator to the given integer
value.
]],
}
diff --git a/help/vegas.lua b/help/vegas.lua
index 1e83289e..01d18173 100644
--- a/help/vegas.lua
+++ b/help/vegas.lua
@@ -3,24 +3,27 @@ local M = {
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.
+ 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.
]],
}
generated by cgit v1.2.3 (git 2.39.1) at 2025年10月03日 00:14:11 +0000

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