# Consider the function f(\mu)=\sum_{i=1}(x_{i}-\mu)^{2}, where x_[i}=i,\ i=1,\ 2,\ \cdots,\ n What is the

Consider the function
$f\left(\mu \right)=\sum _{i=1}{\left({x}_{i}-\mu \right)}^{2},$ where

What is the first and second derivative os $f\left(\mu \right)$?
You can still ask an expert for help

• Questions are typically answered in as fast as 30 minutes

Solve your problem for the price of one coffee

• Math expert for every subject
• Pay only if we can solve it

Janet Young
Step 1
$\frac{d}{d\mu }f\left(\mu \right)=-2\sum _{i=1}^{n}\left({x}_{1}-\mu \right)=-2\sum _{i=1}^{n}{x}_{i}+2n\mu$
$\frac{{d}^{2}}{d{\mu }^{2}}f\left(\mu \right)=2n$
In the 1st step on line 1, the chain rule is applied. The term within the brackets is differentiated, producing a -1.
Then the bracket itself is differentiated, producing the 2 at the front. The 2nd step on line 1 involves no differentiation. Instead, the bracket is split into two terms.
The second term has an n because it is simply the summation from $i=1$ to $i=n$ of a constant.
The summation of a constant is equal to n multiplied by the constant. Then for the second line, there are no extra rules.
The first term becomes 0 because it's a constant and the second term loses $\mu$.
###### Not exactly what you’re looking for?
accimaroyalde
Step 1
Adding an answer here to further clarify the other ones which are simply answers without steps. To get the first derivative, this can be re-written as:
$\frac{d}{d\mu }sun{\left(x-\mu \right)}^{2}$
$=\sum \frac{d}{d\mu }{\left(x-\mu \right)}^{2}$
After that its
###### Not exactly what you’re looking for?
nick1337

Step 1
Here we have one function $\left({x}_{i}-\mu \right)$ that is part of a larger function in that it is raised to a power of 2, $\left(\mu -i{\right)}^{2}$
According to the extended power rule, we multiply the derivative of the outer function
$\left(\mu -i{\right)}^{2}x$
the derivative of the inner function $\left({x}_{i}-\mu \right)$
The derivative of the outer function brings the 2 down in front as
$2×\left({x}_{i}-\mu \right)$
and the derivative of the inner function
$\left({x}_{i}-\mu \right)$ is -1.
So the -2 comes from multiplying the two derivatives according to the extend power rule:
$2×\left({x}_{i}-\mu \right)×-1=-2\left({x}_{i}-\mu \right)$
${f}^{\prime }\left(\mu \right)=-2\sum _{i=1}^{n}\left({x}_{i}-\mu \right)$ and ${f}^{″}\left(\mu \right)=2n$

###### Not exactly what you’re looking for?

• Questions are typically answered in as fast as 30 minutes

Solve your problem for the price of one coffee