# [seqfan] Re: "What primes P have P^P containing the string 'P' as substring'?"

Charles Greathouse charles.greathouse at case.edu
Tue Apr 27 20:58:18 CEST 2010

```There's A049329, which is numbers n for which n is contained in the
decimal expansion of n^n.  I'm calculating terms for it -- well,
rather for its complement, which I have through 7000.  I'm just using
a very basic perl script, which apart from the fluff is:

#!/usr/bin/perl -w
use strict;
use bignum;
\$|++;

for (my \$n = 1; \$n < 40000; \$n++) {
my \$pow = \$n ** \$n;
if (\$pow !~ /\$n/) {
print "\$n,";
}
}

Charles Greathouse
Analyst/Programmer
Case Western Reserve University

On Tue, Apr 27, 2010 at 10:19 AM, Leroy Quet <q1qq2qqq3qqqq at yahoo.com> wrote:
> Is the base-2 version in the EIS? What about, not limited to primes, the sequence of all n where n is a substring in n^n, for the bases 2 through 10?
>
> Thanks,
> Leroy Quet
>
> [ ( [ ([( [ ( ([[o0Oo0Ooo0Oo(0)oO0ooO0oO0o]]) ) ] )]) ] ) ]
>
>
> --- On Mon, 4/26/10, Jonathan Post <jvospost3 at gmail.com> wrote:
>
>> From: Jonathan Post <jvospost3 at gmail.com>
>> Subject: [seqfan] "What primes P have P^P containing the string 'P' as substring'?"
>> To: "JM Bergot" <thekingfishb at yahoo.ca>, "Sequence Fanatics Discussion list" <seqfan at list.seqfan.eu>
>> Date: Monday, April 26, 2010, 8:07 PM
>> JM Bergot asked me in an email: "What
>> primes P have P^P containing the
>> string 'P' as substring'?"
>>
>> 5^5 = 3125 has "5" as substring.
>>
>> 11^11 = 285311670611 has two substrings of "11"
>>
>> 17^17 = 827240261886336764177  has "17" as 3rd and 2nd
>> digit from right-hand.
>>
>> 19^19 = 1978419655660313589123979 has a "19" as its left
>> end, and another later.
>>
>> 31^31 = 17069174130723235958610643029059314756044734431
>>
>> has a "31" at right-hand end, and a second to the left a
>> ways.
>>
>> A051674 (n-th prime)^(n-th prime).
>>
>> Is there a sequence in there, base and prime related,
>> struggling to be
>> interesting to anyone on seqfans?
>>
>> Eventually, all P^P are pandigital.  But not "normal."
>> Right?
>>
>> Best,
>>
>> Jonathan Vos Post
>>
>>
>> _______________________________________________
>>
>> Seqfan Mailing list - http://list.seqfan.eu/
>>
>
>
>
>
>
> _______________________________________________
>
> Seqfan Mailing list - http://list.seqfan.eu/
>

```