At 10:07 AM 2/20/2003 -0500, you wrote: >Quoting Scott Touchton : > > > How about just using a look up table? > >This might be a stupid question, but what exactly is a lookup table. Recently, >I have been reading a lot of posts dealing with lookup tables. Is it just a >table basically stored in RAM/EEPROM that can be used to obtain a value from a >calculation instead of coding math routines? At the expense of code space of >course... Yes, that's all it is. In this case the function is of *two* variables, so you need an n x m LUT, and it's probably necessary to use two dimensional interpolation. For example, he might have temperature from 0 to 40 degrees C in 2' steps, and RH from 0 to 100% in 5% steps. That would require 400 values. If dew point was represented as a single byte (+/-63 degrees C with 0.5'C resolution) then it would require 400 bytes or words depending on the part. Best regards, Spehro Pefhany --"it's the network..." "The Journey is the reward" speff@interlog.com Info for manufacturers: http://www.trexon.com Embedded software/hardware/analog Info for designers: http://www.speff.com -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu