Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Square pyramidal number
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
==Geometric enumeration== <!-- [[File:Squares in a square grid.svg|thumb|upright=0.75|A 5 by 5 square grid, with three of its 55 squares highlighted.]] --> [[File:grid_square_count_puzzle.svg|thumb|upright=0.5|All 14 squares in a 3×3-square (4×4-vertex) grid]] As well as counting spheres in a pyramid, these numbers can be used to solve several other counting problems. For example, a common [[mathematical puzzle]] involves counting the squares in a large {{mvar|n}} by {{mvar|n}} square grid.{{r|dpas}} This count can be derived as follows: *The number of {{nowrap|1 × 1}} squares in the grid is {{math|''n''<sup>2</sup>}}. *The number of {{nowrap|2 × 2}} squares in the grid is {{math|(''n'' − 1)<sup>2</sup>}}. These can be counted by counting all of the possible upper-left corners of {{nowrap|2 × 2}} squares. *The number of {{math|''k'' × ''k''}} squares {{math|(1 β€ ''k'' β€ ''n'')}} in the grid is {{math|(''n'' − ''k'' + 1)<sup>2</sup>}}. These can be counted by counting all of the possible upper-left corners of {{math|''k'' × ''k''}} squares. It follows that the number of squares in an {{math|''n'' × ''n''}} square grid is:{{r|robitaille}} <math display=block>n^2 + (n-1)^2 + (n-2)^2 + (n-3)^2 + \ldots = \frac{n(n+1)(2n+1)}{6}.</math> That is, the solution to the puzzle is given by the {{mvar|n}}-th square pyramidal number.{{r|oeis}} The number of rectangles in a square grid is given by the [[squared triangular number]]s.{{r|stein}} The square pyramidal number <math>P_n</math> also counts the [[acute triangle]]s formed from the vertices of a <math>(2n+1)</math>-sided [[regular polygon]]. For instance, an equilateral triangle contains only one acute triangle (itself), a regular [[pentagon]] has five acute [[Golden triangle (mathematics)|golden triangle]]s within it, a regular [[heptagon]] has 14 acute triangles of two shapes, etc.{{r|oeis}} More abstractly, when permutations of the rows or columns of a [[Matrix (mathematics)|matrix]] are considered as equivalent, the number of <math>2\times 2</math> matrices with non-negative integer coefficients summing to <math>n</math>, for odd values of <math>n</math>, is a square pyramidal number.{{r|bvt}}
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)