Quote Originally Posted by Ioannis View Post
Since you have done it in PBP and if you don't mind, could you post the code you tested please?

Maybe there is a way to overcome the Long need using functions of 32 bit like DIV32?

Ioannis

P.S. Test it in Excel and I think there is a mistake on the B3 function. My output result on B13 is always equal to B11.

I divided by 4 first, then ran it through the formula.

"EDIT: Hmmm, what if I divide my input by 4, and adjust my input range accordingly..."