login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A301851 Table read by antidiagonals: T(n, k) gives the number of distinct distances on an n X k pegboard. 2
1, 2, 2, 3, 3, 3, 4, 5, 5, 4, 5, 7, 6, 7, 5, 6, 9, 9, 9, 9, 6, 7, 11, 12, 10, 12, 11, 7, 8, 13, 15, 14, 14, 15, 13, 8, 9, 15, 18, 17, 15, 17, 18, 15, 9, 10, 17, 21, 21, 19, 19, 21, 21, 17, 10, 11, 19, 24, 25, 24, 20, 24, 25, 24, 19, 11, 12, 21, 27, 29, 29, 26, 26, 29, 29, 27, 21, 12 (list; table; graph; refs; listen; history; text; internal format)
OFFSET
1,2
COMMENTS
Main diagonal is A047800.
LINKS
EXAMPLE
The 4 X 6 pegboard has 17 distinct distances: 0, 1, sqrt(2), 2, sqrt(5), sqrt(8), 3, sqrt(10), sqrt(13), 4, sqrt(17), sqrt(18), sqrt(20), 5, sqrt(26), sqrt(29), and sqrt(34).
+---+---+---+---+---+---+
| * | | | | 16| 25|
+---+---+---+---+---+---+
| 1 | 2 | | | 17| 26|
+---+---+---+---+---+---+
| 4 | 5 | 8 | | 20| 29|
+---+---+---+---+---+---+
| 9 | 10| 13| 18| | 34|
+---+---+---+---+---+---+
(As depicted, the pegs are at the center of each face.)
Square array begins:
n\k| 1 2 3 4 5 6 7 8
---+----------------------------------------
1| 1 2 3 4 5 6 7 8
2| 2 3 5 7 9 11 13 15
3| 3 5 6 9 12 15 18 21
4| 4 7 9 10 14 17 21 25
5| 5 9 12 14 15 19 24 29
6| 6 11 15 17 19 20 26 31
7| 7 13 18 21 24 26 27 33
8| 8 15 21 25 29 31 33 34
PROG
(Haskell)
import Data.List (nub)
a301851 n k = length $ nub [i^2 + j^2 | i <- [0..n-1], j <- [0..k-1]]
CROSSREFS
Sequence in context: A135646 A360920 A334922 * A101646 A166079 A269381
KEYWORD
nonn,tabl
AUTHOR
Peter Kagey, Mar 27 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 19 08:39 EDT 2024. Contains 371782 sequences. (Running on oeis4.)