Thursday, March 22, 2018

Fascinating Palindrome Connection (2)

The approach in the last entry can be generalised for all self-generating numbers, where in the appropriate number bases, the original starting number * k (where k = 2, 3, 4, 5, …) = its reverse number.

When n = 4, a unique repeating 2-digit sequence applies to 1/n in bases 2n – 1, 3n – 1, 4n – 1, …, so
that the original starting number (using these 2 digits) * 3 = its reverse number.

And just as the kth term in the previous case “Fascinating Palindrome Connection 1”, where n = 3, is given by 3n2 – 2n, the kth term (where n = 4) is given by 4n2 – 2n, resulting in the series,

2, 12, 30, 56, 90, …

So the relevant number bases, where this form of self-generating behaviour applies is in the number bases 7, 11, 15, … (Once again we omit the number base where n – 1 = 3, applying to the 1st term of the series i.e. 2, as this results in a redundant 1st digit of 0 in the original starting number).

However the 2nd term, applying to base 7 is fully valid.

And 12 in base 7 = 15.

Therefore, 15 * 3 = 51 (in base 7).

However this can equally be expressed as 2 * (2n – 2) = 2 * 6 = 12 (in base 10), i.e. 15 in base 7.

So the subsequent 2-digit starting terms are given by 3 * 10 (= 28 in base 11), 4 * 14 (= 3B in base 15), 5 * 18 (= 4E in base 19) and so on.

Thus  28 * 3 = 82 (in base 11)
         3B * 3 = B3 (in base 15)
         4E * 3 = E4 (in base 19)
                 

Then one 3-digit term in each case is obtained from 22 * 6 in base 7, 33 * 10 (in base 11), 44 * 14 (in base 15), 55 * 18 (in base 19) and so on.

And as we saw in Fascinating Palindrome Connection 1” one can then use the formulas k/2(k/2 + 1), where k is odd and k/2 * k/2 where k is even, to calculate the total number of self-generating numbers (of a particular type) up to (and including) k digits.

So for example the total collection of self-generating numbers (where the original starting number * 3 = its reverse) -up to an including 4 digits - in each relevant number base, is    
4/2 * 4/2 = 4.
And in base 7, these are 15, 165, 1515 and 1665 respectively.

Tuesday, March 20, 2018

Fascinating Palindrome Connection (1)

I wish to correct a recent assertion regarding the frequency of self generating numbers in different number bases.

What I mean in this context is a number that when multiplied by a positive integer (> 1) = its reverse.

So for example in base 8, 25 (original starting number) * 2 = 52 (i.e. its reverse number).

Now I claimed that where such a 2-digit number exists (in an appropriate base), that one example will then occur for every higher digit number (in the same number base).

However I have since discovered, through an interesting number connection, that this is not in fact strictly true.

Once again when we start with a positive integer n (> 1), then the reciprocal of n will result in a unique repeating 2-digit decimal sequence in the corresponding number bases
2n – 1, 3n – 1, 4n – 1, …    

So again for example when n = 3, then 1/n results in this unique 2-digit sequence in base 5, 8, 11, …

And then when we take these 2 digits as the original starting number and subtract it from its reverse, the same starting number will result.

Alternatively, when we multiply the starting number by 2, we obtain its reverse in these number bases.

Thus in base 5, 13 * 2 = 31; in base 8, 25 * 2 = 52; in base 11, 37 * 3 = 73, and so on.

However there is another revealing perspective with respect to these numbers.
Thus when we divide each of these numbers by the number that is one less than the number base in question i.e. 2n – 2, 3n – 2, 4n – 2, … respectively we obtain 2, 3, 4, …

Now once again we are excluding the 2-digit number in base 2 i.e. 01, as the first digit as a 0 is strictly redundant.

So 2 * 4 = 13 (in base 5); 3 * 7 = 25 (in base 8); 4 * 10 = 37 (in base 11) and so on.

Now a corresponding higher digit numbers (where starting number * 2 = its reverse number) can now be created with respect to the original starting number provided that its palindrome nature is preserved and where the inclusion of one or more zeros is allowed (between first and last digits).

So when the palindrome has 2 digits, then only one possibility arises.

Thus in base 5, 22 * 4 = 143 and 143 (starting number) * 2 = 341 (its reverse number).
In like manner, in base 8,  33 * 7 = 275 and 275 (starting number) * 2 = 572 (its reverse number).

And in base 11, 44 * 10 = 3A7 and 3A7 (starting number) * 2 = 7A3 (its reverse number).

Thus there is indeed only one example of a self-generating number (of this type) with respect to all 3-digit numbers in bases 5, 8, 11, …

However when the palindrome now has 3 digits, two possibilities exist

So with respect for example to base 8, we can have 333 or 303.

Thus in base 8, we have as our possible starting numbers 333 * 7 = 2775 and 2775 (starting number) * 2 = 5772 (its reverse number).

However, we also have 303 * 7 = 2525 and 2525 (starting number) * 2 = 5252 (its reverse number).

Thus for 4-digit numbers in bases 5, 8, 11, …, we have 2 examples of such self-generating numbers (i.e. where the starting number * 2 = its reverse number).

Now when the initial palindrome has 4 digits, again illustrating with respect to base 8, we have just two possibilities i.e. 3333 or 3003.

And in base 8, 3333 * 7 = 27775 and 27775 (starting number) * 2 = 57772 (its reverse).

However, we also have 3003 * 7 = 25025 and 25025 (starting number) * 2 = 52052 (its reverse).

So for 4 and 5-digit numbers, we have two examples in each case of such self-generating numbers.

Then when we go to 6 and 7-digit numbers, we have three examples in each case, with 8 and 9-digit numbers 4 examples, with 10 and 11-digit numbers five examples and so on.

Thus when k is an even integer we have k/2 examples of such numbers in the relevant number bases.
And when k is an odd integer, we have (k – 1)/2 examples.

And the cumulative number of such numbers up to and including k digits is k/2(k/2 + 1), where k is odd and k/2 * k/2 where k is even.

Therefore, for example the total number of such self generating numbers up to and including 6 digits (i.e. where the reverse is twice the original starting number), in the appropriate number bases  5, 8, 11, ..., = 3 * 3 = 9.

Tuesday, March 13, 2018

Calculating Frequency of Palindromes

In this entry, I will attempt to provide formulas for the calculation of the number of palindromes (in any number base).

If we start with our customary base 10 system, through perhaps somewhat trivial, all of the single-digit numbers from 1 - 9 (inclusive) can be viewed as palindromes.

The number 9 for example in clearly the same whether digit(s) are read from left to right (or alternatively right to left).

Then with respect to 2-digit numbers from 11 – 99 (inclusive) again we have 9 examples (where the digits from 1 - 9 repeat).

Then with respect to 3-digit palindromes, the 1st and last digits must be the same (as one of the 9 digits from 1 - 9). Then the middle digits can be any one of the 10 digits (from 0 to 9 inclusive).

Thus with respect to 3-digit numbers, we have an additional 90 examples.
Then it is just the same with respect to 4 digit numbers where the two middle digits must be the same leaving again 10 options from 00 to 99.

Then with 5-digit numbers we will have 900 additional examples and another 900 with 6 digit numbers.

So we have  9 + 9 + 90 + 90 + 900 + 900 + …

= 18 + 180 + 1800 + …

= 2 * 9(1 + 10 + 102 + …)

Thus if we let x = base number (which in this case = 10), then we have

2 (x – 1)(1 + x + x2 + …) = – 2(1 – x)( 1 + x + x2  + …)

Therfore from 1-digit to n-digit numbers (where n is even), the total no. of palindromes is

2(xn/2 – 1).

So where n = 6, we have

2(x3 – 1) which when x = 10, gives 2 * 999 = 1998 (i.e. 9 + 9 + 90 + 90 + 900 + 900).

When n is odd we get,

2{x(n + 1)/2} – {x – 1}x(n 1)/2

So with n = 5 we get 2(x3 – 1) – {x – 1}x2.

So again with x = 10 (as number base) we obtain

1998 – 900 = 1098 (i.e. 9 + 9 + 90 + 90 + 900).

Again this expresses the frequency of all palindromes for numbers up to 5 digits i.e. from 1 - 99999 (inclusive).


The 2nd part of the formula {x – 1}x(n  1)/2 expresses the narrower notion of the number of n digit palindromes (where n is odd).

Then {x – 1}x(n  2)/2 expresses the corresponding notion of the number of n digit palindromes (where n is even).

Thus when n = 6, the no. of palindromes (in base 10) = 9 * 10= 900.

Monday, March 12, 2018

Extending Relationships (3)

This process of self-similarity in a complementary fashion, whereby a number when multiplied by another whole number is equal to its reverse is very rare indeed with respect to our customary denary system.

In fact there are only two types of situation where it occurs.

The first is the somewhat trivial case where the whole number multiple = 1. This in fact entails that the number is a palindrome, which could be alternatively stated by saying that a zero result results from subtracting the number from its reverse.

So when a number is a palindrome e.g. 343, when this number is multiplied by 1, the reverse number is obtained (which is identical to the starting number). So 343 * 1 = 343.

The other case, which again is somewhat trivial, results when a number - starting in 0 and with other digits forming a palindrome, is multiplied by 10 (i.e. the base number).

Here when the staring number is multiplied by 10, the reverse number is obtained.

So  for example 099 * 10 = 990.

However, if we exclude the validity of the starting digits (or digits) of the original number being equal to 0, then no examples of this latter form of behaviour exist in our customary number base.

Therefore, bearing this exclusion in mind,  the only case in base 10, where starting number * k = reverse (where k is a whole number) is where k = 1 (such that the number is a palindrome).

However such similarity is much more prevalent in other number bases.


Now, we have already seen that in number bases, 2, 5, 8, ... that the most striking form of such self-similarity arises where the whole number multiple (k) = 2. This implies that

reverse – original (starting) number = original number.

This coincides with the octagonal sequence

1, 8, 21, 40, ... (with kth term =  3n2 – 2n, where k = 1, 2, 3, ...).

However in base 2, this could be deemed as a somewhat trivial result that should be excluded.


We have already dealt with this issue in base 10 whereby a number (starting in one or more 0's), when multiplied by 10 can result in the reverse number being generated.

This can equally be associated with any number base. Therefore in base 2 when in the simplest case, we multiply 01 (the 1st number of the sequence) by 2 we obtain 10 (i.e. the reverse).

However if we exclude original numbers that start with one or more zeros in base 10, then we should equally exclude then in base 2.
 
Therefore, from this perspective, the first non-trivial case arises in base 5, whereby we have already seen (in the simple 2-digit case) that 8 (in denary terms) = 13 (in base 5), so that  13 * 2 = 31 (with 31 13 = 13)  .

Then in base 8, 21 (in denary terms) = 25 (in base 8) so that 25 * 2 = 52 (with 52 – 25 = 25) and in base 11, 40 (in denary terms) = 37 (in base 11) so that 37 * 2  = 73 (i.e. 73 – 37 = 37) and so on.

So in all these bases (2, 5, 8, 11, ...) just one example of such self similarity exists.

This equally applies then by extension to 3-digit, 4-digit, 5-digit, ...    numbers with just one valid example in each case.

Thus in base 5, in the 3-digit case, 143 * 2 = 341 (so that 341 143 = 143). This number is obtained by inserting the number that is 1 less than the base number in question (i.e. 5) between first and last digits.

Then again in base 5, in the 4-digit case, 1443 * 2 = 3441 (so that 3441 – 1443 = 1443). So here an additional 4 is placed anywhere between first and last digits.

And to illustrate further for the 5-digit case, 14443 * 2 = 34441 (so that 34441 14443 = 14443) with again an additional 4 placed between first and last digits.


Then when the whole number multiple, k = 3 so that original (starting) number * 3 = reverse, we found that this will exist in number bases 3, 7, 11, 15, ...  

This is associated with the number sequence  

2, 12, 30, 56, ...  (with kth term =  4n2 – 2n, where k = 1, 2, 3, ...).


Now again (as always the case), the initial base leads to a somewhat trivial result, where for example in the 2-digit case, where we express the 1st term of the sequence in base 3, 02 * 3 = 20.

Thus, excluding this case, the first non-trivial example occurs in base 7, where 12 (in denary terms) = 15 (in base 7) and 51 = 15 * 3.  

Then in base 11, 30 (in denary terms) = 28 (in base 11) and 82 = 28 * 3.

And in base 15, 56 in denary terms) = 3B (in base 15) and B3 = 3B * 3.

So in each of these bases, again just one 2-digit case arises with respect to this form of self-similarity.

However once again, the 2-digit-case can be extended to 3-digit, 4-digit, 5-digit, ... numbers by the continual inclusion between the first and last digits of the digit that is 1 less than the number base in question.

Thus the sole 3-digit example in base 7 of this form of self-similarity, (where reverse = original number * 3) is 165 so that 561 = 165 * 3.

And the sole 4-digit example in base 7 is 1665 so that 5661 = 1665 * 3.

And finally to illustrate the sole 5-digit example is 16665 so that 56661 = 16665 * 3.

Friday, March 9, 2018

Extending Relationships (2)

When I had completed yesterday’s entry, I realised that the results could be generalised further in a remarkable way.

Thus the starting sequence (where n = 2) is,

0, 4, 12, 24, …,  = 4(0, 1, 3, 6, …).

In other words the nth term of the starting sequence = 4 * nth term of the triangular sequence, where n = 0, 1, 2, 3, …

Now the nth term of the triangular sequence = n(n – 1)/2

Therefore the nth term of our starting sequence = 2n(n – 1) = 2n2 – 2n.

Now each further sequence for n = 3, 4, 5, … is obtained by successively adding n2 (i.e. the nth term of the sum of squares) to the previous result.

So for example the nth term of the octagonal sequence, where n = 3, is 3n2 – 2n, and the nth term of the sequence, where n = 4, is 4n2 – 2n, the nth term of the sequence where n = 5, is 5n2 – 2n and so on.

This means for example when n = 11, the nth term of the corresponding sequence = 11n2 – 2n.

Therefore the corresponding sequence is

9, 40, 93, 168, …

The reason for choosing this sequence is that the starting base is therefore 10 with subsequent relevant number bases increasing by 11.

So clearly 9 in base 10 (using 2 digits = 09) and the reverse = 90

And 90 (reverse) = 09 (original number) * 10.

However whereas this is clearly true, the result is not unique in this base as any other digit (from 1 – 8 inclusive) can be used with 0 so that the reverse = original number * 10.

Indeed this non-exclusivity applies to all number bases > 2.

When n = 3 and the starting base = 2. Then 01 is the  2-digit original number that can arise in this base with 10 its reverse so that 10 – 01 = 01. However even here the 0 in 01 is strictly redundant.  

And 10 reverse = 01 (original number) * 2.

Then when we keep inserting 1 (in base 2) between first and last digits the self generating pattern is preserved for higher digit numbers.

So 110 – 011 = 011; 1110 – 0111 = 0111 and so on.

However where n > 3 (and consequent number base > 2) a non-exclusive basis attaches to the original number generated in the starting base.

So again where n = 11 (and starting base = 10) any digit from 1 to 9 can be associated with 0 in the 2-digit case and again any digit from 1 to 9 can be continually inserted as between first and last digits to generate higher digit numbers (where the reverse – original number * 10).

However once we proceed on to the next relevant number base, a unique relationship exists (where 0 is not a starting digit).

For example 40 in base 21 is 1S (where S denotes the number 19).

The reverse S1 = (21*19) + 1 = 400

And 400 (reverse)  = 10 * 40 (original number) in denary terms .

So S1 (reverse) = 10 * 1S (original number) in base 21.

This is then unique as the only 2-digit example with this number property in base 21.

However we can then continually extend this property uniquely to 3-digit, 4-digits, 5-digit, … numbers in base 21 by inserting T (representing units measured in 20’s) as between 1st and last digits.

