added function to check whether a term is first-order. intensive test following
added function to check whether a term is first-order. intensive test following

leoprover/Leo-III,leoprover/Leo-III,lex-lex/Leo-III,lex-lex/Leo-III,lex-lex/Leo-III,leoprover/Leo-III