This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
If a chessboard were to have wheat placed upon each square such that one grain were placed on the first square, two on the second, four on the third, and so on (doubling the number of grains on each subsequent square), how many grains of wheat would be on the chessboard at the finish?
The problem may be solved using simple addition. With 64 squares on a chessboard, if the number of grains doubles on successive squares, then the sum of grains on all 64 squares is: 1 + 2 + 4 + 8 + ... and so forth for the 64 squares. The total number of grains equals 18,446,744,073,709,551,615, much higher than what most intuitively expect.
When I run my workflow, everything is fine until field 63. On the last field, the number seem to be too big and cannot displayed properly (becoming a negative number).
What is the limitation for numbers in Alteryx? Is there any workaround?
@jdunkerley79: thanks for the solution & explanation. In your example field 64 already covers the total sum instead of the number of wheat at field 64 (the table would need to start with "1" in field 1). But no need for modification from my side.
I faintly remember in high school doing a coding exercise to multiply large numbers using strings. You could multiply numbers of any size (up to the limit of a string) which went beyond the limits of the time (Numbers were smaller then 🙂 ). I wouldn't even remember where to start ( but I'm guessing an iterative macro would have to be involved). But it is possible.
I'm not familiar with macros or phyton in Alteryx and I wonder, if that might be solutions for this problem:
in order to check IBANs, I want to calculate the modulo 97 of very large numbers. In my example the number is 700901001234567890131400. Two websites independently say, that the result of 700901001234567890131400 modulo 97 is 90 (e.g. https://www.entwicklertools.de/tools/mathematik-tools/modulo-rechner/). But when I calculate it with Alteryx the result is -79. The reason for this miscalculation seems to be, that the Formula-Tool can not handle numbers, that are as large as the first one. Do you have any idea for a workaround for me?