Computes the evolution
by integrating its ODEs, from given initial values.
It is:
X' = k1 A Y
−k2 X Y
+ k3 A X
−2k4 X²;
Y' = −k1 A Y
−k2 X Y
+ f k5 A Z;
Z' = k3 A X
−k5 A Z..
Integration is by Python 'scipy' module solver solve_ivp.
Warning Simpler methods (such as RK) are
exceedingly slow.
Files involved:#
P-DAmbrosio.php (this one),
DAmbrosio.php,
dAmbrosio.py.
Draws plots of the integrated functions vs. time.
Python file (download): dAmbrosio.py
Computation structure — A PHP file
(this page: 'P-DAmbrosio.php') calls (via
'action=...') an intermediate PHP file ('DAmbrosio.php'), which
(through $_POST) sends the problem data as command line arguments to
a Python script. This last does the computing, and makes
'system' call(s) to 'gnuplot', for the final (temporary) webpage.
Keywords: PHP, command line arguments,
Python script, gnuplot. |