Values of a for which equation $\log_ax = \lvert x+1 \rvert + \lvert x-5 \rvert$ has a unique solution \begin{equation*} 
\log_ax = \lvert x+1 \rvert + \lvert x-5 \rvert.
\end{equation*}
I don't even know how to approach this one, any hints would be amazing. 
I tried separating into two cases, where $0<x<5$ and $x>5$. The first pretty much limits a to every positive number as far as I have seen, the latter I don't know how to solve.
Answer is supposed to be
$(0,1)$ and $5^{\frac 16}$
 A: For $0< x <5$,
$$
\log_ax = x+1-x+5=6
$$
So,
$$
a=\sqrt[6]{x} 
$$
Therefore,
$$
0<a<5^\dfrac{1}{6}\tag{1}
$$
For $x>5$,
$$
\log_ax = x+1+x-5=2x-4 
$$
$$
\log_ax=2x-4
$$
$$
a=\sqrt[2x-4]{x}
$$
Using graph,
$$
1<a<5^\dfrac{1}{6}\tag{2}
$$
At $x=5$,
$$
\log_a5 = 1+5=6
$$
Therefore,
$$
a=5^{\frac 16}
$$
From equation 1 and 2, $a=5^{\frac 16}$ and $0<a<1$.
A: Hint: Plot the expression $|x+1|+|x-5|$.  You will see that for $x \leq -1$, it is a line with slope $-2$; for $-1 \leq x \leq 5$, it is a horizontal line at $y = 6$; for $x \geq 5$, it is a line with slope $2$.  It looks a bit like a playground swing.
For any given $a$, the locations at which $\log_a x = |x+1|+|x-5|$ are the places where the graph of $\log_a x$ intersects the "playground swing" plot.  Now consider that $\log_a x$ is an increasing function of $x$ for any $a$.  For most such $a$, those two plots will intersect in either zero points, or two points.  But for one value of $a$, the increasing $\log_a x$ function will intersect the  "playground swing" in only one point.  What point $(x^*, y^*)$ would that be?  Figure that out, and then you can solve for $a$ using
$$
a^{y^*} = x^*
$$
which yields
$$
a = (x^*)^{(1/y^*)}
$$
A: The graph of the function has the shape of a truncated V, being constantly equal to 6 on the interval [-1, 5] and greater than 6 elsewhere.  This is a convex function and so is (in the opposite direction) the logarithm of base a (positive and distinct of 1). Hence in order to have a unique solution,  $log_ax$ must touch tangentially f at the point (5, 6) or  cuts f to a single point. Then, by convexity, the possible values of a are  positive and less than 1.
The point of tangency is given by $log_a5 = 6$ hence $a=\sqrt[6]5$ = 1.307660 and for greater values of a there are no common points. On the other hand if a > 1 and $log_ax$  cuts f, there are two points (by convexity and because the line to the right side increase more than the log). The other possible values, 0 < a < 1, have the positive axis OY as asymptote given then a unique point of ordinate 6. 
