We consider variational problems in which the slope of the admissible
curves is not necessarily bounded, so that they admit discontinuous so
lutions. A problem is first reformulated as one consisting of the mini
mization of an integral in a space of functions satisfying a set of in
tegral equalities; this is then transfered to a nonstandard framework,
in which Loeb measures rake the place of the functions and a near-min
imizer can always be found. This is mapped back to the standard world
by means of the standard part map; its image is a minimizer, so that t
he optimization is global. The minimizer is shown to be the solution o
f an infinite dimensional linear program and by well-proven approximat
ion procedures a finite dimensional linear program is found by means o
f which nearly-optimal curves can be constructed for the original prob
lem. A numerical example is given.