Arithmetic mean of an infinite number of points?

In summary: The concept of the average value of a function over some interval [a, b] can be generalized to any function that is continuous on the interval in question.
  • #1
Feynstein100
162
16
So I was thinking about arithmetic, geometric and harmonic means when I had a thought. Let's say we have a curve y = x^2. We want to find the AM of the points on the curve between x=1 and x=2 i.e. y = 1 and y = 4. To make thing easier, we'll start with just the endpoints and keep adding midpoints with every iteration.
Iteration 1:
Data series = 1, 4
AM = 3
Iteration 2:
Data series = 1, 1.77, 2.76, 4
AM = 2.38
And so on
As we add more and more points, or rather midpoints, does the AM converge to a certain value? At first I thought that the sum of an infinite number of points would be infinity and thus the AM would diverge but then it occurred to me that by its very definition, the AM must lie somewhere between the endpoints and thus can't diverge to infinity. So what would the AM be for all the points between y = 1 and y = 4? Is there a formula to calculate this? And can it be generalized to any function? Same for the GM and HM.
 
Mathematics news on Phys.org
  • #2
Feynstein100 said:
So I was thinking about arithmetic, geometric and harmonic means when I had a thought. Let's say we have a curve y = x^2. We want to find the AM of the points on the curve between x=1 and x=2 i.e. y = 1 and y = 4. To make thing easier, we'll start with just the endpoints and keep adding midpoints with every iteration.
Iteration 1:
Data series = 1, 4
AM = 3
Iteration 2:
Data series = 1, 1.77, 2.76, 4
AM = 2.38
I had to think a bit and do some calculations to understand where these numbers came from. Evidently, you're partitioning the interval [1, 2] into three subintervals with endpoints {1, 4/3, 5/3, 2}. It would have been nice if you had said that.
Feynstein100 said:
And so on
As we add more and more points, or rather midpoints, does the AM converge to a certain value?
Yes. In calculus there is the concept of the average value of a function over some interval [a, b].
Average value of f = ##\frac 1 {b - a}\int_a^b f(x) dx##

For your function on the interval [1, 2], the average function value is ##\frac 1 1 \int_1^2 x^2 dx = \left . \frac {x^3} 3 \right|_1^2 = \frac 8 3 - \frac 1 3 = \frac 7 3 \approx 2.333##
Feynstein100 said:
At first I thought that the sum of an infinite number of points would be infinity and thus the AM would diverge
No, in part because you have to take into account the length of the interval, just like when you find the average (the mean) of a finite number of values, you need to divide by the number of values.
Feynstein100 said:
but then it occurred to me that by its very definition, the AM must lie somewhere between the endpoints and thus can't diverge to infinity. So what would the AM be for all the points between y = 1 and y = 4? Is there a formula to calculate this? And can it be generalized to any function? Same for the GM and HM.
The average function value can be calculated for any function that is continuous on the interval in question. I don't know of any counterpart for the geometric or harmonic means.
 
  • Care
Likes Feynstein100
  • #3
Feynstein100 said:
Is there a formula to calculate this?
I don't think there is even a definition for this, let alone a formula. The mean value theorem for integration could be thought of as a version of an arithmetic mean:
$$
\int_a^bf(x)\,dx=f(\xi)\cdot (b-a)
$$
and there are certainly algorithms to approach ##\xi.## But what would other means be?
 
  • #4
fresh_42 said:
I don't think there is even a definition for this, let alone a formula. The mean value theorem for integration could be thought of as a version of an arithmetic mean: $$
\int_a^bf(x)\,dx=f(\xi)\cdot (b-a)
$$
Every calculus book I've ever seen includes a topic on the average value of a function and gives the definition I showed above. If you isolate ##f(\xi)## in the equation above, you get the integral I wrote in my previous post. What I'm calling the "average function value" is ##f(\xi)##.
 
  • #5
