This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A005378 M0263 #70 Jul 02 2025 16:01:54 %S A005378 1,1,2,2,3,3,4,5,5,6,6,7,8,8,9,9,10,11,11,12,13,13,14,14,15,16,16,17, %T A005378 17,18,19,19,20,21,21,22,22,23,24,24,25,25,26,27,27,28,29,29,30,30,31, %U A005378 32,32,33,34,34,35,35,36,37,37,38,38,39,40,40,41,42,42,43,43,44,45,45 %N A005378 The female of a pair of recurrences. %C A005378 F(n) is not equal to M(n) if and only if n+1 is a Fibonacci number (A000045); a(n) = A005379(n) + A192687(n). - _Reinhard Zumkeller_, Jul 12 2011 %C A005378 Differs from A098294 at indices n = 0, 17, 20, 22, 25, 27, 29, 30, ... - _M. F. Hasler_, Jun 29 2014 %D A005378 Hofstadter, "Goedel, Escher, Bach", p. 137. %D A005378 N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence). %H A005378 Reinhard Zumkeller, <a href="/A005378/b005378.txt">Table of n, a(n) for n = 0..10000</a> %H A005378 D. R. Hofstadter, <a href="/A006336/a006336_1.pdf">Eta-Lore</a> [Cached copy, with permission] %H A005378 D. R. Hofstadter, <a href="/A006336/a006336_2.pdf">Pi-Mu Sequences</a> [Cached copy, with permission] %H A005378 D. R. Hofstadter and N. J. A. Sloane, <a href="/A006336/a006336.pdf">Correspondence, 1977 and 1991</a> %H A005378 J. Shallit, <a href="https://arxiv.org/abs/2308.06544">Proving properties of some greedily-defined integer recurrences via automata theory</a>, arXiv:2308.06544 [cs.DM], August 12 2023. %H A005378 Th. Stoll, <a href="https://web.archive.org/web/2024*/https://www.fq.math.ca/Papers1/46_47-1/Stoll_11-08.pdf">On Hofstadter's married functions</a>, Fib. Q., 46/47 (2008/2009), 62-67. - from _N. J. A. Sloane_, May 30 2009 %H A005378 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/HofstadterMale-FemaleSequences.html">Hofstadter Male-Female Sequences.</a> %H A005378 <a href="/index/Ho#Hofstadter">Index entries for Hofstadter-type sequences</a> %H A005378 <a href="/index/Go#GEB">Index entries for sequences from "Goedel, Escher, Bach"</a> %F A005378 F(0) = 1; M(0) = 0; F(n) = n-M(F(n-1)); M(n) = n-F(M(n-1)). %t A005378 f[0] = 1; m[0] = 0; f[n_] := f[n] = n - m[f[n-1]]; m[n_] := m[n] = n - f[m[n-1]]; Table[f[n], {n, 0, 73}] (* _Jean-François Alcover_, Jul 27 2011 *) %o A005378 (Haskell) %o A005378 a005378 n = a005378_list !! n %o A005378 a005378_list = 1 : zipWith (-) [1..] (map a005379 a005378_list) %o A005378 a005379 n = a005379_list !! n %o A005378 a005379_list = 0 : zipWith (-) [1..] (map a005378 a005379_list) %o A005378 -- Without memoization the original recursion would be feasible only for small n. %o A005378 -- _Reinhard Zumkeller_, Jul 12 2011 %Y A005378 Cf. A005379. %K A005378 nonn,nice,easy %O A005378 0,3 %A A005378 _N. J. A. Sloane_ %E A005378 More terms from _James Sellers_, Jul 12 2000 %E A005378 Comment corrected by _Jaroslav Krizek_, Dec 25 2011