× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.




On 2012-07-02, at 7:43 PM, rpg400-l-request@xxxxxxxxxxxx wrote:

I should be safe because the greatest value we receive is 4 currently (and that's been true for 10 years), and at most we currently store up to 6 decimals, although to be safe (since RevDec is 2,0) I could check for a value of 13 and error it. Or I could change it to a loop, which would still be better than having to check for each possible value of RevDec (which is what it currently does today).

Why not just store the appropriate multiplier value for each value of RevDec in an array and index into it. No divide - no float ...

D revDevScale DS
D val1 5p 5 Inz(0.1)
D val2 5p 5 Inz(0.01)
....
D scale 5p 5 Overlay(revDevScale) Dim(4)

/Free

result = value * scale( ds_Inp.RevDec );

Bit more typing to create - much faster to execute I suspect.


Jon Paris

www.partner400.com
www.SystemiDeveloper.com





As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.