OFFSET
1,1
COMMENTS
Numbers of stars which can be arranged on a flag so as either to completely fill a rectangle (j*k stars), or where one additional star is put in each unit square (j*k + (j-1)*(k-1) stars).
LINKS
António Martins-Tuválkin, How to arrange any number of stars on the U.S. flag; a broader definition of allowable arrangements that indicates that for any number k of stars > 0, one of four types of arrangement is applicable.
EXAMPLE
a(1) = 4 stars on the corners of the unit square.
a(2) = 5 stars after putting an additional star in the center of that unit square.
PROG
(Python) print(sorted({v for max in [50] for j in range(2, max+1) for k in range(2, max+1) for v in (j*k, j*k+(j-1)*(k-1)) if v <= 2*max+1}))
CROSSREFS
KEYWORD
nonn
AUTHOR
Oliver Gramberg, Dec 17 2025
STATUS
approved
