Area of a recursive function

What is the area of the region bounded by $y = f_n(x)$ and the $x$-axis as $n$ gets large?

$f_0=1-|x|$
$f_n=1-|1-2f_{n-1}(x)|$

Assume the domain of $f$ to be the real numbers.

By trying various values for $n$ and $x$ I got that $f_n(x) = 2^{n}\cdot f_0(x)$

By integrating this I got that the area is given by $2^{n-1}\cdot x\cdot (2-|x|)$.

However, I was also told that the area is in fact $1$ as $n$ approaches infinity.

The formula I came up with (guessed) seems to check out if I integrate $2^{n-1}\cdot f_0(x)$ between certain values and for a certain $n$ and compare it to manually expanding that certain $f_n$ and integrating it between the same values.

My questions are:

1. Is my formula wrong?
2. How can we prove the area is 1?
-
Is the domain of f defined? Or do we take -infinity to infinity? –  Aryabhata Sep 8 '10 at 13:29
@Moron - take -inf to inf. –  IVlad Sep 8 '10 at 13:39
Your formula seems wrong: f_1(0) is 0 while your formula gives 1. –  Aryabhata Sep 8 '10 at 13:46
@Moron - true, I see it now. I just realized the formula was supposed to contain $n$ instead of $n - 1$, otherwise the integral doesn't match. Still wrong though. –  IVlad Sep 8 '10 at 13:54
@IVlad: Are you sure it is -∞ to ∞ instead of -1 to 1? –  KennyTM Sep 8 '10 at 15:13

You must be integrating between -1 and 1; otherwise, the integral diverges. Within this region, $f_n$ is a periodic sawtooth. This is obvious by following the steps geometrically for any one of the teeth: $-2f_{n-1}$ doubles the height of $f_{n-1}$ and flips the graph over the x-axis, which is then raised by $1$. The absolute value creates a new "tooth", and then subtracting all that from $1$ flips everything over. The process converts each tooth into a pair of teeth of the same height but half the width, whence the new teeth have half the original area of the teeth they have replaced. Two of them occupy the original area. Therefore, by induction, the integrals of all the $f_n$ between -1 and 1 equal the integral of $f_0$, which is 1.

-
But why does it matter if the integral diverges? Doesn't that mean the area is infinite? Why do we pick [-1, 1] when there is no such restriction on the domain of the function? –  IVlad Sep 8 '10 at 15:41
[-1,1] is the only interval where it's interesting to integrate. Beyond that interval, you can see that (at any fixed point x) the values of f(x) eventually get larger and larger in size, almost doubling each time, and are very negative. Note, too, that the integral of even f_0 itself diverges. Thus your series isn't even defined unless you limit the domain of the f_n. Whoever told you the area was 1 must have been assuming the domain of f is restricted to [-1,1]. –  whuber Sep 8 '10 at 22:18
I understand that it's 1 in [-1, 1], but if you were given just the function with no domain restriction, why would you decide to only integrate in [-1, 1] instead of saying the area is infinite? How and why would you arrive at it? With no domain restriction, is it correct to say the area is infinite? –  IVlad Sep 9 '10 at 11:50
@IVlad: In general there's no reason to restrict to [-1,1]. But the problem statement contains many indications that this is the intention, including (a) the implicit assumption that f_n actually has an area, (b) your friend's assertion that the (limiting) area is 1, (c) the loose statement of the problem. All these lead one to consider the conditions under which the problem might make some sense and have a nontrivial solution. In this case, there is a clear difference in behavior of the f_n on [-1,1] compared to the rest of the reals. Finally, yes, it's correct to say the area is -infinity. –  whuber Sep 9 '10 at 12:43