Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #5849 > unrolled thread

Another basic (?) question about RecurrenceTable and replacement

Started byvictorphy <vbapst@gmail.com>
First post2011-10-25 10:19 +0000
Last post2011-10-26 21:46 +0000
Articles 2 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Another basic (?) question about RecurrenceTable and replacement victorphy <vbapst@gmail.com> - 2011-10-25 10:19 +0000
    Re: Another basic (?) question about RecurrenceTable and replacement victorphy <vbapst@gmail.com> - 2011-10-26 21:46 +0000

#5849 — Another basic (?) question about RecurrenceTable and replacement

Fromvictorphy <vbapst@gmail.com>
Date2011-10-25 10:19 +0000
SubjectAnother basic (?) question about RecurrenceTable and replacement
Message-ID<j862fv$5r5$1@smc.vnet.net>
Hello,

here is another question I could'nt find the asnwer on the web,
altough I guess it's very elementary.


Here is my problem. Assume I want to solve an implicit equation on two
variables :

x_0 = _2, y_0 = 0

(x_{n+1},y_{n+1}) = sol(n/10,x_n,y_n)
for n = 1..10

where f cannot be defined explicitely but is given by something like
(I give  a silly exemple):


f[x_, a_] := -(x - a)^3 + (x - a)
sol[a_?NumericQ, b_?NumericQ,c_?NumericQ] := FindRoot[{f[x, a], x +
y}, {x, b}, {y, c}]

What is the way to write this using RecurrenceTable and computing
sol[n/10,x[n],y[n]] only once ? (as in the real life the rootsearching
is longer than above) ?



Any help would be very welcome.

Thank you very much in advance.


Best regards,

Victor

[toc] | [next] | [standalone]


#5884

Fromvictorphy <vbapst@gmail.com>
Date2011-10-26 21:46 +0000
Message-ID<j89v37$8j$1@smc.vnet.net>
In reply to#5849
I kind of got confused with my notations : I want to solve

x_0 = -2, y_0 = 0

(x_{n+1},y_{n+1}) = sol(n/10,x_n,y_n) for n = 1..10

where *sol* cannot be defined explicitely but is given by something
like

f[x_, a_] := -(x - a)^3 + (x - a)
sol[a_?NumericQ, b_?NumericQ,c_?NumericQ] := FindRoot[{f[x, a], x +y},
{x, b}, {y, c}]



[toc] | [prev] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web