def moment_function(magnitude):
    """
    Get moment (in Nm) from magnitude using Hanks & Kanamori (1979)

    :param float (or numpy.ndarray) magnitude:
        Magnitude of event
    :returns:
        Seismic Moment in Nm
    """
    return 10.0 ** (1.5 * magnitude + 9.05)