So the corresponding 3-digit original number (in base 21) = 1TS = 19 + 20 * 21 + 21* 21 = 880 (in denary terms).

And the reverse ST1 = 1 + 20 * 21 + 19 * 21 * 21 = 8800.

So again as we see in base 21,

ST1 (8800 in denary terms) = 10 * 1TS (880 in denary terms).


We saw when dealing with the octagonal sequence (which offers the most unique self similarity features of number), that it also has a well-defined “shadow” sequence that arises when the nth term of the octagonal i.e. 3n2 – 2n is defined for n = 0, – 1, – 2, – 3…

Alternatively this sequence i.e.

0, 5, 16, 33, 56, …,

can be defined, where the nth term = 3n2 + 2n for n = 0, 1, 2, 3, …

Now the nth term of the sequences that we have so far addressed can be defined in general terms as kn2 – 2n where k = 2, 3, 4, ….

And the nth term of the corresponding “shadow” sequences can be defined in general terms as kn2 + 2n, where k = 2, 3, 4, …

Therefore the “shadow” sequence to the starting sequence that we have already considered i.e. 0, 4, 12, 24, … has as its nth term 2n2 + 2n , for n = 0, 1, 2, 3, … i.e.

0, 4, 12, 24, 40, …,

which gives us the same starting sequence. Again in the “shadow” case we start with negative base 1, with subsequent bases increasing in negative terms by 2.

Thus 4 in negative base 3 = – 22 i.e. –{(2 * – 3) + 2}

And the reverse is also – 22

Thus – 22 = – 22 * 1

So reverse = original number * 1.

And to give one more example,
12 in negative base 5 = – 33 i.e. –{(3 * – 5) + 3}

And – 33 = – 33 * 1

So again reverse = original number * 1.

Thus we have replicated the same result in the negative bases of the “shadow” sequence as in the original starting sequence for positive bases.

Then when we switch to considering these numbers in corresponding positive bases, the same behaviour occurs.

So 4 in base 3 = 11 with the reverse also 11.

And 12 in base 5 = 22 with the reverse also 22.

So uniquely with the starting sequence, with its shadow is the same sequence, the self replicating feature where the original number = the reverse number (i.e. where both are palindromes) applies to interpretation in  positive and corresponding negative number bases.

Then when we went on to consideration of the “shadow” to the next sequence i.e. octagonal, we found that the same behaviour there ( i.e. where reverse = original number * 2) was replicated in negative number bases 1, 4, 7, …

Thus one interesting feature here is that though the gap between relevant number bases is related to the value of n (= 3 in this case) the starting base for all “shadow” cases starts at 1. This is ultimately due to the fact that we are now defining n with respect to 0, 1, 2, 3, ..., whereas formerly we defined n with respect to 1,2 3, ...  from

Then in the “shadow” case of the octagonal, where we now consider results in positive number bases, palindromes results i.e. where reverse = original number * 1.

And this behaviour universally characterises subsequent sequences.

For example the next “shadow” sequence (where the nth term is 4n2 + 2n) for n = 0, 1, 2, 3, … is

0, 6, 20, 42, … with n = 4 and relevant number bases are 1, 5, 9, 13, …

Thus the 1st non-trivial result applies to 6 in negative base 5, which is – 24. And the reverse is – 42 (i.e. 18 in denary terms).

Thus – 42 (reverse) = – 24 * 3 (original number)

And this replicates behaviour for its complementary sequence (in positive number bases).

And when we interpret base 3 in positive terms 6 = 11 (a palindrome) so that

11 (reverse) = 11 (original number) * 1.  

Thursday, March 8, 2018

Extending Relationships for Octagonal Numbers

We have been looking at the octagonal sequence (and its “shadow” sequence) showing how its terms when expressed in appropriate number bases leads naturally to one important form of self-generating numbers i.e. where the same number results, when subtracted from its reverse.

However this in fact represents but a specific example of a more general number phenomenon.

Now when we return to the octagonal numbers, we may recall that the two digits that occur in the respective number bases 2, 5, 8, … (when converting each term to its appropriate number base) represent the unique 2-digit recurring sequence of the reciprocal of 3 in each of these bases.

