def parameter_id_to_index(parameter_id):
    """Converts a SMIRNOFF parameter id string (like 'n3' or 'n15') to an 0-start integer index"""

    assert(parameter_id[0] == 'n') # make sure this is a nonbonded parameter...

    return int(parameter_id[1:]) - 1