Skip to content

[FEATURE] Generate binary cryptarithms #169

@arnaud-m

Description

@arnaud-m

Is your feature request related to a problem? Please describe.
The generator enforces that letters are associated to distinct digits.
So, binary cryptarithms cannot be generated.

Describe the solution you'd like
Relax the constraint that letters are associated to distinct digits.

Provide usage examples

java -cp cryptator-1.0.1-SNAPSHOT-with-dependencies.jar cryptator.Crypgen --base 2 -v verbose --generate ADD --solver ADAPT words/alpha.txt

The generation model enforces that

ARITHM ([symbCount <= 2])

But, one want to discover that

java -cp cryptator-1.0.1-SNAPSHOT-with-dependencies.jar cryptator.Cryptator --base 2 "pi+pi=rho" 
pi+pi=rho  
[2025-07-14 16:37:31] [INFOS] Find cryptarithm solution #1 [OK]
 h| i| o| p| r|
 0| 0| 0| 1| 1|  
...

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions