mersenneforum.org  

Go Back   mersenneforum.org > Fun Stuff > Lounge

Reply
 
Thread Tools
Old 2022-06-16, 23:43   #1
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

1316 Posts
Default Back to the Future Sequence

I recently proposed the following sequence to the OEIS (it’s still being reviewed). I wonder if any of you have any ideas/insights into it. It goes like this: a(1)=1, a(2)=0; for n > 2, a(n) is the number of times a(n - 1 - a(n-1)) has appeared in the sequence. In other words, you look at n, which tells you how many terms to go back by, then you count how many terms there are in the sequence of the value you land on and that is your next term. So beginning with 1,0 as given, here are the first 60 or so terms: 1, 0, 1, 1, 3, 1, 1, 5, 5, 5, 1, 3, 3, 3, 6, 3, 5, 5, 5, 5, 1, 7, 1, 1, 9, 5, 9, 8, 8, 9, 9, 1, 4, 2, 10, 4, 10, 4, 1, 3, 2, 11, 4, 11, 4, 2, 2, 5, 5, 2, 10
I would conjecture that every positive integer will eventually appear. I have no idea what happens with large numbers. I’m curious about the size of the gaps between numbers, also if there’s any constant which the ratio of consecutive terms approaches to the limit. Also what happens for the same sequence starting on different numbers (like 2,0 or 3,0). Lots of questions:) Thanks in advance! (I hope this is the right forum to post to, I wasn’t sure where else it would fit better)
By the way, in case someone uses MatLab here’s code someone on the OEIS wrote:
(MATLAB)
function a = A354971(max_n)
a = [1 0];
for n = 3:max_n
a = [a length(find(a == a(n-1-a(n-1))))];
end
end % Thomas Scheuerle, Jun 15 2022
oreotheory is offline   Reply With Quote
Old 2022-06-17, 02:51   #2
MattcAnderson
 
MattcAnderson's Avatar
 
"Matthew Anderson"
Dec 2010
Oregon, USA

3×389 Posts
Smile

Wow!

That is impressive, oreotheory!
I too have a comment pending at OEIS.
See oeis.org/A272176/ smile :--)

Mine has to do with pairs of prime numbers.

best of luck with yours

(I haven't read yours in detail yet.)

Have a nice day.
Regards,
MCA

Last fiddled with by MattcAnderson on 2022-06-17 at 02:52 Reason: didn't add clickable link yet.
MattcAnderson is offline   Reply With Quote
Old 2022-06-17, 06:59   #3
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

19 Posts
Default

Hi Matt, Thanks for the encouragement, am curious to know your comment about the p+44 series.
It would be awesome if we had a subforum for number series. And maybe another one for visualizations of number series (since they can be beautiful and illuminating in their own right). A separate topic for cellular automata would be cool too…
Best, Neal (or oreotheory) PS My series is fairly simple; the formal definition just seems intimidating, but the steps as described are really simple
oreotheory is offline   Reply With Quote
Old 2022-06-17, 08:05   #4
slandrum
 
Jan 2021
California

23·5·11 Posts
Default

I don't like this series because it grows very slowly, and computation of any element requires looking at every previous element. There's no elegant way of working on part of the series or extending the series without having the entire series up to the point that it's being worked on.

Last fiddled with by slandrum on 2022-06-17 at 08:05
slandrum is online now   Reply With Quote
Old 2022-06-17, 15:52   #5
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

19 Posts
Default

Quote:
Originally Posted by slandrum View Post
I don't like this series because it grows very slowly, and computation of any element requires looking at every previous element. There's no elegant way of working on part of the series or extending the series without having the entire series up to the point that it's being worked on.
Hm, I guess there’s no agreeing on aesthetics. To me, that’s what makes it difficult and interesting. Recaman’s sequence is also based on a recurrence relation. Anyway, like they say, “if you don’t like it, don’t eat it.”
oreotheory is offline   Reply With Quote
Old 2022-06-25, 02:39   #6
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

19 Posts
Default "Back to the Future" Sequence

I admittedly posted this in the lounge and didn't get too much engagement, so I thought I'd try here. I recently proposed the following sequence to the OEIS (it’s still being reviewed). I wonder if any of you have any ideas/insights into it. It goes like this: a(1)=1, a(2)=0; for n > 2, a(n) is the number of times a(n - 1 - a(n-1)) has appeared in the sequence. In other words, you look at n, which tells you how many terms to go back by, then you count how many terms there are in the sequence of the value you land on and that is your next term. So beginning with 1,0 as given, here are the first 60 or so terms: 1, 0, 1, 1, 3, 1, 1, 5, 5, 5, 1, 3, 3, 3, 6, 3, 5, 5, 5, 5, 1, 7, 1, 1, 9, 5, 9, 8, 8, 9, 9, 1, 4, 2, 10, 4, 10, 4, 1, 3, 2, 11, 4, 11, 4, 2, 2, 5, 5, 2, 10
I would conjecture that every positive integer will eventually appear. I’m curious about the size of the gaps between numbers, also if there’s any constant by which it increases to the limit. Also what happens for the same sequence starting on different numbers (like 2,0 or 3,0). Lots of questions:) Really I'm interested in anything you might notice or come up with. Thanks in advance!
oreotheory is offline   Reply With Quote
Old 2022-06-25, 02:41   #7
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

238 Posts
Default

P.S. Here's code people at the OEIS wrote in a few different languages:
(MATLAB) function a = A354971( max_n )
a = [1 0]; c = zeros(1, max_n); c(1:2) = [1 1];
for n = 3:max_n
m = a(n-1-a(n-1))+1;
a = [a c(m)];
c(c(m)+1) = c(c(m)+1)+1;
end
end % Thomas Scheuerle, Jun 15 2022
(PARI) { nb = [0]; for (n=1, #a=vector(81), print1 (a[n] = if (n==1, 1, n==2, 0, nb[1+a[n-1-a[n-1]]])", "); if (#nb < 1+a[n], nb = concat(nb, vector(#nb))); nb[1+a[n]]++) } \\ Rémy Sigrist, Jun 18 2022
(Python)
from collections import Counter
from itertools import count, islice
def agen():
a = [None, 1, 0]; inventory = Counter(a); yield from a[1:]
for n in count(3):
c = inventory[a[n-1-a[n-1]]]
a.append(c); inventory.update([c]); yield c
print(list(islice(agen(), 81))) # Michael S. Branicky, Jun 18 2022
oreotheory is offline   Reply With Quote
Old 2022-06-25, 04:52   #8
Uncwilly
6809 > 6502
 
Uncwilly's Avatar
 
"""""""""""""""""""
Aug 2003
101×103 Posts

5·2,129 Posts
Default

Quote:
Originally Posted by oreotheory View Post
I admittedly posted this in the lounge and didn't get too much engagement, so I thought I'd try here.
Don't do that anymore. Posting the same thing twice just to get responses is likely to get one or both posts deleted. Also it might get you time away.

BTW, I merged the threads.

Last fiddled with by Uncwilly on 2022-06-25 at 04:54
Uncwilly is online now   Reply With Quote
Old 2022-06-26, 00:47   #9
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

19 Posts
Default

Quote:
Originally Posted by Uncwilly View Post
Don't do that anymore. Posting the same thing twice just to get responses is likely to get one or both posts deleted. Also it might get you time away.

BTW, I merged the threads.
Gotcha, thanks. I assume mods are the only ones who can move a thread to another forum.
oreotheory is offline   Reply With Quote
Old 2022-06-26, 01:34   #10
oreotheory
 
oreotheory's Avatar
 
"NT"
May 2022
U.S.

19 Posts
Default Update

Here's the sequence: https://oeis.org/A354971
oreotheory is offline   Reply With Quote
Reply

Thread Tools


Similar Threads
Thread Thread Starter Forum Replies Last Post
Going back to PRP JuanTutors PrimeNet 15 2021-03-09 20:42
Is the work thread sequence match with cpu core sequence? jiangv Hardware 1 2020-04-08 04:29
Non-k over clocking back on henryzz Hardware 1 2016-03-12 13:18
How to go back to work? Nipal Information & Answers 3 2013-09-04 18:20
How to get LL assignment back RickC PrimeNet 12 2011-08-14 02:33

All times are UTC. The time now is 16:15.


Thu Aug 18 16:15:00 UTC 2022 up 13:43, 0 users, load averages: 1.54, 1.49, 1.46

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2022, Jelsoft Enterprises Ltd.

This forum has received and complied with 0 (zero) government requests for information.

Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or any later version published by the Free Software Foundation.
A copy of the license is included in the FAQ.

≠ ± ∓ ÷ × · − √ ‰ ⊗ ⊕ ⊖ ⊘ ⊙ ≤ ≥ ≦ ≧ ≨ ≩ ≺ ≻ ≼ ≽ ⊏ ⊐ ⊑ ⊒ ² ³ °
∠ ∟ ° ≅ ~ ‖ ⟂ ⫛
≡ ≜ ≈ ∝ ∞ ≪ ≫ ⌊⌋ ⌈⌉ ∘ ∏ ∐ ∑ ∧ ∨ ∩ ∪ ⨀ ⊕ ⊗ 𝖕 𝖖 𝖗 ⊲ ⊳
∅ ∖ ∁ ↦ ↣ ∩ ∪ ⊆ ⊂ ⊄ ⊊ ⊇ ⊃ ⊅ ⊋ ⊖ ∈ ∉ ∋ ∌ ℕ ℤ ℚ ℝ ℂ ℵ ℶ ℷ ℸ 𝓟
¬ ∨ ∧ ⊕ → ← ⇒ ⇐ ⇔ ∀ ∃ ∄ ∴ ∵ ⊤ ⊥ ⊢ ⊨ ⫤ ⊣ … ⋯ ⋮ ⋰ ⋱
∫ ∬ ∭ ∮ ∯ ∰ ∇ ∆ δ ∂ ℱ ℒ ℓ
𝛢𝛼 𝛣𝛽 𝛤𝛾 𝛥𝛿 𝛦𝜀𝜖 𝛧𝜁 𝛨𝜂 𝛩𝜃𝜗 𝛪𝜄 𝛫𝜅 𝛬𝜆 𝛭𝜇 𝛮𝜈 𝛯𝜉 𝛰𝜊 𝛱𝜋 𝛲𝜌 𝛴𝜎𝜍 𝛵𝜏 𝛶𝜐 𝛷𝜙𝜑 𝛸𝜒 𝛹𝜓 𝛺𝜔