I am currently tasked to write a software to help engineers design standard compliant designs. If there is a bad design, software will report an error or warning.

Maybe it's just me, but anyone who has done this should be familiar with the massive amounts of ANSI standards tables like this one: http://en.wikipedia.org/wiki/Nominal_Pipe_Size

Computers are, as its name suggest, computing machines, not lookup machines. I feel that feeding formulas into computers and churning out standard compliant designs is much more efficient than doing memory intensive data lookups that are prone to human input errors and susceptible to "data updates".

I actually think that there are formulas to calculate all those numbers, but nobody so far could give me that information. Anyone been through this before? What is THE best approach to this? Thanks for sharing.


I think what you are going to find is that while computers are computing machines, the ANSI standards you are trying to enforce were mostly written by committees which consist of people, who are not computing machines. While I'm sure some things are going to be formula-based and by all means if that's the case, use formulas, I think you will also find plenty of standards which are table based simply because humans came up with them and simply listing a table was the most logical thing for them to do. If that's the case, you will probably have to resort to storing/accessing tables in your app as well.

Maybe to minimize user-error you should design a mechanism that makes it super easy to import table data from other sources/documents so that your final end-user isn't actually required to punch in table data, which would definitely be error-prone. Once the data is in there, I doubt you'll have any runtime problems with using lookup tables and considering how much memory is accessible to a modern process, I doubt that your app would even be considered memory-intensive.

Also keep in mind that there's plenty of examples where computers use lookup tables, for example rainbow tables, which are used for in anti-encryption, are just giant lookup lists that can easily reach half a terabyte in size.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.