Basic Examples
Find the marks for a sparse ruler of length 9:
Check that all differences are covered:
Find the marks for a sparse ruler of length 57:
Check that the ruler is complete (i.e. all differences are covered):
Show the intervals between marks in the full form of a length-396 ruler:
Split the differences:
Make a series of lists from the compact form of a length-396 ruler:
Show the compact form:
Verify that the compact form from the previous result has length 396:
Show the full form for a length-396 ruler:
Scope
Show the marks for the first 51 rulers:
Show the excess values for the first 51 rulers:
Count the number of marks for a length-58 ruler in full form or compact form:
The excess of a ruler with length L and M marks is :
An excess-01 ruler has an excess of 0 or 1:
A list of some rulers with a single mark less than those generated by this function:
Show the length-999 ruler with one less mark:
Show how the Leech upper bound for the number of marks in a complete ruler compares to the number of marks in function-generated rulers:
Generate rulers of length n! and plot the number of marks:
Possible Issues
Show the default shortened form for a length-googol ruler:
Show the number of marks in a length-googol ruler:
Showing the full form of a googol-length ruler is not recommended.
Neat Examples
Generate reasonable rulers for various integer powers and calculate their excess:
All rulers to length 213 are minimal. Show a pixel representation of these sparse rulers:
The maximal length for a given number of marks is usually a Wichmann value:
Arrange lengths in columns ending in Wichmann values and bold the lengths with excess 1: