def present(x):
    '''
    This is a Python equivalent of the Fortran 'present' function for optional arguments.
    '''
    return x is not None