- #1
PhDeezNutz
- 796
- 553
- Homework Statement
- Given ##f: \mathbb{R}^n \rightarrow \mathbb{R}## where ##f\left(\vec{x}\right) = \| \vec{x} \|^2## prove that ##f## is convex
- Relevant Equations
- Definition of convex function
A function ##f: \mathcal{C} \subset \mathbb{R}^n \rightarrow \mathbb{R}## is convex on convex set ##\mathcal{C}## if ## \forall \vec{x}, \vec{y} \in \mathcal{C}##
##f\left(\left( 1 - \lambda \right) \vec{x} + \lambda \vec{y} \right) \leq \left( 1 - \lambda \right) f \left(\vec{x} \right) + \lambda f \left( y \right)##
where ##\lambda \in \left[ 0,1 \right]##
Also the triangle inequality
## \left\| \vec{a} + \vec{b} \right\|^2 \leq \left\| \vec{a} \right\|^2 + \left\| \vec{b} \right\|^2##
Part 1
##\left\| \vec{y} \right\|^2 \leq \left\| \vec{y} \right\|^2## and since ##\lambda \in \left[ 0,1 \right] \Rightarrow \lambda^2 \leq \lambda##
So
##\lambda^2 \left\| \vec{y} \right\|^2 \leq \lambda \left\| \vec{y} \right\|^2 ##
Part 2
##\left\| \vec{x} \right\|^2 \leq \left\| \vec{x} \right\|^2## and since ##\lambda \in \left[ 0,1 \right] ## we have ##1 - \lambda \leq 1 \Rightarrow \left( 1 - \lambda \right)^2 \leq \left( 1 - \lambda \right)##
So
##\left( 1 - \lambda \right)^2 \left\| \vec{x} \right\|^2 \leq \left(1 - \lambda \right) \left\| \vec{x} \right\|^2##
Part 3 (adding Parts 1 and 2)
##\left( 1 -\lambda \right)^2 \left\| \vec{x} \right\|^2 + \lambda^2 \left\| \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##
Part 4 (Invoking the triangle inequality)
##\left\| \left(1 - \lambda \right) \vec{x} + \lambda \vec{y} \right\|^2 \leq \left( 1 -\lambda \right)^2 \left\| \vec{x} \right\|^2 + \lambda^2 \left\| \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##Taking the first and last part of the above inequality we have
##\left\| \left(1 - \lambda \right) \vec{x} + \lambda \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##
Therefore ##f\left(\vec{x}\right) = \left\| \vec{x} \right\|^2## is convex
##\left\| \vec{y} \right\|^2 \leq \left\| \vec{y} \right\|^2## and since ##\lambda \in \left[ 0,1 \right] \Rightarrow \lambda^2 \leq \lambda##
So
##\lambda^2 \left\| \vec{y} \right\|^2 \leq \lambda \left\| \vec{y} \right\|^2 ##
Part 2
##\left\| \vec{x} \right\|^2 \leq \left\| \vec{x} \right\|^2## and since ##\lambda \in \left[ 0,1 \right] ## we have ##1 - \lambda \leq 1 \Rightarrow \left( 1 - \lambda \right)^2 \leq \left( 1 - \lambda \right)##
So
##\left( 1 - \lambda \right)^2 \left\| \vec{x} \right\|^2 \leq \left(1 - \lambda \right) \left\| \vec{x} \right\|^2##
Part 3 (adding Parts 1 and 2)
##\left( 1 -\lambda \right)^2 \left\| \vec{x} \right\|^2 + \lambda^2 \left\| \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##
Part 4 (Invoking the triangle inequality)
##\left\| \left(1 - \lambda \right) \vec{x} + \lambda \vec{y} \right\|^2 \leq \left( 1 -\lambda \right)^2 \left\| \vec{x} \right\|^2 + \lambda^2 \left\| \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##Taking the first and last part of the above inequality we have
##\left\| \left(1 - \lambda \right) \vec{x} + \lambda \vec{y} \right\|^2 \leq \left( 1 - \lambda \right) \left\| \vec{x} \right\|^2 + \lambda \left\| \vec{y} \right\|^2##
Therefore ##f\left(\vec{x}\right) = \left\| \vec{x} \right\|^2## is convex