I have a definite integral defined by

$\displaystyle T\left(G\left(g\right)\right)=\int_{g_{1}}^{g_{2}} G(g)\mathrm{d}g$

where $\displaystyle G$ is a continuous function of a variable $\displaystyle g$, and $\displaystyle g_{1}$ and $\displaystyle g_{2}$ are known numbers. I want to minimize $\displaystyle T\left(G\left(g\right)\right)$, that is I want to find a continuous function $\displaystyle G=f\left(g\right)$ that makes $\displaystyle T\left(G\left(g\right)\right) $ minimum. Ideally I would differentiate it and equate to zero, but because $\displaystyle T\left(G\left(g\right)\right)$ is too complicated to be obtained and then differentiated analytically, I would like to know if there is a numeric technique or any other technique by which this problem can be solved.