12:51 pm - Ask LJ: Finding how a sequence of numbers growsI have an infinite sequence of numbers which grows superlinearly and I'm attempting to figure out the formula to figure out the next one.

I can prove that it's not a function x^k where k is a natural number <=7 by taking the numbers and figuring out the difference between the numbers in the sequence, then figuring out the differences between those.

It's worth noting the point of inflection on the 4th level. I don't have more than those 10 numbers unfortunately. It's tempting to believe that the next one on the 7th row would be -160 though.

The numbers always end in either 0 or 5, though they don't switch between 0 and 5 in any sort of regular pattern.

That's all I can think of off hand to try and crack that problem.

Incidentally, this is (in theory) part of a class of functions. Those numbers correspond to resource counts for a game (Travian incidentally) and I'm trying to predict how it grows for a program I'm writing.

The next number is plausible and seems to follow the pattern. There's nothing in the game to suggest the prior number (but that doesn't mean that they don't compute it using a prior term). How'd you come to that solution?

Dividing it by 5 really does remove a lot of the uncertainty. Good eye!

I'd noticed that there's a difference of around 1.28 between each step, but I'd discarded that in favor of trying to find a correction factor

Somewhere in your explanation this time, I was reminded of a class in 2001 -- Computer Engineering 16 in which we figured out a solution for the Fibonacci sequence. I remembered the solution and the interesting bit of trivia, that it involved the golden mean as one of the factors, and that it didn't appear to be something which would return an integer solution. Suddenly all sorts of things came back to me: the master theorem, characteristic equations, and the book for the course which I had sense enough to keep, thankfully.

10 minutes later and it's sitting in front of me. I expect that by the end of the evening, I'll have remembered what would have allowed me to solve this in the first place.

And now I realize why you used 1.28 instead of 1.67 -- you were working on the other sequence I didn't see until just now. I'd thought it was a typo, and forgot about it until ready to close this window down.

Incidentally, what might you have remembered that would have allowed you to solve it?

What I remembered turned out to be slightly different from what I wanted, but I was still in the right place. I had been thinking of solving it as a linear homogenous recurrence with constant coefficients, but that presumed that I already had a generating function for the sequence I wanted.

The master theorem (which I also remembered) was how to find asymptotic bounds for recurrences. Interesting, but not really what I wanted either (after all, I already knew the bounds from all the work I'd scribbled out on the side trying to figure out how to solve it).

What I wanted was to find the generating function for that sequence and, on doing that, solve the relation.