Graphing Functions Algebra Suppose $f(x),g(x),h(x)$ are all linear functions, and $j(x)$ and $k(x)$ are defined by $$j(x) = \max\{f(x),g(x),h(x)\},$$ $$k(x) = \min\{f(x),g(x),h(x)\}.$$ This means that, for each $x$, we define $j(x)$ to be equal to either $f(x),$ $g(x),$ or $h(x),$ whichever is greatest; similarly, $k(x)$ is the least of these three values.
Shown below is the graph of $y=j(x)$ for $-3.5\le x\le 3.5$.
Let $\ell$ be the length of the graph of $y=k(x)$ for $-3.5\le x\le 3.5$. What is the value of $\ell^2$?

Since the function $j(x)$ is made up of 3 parts. I first tried to find the equations of each of the lines. The horizontal line is just $j(x)=2  [-2\le{x}\le{2}]$. The other two lines have almost the same equation - the only thing that differs is their slope. I used point-slope form to find that the equation of the left-most line is $j(x)=-2x-2  [-3.5\le{x}\le{-2}]$, and the equation of the right-most line is $j(x)=2x-2 [2\le{x}\le{3.5}]$. Therefore, the slopes of the two lines, respectively, are $-2$ and $2$.
Then, I tried finding the total length of the function $j(x)$. I drew a perpendicular line from the top point of the right-most function until it met the line $y=2$. The distance between the point where it meets and the red dot is $1.5$. Since the slope is $2$, the change in $y$ goes up by $(1.5)(2)=3$. The same is true with the left-most function.  Then, I used the Pythagorean theorem, $\sqrt{1.5^2+3^2}$, to find the lengths of the two slanted sides. I got $\sqrt{11.25}$. So, the total length is $4+2\sqrt{11.25}$.
However, I'm don't know how to find the relationship between $j(x)$ and $k(x)$ (aka how the maximum and minimum are related).
 A: 
Since the functions $f(x),g(x),h(x)$ are linear, every interval that $j(x)$ maps to a line is in the domain of one of the linear functions.
If we extend the lines corresponding to the $3$ functions, (and choose the function with the smallest value for each $x$) we can see that $k(x)$, from left to right, is the rightmost function for $j(x)$ upto its intersection point with the leftmost line of $j(x)$ and then the leftmost function of $j(x)$.
The left and right functions are:
\begin{eqnarray}
L_1&=&-2x-2\\
L_2&=&2x-2\\
L_1&\overset{\tiny \text{set}}{=}&L_2\\
x&=&0\\
L_1(0)&=&L_2(0)=-2\\
L_1(3.5)&=&-9\\
L_2(3.5)&=&5\\
\end{eqnarray}
Now we can calculate $\ell$ using Pythagoras' theorem:
\begin{eqnarray}
\ell&=&\sqrt{3.5^2+(-2-(-9))^2}+\sqrt{3.5^2+(-2-5)^2}\\
&=&2\sqrt{3.5^2+7^2}\\
\ell^2&=&4(3.5^2+7^2)\\
&=&(2\cdot 3.5)^2+4\cdot 7^2\\
&=&5\cdot 7^2\\
&=&5\cdot 49\\
&=&245\\
\end{eqnarray}
A: Up to what i know, there is no relationship between the length of $j(x)$ and $k(x)$. Below there is the solution I came up to solve this problem:
The first thing we have to do is to identify $f$, $g$ and $h$ individually (order doesn't matter), leading to:
$f\left(x\right)=-2x-2$
$g\left(x\right)=2$
$h\left(x\right)=2x-2$
Now we have to find the intersection of these functions to determine when one becomes smaller than the other. We do that by equalizing every pair of functions:
$f\left(x\right)=g\left(x\right)\Rightarrow-2x-2=2\Rightarrow x=-2,y=2$
$f\left(x\right)=h\left(x\right)\Rightarrow-2x-2=2x-2\Rightarrow x=0,y=-2$
$g\left(x\right)=h\left(x\right)\Rightarrow2=2x-2\Rightarrow x=2,y=2$
Now that we have the intersection points, we can study the sections of the real line where the order of the functions is the same:
for all $x\in\space]-\infty,-2[$, the relation $f\left(x\right)\gt g\left(x\right)\gt h\left(x\right)$ stands
for $x=2$, the relation $f\left(x\right)=g\left(x\right)\gt h\left(x\right)$ stands
for all $x\in\space]-2,0[$, the relation $g\left(x\right)\gt f\left(x\right)\gt h\left(x\right)$ stands
for $x=0$, the relation $g\left(x\right)\gt f\left(x\right)=h\left(x\right)$ stands
for all $x\in\space]0,2[$, the relation $g\left(x\right)\gt h\left(x\right)\gt f\left(x\right)$ stands
for $x=2$, the relation $g\left(x\right)=h\left(x\right)\gt f\left(x\right)$ stands
for all $x\in\space]2,\infty[$, the relation $h\left(x\right)\gt g\left(x\right)\gt f\left(x\right)$ stands
Taking the minimum out of these, you get
$k\left(x\right)=\begin{cases}2x-2&&\text{if }x\le0\\-2x-2&&\text{if }x\gt0\end{cases}$
which looks like this:

From $\left(-3.5,-9\right)$ to $\left(0,-2\right)$, the length of $k(x)$ is $\frac{7\sqrt{5}}{2}$, and from $\left(0,-2\right)$ to $\left(3.5,-9\right)$, the length is the same, therefore, the square of the length of $k(x)$ in the interval $[-3.5,3.5]$ is $\ell^2=\left(2\frac{7\sqrt{5}}{2}\right)^2=245$
