Skip to content

Commit

Permalink
docs: fix typos (#92)
Browse files Browse the repository at this point in the history
* Enable sicnm and Hessian-vector product (#91)

* To deploy docs only in the default repo

* To deploy docs only in the default repo

* feat: add inline hvp

* feat: fix hvp initializer

* test: add the hvp test.

* feat: add the module printer of hvp

* test: add hvp module generator tests

* fix: to sort jac blocks in lecico order

* fix: simplify the `dae.M` property

Deprecate expr in variable slice

* feat: add the sicnm solver

* fix: resolve typos in sicnm

* fix: resolve typos in scinm

* fix: resolve sicnm typos

* ENH: try spsolve_triangular() in scipy 1.14.0

* feat: add octave code printers

'Mat_Mul', 'Diag' and `Sign`

* feat: add heaviside func

* feat: add event detection in scinm

* feat: add `ln`

* EHN: improve stats of sicnm and nr

* EHN: improve `lm.stats`

* EHN: improve `cnr.stats`

* feat: add __repr__ of `sol` class

* Update doc-deploy.yml

* To deploy docs only in the default repo

* Update doc-deploy.yml

* Update doc-deploy.yml

* update workflow trigger

* Update doc-deploy.yml

* fix: prepare Solverz for numpy 2.0

* fix: resolve issues arose from scipy compabaility

* remove matplotlib requirement

* fix: deprecate explicit call of matplotlib

* Revert "remove matplotlib requirement"

This reverts commit 00bdfd7.

* fix: update fdaesolver

* fix: resolve #79

* doc: add docstring of `sicnm()`

Resolves #86

* docs: add `HVP` in gettingstarted.md

Resolve #77.

* docs: fix typos

---------

Co-authored-by: Ruizhi Yu <[email protected]>
  • Loading branch information
rzyu45 and rzyu54 authored Aug 7, 2024
1 parent a453828 commit 666c7ac
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 7 deletions.
8 changes: 5 additions & 3 deletions Solverz/solvers/nlaesolver/sicnm.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,8 @@ def sicnm(ae: nAE,
\begin{aligned}
\dot{y}&=z \\
0&=J(y)z+g(y)
\end{aligned},
\end{aligned}
with $y_0$ being the initial value guess and $z_0=-J(y_0)^{-1}g(y_0)$, where $z$ is an intermediate variable introduced. Then the DAEs are solved by Rodas. SICNM is found to be more robust than the Newton's method, for which the theoretical proof can be found in my paper [1]_. In addition, the non-iterative nature of Rodas guarantees the efficiency.
Expand All @@ -41,10 +42,11 @@ def sicnm(ae: nAE,
Parameters
==========
eqn : nAE
ae : nAE
Numerical AE object.
y : np.ndarray
y0 : np.ndarray
The initial values of variables
opt : Opt
Expand Down
9 changes: 6 additions & 3 deletions docs/src/gettingstart.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ The basic steps of a simple modeling and solution process are:
3. Apply solver
4. Interrogate solver results

These steps and the philosophy behind Soverz are explained as follows.
These steps and the philosophy behind Solverz are explained as follows.
## Symbolic Modelling
The modelling starts with declaring an empty Model with
```python
Expand Down Expand Up @@ -139,7 +139,7 @@ Moreover, by overloading operators, `y0` can be used for addition, subtraction,
## From Symbolic to Numerical
### Numerical Equations
To directly use the symbolic equations for computation is too slow. Alternatively, you should use the numerical equations
derived by the Solverz, which are optimized for efficient simulation.
derived by Solverz, which are optimized for efficient simulation.
Specifically, Solverz prints all the symbolic expressions to well-organized python functions based on mature
libraries such as numpy, scipy and numba.

Expand Down Expand Up @@ -272,12 +272,15 @@ Currently, dynamic compilation is not supported in `made_numerical`.
Solverz provides basic solvers for the solutions of AE, FDAE and DAE.
We are working hard on implementing more mature solvers. Please feel free to contact us if you have any good idea~

The current solvers are summarized below.
Below is an overview of the built-in solvers.

### AE solvers

1. `nr_method()` the Newton-Raphson method
2. `continuous_nr()` the continuous Newton method, which is more robust compared with the Newton-Raphson
3. `lm()` the Levenberg-Marquardt method provided by `scipy.optimize.root`. Only dense Jacobian is allowed, which may be time-consuming.
4. `sicnm()` the semi-implicit version of continuous Newton method. It possesses both the implicit stability and explicit computation overhead, which shows both robustness and efficiency. Please make Hessian-vector product if you want to use it.

### FDAE solver
`fdae_solver()`
### DAE solvers
Expand Down
2 changes: 1 addition & 1 deletion docs/src/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ If you are new to Solverz, start with the :ref:`introductory example <intro>`.
If you find Solverz intriguing, just :ref:`get started <gettingstarted>`.

Additional Solverz paradigms covering multiple areas can be found in
`Solverz' Cookbook <https://cookbook.solverz.org>`_:
`Solverz' Cookbook <https://cook.solverz.org>`_:

==================================================================

Expand Down
4 changes: 4 additions & 0 deletions docs/src/reference/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ Functions

.. autoclass:: Solverz.sym_algebra.functions.Saturation

.. autoclass:: Solverz.sym_algebra.functions.heaviside

.. autoclass:: Solverz.sym_algebra.functions.ln

Solvers
-------

Expand Down

0 comments on commit 666c7ac

Please sign in to comment.