Guest User

Untitled

a guest
Jan 12th, 2017
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. c = 6; (*constant adder in square root*)
  2. b = 6; (*initial value (for F_0)*)
  3. f0[x_] := x;
  4.  
  5. (*finding f(x)*)
  6. N1 = 10; (*precision*)
  7. g[x_] := Sqrt[c + x];
  8. f[x_] := Nest[g, f0[x^2^N1], N1];
  9.  
  10. (*findinf X*)
  11. N2 = 10; (*precision*)
  12. res1 = FindRoot[f[x] == b, {x, c}, WorkingPrecision -> 1000];
  13. X = x /. res1;
  14.  
  15. F[n_] := f[X^2^n]
  16.  
  17. (* you can use this function for comparing (this for eq1) *)
  18. F2[n_] := F2[n - 1]^2 - c;
  19. F2[0] := b;
  20.  
  21. F[0]
  22. F[-1]
  23. F[-2]
  24.  
  25. 6.00000000000000000000000000000000000000000000000000000000000000000000...
  26. 3.46410161513775458705489268301174473388561050762076125611161395890386...
  27. 3.07637800264170309696602586393672241931859085772505962544063421316756...
Add Comment
Please, Sign In to add comment