added NaN test for check_equal
added doc in code for check_equal