Removed unnecessary "isNull" function, debugged toDecimal() and verified that singleToNum() works.