We know that every convex function $g:\mathbf{R}\rightarrow\mathbf{R}$ is locally Lipschitz, and therefore $g$ is differentiable almost everywhere (Alexandrov's theorem says that $g$ is in fact twice differentiable almost everywhere and so $g$ is ${\rm C}^1$ almost everywhere). For $n=1,2$ we define the lower (upper, resp.) smooth convex envelope of $g$ as follows:
$L_n(g):={\rm sup}\{h:\mathbf{R}\rightarrow\mathbf{R}: h\leq g,\; h\;\hbox{is convex},\;h\in{\rm C}^n(\mathbf{R})\}$
($U_n(g):={\rm inf}\{h:\mathbf{R}\rightarrow\mathbf{R}: h\geq g,\; h\;\hbox{is convex},\;h\in{\rm C}^n(\mathbf{R})\}$, resp.).
My question is: can we formulate necessary and/or sufficient conditions on $g$ which yield the following conclusions:
(1) $L_1(g)$ exists ($U_1(g)$ exists, resp.), meaning that there exists at least one lower (upper, resp.) function ${\rm C}^1$-smooth function $h$,
(2) $L_1(g)=g$ ($U_1(g)=g$, resp.),
(3) $L_2(g)$ exists ($U_2(g)$ exists, resp.), meaning that there exists at least one lower (upper, resp.) function ${\rm C}^2$-smooth function $h$,
(4) $L_2(g)=g$ ($U_2(g)=g$, resp.).
Ofcourse, we can extend the question to the case $h\in{\rm C}^n(\mathbf{R})$ for every $n\in\mathbf{N}$, or even to the case when $h$ is analytic functon on $\mathbf{R}$, but for my purposes it is enough to consider the case $n=1$ and $n=2$. If classical smoothness can not be considered, I would settle for weakly differentiable functions $h\in {\rm W}^{2,p}_{loc}(\mathbf{R})$ for some $p\geq 1$, but I have the feeling that this could be much harder question. One possibility of extra assumption on $g$ is, for instance, that $g$ is differentiable (or twice differenntiable) except on at most countable points $x\in\mathbf{R}$. Remark. Corollary 7.2.4 in Garling: A Course in Mathematical Analysis, Volume 1, provides that one-sided derivatives of convex function $g$, denoted by $g'(x-)$ and $g'(x+)$, exist everwhere, except on at most countably many points $x\in\mathbf{R}$. Here
A convex function is differentiable at all but countably many points
we have an improvement of the corollary from Garling's book, which says that every convex function is differentiable except at most countably many points, but the question still stands.