Original Post
I want an algorithm which can predict all possible values of an integer expression. For instance if we have:
x = (f(4) + g(9) * 5 ) / 2 Where f(y)’s range is any integer x where (x-32)/y is an integer, and x is smaller than or equal to 32+8y. g(y)’s range is any integer x where (x-8)/y is an integer and x is smaller than or equal to 8+5y. So x should be one of the following: {36, 38, 40, 42, 44, 46, 48, 50, 52, 58, 60, 62, 64, 66, 68, 70, 72, 74, 81, 83, 85, 87, 89, 91, 93, 95, 97, 103, 105, 107, 109, 111, 113, 115, 117, 119, 126, 128, 130, 132, 134, 136, 138, 140, 142, 148, 150, 152, 154, 156, 158, 160, 162, 164} I have given it a little thought myself and think I can make it work with a reasonable performance. Before giving more thought to it I would like to know if any research have been made in this kinds of algorithms, so that I avoid re-inventing the wheel (my algorithm might even be worse than others out there). I have tried searching, but what is this kind of thing called? I tried various search terms, integer prediction, integer tracking, integer possibilities, etc. I have also tried some terms without integer in it.