add math. to isnan
x==x instead of isnan(x) in c++
Merge branch 'doublebug'