# Finding f(2) - Functional equation question

• Saitama

## Homework Statement

Let ##f\left(\frac{x+y}{2}\right)=\frac{f(x)+f(y)}{2}## for all real x and y. If f'(0) exists and equal -1 and f(0)=1, find f(2).

## The Attempt at a Solution

Substituting y=0, 2f(x/2)=f(x)+1. This doesn't seem to be of much help. I don't see how to use the info given about f'(0). I have the equation in two variables x and y, how do I differentiate it?

Any help is appreciated. Thanks!

You have probably already noticed that $f(x)= -x+1$ solves the problem. To show that the function must be linear, try fixing y and differentiating the both sides of the equation given with respect to x.

Try working it backwards. Suppose you knew f(2) and that bit is differentiable at 0 (but not the value). Could you deduce f(1)? f(.5)? f(.25)? ... and thus f'(0)?

You have probably already noticed that $f(x)= -x+1$ solves the problem. To show that the function must be linear, try fixing y and differentiating the both sides of the equation given with respect to x.
You only know it to be differentiable at 0.

Try working it backwards. Suppose you knew f(2) and that bit is differentiable at 0 (but not the value). Could you deduce f(1)? f(.5)? f(.25)? ... and thus f'(0)?

Let f(2)=k.
Substituting y=0 and x=2, f(1)=(k+1)/2
With y=0 and x=1, f(1/2)=(k+3)/4
y=0 and x=1/2, f(1/4)=(k+7)/8

I still do not see what to do with this. How do I determine f'(0)? Differentiating the given equation wrt x treating y as constant gives,
$$f'\left(\frac{x+y}{2}\right)=f'(x)$$

Last edited:
Let f(2)=k.
Substituting y=0 and x=2, f(1)=(k+1)/2
With y=0 and x=1, f(1/2)=(k+2)/4
y=0 and x=1/2, f(1/4)=(k+6)/8

I still do not see what to do with this. How do I determine f'(0)? Differentiating the given equation wrt x treating y as constant gives,
$$f'\left(\frac{x+y}{2}\right)=f'(x)$$

Initially, you cannot assume f is differentiable, or even continuous! In fact, you can *prove* these results using the functional equation plus the existence of a derivative at x = 0. However, you don't need all that to just answer the original question.

Hint: the functional equation says that the points (x1,f(x1)), (m,f(m)) and (x2,f(x2)) all lie on a straight line in xy space (where m = (x1+x2)/2 is the mid-point of the interval [x1,x2]). Apply this result several times to conclude that ##f(r x_1 + (1-r) x_2) = r f(x_1) + (1-r) f(x_2)## for any ##r## in dyadic rational form, that is, for ##r = k/2^n##, ## k = 0,
\pm 1, \pm 2, \ldots## and ## n \geq 0## is an integer. Apply this to, eg., ##x_1 = 0, x_2 = 1## and you are almost done. Can you see where the existence of ##f '(0)## comes in, and how its value can be used?

Initially, you cannot assume f is differentiable, or even continuous! In fact, you can *prove* these results using the functional equation plus the existence of a derivative at x = 0. However, you don't need all that to just answer the original question.

Hint: the functional equation says that the points (x1,f(x1)), (m,f(m)) and (x2,f(x2)) all lie on a straight line in xy space (where m = (x1+x2)/2 is the mid-point of the interval [x1,x2]). Apply this result several times to conclude that ##f(r x_1 + (1-r) x_2) = r f(x_1) + (1-r) f(x_2)## for any ##r## in dyadic rational form, that is, for ##r = k/2^n##, ## k = 0,
\pm 1, \pm 2, \ldots## and ## n \geq 0## is an integer. Apply this to, eg., ##x_1 = 0, x_2 = 1## and you are almost done. Can you see where the existence of ##f '(0)## comes in, and how its value can be used?

:uhh:
I am sorry Ray, that all went over my head. If you are assuming that I have taken a course on Real Analysis (I guess that's what it is called, sorry if I used the wrong word), then no. This question showed in a limits practice sheet I am currently solving.

:uhh:
I am sorry Ray, that all went over my head. If you are assuming that I have taken a course on Real Analysis (I guess that's what it is called, sorry if I used the wrong word), then no. This question showed in a limits practice sheet I am currently solving.

The important point is that the three points (x,f(x)), (m,f(m)) and (y,f(y)) all lie on the same straight line, where m = (x + y)/2 is the mid-point. Is that over your head?

Now just keep applying that result, so you find that not only mid-points, but also 1/4 and 3/4 points are on the line, as are points that are 1/8, 3/8, 5/8, 7/8 of the way from x to y. That, I hope, is not above your head. Keep going like that.

Let f(2)=k.
Substituting y=0 and x=2, f(1)=(k+1)/2
With y=0 and x=1, f(1/2)=(k+2)/4
y=0 and x=1/2, f(1/4)=(k+6)/8
f'(0) is the limit of the gradient of the line from (0, f(0)) to (δ, f(δ)) as δ→0.
So, in terms of k, what are these gradients for δ=2, 1, .5, .25, ...?

f'(0) is the limit of the gradient of the line from (0, f(0)) to (δ, f(δ)) as δ→0.
So, in terms of k, what are these gradients for δ=2, 1, .5, .25, ...?

Sorry, I had calculated the incorrect values of f(1), f(.5), f(0.25)... in terms of k. I have corrected them. Using your method, I get k=-1 which is the correct answer.

I tried to generalize it,
$$f\left(\frac{1}{2^n}\right)=\frac{k+2^{n+1}-1}{2^{n+1}}$$
f'(0) is defined as,
$$f'(0)=\lim_{h \rightarrow 0} \frac{f(0+h)-f(0)}{h} = \lim_{n \rightarrow \infty} \frac{f(1/2^n)-f(0)}{1/2^n}$$
Solving the limit and using f'(0)=-1, I get k=-1. Is this a correct way to put it?

Also, how did you think of calculating the values of 1, 1/2, 1/4, 1/8...? What part of the question hinted you that? Thanks! :)

Solving the limit and using f'(0)=-1, I get k=-1. Is this a correct way to put it?
Yes, that's what I had in mind.
Also, how did you think of calculating the values of 1, 1/2, 1/4, 1/8...? What part of the question hinted you that? Thanks! :)
Since we only know it to be differentiable at one point, it is natural to look for a sequence converging on that point, and try to determine the corresponding sequence of slopes.
The given functional equation allows us to find the value at a point in a triple in arithmetic progression if we know the value at the other two points. To get a converging sequence out of that we need to know the outer two points and deduce the one in the middle.

...find the value at a point in a triple in arithmetic progression ...

What does this mean?

What does this mean?

By a "triple in a.p." I mean three numbers equally spaced: a-b, a, a+b. From the functional equation, if you know f at any two then you can calculate it at the third.

Btw, you can go on to show that if f satisfies that functional equation and is known to be differentiable at some point (any point) then it is simply a straight line. An interesting challenge then is to find some other solution of the functional equation - it would be nowhere differentiable.

Btw, you can go on to show that if f satisfies that functional equation and is known to be differentiable at some point (any point) then it is simply a straight line.

Sorry if this is something very obvious but I don't even have the slightest idea about this. Is this related to hints given by Ray Vickson? I still haven't been able to figure out how did he conclude that the three points (x,f(x)), (m,f(m)) and (y,f(y)) lie on the same straight line. I really suck at this part of Mathematics (or almost every part) :(

Sorry if this is something very obvious but I don't even have the slightest idea about this. Is this related to hints given by Ray Vickson?
Yes.
Suppose f satisfies the given functional equation and is differentiable at p. Let f(p) = a and f(x) = b. in terms of those we can compute f((p+x)/2), f((3p+x)/4), f((7p+x)/8) etc. The slopes of the lines from (p, f(p)) to these points are all (b-a)/(x-p). E.g. f((p+x)/2) = f(p)/2+f(x)/2 = (a+b)/2; f((p+x)/2) - f(p) = (b-a)/2; (p+x)/2 - p = (x-p)/2. So the slope is ((b-a)/2)/((x-p)/2) = (b-a)/(x-p).
So we have a sequence converging at p, and the slopes are all the same, so converge to (b-a)/(x-p) = c, say. From the definition of differentiability, all such sequences must produce the same convergent value c for the slope, so regardless of the choice of x we get (f(x)-a)/(x-p) = c, an equation of a straight line.

Sorry if this is something very obvious but I don't even have the slightest idea about this. Is this related to hints given by Ray Vickson? I still haven't been able to figure out how did he conclude that the three points (x,f(x)), (m,f(m)) and (y,f(y)) lie on the same straight line. I really suck at this part of Mathematics (or almost every part) :(

If ##a < b < c## are three equally-spaced numbers, so that ##b-a = c-b## then we have ##b = (a+c)/2##. Your functional equation says that
$$f(b) = \frac{1}{2} f(a) + \frac{1}{2}f(c).$$ Now imagine plotting the three points ##A = (a,f(a)), \; B = (b,f(b)), \: C = (c,f(c))## in a Cartesian coordinate system. Along the x-axis the points are equally spaced, since ##b-a = c-b##. Are they equally-spaced along the y-axis; that is, do we have ##f(b)-f(a) = f(c)-f(b)?## Just plug in the expression for ##f(b)## (in terms of ##f(a)## and ##f(c)##) and you will see that the answer is YES: they are equally-spaced also along the y-axis. Can you see now why they lie along a straight line?

Last edited: