From ed873252cd5528c505f271d151d43ff63097015d Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:05:17 +0000 Subject: [PATCH 01/26] equations --- Equations.md | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/Equations.md b/Equations.md index 0a31501..78face1 100644 --- a/Equations.md +++ b/Equations.md @@ -1,13 +1,10 @@ **Equations** -$$ dW/dt = W*( \frac{(B^x*aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} + \frac{(u*aM*M^x)}{( - 1 + M^x*hM* aM + B^x*hB* aB)} - d - \omega)$$ +$$ dW/dt = W (\frac{(B^x*aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} + \frac{(u*aM*M^x)}{(1 + M^x*hM* aM + B^x*hB* aB)} - d - \omega)$$ -$$ dB/dt = B*(rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{( - 1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$$ +$$ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$$ -$$ dM/dt = M*(rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{( - 1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu$$ +$$ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ **Parameter Definitions** From 7474603c8a3bb5978522c2e2a4f077b729aeff09 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:29:11 +0000 Subject: [PATCH 02/26] equation rendering --- Equations.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Equations.md b/Equations.md index 78face1..98de7e4 100644 --- a/Equations.md +++ b/Equations.md @@ -1,10 +1,10 @@ **Equations** -$$ dW/dt = W (\frac{(B^x*aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} + \frac{(u*aM*M^x)}{(1 + M^x*hM* aM + B^x*hB* aB)} - d - \omega)$$ +$ dW/dt = W ($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ -$$ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$$ +$ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ -$$ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ +$ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$ **Parameter Definitions** From 5df7e1e779463f4520742b8a1e9904f482a60142 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:29:54 +0000 Subject: [PATCH 03/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 98de7e4..5933960 100644 --- a/Equations.md +++ b/Equations.md @@ -1,6 +1,6 @@ **Equations** -$ dW/dt = W ($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$ dW/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ From e07c984cd085d9d9536499c7f1a9e01adbcb6f17 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:30:28 +0000 Subject: [PATCH 04/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 5933960..ba29bae 100644 --- a/Equations.md +++ b/Equations.md @@ -1,6 +1,6 @@ **Equations** -$ dW/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$ \frac{dW}{dt}$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ From a07153f3eae58f36c5aeed9115580adb0811904d Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:31:07 +0000 Subject: [PATCH 05/26] equation rendering --- Equations.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Equations.md b/Equations.md index ba29bae..83aac63 100644 --- a/Equations.md +++ b/Equations.md @@ -1,10 +1,10 @@ **Equations** -$ \frac{dW}{dt}$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +Wolves: $ \frac{dW}{dt}$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ -$ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ +Carib: $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ -$ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$ +Moose: $ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$ **Parameter Definitions** From 901a087c47cfe0773c83f0e8c50b4f4a771b48bd Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:31:49 +0000 Subject: [PATCH 06/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 83aac63..052ed93 100644 --- a/Equations.md +++ b/Equations.md @@ -1,6 +1,6 @@ **Equations** -Wolves: $ \frac{dW}{dt}$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$dW$ $/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ Carib: $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ From b075cdca1c53e073035c40ef49a18ebbad3bb50d Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:32:47 +0000 Subject: [PATCH 07/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 052ed93..aa4778f 100644 --- a/Equations.md +++ b/Equations.md @@ -1,6 +1,6 @@ **Equations** -$dW$ $/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$dW/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ Carib: $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ From 7bc81db44ce5da25babdedea0031ad4274d69ea3 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:33:14 +0000 Subject: [PATCH 08/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index aa4778f..e30cb3a 100644 --- a/Equations.md +++ b/Equations.md @@ -1,6 +1,6 @@ **Equations** -$dW/dt$ $= W$ $($ $\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ Carib: $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ From 214ab5823e91ecfa0ce2a6e7b341748286a76683 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:33:54 +0000 Subject: [PATCH 09/26] equation rendering --- Equations.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Equations.md b/Equations.md index e30cb3a..8abbd2a 100644 --- a/Equations.md +++ b/Equations.md @@ -1,10 +1,10 @@ **Equations** -$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B}$ $+ \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d -$ $\omega)$ +$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ -Carib: $ dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$ +$$dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$$ -Moose: $ dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$ +$$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ **Parameter Definitions** From c1964ee1ba981e92448ed9bbb5dd695c75ba8e9a Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:34:55 +0000 Subject: [PATCH 10/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 8abbd2a..03b8f2c 100644 --- a/Equations.md +++ b/Equations.md @@ -2,7 +2,7 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ -$$dB/dt = B (rb - \frac{(rb*\alpha_{bb} *B)}{Kb} - \frac{(B^{x - 1}*W *aB)}{(1 + M^x*hM* aM + B^x*hB* aB)} - \frac{(rb*\alpha_{bm} *M)}{Kb} )$$ +$$dB/dt = B (rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb} )$$ $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From 5827c746dcb26195da7273c7694604cec008d6c5 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:36:14 +0000 Subject: [PATCH 11/26] equation rendering --- Equations.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Equations.md b/Equations.md index 03b8f2c..62a2632 100644 --- a/Equations.md +++ b/Equations.md @@ -1,9 +1,12 @@ **Equations** +Wolves: $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ - -$$dB/dt = B (rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb} )$$ - + +Caribou: +$$dB/dt = B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$$ + +Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ **Parameter Definitions** From ad8d3682bde620548456d972a43c573467be33d8 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:36:48 +0000 Subject: [PATCH 12/26] equation rendering --- Equations.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 62a2632..1e28f78 100644 --- a/Equations.md +++ b/Equations.md @@ -4,7 +4,8 @@ Wolves: $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ Caribou: -$$dB/dt = B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$$ + +$dB/dt = B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From f9f76216c10eea0efc1bb5bf1bb6c715a33da3e3 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:37:06 +0000 Subject: [PATCH 13/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 1e28f78..c95370f 100644 --- a/Equations.md +++ b/Equations.md @@ -5,7 +5,7 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 Caribou: -$dB/dt = B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ +$dB/dt$ $= B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From df7696774db30c515f0cf539a858c8a190dc0a02 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:37:29 +0000 Subject: [PATCH 14/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index c95370f..27be177 100644 --- a/Equations.md +++ b/Equations.md @@ -5,7 +5,7 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 Caribou: -$dB/dt$ $= B(rb - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ +$dB/dt$ $= B$ $(rb$ - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From cf79434e62aeef0cd38bdc5b6c2b5880d7b89c41 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:38:13 +0000 Subject: [PATCH 15/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 27be177..6324e6f 100644 --- a/Equations.md +++ b/Equations.md @@ -5,7 +5,7 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 Caribou: -$dB/dt$ $= B$ $(rb$ - \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ +$dB/dt$ $= B$ $(rb$ $- \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From 70a00ebbbde686e8ced13fa66301f1dff3cd4387 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:38:37 +0000 Subject: [PATCH 16/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 6324e6f..36ffb21 100644 --- a/Equations.md +++ b/Equations.md @@ -5,7 +5,7 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 Caribou: -$dB/dt$ $= B$ $(rb$ $- \frac{rb*\alpha_{bb} *B}{Kb} - \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ +$dB/dt$ $= B$ $(rb$ $- \frac{rb*\alpha_{bb} *B}{Kb}$ $- \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From 003b1a688c4f73586383e6db1898019d11adae95 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:39:56 +0000 Subject: [PATCH 17/26] equation rendering --- Equations.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Equations.md b/Equations.md index 36ffb21..99bd1bb 100644 --- a/Equations.md +++ b/Equations.md @@ -1,11 +1,11 @@ **Equations** Wolves: -$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M* aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ +$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ Caribou: -$dB/dt$ $= B$ $(rb$ $- \frac{rb*\alpha_{bb} *B}{Kb}$ $- \frac{B^{x - 1}*W *aB}{1 + M^x*hM* aM + B^x*hB* aB} - \frac{rb*\alpha_{bm} *M}{Kb})$ +$$dB/dt = B(rb- \frac{rb \alpha_{bb} B}{Kb}- \frac{B^{x - 1} W aB}{1 + M^x hM aM + B^x hB aB} - \frac{rb \alpha_{bm} M}{Kb})$$ Moose: $$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ From 93fe206a12b480e2133ff485f88e5428c9d62ee9 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:41:07 +0000 Subject: [PATCH 18/26] equation rendering --- Equations.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Equations.md b/Equations.md index 99bd1bb..6b5f214 100644 --- a/Equations.md +++ b/Equations.md @@ -5,10 +5,10 @@ $$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + Caribou: -$$dB/dt = B(rb- \frac{rb \alpha_{bb} B}{Kb}- \frac{B^{x - 1} W aB}{1 + M^x hM aM + B^x hB aB} - \frac{rb \alpha_{bm} M}{Kb})$$ +$$dB/dt = B(r_b- \frac{r_b \alpha_{bb} B}{K_b}- \frac{B^{x - 1} W a_B}{1 + M^x h_M a_M + B^x h_B a_B} - \frac{r_b \alpha_{bm} M}{K_b})$$ Moose: -$$dM/dt = M (rm - \frac{(rm*\alpha_{mm}*M)}{Km} - \frac{(M^{x - 1}*W *aM)}{(1 + B^x*hB* aB + M^x*hM* aM)} - \frac{(rm*\alpha_{mb}*B)}{Km} - \mu)$$ +$$dM/dt = M (rm - \frac{(rm \alpha_{mm} M)}{Km} - \frac{(M^{x - 1} W aM)}{(1 + B^x hB aB + M^x hM aM)} - \frac{(rm \alpha_{mb} B)}{Km} - \mu)$$ **Parameter Definitions** From 75ca66656552976563c0e0790e3c8922007ca70b Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:41:45 +0000 Subject: [PATCH 19/26] equation rendering --- Equations.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Equations.md b/Equations.md index 6b5f214..cae5574 100644 --- a/Equations.md +++ b/Equations.md @@ -8,7 +8,7 @@ Caribou: $$dB/dt = B(r_b- \frac{r_b \alpha_{bb} B}{K_b}- \frac{B^{x - 1} W a_B}{1 + M^x h_M a_M + B^x h_B a_B} - \frac{r_b \alpha_{bm} M}{K_b})$$ Moose: -$$dM/dt = M (rm - \frac{(rm \alpha_{mm} M)}{Km} - \frac{(M^{x - 1} W aM)}{(1 + B^x hB aB + M^x hM aM)} - \frac{(rm \alpha_{mb} B)}{Km} - \mu)$$ +$$dM/dt = M (r_m - \frac{(r_m \alpha_{mm} M)}{K_m} - \frac{(M^{x - 1} W a_M)}{(1 + B^x h_B a_B + M^x h_M a_M)} - \frac{(r_m \alpha_{mb} B)}{K_m} - \mu)$$ **Parameter Definitions** From cb77ce0b65d33204228e25895afbb28908d814d4 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 19:48:53 +0000 Subject: [PATCH 20/26] eq order --- Equations.md | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Equations.md b/Equations.md index cae5574..c5047a4 100644 --- a/Equations.md +++ b/Equations.md @@ -1,14 +1,13 @@ **Equations** -Wolves: -$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ +Moose: +$$dM/dt = M (r_m - \frac{(r_m \alpha_{mm} M)}{K_m} - \frac{(M^{x - 1} W a_M)}{(1 + B^x h_B a_B + M^x h_M a_M)} - \frac{(r_m \alpha_{mb} B)}{K_m} - \mu)$$ Caribou: - $$dB/dt = B(r_b- \frac{r_b \alpha_{bb} B}{K_b}- \frac{B^{x - 1} W a_B}{1 + M^x h_M a_M + B^x h_B a_B} - \frac{r_b \alpha_{bm} M}{K_b})$$ -Moose: -$$dM/dt = M (r_m - \frac{(r_m \alpha_{mm} M)}{K_m} - \frac{(M^{x - 1} W a_M)}{(1 + B^x h_B a_B + M^x h_M a_M)} - \frac{(r_m \alpha_{mb} B)}{K_m} - \mu)$$ +Wolves: +$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ **Parameter Definitions** From 87a7621abde2c8c21e48b845fee38494a7ab45f7 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 21:38:07 +0000 Subject: [PATCH 21/26] typo in eqs, updated caribou env --- Equations.md | 2 +- src/rl4caribou/envs/caribou.py | 107 ++++++++++++++++----------------- 2 files changed, 53 insertions(+), 56 deletions(-) diff --git a/Equations.md b/Equations.md index c5047a4..5012e23 100644 --- a/Equations.md +++ b/Equations.md @@ -7,7 +7,7 @@ Caribou: $$dB/dt = B(r_b- \frac{r_b \alpha_{bb} B}{K_b}- \frac{B^{x - 1} W a_B}{1 + M^x h_M a_M + B^x h_B a_B} - \frac{r_b \alpha_{bm} M}{K_b})$$ Wolves: -$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x)}{1 + M^x h_M aM + B^x h_B a_B} - d - \omega)$$ +$$dW/dt = W(\frac{B^x a_B}{1 + M^x h_M aM + B^x h_B a_B} + \frac{u a_M M^x}{1 + M^x h_M a_M + B^x h_B a_B} - d - \omega)$$ **Parameter Definitions** diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index 37cc71f..3b24c41 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -1,68 +1,68 @@ +import gymnasium as gym import numpy as np - # pop = elk, caribou, wolves # Caribou Scenario def dynamics(pop, effort, harvest_fn, p, timestep=1): pop = harvest_fn(pop, effort) - X, Y, Z = pop[0], pop[1], pop[2] - - K = p["K"] # - 0.2 * np.sin(2 * np.pi * timestep / 3200) - D = p["D"] + 0.5 * np.sin(2 * np.pi * timestep / 3200) - beta = p["beta"] + 0.2 * np.sin(2 * np.pi * timestep / 3200) - - X += ( - p["r_x"] * X * (1 - (X + p["tau_xy"] * Y) / K) - - (1 - D) * beta * Z * (X**2) / (p["v0"] ** 2 + X**2) - + p["sigma_x"] * X * np.random.normal() - ) - - Y += ( - p["r_y"] * Y * (1 - (Y + p["tau_yx"] * X) / K) - - D * beta * Z * (Y**2) / (p["v0"] ** 2 + Y**2) - + p["sigma_y"] * Y * np.random.normal() - ) - - Z += ( - p["alpha"] - * beta - * Z - * ( - (1 - D) * (X**2) / (p["v0"] ** 2 + X**2) - + D * (Y**2) / (p["v0"] ** 2 + Y**2) - ) - - p["dH"] * Z - + p["sigma_z"] * Z * np.random.normal() - ) - - pop = np.array([X, Y, Z], dtype=np.float32) - pop = np.clip(pop, [0, 0, 0], [np.Inf, np.Inf, np.Inf]) - return pop - - -initial_pop = [0.5, 0.5, 0.2] + M, B, W = pop[0], pop[1], pop[2] # moose, caribou, wolf + denominator = (1 + B**x * p['h_B'] * p['a_B'] + M**x * p['h_M'] * p['a_M']) + + return np.float32([ + M + M * ( + p['r_m'] * (1 - p['alpha_mm'] * M / p['K_m']) + - M**(p['x'] - 1) * W * p['a_M'] / denominator + - p['r_m'] * p['alpha_mb'] * B / p['K_m'] + + p['sigma_M'] * np.random.normal() + ), + # + B + B * ( + p['r_b'] * (1 - p['alpha_bb'] * B / p['K_b']) + - B**(p['x']-1) * W * p['a_B'] / denominator + - p['r_b'] * p['alpha_bm'] * M / p['K_b'] + + p['sigma_B'] * np.random.normal() + ), + # + W + W * ( + B**p['x'] * p['a_B'] / denominator + M**p['x'] * p['a_M'] * p['u'] / denominator + - p['d'] + + p['sigma_W'] * np.random.normal() + ), + ]) parameters = { - "r_x": np.float32(0.13), - "r_y": np.float32(0.2), - "K": np.float32(1), - "beta": np.float32(0.1), - "v0": np.float32(0.1), - "D": np.float32(0.8), - "tau_yx": np.float32(0.7), - "tau_xy": np.float32(0.2), - "alpha": np.float32(0.4), - "dH": np.float32(0.03), - "sigma_x": np.float32(0.05), - "sigma_y": np.float32(0.05), - "sigma_z": np.float32(0.05), + "r_m": np.float32(1), + "r_b": np.float32(1), + # + "alpha_mm": np.float32(1), + "alpha_bb": np.float32(1), + "alpha_bm": np.float32(1), + "alpha_mb": np.float32(1), + # + "a_M": np.float32(1), + "a_B": np.float32(1), + # + "K_m": np.float32(1), + "K_b": np.float32(1), + # + "h_M": np.float32(1), + "h_B": np.float32(1), + # + "x": np.float32(1), + "u": np.float32(1), + "d": np.float32(1), + # + "sigma_M": np.float32(0.1), + "sigma_B": np.float32(0.1), + "sigma_W": np.float32(0.1), } def harvest(pop, effort): q0 = 0.5 # catchability coefficients -- erradication is impossible q2 = 0.5 - pop[0] = pop[0] * (1 - effort[0] * q0) # pop 0, elk + pop[0] = pop[0] * (1 - effort[0] * q0) # pop 0, moose pop[2] = pop[2] * (1 - effort[1] * q2) # pop 2, wolves return pop @@ -75,9 +75,6 @@ def utility(pop, effort): return benefits - costs -import gymnasium as gym - - class Caribou(gym.Env): """A 3-species ecosystem model with two control actions""" @@ -90,7 +87,7 @@ def __init__(self, config=None): self.threshold = config.get("threshold", np.float32(1e-4)) self.init_sigma = config.get("init_sigma", np.float32(1e-3)) self.training = config.get("training", True) - self.initial_pop = config.get("initial_pop", initial_pop) + self.initial_pop = config.get("initial_pop", np.ones(3, dtype=np.float32)) self.parameters = config.get("parameters", parameters) self.dynamics = config.get("dynamics", dynamics) self.harvest = config.get("harvest", harvest) From 5d063c0a14762e5d88d69f16aee37aa3af0ba12f Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 21:53:31 +0000 Subject: [PATCH 22/26] added param vals based on literature --- src/rl4caribou/envs/caribou.py | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index 3b24c41..fa82367 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -2,7 +2,7 @@ import numpy as np # pop = elk, caribou, wolves -# Caribou Scenario +# Population dynamics def dynamics(pop, effort, harvest_fn, p, timestep=1): pop = harvest_fn(pop, effort) M, B, W = pop[0], pop[1], pop[2] # moose, caribou, wolf @@ -31,25 +31,32 @@ def dynamics(pop, effort, harvest_fn, p, timestep=1): ), ]) + +## +## Param vals taken from https://doi.org/10.1016/j.ecolmodel.2019.108891 +## +am = {"current": 15.32, "full_rest": 11.00} +ab = {"current": 51.45, "full_rest": 26.39} + parameters = { - "r_m": np.float32(1), - "r_b": np.float32(1), + "r_m": np.float32(0.39), + "r_b": np.float32(0.30), # "alpha_mm": np.float32(1), "alpha_bb": np.float32(1), "alpha_bm": np.float32(1), "alpha_mb": np.float32(1), # - "a_M": np.float32(1), - "a_B": np.float32(1), + "a_M": am["current"], + "a_B": ab["current"], # - "K_m": np.float32(1), - "K_b": np.float32(1), + "K_m": np.float32(1.1), + "K_b": np.float32(0.40), # - "h_M": np.float32(1), - "h_B": np.float32(1), + "h_M": np.float32(0.112), + "h_B": np.float32(0.112), # - "x": np.float32(1), + "x": np.float32(2), "u": np.float32(1), "d": np.float32(1), # @@ -59,6 +66,9 @@ def dynamics(pop, effort, harvest_fn, p, timestep=1): } +## +## Harvest, utility +## def harvest(pop, effort): q0 = 0.5 # catchability coefficients -- erradication is impossible q2 = 0.5 @@ -74,7 +84,6 @@ def utility(pop, effort): benefits -= 1 return benefits - costs - class Caribou(gym.Env): """A 3-species ecosystem model with two control actions""" From 8b1402bb40d97409d32dc260166be1f398596b7a Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 21:57:35 +0000 Subject: [PATCH 23/26] debug --- src/rl4caribou/envs/caribou.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index fa82367..c55f6f2 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -25,7 +25,7 @@ def dynamics(pop, effort, harvest_fn, p, timestep=1): # W + W * ( B**p['x'] * p['a_B'] / denominator - M**p['x'] * p['a_M'] * p['u'] / denominator + + M**p['x'] * p['a_M'] * p['u'] / denominator - p['d'] + p['sigma_W'] * np.random.normal() ), From cf780e5c7fe43a2ea83c3ed253b2288f04743f5e Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 22:49:00 +0000 Subject: [PATCH 24/26] debug --- src/rl4caribou/envs/caribou.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index c55f6f2..0a3530b 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -104,7 +104,7 @@ def __init__(self, config=None): self.observe = config.get( "observe", lambda state: state ) # default to perfectly observed case - self.bound = 2 * self.parameters["K"] + self.bound = 2 * np.max(self.parameters["K_b"], self.parameters["K_m"]) self.action_space = gym.spaces.Box( np.array([-1, -1], dtype=np.float32), From bdb5b9bf934d84fa058108c33d5133a84a71b795 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 23:00:24 +0000 Subject: [PATCH 25/26] debug --- src/rl4caribou/envs/caribou.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index 0a3530b..44e2c77 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -104,7 +104,7 @@ def __init__(self, config=None): self.observe = config.get( "observe", lambda state: state ) # default to perfectly observed case - self.bound = 2 * np.max(self.parameters["K_b"], self.parameters["K_m"]) + self.bound = 2 self.action_space = gym.spaces.Box( np.array([-1, -1], dtype=np.float32), From a4aa852796b7171839fef0de87ab72afbd4f1029 Mon Sep 17 00:00:00 2001 From: Felipe Montealegre-Mora Date: Tue, 27 Feb 2024 23:04:04 +0000 Subject: [PATCH 26/26] debug --- src/rl4caribou/envs/caribou.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rl4caribou/envs/caribou.py b/src/rl4caribou/envs/caribou.py index 44e2c77..99d9be7 100644 --- a/src/rl4caribou/envs/caribou.py +++ b/src/rl4caribou/envs/caribou.py @@ -6,7 +6,7 @@ def dynamics(pop, effort, harvest_fn, p, timestep=1): pop = harvest_fn(pop, effort) M, B, W = pop[0], pop[1], pop[2] # moose, caribou, wolf - denominator = (1 + B**x * p['h_B'] * p['a_B'] + M**x * p['h_M'] * p['a_M']) + denominator = (1 + B**p['x'] * p['h_B'] * p['a_B'] + M**p['x'] * p['h_M'] * p['a_M']) return np.float32([ M + M * (