changeset 33328:87a54302d126 stable

doc: Fix Texinfo problems in cset 0d2a6a831574 * nonlin.txi: Use Texinfo '@@' macro to generate AT symbol. Call Texinfo @result{} macro with mandatory braces. Place @group/@end group macros within @example block. Fix naming of @ref to "Anonymous Functions". * fminsearch.m: Delete extra space between two words.
author Rik <rik@octave.org>
date Thu, 04 Apr 2024 18:16:20 -0700
parents 0d2a6a831574
children 5bc48a35b792 a2a202991cc7
files doc/interpreter/nonlin.txi scripts/optimization/fminsearch.m
diffstat 2 files changed, 11 insertions(+), 11 deletions(-) [+]
line wrap: on
line diff
--- a/doc/interpreter/nonlin.txi	Thu Apr 04 15:13:32 2024 -0400
+++ b/doc/interpreter/nonlin.txi	Thu Apr 04 18:16:20 2024 -0700
@@ -197,32 +197,32 @@
 the function, @code{F}, being minimized. E.g., @w{@code{F = F(x, C)}}.
 Octave's minimizer functions are designed to only pass one optimization
 variable to @code{F}, but parameter passing can be accomplished by defining
-an @ref{Anonymous Function} that contains the necessargy parameter(s).  See
+an @ref{Anonymous Functions} that contains the necessary parameter(s).  See
 the example below:
 
+@example
 @group
-@example
 A = 2; B = 3;
-f = @(x) sin (A*x + B);
+f = @@(x) sin (A*x + B);
 fminbnd (f, 0, 2)
-@result 0.8562
+@result{} 0.8562
+@end group
 @end example
-@end group
 
 Note that anonymous functions retain the value of parameters at the time they
 are defined.  Changing a parameter value after function definition will not
 affect output of the function until it is redefined:
 
+@example
 @group
-@example
 B = 4;
 fminbnd (f, 0, 2)
-@result 0.8562
-f = @(x) sin (A*x + B);
+@result{} 0.8562
+f = @@(x) sin (A*x + B);
 fminbnd (f, 0, 2)
-@result 0.3562
+@result{} 0.3562
+@end group
 @end example
-@end group
 
 The function @code{humps} is a useful function for testing zero and
 extrema finding functions.
--- a/scripts/optimization/fminsearch.m	Thu Apr 04 15:13:32 2024 -0400
+++ b/scripts/optimization/fminsearch.m	Thu Apr 04 18:16:20 2024 -0700
@@ -123,7 +123,7 @@
 ## @item
 ## The legacy, undocumented syntax for passing parameters to @var{fcn} by
 ## appending them to the input argument list after @var{options} is
-## discouraged and will  be completely removed in Octave 10.  The
+## discouraged and will be completely removed in Octave 10.  The
 ## preferred, cross-platform compatible method of passing parameters to
 ## @var{fcn} is through use of @ref{Anonymous Functions}.  For specific
 ## examples of doing so for @code{fminsearch} and other minimization