Corrected to use gngdouble_t.