US 6,983,298 B2 | ||
Method and apparatus for linear interpolation using gradient tables | ||
Vivek Kumar Thakur, Plano, Tex. (US) | ||
Assigned to Texas Instruments Incorporated, Dallas, Tex. (US) | ||
Filed on Feb. 15, 2002, as Appl. No. 10/77,230. | ||
Claims priority of provisional application 60/279538, filed on Mar. 28, 2001. | ||
Prior Publication US 2002/0165890 A1, Nov. 07, 2002 | ||
Int. Cl. G06F 7/38 (2006.01) |
U.S. Cl. 708—290 | 6 Claims |
1. A method of forming an interpolation value of a function for input values between argument values for which the function
value is known, comprising the steps of:
storing in a memory function values corresponding to discrete values of an argument of the function for which the function
value is known;
receiving an input value;
determining a first argument value for which the function value is known immediately less than the input value;
forming a least significant bit difference between the input value and the first argument value having a predetermined number
of less significant bits, each such bit less significant than a least significant bit of the first argument value;
determining a second argument value for which the function value is known immediately greater than the input value;
recalling from the memory a first function value for the first argument value;
recalling from the memory a second function value for the second argument value;
forming an absolute value of a difference between the second function value minus the first function value;
determining a sign of the difference between the second function value minus the first function value;
storing in a memory a set of gradient values for each bit of the absolute value of the difference and each of the predetermined
number of less significant bits;
recalling from the memory gradient values for the least significant bit difference corresponding to bits where the absolute
value of the difference is 1;
summing the recalled gradient values;
if the sign of the difference is 1, adding the sum of the recalled gradient values to the first function value; and
if the sign of the difference is 0, subtracting the sum of the recalled gradient values from the first function value.
|