def _set_ghparameters(parlist, default, deg_gh) :
    """ Set up the parameters given a default

    if the Input does not have the right size (deg_gh) it fills in the rest
    with the default

    Input is :
    ==========
    : param parlist : the input parameters you wish to set
    : param default : the default when needed
    : param deg_gh   : the right size (degree of Gauss-Hermite to fit)

    :returns : parameter list

    """
    if parlist is None : parlist = default

    # Replicate the parlist with the right size first
    newparlist = [parlist[0]] * deg_gh
    # Now computing the length of the input parlist
    lparlist = len(parlist)
    # And completing it with the right default if needed
    newparlist[:lparlist] = parlist
    newparlist[lparlist:] = default[lparlist:]

    return newparlist