function mgf( t, p ) {
	var et;
	var q;
	if ( isnan( t ) || !isProbability( p ) ) {
		return NaN;
	}
	q = 1.0 - p;
	if ( t >= -ln( q ) ) {
		return NaN;
	}
	et = exp( t );
	return ( p * et ) / ( 1.0 - (q * et) );
}
Evaluates the moment-generating function (MGF) for a geometric distribution with success probability `p` at a value `t`.

@param {number} t - input value
@param {Probability} p - success probability
@returns {number} evaluated MGF

@example
var y = mgf( 0.2, 0.5 );
// returns ~1.569

@example
var y = mgf( 0.4, 0.5 );
// returns ~2.936

@example
// Case: t >= -ln(1-p)
var y = mgf( 0.8, 0.5 );
// returns NaN

@example
var y = mgf( NaN, 0.0 );
// returns NaN

@example
var y = mgf( 0.0, NaN );
// returns NaN

@example
var y = mgf( -2.0, -1.0 );
// returns NaN

@example
var y = mgf( 0.2, 2.0 );
// returns NaN