Model Checking Programs Using Recursive Functions