New answers tagged

4

A slick reformulation of bbgodfrey's answer is to recognize that the required computation is equivalent to evaluating an appropriate matrix power: With[{n = 5}, MatrixPower[{{-m, 1, 0}, {0, 0, 1}, {1, 0, 0}}, n - 2, {1, 0, 0}]] // Simplify {1 - m^3, -m, m^2} With[{n = 25}, MatrixPower[{{-m, 1, 0}, {0, 0, 1}, {1, 0, 0}}, n - 2, {1, 0, 0}]] // ...


5

Since you did not provide numerical values, I made some up. Basically, what you could do is run RecurrenceTable on the 3 equations starting from some initial conditions, then use Graphics3D to plot the trajectory. ClearAll["Global`*"]; α = 1; β = 2; γ = 3; δ = 4; ζ = 5; η = 6; μ = 7; ε = 8; υ = 9; ρ = 10; σ = 11; ω = 12; eq1 = x[n + 1] == ((α x[n] - β x[n]...


1

One more possibility is to recast your coupled difference equations as repeated matrix-vector multiplication: $$\begin{pmatrix}p(n+1)\\q(n+1)\\p(n)\\q(n)\end{pmatrix}=\begin{pmatrix}\tfrac{2\beta}{n+1}&-\tfrac{\alpha}{n+1}&\tfrac2{n+1}&0\\\tfrac{\alpha}{n}&\tfrac{2\beta}{n}&0&\tfrac2{n}\\1&0&0&0\\0&1&0&0\end{...


0

One can exploit the equivalence of evaluating three-term recurrence relations with repeated multiplication of $2\times 2$ matrices for this task. Just like in ubpdqn's solution, I use RandomChoice[] to generate a bunch of $\pm1$ multipliers all at once: BlockRandom[SeedRandom[42, Method -> "MersenneTwister"]; (* for reproducibility *) With[{n ...


2

I wrote the recursion directly by solving for x[k] in terms of x[k-1]: Clear[x]; x[k_] := x[k] = (a + k + k^2)/(b - x[k - 1]) x[1] = c; This clearly gives a "continued fraction-like" answer: x[#] & /@ Range[10] Observing that the coefficients in each stack are the same: coef={6, 12, 20, 30, 42, 56, 72, 90, 110} I tried: FindSequenceFunction[{6, ...


4

Clear["Global`*"] Format[Q[k_]] := Subscript[Q, k]; Format[Q0] = Subscript[Q, 0]; Include the initial condition in RSolve sol = (RSolve[ {Q[k] == Q[k - 1] + \[Alpha] (Subscript[r, k] - Q[k - 1]), Q[0] == Q0}, Q[k], k][[1]] // Simplify) /. K[1] -> i Translate the index of summation sol2 = ((sol /. Sum -> Inactive[Sum]) /. Inactive[...


6

You are missing the initial condition Q[0] == Q0. Q[k] /. RSolve[{Q[k] == Q[k - 1] + α (Subscript[r, k] - Q[k - 1]), Q[0] == Q0}, Q[k], k][[1]] // FullSimplify This is equivalent to $$(1-\alpha )^k Q0+\sum _{K[1]=1}^k \alpha\ (1-\alpha )^{k-K[1]}\ r_{K[1]}$$


Top 50 recent answers are included