From ddf6aa8f9067001373e3963fc643f83bdbab0ba9 Mon Sep 17 00:00:00 2001 From: isaacbasil <123981577+isaacbasil@users.noreply.github.com> Date: Mon, 25 Nov 2024 17:08:54 +0100 Subject: [PATCH] Update documentation on Integral operator (#4595) (#4609) * Update documentation on Integral operator to give additional details on different coordinate systems (#4595) * use double backslash to avoid \pi being interpreted as an escape sequence Co-authored-by: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> --------- Co-authored-by: Agriya Khetarpal <74401230+agriyakhetarpal@users.noreply.github.com> --- src/pybamm/expression_tree/unary_operators.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/pybamm/expression_tree/unary_operators.py b/src/pybamm/expression_tree/unary_operators.py index f41897e2de..85c2bc5c54 100644 --- a/src/pybamm/expression_tree/unary_operators.py +++ b/src/pybamm/expression_tree/unary_operators.py @@ -611,10 +611,13 @@ class Integral(SpatialOperator): A node in the expression tree representing an integral operator. .. math:: - I = \\int_{a}^{b}\\!f(u)\\,du, + I = \\int_{u_{min}}^{u_{max}}\\!f(u)\\,dq, - where :math:`a` and :math:`b` are the left-hand and right-hand boundaries of - the domain respectively, and :math:`u\\in\\text{domain}`. + where :math:`u\\in\\text{domain}` is a spatial variable, :math:`u_{min}` and :math:`u_{max}` are the values of + :math:`u` at the left-hand and right-hand boundaries of the domain respectively, and :math:`dq` is given by, \n + :math:`dq=du` for cartesian coordinates, \n + :math:`dq=2\\pi udu` for cylindrical coordinates, \n + :math:`dq=4\\pi u^2 du` for spherical coordinates. Parameters ----------