So again for example, 8 in base 5 = 13 (with 31 – 13 = 13). 13 then equally represents the unique 2-digit sequence of 1/3 in this base (.131313…)

Thus the number in question here (to which 1st reciprocal relates) is 3.

And the 1st relevant number base (through which the respective terms of the octagonal sequence are expressed) = 2 (i.e. 3 – 1). And then subsequent number bases keep increasing by 3.

So we now can express a more general number phenomenon in these terms.

Let n represent a number. Then when we obtain the unique digit sequence of its reciprocal (1/n) in the respective number bases n – 1, 2n – 1, 3n – 1, …, a unique recurring connection will characterise the relationship between each resulting 2-digit number and its reverse (in its respective number base).

The simplest case occurs when n = 2, Therefore the appropriate number bases here to express the unique digit sequence of  1/2 are 1, 3, 5, …

Now 1/2 expressed in base 1 does not have a meaningful expression. But 1/2 in base 3 is .111… Though there is only one recurring digit in this case, we will preserve the first two digits as 2 unique digits will arise when n> 2.  So the digit sequence here is 11.


And in this case 11 is equal to its reverse. So 11 (reverse) = 11 (original number) * 1. And 11 in base 10 = 4.

And this is equally the case for all subsequent number bases. For example in base 5, the reciprocal of 2 = .222… So 22 (reverse) = 22 (original number) * 1. And 22 in base 10 = 12

So when the number (to which the reciprocal relates) is 2 with relevant number bases 3, 5, 7, …,

reverse = original number * 1

Now  when expressed in base 10, these numbers in the respective number bases leads to a unique sequence i.e. the triangular numbers * 4,

0, 4, 12, 24,  …

Then as we have seen in the next case, where 3 is the number to which the reciprocal relates (bases 2, 5, 8, …), a unique 2-digit sequences arise.

And in all these cases (as for example 31 and 13 in base 5),

reverse = original number * 2.

And these numbers in their respective number bases, expressed in base 10, lead to the octagonal sequence of numbers,

1, 8, 21, 40, …

Then when we subtract each term of the original sequence from the octagonal sequence we get

1, 4, 9, 16, ... (i.e. the sum of squares).


And continuing on, in the next case, where 4 is the starting number to which the reciprocal relates, the relevant number bases (for expressing its unique 2-digit sequence) are 3, 7, 11, …

So for example in base 3, 1/4 = .0202…

Thus the unique 2-digit sequence = 02.

Then when we subtract 02 from its reverse we get 20 – 02 = 11

So in denary terms the reverse = 6 and the original number = 2.

Then in base 7,  1/4 = .1515…

Thus the unique 2-digit sequence is 15.

And 51 in denary terms = 36 and 15 = 12

So generalising for all such cases related to starting number 4,

reverse = original number * 3

Once again a unique sequence is associated with each of these original numbers, when expressed in a denary manner i.e.

2, 12, 30, 56, …

In fact we can see a discernible pattern emerging as we move to higher number bases.
Thus the original number in base 3 = 02, in base 7 = 15, in base 11 = 28, base 15 = 3A and so on.

And 2, 12, 30, 56 = 2(1, 6, 15, 28, …)

The terms inside the brackets constitute the hexagonal sequence (which comprises the odd numbered terms of the triangular sequence).

It is fascinating in this context that if now subtract each term of the previous octagonal sequence from each corresponding term of this new sequence, we again obtain

1, 4, 9, 16, … (i.e. the squares of the natural numbers).


So using just one final case for illustration, when the starting number is 5, we consider 1/5 in bases 4, 9, 14, …

1/5 in base 4 = .0303…

Therefore the unique 2-digit sequence = 03 which now constitutes our original number in base 4.

And the 30 = 12 (in denary terms)

So 30 = 03 * 4 (in base 4).

In base 9, 1/5 = .1717…

Therefore the unique 2-digit sequence = 17, which now constitutes our original number in base 9.
And 17 = 16 and 71 (the reverse) = 64 (in denary terms).

So 71 = 17 * 4 (in base 9).

