In mathematics, a generalized mean , also known as power mean or Hölder mean (named after Otto Hölder ), is an abstraction of the Pythagorean means including arithmetic , geometric , and harmonic means .
Definition
If p is a non-zero real number , we can define the generalized mean with exponent p (or power mean with exponent p ) of the positive real numbers
x
1
,
…
,
x
n
{\displaystyle x_{1},\dots ,x_{n}}
as:
M
p
(
x
1
,
…
,
x
n
)
=
(
1
n
⋅
∑
i
=
1
n
x
i
p
)
1
/
p
{\displaystyle M_{p}(x_{1},\dots ,x_{n})=\left({\frac {1}{n}}\cdot \sum _{i=1}^{n}x_{i}^{p}\right)^{1/p}}
While for p equal to 0 we assume that it's equal to the geometric mean (which is, in fact, the limit of means with exponents approaching zero):
M
0
(
x
1
,
…
,
x
n
)
=
∏
i
=
1
n
x
i
n
{\displaystyle M_{0}(x_{1},\dots ,x_{n})={\sqrt[{n}]{\prod _{i=1}^{n}x_{i}}}}
Furthermore, for a sequence of positive weights wi we can define weighted power means as follows:
M
p
(
x
1
,
…
,
x
n
)
=
(
1
∑
i
=
1
n
w
i
⋅
∑
i
=
1
n
w
i
x
i
p
)
1
/
p
{\displaystyle M_{p}(x_{1},\dots ,x_{n})=\left({\frac {1}{\sum _{i=1}^{n}w_{i}}}\cdot \sum _{i=1}^{n}w_{i}x_{i}^{p}\right)^{1/p}}
M
0
(
x
1
,
…
,
x
n
)
=
∏
j
=
1
n
x
j
w
j
∑
i
=
1
n
w
i
{\displaystyle M_{0}(x_{1},\dots ,x_{n})={\sqrt[{\sum _{i=1}^{n}w_{i}}]{\prod _{j=1}^{n}x_{j}^{w_{j}}}}}
For the sake of simplicity, we might assume that the weights are normalized so that they sum up to 1 (which can be easily done by dividing each weight by their sum), thus allowing some terms in the above formulae to be omitted:
M
p
(
x
1
,
…
,
x
n
)
=
(
∑
i
=
1
n
w
i
x
i
p
)
1
/
p
{\displaystyle M_{p}(x_{1},\dots ,x_{n})=\left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)^{1/p}}
M
0
(
x
1
,
…
,
x
n
)
=
∏
i
=
1
n
x
i
w
i
{\displaystyle M_{0}(x_{1},\dots ,x_{n})=\prod _{i=1}^{n}x_{i}^{w_{i}}}
The unweighted means can be easily produced by assuming that all weights equal 1/n . For exponents equal to positive or negative infinity the means are maximum and minimum, respectively, regardless of weights (and they are actually the limit points for exponents approaching the respective extremes):
M
∞
(
x
1
,
…
,
x
n
)
=
max
(
x
1
,
…
,
x
n
)
{\displaystyle M_{\infty }(x_{1},\dots ,x_{n})=\max(x_{1},\dots ,x_{n})}
M
−
∞
(
x
1
,
…
,
x
n
)
=
min
(
x
1
,
…
,
x
n
)
{\displaystyle M_{-\infty }(x_{1},\dots ,x_{n})=\min(x_{1},\dots ,x_{n})}
Properties
Like most means , the generalized mean is a homogeneous function of its arguments
x
1
,
…
,
x
n
{\displaystyle x_{1},\dots ,x_{n}}
. That is, if b is a positive real number, then the generalized mean with exponent p of the numbers
b
⋅
x
1
,
…
,
b
⋅
x
n
{\displaystyle b\cdot x_{1},\dots ,b\cdot x_{n}}
is equal to b times the generalized mean of the numbers
x
1
,
…
,
x
n
{\displaystyle x_{1},\dots ,x_{n}}
.
Like the quasi-arithmetic means , the computation of the mean can be split into computations of equal sized sub-blocks.
M
p
(
x
1
,
…
,
x
n
⋅
k
)
=
M
p
(
M
p
(
x
1
,
…
,
x
k
)
,
M
p
(
x
k
+
1
,
…
,
x
2
⋅
k
)
,
…
,
M
p
(
x
(
n
−
1
)
⋅
k
+
1
,
…
,
x
n
⋅
k
)
)
{\displaystyle M_{p}(x_{1},\dots ,x_{n\cdot k})=M_{p}(M_{p}(x_{1},\dots ,x_{k}),M_{p}(x_{k+1},\dots ,x_{2\cdot k}),\dots ,M_{p}(x_{(n-1)\cdot k+1},\dots ,x_{n\cdot k}))}
Generalized mean inequality
In general, if p < q , then
M
p
(
x
1
,
…
,
x
n
)
≤
M
q
(
x
1
,
…
,
x
n
)
{\displaystyle M_{p}(x_{1},\dots ,x_{n})\leq M_{q}(x_{1},\dots ,x_{n})}
and the two means are equal if and only if
x
1
=
x
2
=
⋯
=
x
n
{\displaystyle x_{1}=x_{2}=\cdots =x_{n}}
.
It is true for real nonzero p , as well as zero, positive and negative infinity p , as defined above.
This follows from the fact that, for all p in
R
{\displaystyle \mathbb {R} }
,
∂
M
p
(
x
1
,
…
,
x
n
)
∂
p
≥
0
,
{\displaystyle {\frac {\partial M_{p}(x_{1},\dots ,x_{n})}{\partial p}}\geq 0,}
which can be proved using Jensen's inequality . In particular, for
p
∈
{
−
1
,
0
,
1
}
{\displaystyle p\in \{-1,0,1\}}
, the generalized mean inequality implies the Pythagorean means inequality as well as the inequality of arithmetic and geometric means .
Special cases
A visual depiction of some of the specified cases for n=2 .
lim
p
→
−
∞
M
p
(
x
1
,
…
,
x
n
)
=
min
{
x
1
,
…
,
x
n
}
{\displaystyle \lim _{p\to -\infty }M_{p}(x_{1},\dots ,x_{n})=\min\{x_{1},\dots ,x_{n}\}}
minimum
M
−
1
(
x
1
,
…
,
x
n
)
=
n
1
x
1
+
⋯
+
1
x
n
{\displaystyle M_{-1}(x_{1},\dots ,x_{n})={\frac {n}{{\frac {1}{x_{1}}}+\dots +{\frac {1}{x_{n}}}}}}
harmonic mean
lim
p
→
0
M
p
(
x
1
,
…
,
x
n
)
=
x
1
⋅
⋯
⋅
x
n
n
{\displaystyle \lim _{p\to 0}M_{p}(x_{1},\dots ,x_{n})={\sqrt[{n}]{x_{1}\cdot \dots \cdot x_{n}}}}
geometric mean
M
1
(
x
1
,
…
,
x
n
)
=
x
1
+
⋯
+
x
n
n
{\displaystyle M_{1}(x_{1},\dots ,x_{n})={\frac {x_{1}+\dots +x_{n}}{n}}}
arithmetic mean
M
2
(
x
1
,
…
,
x
n
)
=
x
1
2
+
⋯
+
x
n
2
n
{\displaystyle M_{2}(x_{1},\dots ,x_{n})={\sqrt {\frac {x_{1}^{2}+\dots +x_{n}^{2}}{n}}}}
quadratic mean
lim
p
→
∞
M
p
(
x
1
,
…
,
x
n
)
=
max
{
x
1
,
…
,
x
n
}
{\displaystyle \lim _{p\to \infty }M_{p}(x_{1},\dots ,x_{n})=\max\{x_{1},\dots ,x_{n}\}}
maximum
Proof of power means inequality
We will prove weighted power means inequality, for the purpose of the proof we will assume without loss of generality that:
w
i
∈
(
0
;
1
]
{\displaystyle w_{i}\in (0;1]}
and
∑
i
=
1
n
w
i
=
1
{\displaystyle \sum _{i=1}^{n}w_{i}=1}
Proof for unweighted power means is easily obtained by substituting
w
i
=
1
n
{\displaystyle w_{i}={\frac {1}{n}}}
.
Equivalence of inequalities between means of opposite signs
Suppose an average between power means with exponents p and q holds:
∑
i
=
1
n
w
i
x
i
p
p
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
then:
∑
i
=
1
n
w
i
x
i
p
p
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{p}]{\sum _{i=1}^{n}{\frac {w_{i}}{x_{i}^{p}}}}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}{\frac {w_{i}}{x_{i}^{q}}}}}}
We raise both sides to the power of −1 (strictly decreasing function in positive reals):
∑
i
=
1
n
w
i
x
i
−
p
−
p
=
1
∑
i
=
1
n
w
i
1
x
i
p
p
≥
1
∑
i
=
1
n
w
i
1
x
i
q
q
=
∑
i
=
1
n
w
i
x
i
−
q
−
q
{\displaystyle {\sqrt[{-p}]{\sum _{i=1}^{n}w_{i}x_{i}^{-p}}}={\sqrt[{p}]{\frac {1}{\sum _{i=1}^{n}w_{i}{\frac {1}{x_{i}^{p}}}}}}\geq {\sqrt[{q}]{\frac {1}{\sum _{i=1}^{n}w_{i}{\frac {1}{x_{i}^{q}}}}}}={\sqrt[{-q}]{\sum _{i=1}^{n}w_{i}x_{i}^{-q}}}}
We get the inequality for means with exponents −p and −q , and we can use the same reasoning backwards, thus proving the inequalities to be equivalent, which will be used in some of the later proofs.
Geometric mean
For any q the inequality between mean with exponent q and geometric mean can be transformed in the following way:
∏
i
=
1
n
x
i
w
i
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle \prod _{i=1}^{n}x_{i}^{w_{i}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
∑
i
=
1
n
w
i
x
i
q
q
≤
∏
i
=
1
n
x
i
w
i
{\displaystyle {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}\leq \prod _{i=1}^{n}x_{i}^{w_{i}}}
(the first inequality is to be proven for positive q , and the latter otherwise)
We raise both sides to the power of q :
∏
i
=
1
n
x
i
w
i
⋅
q
≤
∑
i
=
1
n
w
i
x
i
q
{\displaystyle \prod _{i=1}^{n}x_{i}^{w_{i}\cdot q}\leq \sum _{i=1}^{n}w_{i}x_{i}^{q}}
in both cases we get the inequality between weighted arithmetic and geometric means for the sequence
x
i
q
{\displaystyle x_{i}^{q}}
, which can be proved by Jensen's inequality , making use of the fact the logarithmic function is concave:
∑
i
=
1
n
w
i
log
(
x
i
)
≤
log
(
∑
i
=
1
n
w
i
x
i
)
{\displaystyle \sum _{i=1}^{n}w_{i}\log(x_{i})\leq \log \left(\sum _{i=1}^{n}w_{i}x_{i}\right)}
log
(
∏
i
=
1
n
x
i
w
i
)
≤
log
(
∑
i
=
1
n
w
i
x
i
)
{\displaystyle \log \left(\prod _{i=1}^{n}x_{i}^{w_{i}}\right)\leq \log \left(\sum _{i=1}^{n}w_{i}x_{i}\right)}
By applying (strictly increasing) exp function to both sides we get the inequality:
∏
i
=
1
n
x
i
w
i
≤
∑
i
=
1
n
w
i
x
i
{\displaystyle \prod _{i=1}^{n}x_{i}^{w_{i}}\leq \sum _{i=1}^{n}w_{i}x_{i}}
Thus for any positive q it is true that:
∑
i
=
1
n
w
i
x
i
−
q
−
q
≤
∏
i
=
1
n
x
i
w
i
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{-q}]{\sum _{i=1}^{n}w_{i}x_{i}^{-q}}}\leq \prod _{i=1}^{n}x_{i}^{w_{i}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
thus we have proved the inequality between geometric mean and any power mean.
Geometric mean as a limit
Furthermore, we can prove that the geometric mean is the limit of power means for exponent approaching zero. Firstly, we will prove the limit:
lim
p
→
0
log
(
∑
i
=
1
n
w
i
x
i
p
)
p
=
∑
i
=
1
n
w
i
log
(
x
i
)
{\displaystyle \lim _{p\to 0}{\frac {\log \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)}{p}}=\sum _{i=1}^{n}w_{i}\log(x_{i})}
It's easy to conclude that the limits of both the numerator and the denominator are both 0, so we can use L'Hôpital's rule :
lim
p
→
0
log
(
∑
i
=
1
n
w
i
x
i
p
)
p
=
lim
p
→
0
1
∑
i
=
1
n
w
i
x
i
p
⋅
(
∑
i
=
1
n
w
i
x
i
p
)
′
=
{\displaystyle \lim _{p\to 0}{\frac {\log \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)}{p}}=\lim _{p\to 0}{\frac {1}{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\cdot \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)'=}
=
1
∑
i
=
1
n
w
i
⋅
lim
p
→
0
∑
i
=
1
n
(
w
i
⋅
log
(
x
i
)
⋅
x
i
p
)
=
∑
i
=
1
n
w
i
log
(
x
i
)
{\displaystyle ={\frac {1}{\sum _{i=1}^{n}w_{i}}}\cdot \lim _{p\to 0}\sum _{i=1}^{n}(w_{i}\cdot \log(x_{i})\cdot x_{i}^{p})=\sum _{i=1}^{n}w_{i}\log(x_{i})}
Then we make use of the exponential function 's continuity:
lim
p
→
0
∑
i
=
1
n
w
i
x
i
p
p
=
lim
p
→
0
exp
(
log
(
∑
i
=
1
n
w
i
x
i
p
)
p
)
=
exp
(
lim
p
→
0
log
(
∑
i
=
1
n
w
i
x
i
p
)
p
)
=
exp
(
∑
i
=
1
n
w
i
log
(
x
i
)
)
=
∏
i
=
1
n
x
i
w
i
{\displaystyle {\begin{aligned}&\lim _{p\to 0}{\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}=\lim _{p\to 0}\exp \left({\frac {\log \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)}{p}}\right)\\&=\exp \left(\lim _{p\to 0}{\frac {\log \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)}{p}}\right)=\exp \left(\sum _{i=1}^{n}w_{i}\log(x_{i})\right)=\prod _{i=1}^{n}x_{i}^{w_{i}}\end{aligned}}}
which was to be proven.
Inequality between any two power means
We are to prove that for any p < q the following inequality holds:
∑
i
=
1
n
w
i
x
i
p
p
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
if p is negative, and q is positive, the inequality is equivalent to the one proved above:
∑
i
=
1
n
w
i
x
i
p
p
≤
∏
i
=
1
n
x
i
w
i
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\leq \prod _{i=1}^{n}x_{i}^{w_{i}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
The proof for positive p and q is as follows:
Define the following function:
f
:
R
+
→
R
+
,
{\displaystyle f:{\mathbb {R} _{+}}\rightarrow {\mathbb {R} _{+}},}
f
(
x
)
=
x
q
p
{\displaystyle f(x)=x^{\frac {q}{p}}}
. f is a power function, so it does have a second derivative:
f
″
(
x
)
=
(
q
p
)
(
q
p
−
1
)
x
q
p
−
2
,
{\displaystyle f''(x)=\left({\frac {q}{p}}\right)\left({\frac {q}{p}}-1\right)x^{{\frac {q}{p}}-2},}
which is strictly positive within the domain of f , since q > p , so we know f is convex.
Using this, and the Jensen's inequality we get:
f
(
∑
i
=
1
n
w
i
x
i
p
)
≤
∑
i
=
1
n
w
i
f
(
x
i
p
)
{\displaystyle f\left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)\leq \sum _{i=1}^{n}w_{i}f(x_{i}^{p})}
∑
i
=
1
n
w
i
x
i
p
p
q
≤
∑
i
=
1
n
w
i
x
i
q
{\displaystyle {\sqrt[{\frac {p}{q}}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\leq \sum _{i=1}^{n}w_{i}x_{i}^{q}}
after raising both side to the power of 1/q (an increasing function, since 1/q is positive) we get the inequality which was to be proven:
∑
i
=
1
n
w
i
x
i
p
p
≤
∑
i
=
1
n
w
i
x
i
q
q
{\displaystyle {\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}\leq {\sqrt[{q}]{\sum _{i=1}^{n}w_{i}x_{i}^{q}}}}
Using the previously shown equivalence we can prove the inequality for negative p and q by substituting them with, respectively, −q and −p , QED.
Minimum and maximum
Minimum and maximum are the limits of power means at, respectively,
−
∞
{\displaystyle -\infty }
and
+
∞
{\displaystyle +\infty }
. The proof is as follows:
Suppose without loss of generality that x 1 is the largest, while xn is the smallest of xi .
First, using the squeeze theorem we will prove that:
lim
p
→
∞
(
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
x
1
p
)
)
=
0
{\displaystyle \lim _{p\to \infty }\left({\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{1}^{p}}}\right)\right)=0}
It suffices to notice that for positive p the inequalities hold:
1
p
ln
(
w
1
)
=
1
p
ln
(
w
1
x
1
p
x
1
p
)
≤
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
x
1
p
)
≤
1
p
ln
(
∑
i
=
1
n
w
i
x
1
p
x
1
p
)
=
ln
(
1
)
=
0
{\displaystyle {\frac {1}{p}}\ln(w_{1})={\frac {1}{p}}\ln \left({\frac {w_{1}x_{1}^{p}}{x_{1}^{p}}}\right)\leq {\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{1}^{p}}}\right)\leq {\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{1}^{p}}{x_{1}^{p}}}\right)=\ln(1)=0}
Then, making use of the limit:
lim
p
→
∞
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
)
=
lim
p
→
∞
1
p
ln
(
x
1
p
⋅
∑
i
=
1
n
w
i
x
i
p
x
1
p
)
=
lim
p
→
∞
(
ln
(
x
1
p
)
p
)
+
lim
p
→
∞
(
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
x
1
p
)
)
=
ln
(
x
1
)
+
0
=
ln
(
x
1
)
{\displaystyle \lim _{p\to \infty }{\frac {1}{p}}\ln \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)=\lim _{p\to \infty }{\frac {1}{p}}\ln \left(x_{1}^{p}\cdot {\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{1}^{p}}}\right)=\lim _{p\to \infty }\left({\frac {\ln(x_{1}^{p})}{p}}\right)+\lim _{p\to \infty }\left({\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{1}^{p}}}\right)\right)=\ln(x_{1})+0=\ln(x_{1})}
and finally, we use the fact that the exponential function is continuous:
lim
p
→
∞
∑
i
=
1
n
w
i
x
i
p
p
=
lim
p
→
∞
exp
(
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
)
)
=
exp
(
lim
p
→
∞
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
)
)
=
x
1
{\displaystyle \lim _{p\to \infty }{\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}=\lim _{p\to \infty }\exp \left({\frac {1}{p}}\ln \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)\right)=\exp \left(\lim _{p\to \infty }{\frac {1}{p}}\ln \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)\right)=x_{1}}
Similarly, for negative p :
lim
p
→
−
∞
(
1
p
ln
(
∑
i
=
1
n
w
i
x
n
p
x
n
p
)
)
=
0
{\displaystyle \lim _{p\to -\infty }\left({\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{n}^{p}}{x_{n}^{p}}}\right)\right)=0}
since (for p < 0):
1
p
ln
(
w
n
)
=
1
p
ln
(
w
n
x
n
p
x
n
p
)
≥
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
x
n
p
)
≥
1
p
ln
(
∑
i
=
1
n
w
i
x
n
p
x
n
p
)
=
ln
(
1
)
=
0
{\displaystyle {\frac {1}{p}}\ln(w_{n})={\frac {1}{p}}\ln \left({\frac {w_{n}x_{n}^{p}}{x_{n}^{p}}}\right)\geq {\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{n}^{p}}}\right)\geq {\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{n}^{p}}{x_{n}^{p}}}\right)=\ln(1)=0}
Thus:
lim
p
→
−
∞
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
)
=
lim
p
→
−
∞
(
ln
(
x
n
p
)
p
)
+
lim
p
→
−
∞
(
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
x
n
p
)
)
=
ln
(
x
n
)
{\displaystyle \lim _{p\to -\infty }{\frac {1}{p}}\ln \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)=\lim _{p\to -\infty }\left({\frac {\ln(x_{n}^{p})}{p}}\right)+\lim _{p\to -\infty }\left({\frac {1}{p}}\ln \left({\frac {\sum _{i=1}^{n}w_{i}x_{i}^{p}}{x_{n}^{p}}}\right)\right)=\ln(x_{n})}
and again, by continuity of the exp function:
lim
p
→
−
∞
∑
i
=
1
n
w
i
x
i
p
p
=
exp
(
lim
p
→
−
∞
1
p
ln
(
∑
i
=
1
n
w
i
x
i
p
)
)
=
x
n
{\displaystyle \lim _{p\to -\infty }{\sqrt[{p}]{\sum _{i=1}^{n}w_{i}x_{i}^{p}}}=\exp \left(\lim _{p\to -\infty }{\frac {1}{p}}\ln \left(\sum _{i=1}^{n}w_{i}x_{i}^{p}\right)\right)=x_{n}}
Generalized
f
{\displaystyle f}
-mean
The power mean could be generalized further to the generalized
f
{\displaystyle f}
-mean :
M
f
(
x
1
,
…
,
x
n
)
=
f
−
1
(
1
n
⋅
∑
i
=
1
n
f
(
x
i
)
)
{\displaystyle M_{f}(x_{1},\dots ,x_{n})=f^{-1}\left({{\frac {1}{n}}\cdot \sum _{i=1}^{n}{f(x_{i})}}\right)}
which covers e.g. the geometric mean without using a limit. The power mean is obtained for
f
(
x
)
=
x
p
{\displaystyle f\left(x\right)=x^{p}}
.
Applications
Signal processing
A power mean serves a non-linear moving average which is shifted towards small signal values for small
p
{\displaystyle p}
and emphasizes big signal values for big
p
{\displaystyle p}
. Given an efficient implementation of a moving arithmetic mean called smooth
you can implement a moving power mean according to the following Haskell code.
powerSmooth :: Floating a => ([ a ] -> [ a ]) -> a -> [ a ] -> [ a ]
powerSmooth smooth p = map ( ** recip p ) . smooth . map ( ** p )
See also
External links