Feynstein100 said:
by its very definition, the AM must lie somewhere between the endpoints and thus can't diverge to infinity. So what would the AM be for all the points between y = 1 and y = 4? Is there a formula to calculate this? And can it be generalized to any function? Same for the GM and HM.
You are correct that ##AM_n## will remain between the extreme values (##n = ## the number of values in the average), but that is all you can say in general. You can easily come up with examples that keep swinging between the two extremes as ##n \rightarrow \infty##, so there may not be a limit value.
 
  • Skeptical
Likes Feynstein100
  • #6
Mark44 said:
Evidently, you're partitioning the interval [1, 2] into three subintervals with endpoints {1, 4/3, 5/3, 2}. It would have been nice if you had said that.
Oh haha sorry. I thought it was obvious. My bad 😅
Mark44 said:
Yes. In calculus there is the concept of the average value of a function over some interval [a, b].
Average value of f =
Isn't that just the area under the function divided by the length along the x-axis? I suspected it might be something like this but I thought it'd be the area divided by the perimeter. Damn, can't believe I was so close to the right answer 🤣
Also, what kind of average is this? Is it the arithmetic mean?
Mark44 said:
No, in part because you have to take into account the length of the interval
Well, yes but the length of the interval is finite whereas the sum of the points in it is infinite. So I thought, infinity divided by a finite number is still infinity. Damn, I feel like we're close to discovering calculus 😃
Mark44 said:
I don't know of any counterpart for the geometric or harmonic means.
Aw that's a bummer 😕 I'm sure we can figure something out if we try
 
  • #7
FactChecker said:
You are correct that ##AM_n## will remain between the extreme values (##n = ## the number of values in the average), but that is all you can say in general. You can easily come up with examples that keep swinging between the two extremes as ##n \rightarrow \infty##, so there may not be a limit value.
Idk @Mark44 's answer seems airtight. I completely forgot about the mean value theorem from calculus lol
 
  • #8
fresh_42 said:
But what would other means be?
That's what we're trying to find out 😄
 
  • #9
Feynstein100 said:
Isn't that just the area under the function divided by the length along the x-axis?
The integral of a function may or may not be synonymous with the area under the curve and above the horizontal axis. But otherwise, the definition I showed is the integral of the function from a to b, divided by the length of the interval, b - a.
Feynstein100 said:
Well, yes but the length of the interval is finite whereas the sum of the points in it is infinite. So I thought, infinity divided by a finite number is still infinity.
It doesn't really make sense to sum points. What you're summing are the function values, and you have to do this with an integral. It doesn't make any sense to say you're adding an infinite number of y values, as there would be no way to list them. Calculating the integral and dividing by the length of the interval produces a value that would be the height of a rectangle with the same area.

Feynstein100 said:
Also, what kind of average is this? Is it the arithmetic mean?
Arithmetic mean, I believe. I've never seen a counterpart to the geometric or harmonic mean in this context.
 
  • #10
Feynstein100 said:
That's what we're trying to find out 😄

So we agree to call the ##f(\xi)## from the MVT the arithmetic mean: ##f(\xi)=\dfrac{\int_a^b f(x)\,dx}{b-a}.##

Well. Let's have the full list then:
\begin{align*}
\overline{x}_{min}&= \min\{\,x_1,\ldots,x_n\,\}&\text{ minimum }\quad \checkmark \\
\overline{x}_{harm}&= \dfrac{n}{\dfrac{1}{x_1}+\cdots+\dfrac{1}{x_n}}&\text{ harmonic mean }\\
\overline{x}_{geom}&= \sqrt[n]{x_1\cdot \cdots \cdot x_n}\; , \;x_k>0&\text{ geometric mean }\\
\overline{x}_{arithm}&= \dfrac{x_1+\cdots+x_n}{n}&\text{ arithmetic mean }\quad \checkmark\\
\overline{x}_{quadr}&= \sqrt{\dfrac{1}{n}\left(x_1^2+ \ldots + x_n^2\right)} &\text{ quadratic }\\
\overline{x}_{cubic}&= \sqrt[3]{\dfrac{1}{n}\left(x_1^3+ \ldots + x_n^3\right)} &\text{ cubic }\\
\overline{x}_{max}&= \max\{\,x_1,\ldots,x_n\,\} &\text{ maximum }\quad \checkmark\\
\end{align*}
For the sake of completeness
$$
\overline{x}_{min}\;\leq\; \overline{x}_{harm} \;\leq\; \overline{x}_{geom} \;\leq\; \overline{x}_{arithm} \;\leq\; \overline{x}_{quadr}\;\leq\; \overline{x}_{cubic}\;\leq\; \overline{x}_{max}
$$

