1. A method performed by a computer processor for searching an index vector (X) of a lookup table for a vector index that corresponds to an input value (Xin) that allows for the index vector (X) to be searched regardless of whether the lookup table is linearly index or piecewise indexed, and then executing either an interpolation routine for a linearly indexed vector or an interpolation routine for a piecewise indexed index vector to determine an interpolated output value (Yout) that corresponds to the input value(Xin), the computer processer programmed with instructions to perform the steps of the method, the method comprising the steps of: computing, at the computer processor, based on the input value (Xin) being searched for within an index vector (X) of the lookup table, a value of the vector index to generate a computed vector index; determining at the computer processor, whether the computed vector index is less than a length of an index vector (N); when it is determined that the computed vector index is greater than the length of the index vector (N), re-computing at the computer processor, the computed vector index by decrementing the length of the index vector (N) by one to generate a re-computed vector index; determining, at the computer processor, whether the value of the computed vector index is correct to determine whether the index vector (X) is linearly indexed or piecewise indexed; when either the value of the computed vector index is determined to be correct or when the re-computed vector index is generated, executing at the computer processor, the interpolation routine for the linearly indexed index vector using a presently computed vector index to determine the interpolated output value (Yout) that corresponds to the input value (Xin), wherein the presently computed vector index is either the computed vector index or the re-computed vector index; and when the value of the computed vector index is determined to be incorrect and the index vector (X) is determined to be piecewise indexed, executing, at the computer processor, the interpolation routine for the piecewise indexed index vector to determine the interpolated output value (Yout) that corresponds to the input value (Xin).