login
Numbers n which are anagrams of n+9.
3

%I #54 Sep 08 2022 08:46:05

%S 12,23,34,45,56,67,78,89,101,112,123,134,145,156,167,178,189,201,212,

%T 223,234,245,256,267,278,289,301,312,323,334,345,356,367,378,389,401,

%U 412,423,434,445,456,467,478,489,501,512,523,534,545,556,567,578,589

%N Numbers n which are anagrams of n+9.

%C Numbers with at least 2 digits, ending in digits d and d+1 (and d<=8). - _Joerg Arndt_, Aug 28 2013

%C First differences are 9-periodic: 11,11,11,11,11,11,11,11,12. - _Ralf Stephan_, Aug 28 2013

%H JungHwan Min, <a href="/A228157/b228157.txt">Table of n, a(n) for n = 1..1000</a>

%F From _Chai Wah Wu_, Dec 23 2016: (Start)

%F a(n) = a(n-1) + a(n-9) - a(n-10) for n > 10.

%F G.f.: x*(-x^9 + 12*x^8 + 11*x^7 + 11*x^6 + 11*x^5 + 11*x^4 + 11*x^3 + 11*x^2 + 11*x + 12)/(x^10 - x^9 - x + 1). (End)

%t Reap[Do[If[Sort@IntegerDigits[n] == Sort@IntegerDigits[n + 9], Sow[n]], {n, 500}]][[-1, 1]] (* _JungHwan Min_, Jan 05 2016 *)

%t Select[Range[0, 1000], Sort[IntegerDigits[#]] == Sort[IntegerDigits[# + 9]] &] (* _Vincenzo Librandi_, Jan 06 2016 *)

%o (Magma) [n: n in [0..600] | Sort(Intseq(n)) eq Sort(Intseq(n+9))]; // _Bruno Berselli_, Jan 08 2016

%K base,easy,nonn

%O 1,1

%A _Alan Bryant_, Aug 16 2013