I suggest to call ##\displaystyle{\inf_{x\in D}}f(x)## the minimum and ##\displaystyle{\sup_{x\in D}}f(x)## the maximum. Quadratic and cubic could possibly be done with integrals over ##f^2(x)## or ##f^3(x),## the Hölder means, but I have no idea for geometric and harmonic. And there are still more: Lehmer, Stolarsky, logarithmic.
 
Last edited:
  • Informative
Likes Klystron
  • #11
Feynstein100 said:
Idk @Mark44 's answer seems airtight. I completely forgot about the mean value theorem from calculus lol
Suppose the range of values is in [0,1] and you have added 10 together and got an AM of x. Now suppose that the next million values are 1. That will get you very close to an AM of 1. Now suppose that the next billion values are 0. That will get you very close to an AM of 0. Suppose the next ten trillion values are 1. You can keep going, with the AM swinging between nearly 0 and nearly 1 forever.
 
  • #12
fresh_42 said:
Quadratic and cubic could possibly be done with integrals over f2(x) or f3(x), the Hölder means, but I have no idea for geometric and harmonic. And there are still more: Lehmer, Stolarsky, logarithmic.
The geometric mean is the exponent of the arithmetic mean of log (f(x))
The harmonic mean is the reciprocal of the arithmetic mean of 1/f(x).
Of course both of them need f(x) > 0 for all x.
 
  • Like
Likes Feynstein100 and jbriggs444
  • #13
FactChecker said:
Suppose the range of values is in [0,1] and you have added 10 together and got an AM of x. Now suppose that the next million values are 1. That will get you very close to an AM of 1. Now suppose that the next billion values are 0. That will get you very close to an AM of 0. Suppose the next ten trillion values are 1. You can keep going, with the AM swinging between nearly 0 and nearly 1 forever.
But in each of your scenarios, you're dealing with finite sets of values, which is quite different from the situation where you have an uncountably infinite set of numbers in an interval.
 
  • #14
Mark44 said:
Every calculus book I've ever seen includes a topic on the average value of a function and gives the definition I showed above. If you isolate ##f(\xi)## in the equation above, you get the integral I wrote in my previous post. What I'm calling the "average function value" is ##f(\xi)##.
This must assume that the function is continuous.
 
  • #15
The main question here is: why? GM < AM is useful in many places. For functions, we have Hölder's inequality. The finite means above are all special cases of the Hölder mean. Generalizations are only meaningful if a) we can find similar applications as the ones I mentioned, and b) can easily be calculated. Integrals are notoriously hard to calculate, and applications are totally out of sight.

Functional analysis and function theory are already equipped with appropriate inequalities. To consider such artificial constructions from scratch is a playground, not mathematics.
 
  • #16
FactChecker said:
This must assume that the function is continuous.
Which I said in post #2:
Mark44 said:
The average function value can be calculated for any function that is continuous on the interval in question.
 
  • #17
Mark44 said:
Which I said in post #2:
Sorry, I see that now at the end of the post. I did not notice it and I'm not sure that it was noticed by others. It means that it may not apply to the OP at all and some posts seem to be confused about that.
 
  • #18
fresh_42 said:
The main question here is: why? GM < AM is useful in many places.
Is this the question in this thread? It seems not.

Just one more comment. The arithemtic mean ##\frac{a_1+\cdots +a_n}n## and ##\frac1{b-a}\int_a^b f(x)dx## are special cases of ##\frac1{\mu(X)}\int_X f(x)d\mu(x)##, for ##X## finite measure space. In the first case ##X=\{1,...,n\}## and ##\mu## is the counting measure.
 
  • #19
