# Differentiation wrt integral boundaries

#### nickstern

##### New member
Hi:

Let $f,g$ and $h$ be continuous real valued function with domain $X \times Y$ where $X$ and $Y$ are compact sets.
Let me define the set
$S(x) = \{ y : h(y,x) \geq 0 \}$
and
$\bar{S}(x) = \{ y : h(y,x) \leq 0 \}$

Also for any $(x,y) \in X \times Y$ such that $h(y,x)=0$, it holds $f(y,x)=g(y,x)$

Let the function $m$ be defined as:
\begin{equation*}
m(x) = \int_{y \in S(x)} f(y,x) dy + \int_{y \in \bar{S}(x)} g(y,x) dy
\end{equation*}

I can differentiate the term inside the integral if $f$ and $g$ and their partial derivatives are continuous in $x$ and $y$

What I do not know is the assumptions required on $h$ to have $m$ differentiable.
My intuition is that since at every point where $h(y,x)=0, f(y,x)=g(y,x)$ differentiation with respect to the limits of the integral is not a problem but I want to make the argument formal.

Any help would be much appreciated!!! Thanks!!!!

Nick