Skip to content

Commit

Permalink
update LSES docstrings accounting for comments
Browse files Browse the repository at this point in the history
  • Loading branch information
sofianehaddad committed Nov 21, 2024
1 parent 5ba8fd9 commit f62d74e
Showing 1 changed file with 17 additions and 1 deletion.
18 changes: 17 additions & 1 deletion python/src/LeastSquaresEquationsSolver_doc.i.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
%feature("docstring") OT::LeastSquaresEquationsSolver
"Solve systems of non-linear equations using a least squares method.

.. warning::
This class is experimental and likely to be modified in future releases.
To use it, import the ``openturns.experimental`` submodule.

Parameters
----------
Expand Down Expand Up @@ -31,7 +34,20 @@ openturns.Solver, openturns.OptimizationAlgorithm
Notes
-----
LeastSquaresEquationsSolver might fail and not obtain a result lower than the
specified threshold, in this case an error is thrown."
specified threshold, in this case an error is thrown.

Examples
--------

>>> import openturns as ot
>>> from openturns.experimental import LeastSquaresEquationsSolver
>>> # Analytical construction
>>> inputs = ["x", "y"]
>>> formulas = ["y*x-sin(2*x)", "1 + cos(y) + x"]
>>> analytical = ot.SymbolicFunction(input, formulas)
>>> algo = LeastSquaresEquationsSolver()
>>> starting_point = [2.0, 1.0]
>>> solution = algo.solve(analytical, starting_point)"

// ---------------------------------------------------------------------

Expand Down

0 comments on commit f62d74e

Please sign in to comment.