(self, name, range_)
| 98 | |
| 99 | class ExponentialInteger(Variable): |
| 100 | def __init__(self, name, range_): |
| 101 | super().__init__(name, "exp2") |
| 102 | # Adjust the range to ensure it is in the form of [2^x, 2^y] and satisfies 2^63 - 1 |
| 103 | lower_bound = 2 ** math.floor(math.log2(range_[0])) |
| 104 | upper_bound = min(2 ** math.ceil(math.log2(range_[1])), 2 ** 63) |
| 105 | self.range = (lower_bound, upper_bound) |
| 106 | self.is_discrete = True |
| 107 | |
| 108 | @property |
| 109 | def search_space_range(self): |