From cc8b429475089f930c8449f2d09aad4619240fe7 Mon Sep 17 00:00:00 2001
From: Ian Bell <ian.bell@nist.gov>
Date: Mon, 31 Oct 2022 09:27:11 -0400
Subject: [PATCH] Add some simple profiling to teqp docs

---
 doc/source/models/PCSAFT.ipynb | 19 ++++++++++++++++++-
 1 file changed, 18 insertions(+), 1 deletion(-)

diff --git a/doc/source/models/PCSAFT.ipynb b/doc/source/models/PCSAFT.ipynb
index 57dfb23..d0d99d2 100644
--- a/doc/source/models/PCSAFT.ipynb
+++ b/doc/source/models/PCSAFT.ipynb
@@ -57,6 +57,23 @@
     "model = teqp.PCSAFTEOS(coeffs)"
    ]
   },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "19ec9bfb",
+   "metadata": {},
+   "outputs": [],
+   "source": [
+    "# Here are some rudimentary timing results\n",
+    "T = 300.0\n",
+    "rhovec = np.array([3.0, 4.0, 5.0])\n",
+    "rho = rhovec.sum()\n",
+    "x = rhovec/np.sum(rhovec)\n",
+    "%timeit model.get_fugacity_coefficients(T,rhovec)\n",
+    "%timeit (-1.0)*model.get_Ar20(T, rho, x)\n",
+    "%timeit model.get_partial_molar_volumes(T, rhovec)"
+   ]
+  },
   {
    "cell_type": "markdown",
    "id": "578630c8",
@@ -191,7 +208,7 @@
    "name": "python",
    "nbconvert_exporter": "python",
    "pygments_lexer": "ipython3",
-   "version": "3.10.4"
+   "version": "3.10.6"
   }
  },
  "nbformat": 4,
-- 
GitLab