# Homework 3 Problems

```{note}
This homework is due **Friday, March 13, 11:59pm** on Crowdmark. No credit will be given after Sunday, March 15, 11:59pm.  
```

```{Note}
You may use the following atoms when answering Questions 2 and 4. Otherwise, any assertion of convexity must follow from one of the theorems we studied in class.

| Function | Property |
|----------|----------|
| $x^m$ | convex for $m=2,4$ |
| $x^3$ | convex and non-decreasing for $x \geq 0$ |
| $\lVert\mathbf{x}\rVert$ | convex for any norm $\lVert\cdot\rVert$ |
| $e^{x}$ | convex, non-decreasing |
```

## Instructions

Problems are worth points as noted. You may receive partial credit for correct work leading to a solution. Note you will upload solutions for each question individually to Crowdmark. This can either be handwritten or typed, but make sure your work is clear and legible.

You will also enter information about what resources you used to complete the homework (e.g., textbook, lecture notes, online resources, generative AI, study groups, etc.) when you upload your solutions to Crowdmark.

---

## Problem 1

Show (either geometrically or analytically) why each of the following sets is convex or not convex. You may use graphing software to help you, however, for a quiz or exam, you should be able to do these without graphing software.

(a) $S= \big\{(x_1,x_2) \in \mathbb{R}^2:  x_2 \geq 4x_1^3 \big\}$

(b) $S= \big\{(x_1,x_2,x_3) \in \mathbb{R}^3: x_2\geq |x_1| + |x_3| \big\}$

(c) $S= \big\{(x_1,x_2) \in \mathbb{R}^2: x_2 \geq e^{x_1} \big\}$

(d) $S= \big\{(x_1,x_2,x_3,x_4) \in \mathbb{R}^4: \lVert\mathbf{x}-(1,2,3,4)\rVert_2\leq 1 \big\}$

(e) $S= \big\{(x_1,x_2,x_3,x_4) \in \mathbb{R}^4: \lVert\mathbf{x}-(1,2,3,4)\rVert_2=1 \big\}$

---

## Problem 2

Show that the following functions are convex over the specified set:

(a) $f(x)= (e^{x}+1)^3$ with $x \in \mathbb{R}$.

(b) $f(\mathbf{x})= 2e^{-x_1}+\frac{1}{4}x_2^4$ with $\mathbf{x} = (x_1,x_2) \in \mathbb{R}^2$.

(c) $f(\mathbf{x})= x_1x_2+x_1^2+ x_2^2$ with $\mathbf{x} = (x_1,x_2) \in \mathbb{R}^2$.

(d) $f(x)= \max\{x^4,e^{5x^2+5}\}$ with $x \in \mathbb{R}$.

---

## Problem 3

For each of the functions in Question 2, use CVXPY to determine if the function is convex, concave, quasiconvex, etc. Make a note of any discrepancies between your analytical answer and CVXPY's answer and explain what is happening to cause the difference.

---

## Problem 4

Why is $f(\mathbf{x})= x_1^2-x_2^4$ not convex, with $\mathbf{x} = (x_1,x_2) \in \mathbb{R}^2$?
