L1-regularized quadratic function: Difference between revisions

From Calculus
Line 76: Line 76:
| <math>\frac{-(b - \lambda)}{2a} > 0 > \frac{-(b + \lambda)}{2a}</math> || decreasing on <math>(-\infty,0]</math>.<br>increasing on <math>[0,\infty)</math>.
| <math>\frac{-(b - \lambda)}{2a} > 0 > \frac{-(b + \lambda)}{2a}</math> || decreasing on <math>(-\infty,0]</math>.<br>increasing on <math>[0,\infty)</math>.
|-
|-
| <math>\frac{-(b + \lambda)}{2a} > 0</math> || decreasing on <math>\left(-infty,\frac{-(b + \lambda)}{2a}\right]</math>: note that the derivative is undefined at 0, but the function is continuous and increasing on both the left and right.<br>increasing on <math>\left[\frac{-(b + \lambda)}{2a},\infty\right)</math>  
| <math>\frac{-(b + \lambda)}{2a} > 0</math> || decreasing on <math>\left(-\infty,\frac{-(b + \lambda)}{2a}\right]</math>: note that the derivative is undefined at 0, but the function is continuous and increasing on both the left and right.<br>increasing on <math>\left[\frac{-(b + \lambda)}{2a},\infty\right)</math>  
|}
|}
===Local extreme values===
We include the three cases below. Recall the assumption that <math>a > 0, \lambda > 0</math>. Note that the function is concave up (i.e., a convex function) and therefore has a unique point of local minimum that is also a point of absolute minimum.
{| class="sortable" border="1"
! Case !! Point of unique local minimum that is also a point of absolute minimum !! Local minimum value (also the absolute minimum value)
|-
| <math>0 > \frac{-(b - \lambda)}{2a}</math> || <math>\frac{-(b - \lambda)}{2a}</math> || <math>c - \frac{(b - \lambda)^2}{4a}</math>
|-
| <math>\frac{-(b - \lambda)}{2a} > 0 > \frac{-(b + \lambda)}{2a}</math> || 0 || <math>c</math>
|-
| <math>\frac{-(b + \lambda)}{2a} > 0</math> || <math>\frac{-(b + \lambda)}{2a}</math> || <math>c - \frac{(b + \lambda)^2}{4a}</math>
|}
==Intervals of concave up and concave down===
At all points other than 0, the function is twice differentiable and has positive second derivative <math>2a</math>. At zero, the first derivative jumps upward from <math>b - \lambda</math> to <math>b + \lambda</math>. Therefore, the first derivative is increasing throughout the domain.

Revision as of 17:48, 11 May 2014

Definition

A L1-regularized quadratic function of one variable is a function of the form:

f(x):=ax2+bx+c+λ|x|

where a,b,c,λR,a>0,λ>0. Note that we assume a>0 for some of our case analysis, because we consider such functions in the context of modifying the minimization problem for quadratic functions.

The function has a piecewise quadratic function definition:

f(x):={ax2+(b+λ)x+c,x0ax2+(bλ)x+c,x<0

Differentiation

First derivative

The expression for the first derivative is obtained from the piecewise definition of the function, using the differentiation rule for piecewise definition by interval. We obtain the expression:

f(x)={2ax+(b+λ),x>02ax+(bλ),x<0

The first derivative is undefined at x=0. At this point, the left-hand derivative is bλ and the right-hand derivative is b+λ.

The derivative function is therefore a piecewise linear function with a jump discontinuity at zero.

Second derivative

The second derivative is defined as:

f(x)=2a,x0

The second derivative is undefined at zero.

Points and intervals of interest

Critical points

As noted above, we have the following expression for the derivative:

f(x)={2ax+(b+λ),x>02ax+(bλ),x<0

We have at least one and at most three critical points. The three candidates are discussed below.

Critical point Case that it occurs Description of critical point
0 Always The function is not differentiable at the point. The left-hand derivative is bλ and the right-hand derivative is b+λ.
(b+λ)2a The case that (b+λ)2a>0 It is the unique critical point for the quadratic piece for x>0. It occurs if and only if the critical point for that piece happens to fall within that piece definition.
(bλ)2a The case that (bλ)2a<0 It is the unique critical point for the quadratic piece for x<0. It occurs if and only if the critical point for that piece happens to fall within that piece definition.

The second and third critical point type cannot both occur. This can be seen arithmetically, since subtracting the second condition from the first contradicts the assumption pair λ>0,a>0. It also follows from the fact that the graph of the function is concave up (more on this later).

Here are the combined cases:

Case Set of critical points
0>(bλ)2a {(bλ)2a,0}
(bλ)2a>0>(b+λ)2a {0}
(b+λ)2a>0 {0,(b+λ)2a}

Intervals of increase and decrease

We include the three cases below. Recall the assumption that a>0,λ>0:

Case Set of critical points
0>(bλ)2a decreasing on (,(bλ)2a]
increasing on [(bλ)2a,): note that the derivative is undefined at 0, but the function is continuous and increasing on both the left and right.
(bλ)2a>0>(b+λ)2a decreasing on (,0].
increasing on [0,).
(b+λ)2a>0 decreasing on (,(b+λ)2a]: note that the derivative is undefined at 0, but the function is continuous and increasing on both the left and right.
increasing on [(b+λ)2a,)

Local extreme values

We include the three cases below. Recall the assumption that a>0,λ>0. Note that the function is concave up (i.e., a convex function) and therefore has a unique point of local minimum that is also a point of absolute minimum.

Case Point of unique local minimum that is also a point of absolute minimum Local minimum value (also the absolute minimum value)
0>(bλ)2a (bλ)2a c(bλ)24a
(bλ)2a>0>(b+λ)2a 0 c
(b+λ)2a>0 (b+λ)2a c(b+λ)24a

Intervals of concave up and concave down=

At all points other than 0, the function is twice differentiable and has positive second derivative 2a. At zero, the first derivative jumps upward from bλ to b+λ. Therefore, the first derivative is increasing throughout the domain.