Solve system of ODEs for steady state symbolically
This will give the equilibrium, without checking convergence as t -> Infinity
:
rhs = {X'[t], Y'[t]} /.
First@Solve[eqns, {X'[t], Y'[t]}, {X[0], Y[0]}];
Solve[rhs == 0, {X[t], Y[t]}]
(*
{{X[t] -> -(P/(-k1 + A k1 - k2)),
Y[t] -> ((-k1 + A k1) P)/((-k1 + A k1 - k2) k3)}}
*)
Here's way to get the convergence criteria:
Reduce[
Thread[
Eigenvalues[
CoefficientArrays[rhs, {X[t], Y[t]}][[2]]
] < 0
],
{A, k1, k2, k3}
]
(* (A | k1) \[Element] Reals && k2 > -k1 + A k1 && k3 > 0 *)
Although this is not an ecological model, my EcoEvo package could be useful.
(* load package *)
<< EcoEvo`;
(* define model *)
SetModel[{
Aux[X] -> {Equation :> P - (k1 + k2) X[t] + A k1 X[t]},
Aux[Y] -> {Equation :> k1 X[t] - A k1 X[t] - k3 Y[t]},
Assumptions -> {k0 > 0, k1 > 0, k2 > 0, k3 > 0, 0 <= A < 1}
}]
(* find equilibria *)
eq = SolveEcoEq[]
(* {{X -> -(P/(-k1 + A k1 - k2)),
Y -> ((-k1 + A k1) P)/((-k1 + A k1 - k2) k3)}} *)
(* check stability *)
EcoStableQ[eq[[1]]]
Based on your assumptions, you will find that the equilibrium is always stable:
Simplify[EcoStableQ[eq[[1]]]]
(* True *)
Your initial approach also provides the conditions for convergence
$Version
(* "12.1.1 for Mac OS X x86 (64-bit) (June 19, 2020)" *)
Clear["Global`*"]
eqns = {X'[t] == P - (k1 + k2) X[t] + A k1 X[t],
Y'[t] == k1 X[t] - A k1 X[t] - k3 Y[t], X[0] == 0, Y[0] == 0};
sol = DSolve[eqns, {X, Y}, t][[1]];
Verifying the solution
eqns /. sol // Simplify
(* {True, True, True, True} *)
Using Limit
to find the steady state also provides the conditions for convergence
ss = Limit[{X[t], Y[t]} /. sol, t -> Infinity]
cond = (And @@ (Last /@ ss)) // Simplify
(* P ∈ Reals && A k1 + k3 < k1 + k2 && k1 + k2 > A k1 && k3 > 0 *)
For your initially specified conditions, the additional requirement is
Simplify[cond,
k0 > 0 && k1 > 0 && k2 > 0 && k3 > 0 && P > 0 && A >= 0 && A < 1]
(* A k1 + k3 < k1 + k2 *)