So generalising for all such cases related to starting number 5,

reverse = original number * 4.

Then the corresponding unique associated number sequence (in base 10) is

3, 16, 39, 72, … (A147874 in OEIS)

Once again when we subtract each terms of the previous sequence from the corresponding terms of the new sequence, we obtain,

1, 4, 9, 16,…(the squares of the natural numbers)


Expressed in even more general terms when the starting number (to which the reciprocal 1/n relates in number bases n – 1, 2n – 1, 3n – 1, … then with respect to the original numbers (based on the unique digit sequence of the reciprocal)

reverse = original number * (n – 1)

Thus when the starting number is 6

reverse = original number * 5

We can readily confirm this for 1/6 in base 5 = .0404…

Therefore the unique digit sequence = 04
So the relevant original number (in base 5) = 04 and reverse 40 (i.e. 4 and 20 in denary terms)

Thus 40 = 04 * 5.

Incidentally the sequence (in base 10) associated with these numbers is

4, 20, 48, 88, …  = 4 (1, 5, 12, 22, …)

And the terms inside the brackets comprises the pentagonal sequence.

Once again when we subtract each term of the previous sequence from each corresponding term of the present sequence we obtain

1, 4, 9, 16, … (i.e. the squares of the natural numbers). And this appears to be universally the case.


We can therefore write down immediately the unique digit sequence in the next case(for n = 7) by adding each of these sum of square terms to the respective term in the previous sequence, to obtain

5, 24, 57, 104, …

So 5 in base 6 = 05
And 50 = 05 * 6 (in base 6)
Likewise 24 in base 13  = 1B
And its reverse B1 = 11* 13 + 1 = 144
And 144 (reverse) = 24 (original number * 6).

So starting with the original sequence (where n = 2), we can directly generate all further sequences by simply adding each term of the original sequence to the corresponding term of the sum of squares.system.    

Tuesday, March 6, 2018

More on Octagonal Numbers

We have already considered the octagonal numbers,

1, 8, 21, 40, 65, 96, ..., in the respective bases, 2, 5, 8, 11, 14, ..., where they are self generating to that when each number, in its respective number base is subtracted from its reverse, the same number re-occurs.

So for example the appropriate number base to consider 21, is base 8.

And 21 (in denary terms)  = 25 (in base 8).  Thus the reverse of 25 = 52.

And 52 – 25 = 25.

Now another way of expressing this result is that 25 = 52 * 1/2 (in base 8).



Equally we considered the "shadow" counterpart of the octagonal numbers


0, 5, 16, 33, 56, 85, ..., in the respective negative bases – 1, – 4, – 7, – 10, – 13, ...
 , where they are equally self-generating so that again when each number is subtracted from its reverse, the same number re-occurs.

So for example the appropriate number base to consider for 16 is base – 7.


And in base – 7, 16 (in denary terms) = 35. Once again 5 here relates to + 5, while 3 = – 7 * 3 = 

– 21. So  35 = – 21 + 5 = – 16. 

Therefore 16 (in denary terms)  35 (in base – 7).

And the reverse of 35 = 53 =  – {(– 7 * 5) + 3}  – (– 35 + 3) = 32.

So 53 – (35 ) = 35  i.e. 32 – 16 = 16 (in denary terms).   

And again another way of expressing this result is  – 35 =  – 53 * 1/2 (in base – 7).



In this context, it is therefore interesting to see what happens when we now - with reference to our original octagonal sequence - change the respective number bases to their negative counterparts, and then - with reference to the "shadow" sequence - change the respective negative number bases to their positive counterparts.


So again using 21 in the original sequence to illustrate now in base – 8, this would be written as

– 33 i.e. – {(– 8 * 3) + 3},
So the number here is palindromic so that when subtracted from its reverse 0 will result.

However another way of expressing this result is – 33 =  33 * 1 (in base – 8),

So in the case of its respective positive number base each term of the octagonal sequence is equal to half of its reverse number; however in the case of the corresponding negative number base, each term is now equal to its reverse number.

This is also borne out with reference to the "shadow" octagonal sequence, now considered for respective positive number bases.

So 16 in base 7 = 22 (which of course being a palindrome is equal to its reverse).
So 16 (i.e. 35 in base – 7) is half of its reverse (53).
However 16 (i.e. 22 in base 7) is equal to its reverse (22).

These results can then be extended for both sequences in the respective number bases to 3, 4, ..., digit numbers where a digit (1 less than the number base in question) is continually inserted between 1st and last digits..

Mind you it is very tricky showing this in negative number bases.

For example we can extend this in the case of our example of  35  (in base – 7)

So we insert 6 (which 1 less than the positive base 7) to get 365  However this now calculates as – {(5 + (6 * 7) – (3 * 49)} = – (5 + 42 – 147) = 100 (in denary terms).

Then the reverse  563 calculates as – {(3 + (6 * 7) – (5 * 49)}  = – (5 + 42 – 247) = 200 (in denary terms).

So again the starting number is half of its reverse.

Then for the positive number base 7, 100 (in denary terms)  = 202 (which is a palindrome)
So now the starting number is equal to its reverse in this number base.  


Interesting further connections can be shown as between the octagonal number sequence and its "shadow" sequence.

If one looks at the entry on Octagonal Numbers at Mathworld one can see how geometrically the octagonal sequence can be represented.

So in the 1st diagram we have 1 point (the 1st number in the sequence).
In the 2nd, we have now 8 points (the 2nd number in the sequence).
Now each new circle drawn from the same starting point includes 8 additional points.

So in the 3rd diagram the inner circle contains 8 points and the outer circle 16 points. However 3 of these points are common to both circles. So the total no. of points (where each point is counted once) = 8 + 16  – 3 = 21 (the 3rd number in sequence).

Then in the next diagram a further circle is added this time containing 24 points. However with respect to the 1st circle 3 points repeat and with respect to the second 5 points.
So the total of non-repeating points = (8 + 16 + 24) – (3 + 5) = 40 (the 4th number in the sequence.

In fact a very interesting pattern emerges: 
                                                        
So we have 1 * 8                       =   8
                   3 * 8 (– 3)               = 21
                   6 * 8 (– 3 – 5)         = 40 
                 10 * 8 (– 3 – 5 – 7 )  = 65 

So in fact, each  (n + 1)th term of the octagonal can be represented as the product of the corresponding nth term of the triangular series * 8 (minus an adjustment based on sum of the odd integers except 1).  


The sum of 1st n odd integers = n2 .



And because 1 is not included the sum of 3 + 5 + 7 + …  = n2 – 1.



The nth term of the triangular sequence = n(n + 1)/2.
 
Therefore for example the (n + 1)th term of the octagonal,


= {n(n + 1)/2} * 8  –  n2 + 1.

Then when n = 5 (i.e. 6th term of octagonal sequence) we thereby obtain,
(15 * 8) – 25 + 1 = 120 – 24 = 96.


A geometric basis can also be found for the “shadow” octagonal system relating to non-overlapping points within the circles.

For example in the first circle (of 8) there are no overlapping points.

So the first number in the “shadow” sequence = 0.

Then in the next representation, there 3 over-lapping points on the inner circle (leaving 5 points that do not overlap)

So the second number in the “shadow” sequence = 5.

Then in the next diagram there are 5 additional over-lapping points on the 2nd circle (of 16 points).

Thus the total number that do not overlap with respect to both circles = 5 + 11 = 16

So the third number in the “shadow” sequence = 16.

Then in the final diagram there are an additional 7 over-lapping points with respect to the 3rd circle (of 24 points).

Thus the total number of points that do overlap with respect to the 3 circles = 5 + 11 + 17 = 33.

And the 4th number in the “shadow” sequence = 33.


Therefore, the (n + 1)th term of the shadow” sequence =  {n(n + 1)/2  * 8} – (n + 1)2 + 1}

Thus the 5th term = (10 * 8) – 25 + 1 = 80 – 24 = 56.     

Incidentally one simple implication of the above is that the nth term of the "shadow" octagonal series = nth term of octagonal series i.e. {3n2 – 2n}, 2n + 1.