Given an integer n, find the nth Centered pentagonal number.
A Centered Pentagonal Number is a centered figurate number that represents a pentagon with a dot in the centre and other dots surrounding it in pentagonal layers successively [ Source: Wiki ]
Few Centred pentagonal Number are :
1, 6, 16, 31, 51, 76, 106, 141, 181, 226, 276, 331, 391………………..
Input : 3 Output : 16 Input : 9 Output : 181
Centered pentagonal for n-th term is given by :
Basic implementation of the above approach :
7th Centered pentagonal number: 106
- n'th Pentagonal Number
- Pentagonal Pyramidal Number
- Program to check if N is a Pentagonal Number
- Centered heptagonal number
- Centered hexagonal number
- Centered cube number
- Centered decagonal number
- Centered tridecagonal number
- Centered Square Number
- Centered Pentadecagonal Number
- Centered dodecahedral number
- Centered Hexadecagonal Number
- Centered triangular number
- Centered Dodecagonal Number
- Centered Octahedral number
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.