1. An apparatus for computing mathematical functions, the apparatus comprising: a first hardware pipeline configured to receive an argument x and an opcode and perform a polynomial approximation of second degree or higher, the first hardware pipeline including a plurality of stages; and a plurality of data tables, each associated with at least one of LOG (logarithm), COS (cosine), DIV (division), and SIN (sine) functions and configured to be coupled to the first hardware pipeline according to the at least one opcode, wherein each of the plurality of data tables includes data associated with implementing the associated function, the first hardware pipeline being configured to calculate a value A(x) by performing the polynomial approximation with respect to data from the data tables of the plurality of data tables corresponding to the opcode and x; a second hardware pipeline configured to calculate an adjustment factor B(x) corresponding to the opcode; and wherein the first hardware pipeline further configured to calculate an output value as B(x)*A(x).