plumial.core.P._P.isforced
- _P.isforced()[source]
Determine if the cycle is forced by the p-value bit pattern.
A cycle is considered “forced” if the next operation cannot be determined by inspecting the LSB bit of the x-value alone, but instead is determined by the LSB bit of the p-value. This occurs when:
The p-value contains any adjacent 1 bits in its binary representation, OR
The top and bottom path bits are both 1
This is a critical property for Collatz analysis: any counterexample to the Collatz conjecture would have isforced() == False.
- Return type:
bool- Returns:
True if the cycle is forced by the p-value bit pattern, False otherwise
- Mathematical Background:
For unforced cycles: all(p.x(3,2) % 2 == p.p() % 2 for p in cycle) For forced cycles: the above condition is False for at least one element
Examples
>>> P(9).isforced() # Unforced cycle False >>> P(291).isforced() # Forced cycle True >>> # Verify unforced property for P(9) >>> all(p.x(3,2) % 2 == p.p() % 2 for p in P(9).cycle()) True >>> # Verify forced property for P(291) >>> all(p.x(3,2) % 2 == p.p() % 2 for p in P(291).cycle()) False