# Can somebody run this for me? [closed]

DSolve[{z'[t] == d (x[t] + u) - k (z[t] + s),
y'[t] == -R*x[t] v - R y[t] u - Ruv +
k (1 - c (x[t] + u) - (y[t] + v)),
x'[t] == R x[t] v + R y[t] u + Ruv - x[t] - u}, {y[t], z[t], x[t]},
t] // Simplify


My computer is taking a really long time to simplify the solutions. Thanks in advance!

• Maybe you meant R u v? Spaces matter… Jun 24 '15 at 16:22
• Welcome to Mathematica.SE! I hope you will become a regular contributor. To get started, 1) take the introductory Tour now, 2) when you see good questions and answers, vote them up by clicking the gray triangles, because the credibility of the system is based on the reputation gained by users sharing their knowledge, 3) remember to accept the answer, if any, that solves your problem, by clicking the checkmark sign, and 4) give help too, by answering questions in your areas of expertise. Jun 24 '15 at 16:40
• I assume that you meant R*u*v, as @Guesswhoitis. mentioned. Either way, solving the equation doesn't take very long, but it does return some long, nasty-looking results. Simplify ran on those results for a long time on my machine without returning anything, before I aborted the computation. Apparently, Simplify is the bottleneck here. Try and see if you can work with the non-simplified expression: it might save you A LOT of time. Jun 24 '15 at 17:45
• Simplify may run quicker if you can specify some constraints on the parameters. Are any real, integer, positive, nonnegative, negative? Jun 25 '15 at 1:59

This is the outline of an answer. To begin, assume that R u v is meant instead of Ruv. As noted by MarcoB, attempting to solve the equations by brute force, as suggested in the Question, takes forever. Instead, first simplify the three linear ODEs by adding constants to the dependent variables.

eq = {x'[t] == R x[t] v + R y[t] u + R u v - x[t] - u,
y'[t] == -R*x[t] v - R y[t] u - R u v + k (1 - c (x[t] + u) - (y[t] + v)),
z'[t] == d (x[t] + u) - k (z[t] + s)} /. {x[t] -> x[t] - u,
y[t] -> y[t] - v, z[t] -> z[t] - s} /.
Equal[z1_, z2__] :> Equal[z1, Simplify[z2]]
(* {x'[t] == (-1 + R v) x[t] + R u (-v + y[t]),
y'[t] == k + R u v - (c k + R v) x[t] - (k + R u) y[t],
z'[t] == d x[t] - k z[t]} *)


Because the equations are linear with constant coefficients, it is natural to ask whether they can be separated by a further change of variables. To find out, use

{b, m} = CoefficientArrays[eq, {x[t], y[t], z[t]}]// Normal; m
(* {{1 - R v, -R u, 0}, {c k + R v, k + R u, 0}, {-d, 0, k}} *)
JordanDecomposition[m]


The final result, which is rather long to be reproduced here, shows that the Jordan Canonical Form of the three equations is diagonal, and also provides the similarity matrix. Hence, the system can be separated, with each transformed equation of the form

DSolveValue[w'[t] == a w[t] + e, w[t], t]
(* -(e/a) + E^(a t) C[1] *)


where each a is an eigenvalue of m

Eigenvalues[m]
(* {k,
1/2 (1 + k + R u - R v - Sqrt[(-1 - k - R u + R v)^2 - 4 (k + R u + c k R u - k R v)]),
1/2 (1 + k + R u - R v + Sqrt[(-1 - k - R u + R v)^2 - 4 (k + R u + c k R u - k R v)])} *)


Thus, the transformed equations can be solved without difficulty, and the original variables obtained using the inverse of the similarity matrix, although the results will be long.

Alternatively, one can take advantage of the fact that the the first two equations in eq are independent of z[t] and can be solved by

DSolveValue[Delete[eq, 3], {x[t], y[t]}, t]


The resulting answer, although lengthy, is orders of magnitude less lengthy than that obtained from the equations as given in the Question. With {x[t], y[t]} now known, z[t] can be evaluated from the third element of eq.