martinbn said:
Is this the question in this thread? It seems not.
It should be. Why invent something that doesn't help at least somewhere?
 
  • #20
fresh_42 said:
So we agree to call the ##f(\xi)## from the MVT the arithmetic mean: ##f(\xi)=\dfrac{\int_a^b f(x)\,dx}{b-a}.##

Well. Let's have the full list then:
\begin{align*}
\overline{x}_{min}&= \min\{\,x_1,\ldots,x_n\,\}&\text{ minimum }\quad \checkmark \\
\overline{x}_{harm}&= \dfrac{n}{\dfrac{1}{x_1}+\cdots+\dfrac{1}{x_n}}&\text{ harmonic mean }\\
\overline{x}_{geom}&= \sqrt[n]{x_1\cdot \cdots \cdot x_n}\; , \;x_k>0&\text{ geometric mean }\\
\overline{x}_{arithm}&= \dfrac{x_1+\cdots+x_n}{n}&\text{ arithmetic mean }\quad \checkmark\\
\overline{x}_{quadr}&= \sqrt{\dfrac{1}{n}\left(x_1^2+ \ldots + x_n^2\right)} &\text{ quadratic }\\
\overline{x}_{cubic}&= \sqrt[3]{\dfrac{1}{n}\left(x_1^3+ \ldots + x_n^3\right)} &\text{ cubic }\\
\overline{x}_{max}&= \max\{\,x_1,\ldots,x_n\,\} &\text{ maximum }\quad \checkmark\\
\end{align*}
For the sake of completeness
$$
\overline{x}_{min}\;\leq\; \overline{x}_{harm} \;\leq\; \overline{x}_{geom} \;\leq\; \overline{x}_{arithm} \;\leq\; \overline{x}_{quadr}\;\leq\; \overline{x}_{cubic}\;\leq\; \overline{x}_{max}
$$

I suggest to call ##\displaystyle{\inf_{x\in D}}f(x)## the minimum and ##\displaystyle{\sup_{x\in D}}f(x)## the maximum. Quadratic and cubic could possibly be done with integrals over ##f^2(x)## or ##f^3(x),## the Hölder means, but I have no idea for geometric and harmonic. And there are still more: Lehmer, Stolarsky, logarithmic.
Thank you for the list. It was insanely insightful. I also noticed that all of the means, except the GM follow the pattern of what could be called the general polynomial mean defined by
Xn = ((Σx^n)/n)^(1/n) {Sorry for the format. I don't know how to type in the math symbols}
The AM is just this polynomial mean with n = 1, the HM being n = -1. That does raise the question. Can n go on indefinitely in either direction? What if we set n = i, with i being the imaginary unit?
And why doesn't the GM follow this pattern? 🤔
Hey............does this mean we can find the HM of the function using f-1(x)?
 
  • #21
Feynstein100 said:
Thank you for the list. It was insanely insightful. I also noticed that all of the means, except the GM follow the pattern of what could be called the general polynomial mean defined by
Xn = ((Σx^n)/n)^(1/n) {Sorry for the format. I don't know how to type in the math symbols}
The AM is just this polynomial mean with n = 1, the HM being n = -1. That does raise the question. Can n go on indefinitely in either direction? What if we set n = i, with i being the imaginary unit?
And why doesn't the GM follow this pattern? 🤔
Hey............does this mean we can find the HM of the function using f-1(x)?
Here is the pattern for finitely many points:
https://de.wikipedia.org/wiki/Hölder-Mittel#Spezialfälle
Also, look up the corresponding English page for further information, but it doesn't have this pattern as a list depending on ##p.##

And do not forget @martinbn 's formula. It provides a definition for functions and all you have to do is vary along possible measures.
 

Similar threads

Replies
4
Views
1K
  • General Math
Replies
7
Views
1K
Replies
4
Views
706
Replies
2
Views
1K
Replies
1
Views
850
Replies
1
Views
2K
Replies
9
Views
1K
Replies
2
Views
416
Back
Top