Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- double cfracTan(double x, unsigned int n){
- 30 double xx = x*x;
- 31 int l = 1;
- 32 double eps = 0.0000000001;
- 33 double result = x;
- 34 double xp;
- 35 while (abVal(result-xp) >= eps){
- 36 xp = result;
- 37 result = xp/l-xx;
- 38 l = l + 2;
- 39 }
- 40 return result;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement