Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Periodic Strings
#14
Very interesting.

We know one thing immediately: all strings must repeat at some point because there is a limit of how many numbers can be cycled through.

The general equation is such:

A(1) through A(m) = 1

Starting with A(m+1),
A(n) through A(n+D) = digits [where digits = D] of:
sum(A(k)) where k = n-1 through n-m.


A(X) through A(X+Z) = A(X+Z+1) through A(X+2Z) = A(X+2Z + 1) through A(X+3Z) ...

Find the formula for X, Z, and Y for any "m".

-----------------------------------------


One solution is to pre-generate a very large string, then convert each string to 9 separate strings. Each one would either contain the number 0-9 or "-". Then convert that to frequencies of that number or "-". Drop the last empties.

Code:
Example, arbitrarily set end to 25:
1123581347 1123581347 11235 becomes:
11----1--- 11----1--- 11---
--2------- --2------- --2--
---3---3-- ---3---3-- ---3-
----5----- ----5----- ----5
-----8---- -----8---- -----
--------4- --------4- -----
---------7 ---------7 -----

1: 241324132-
2: 219191-
3: 3131513151-
4: 7191-
5: 4159191
6:
7: 9191-
8: 51491-
9:
Skip the empty ones.

You can generate this list automatically as you go. Apply your basic Gual repeating sequence finder to all of these new ones. If all of them are found to be repeating, you can stop and figure out what the big sequence is.. I haven't figured out how to do that bit though. It seems so simple but I just can't figure out exactly how to do it.

You can make the number sequence go in hundreds or thousands instead as well.

You can also get the sequences inside THESE sequences... and so on...
Peace cannot be obtained without war. Why? If there is already peace, it is unnecessary for war. If there is no peace, there is already war."

Visit www.neobasic.net to see rubbish in all its finest.
Reply


Messages In This Thread
Periodic Strings - by whodat - 10-20-2005, 09:43 PM
Periodic Strings - by Antoni Gual - 10-21-2005, 05:05 AM
Periodic Strings - by whodat - 10-21-2005, 06:51 AM
Periodic Strings - by Mango - 10-21-2005, 07:00 AM
Periodic Strings - by Antoni Gual - 10-21-2005, 01:05 PM
Periodic Strings - by Quibbler - 10-22-2005, 01:14 AM
Periodic Strings - by whodat - 10-23-2005, 02:00 AM
Periodic Strings - by Quibbler - 10-24-2005, 07:02 PM
Periodic Strings - by Quibbler - 10-25-2005, 01:16 AM
Periodic Strings - by whodat - 10-25-2005, 01:46 AM
Periodic Strings - by Antoni Gual - 10-25-2005, 02:42 AM
Periodic Strings - by whodat - 10-25-2005, 05:35 AM
Periodic Strings - by Antoni Gual - 10-25-2005, 04:10 PM
Periodic Strings - by Agamemnus - 10-31-2005, 09:30 AM
solution for order 9 string - by whodat - 11-02-2005, 04:17 AM
Periodic Strings - by Agamemnus - 11-02-2005, 06:23 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)