You need to uninstall patch 119967-02 (for x86) and 119966-02 (for SPARC) (along with any patches that depend on them) which are necessary for Oracle Developer Studio. eg:
patchrm 119967-02
Once you've done this, your /usr/include/math.h will revert to the 2009 version, not the 2016 version. Problem solved.