Timeline for How to find period of a discrete sequence?
Current License: CC BY-SA 3.0
18 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Oct 28, 2015 at 8:12 | comment | added | matheorem | @Kuba the search function of stack exchange should be blamed :) I didn't find this post before. Thank you for providing the link | |
Oct 28, 2015 at 8:06 | comment | added | Kuba | closely related: 80163 | |
Oct 28, 2015 at 6:30 | comment | added | matheorem |
@J.M. I understand FindLinearRecurrence . I should use this. I have modified my answer.
|
|
Oct 28, 2015 at 1:55 | comment | added | matheorem |
@J.M. I found a bug in my code. Tally will not work for {1,1,3,1,1,3,1,1,3} . In my previous post quite related to this one mathematica.stackexchange.com/a/69128/4742 , bill suggest me to use "FindLinearRecurrence`. It works, but I don't understand this function, does it always give the right period?
|
|
Oct 28, 2015 at 1:05 | comment | added | matheorem | @DanielLichtblau Oh, thank you for reminding this. I should add that I want the minimal period. | |
Oct 28, 2015 at 1:04 | comment | added | matheorem | @J.M. Thank you for giving me the opportunity. I answered my own question. I won't forget this was enlightened by you and Szabolcs :) | |
Oct 28, 2015 at 1:02 | answer | added | matheorem | timeline score: 3 | |
Oct 27, 2015 at 20:44 | comment | added | Daniel Lichtblau | Modulo the already noted issue of taking successive differences, there is this prior related post. | |
Oct 27, 2015 at 20:37 | comment | added | Daniel Lichtblau | @J.M. The sequence 1,2,1,2,... has three periods. | |
Oct 27, 2015 at 15:48 | comment | added | J. M.'s missing motivation♦ | Might I suggest answering your own question, if you think you've figured it out? :) | |
Oct 27, 2015 at 15:47 | comment | added | matheorem |
@J.M. Enlightened by you and Szabolcs. I figure out this works period[list_] := (list[[# + 1]] - list[[1]]) &@ Length[Tally[Differences[list]]] . period[{1, 2, 4, 5, 7, 8, 10, 11}] gives 3
|
|
Oct 27, 2015 at 15:25 | comment | added | matheorem | @J.M. The result should be 3. Because translate {1,2} by 3 we got {4,5} | |
Oct 27, 2015 at 15:22 | comment | added | J. M.'s missing motivation♦ |
In that case: FunctionPeriod[FindSequenceFunction[Differences[{1, 2, 4, 5, 7, 8, 10, 11}], k], k] .
|
|
Oct 27, 2015 at 15:21 | comment | added | matheorem | @Szabolcs I drop a comment to J.M. | |
Oct 27, 2015 at 15:20 | comment | added | matheorem |
@J.M. Yeah, the "period" is in the sense of crystallography. The crystal structure is periodic. We talk about base and primitive translation vector in condensed matter physics. {1,2,4,5,7,8,10,11} could be viewed as the coordinates of atoms in 1d crystal
|
|
Oct 27, 2015 at 15:14 | comment | added | J. M.'s missing motivation♦ | I think you are using "period" in a different sense from what I'm accustomed to. To use some examples, $1,2,1,2,\dots$ is a $2$-periodic sequence, and $3,3,\dots$ is $1$-periodic. | |
Oct 27, 2015 at 15:06 | comment | added | Szabolcs |
The sequences you show are not periodic at all. But if you apply Differences to them, you do get a periodic sequence.
|
|
Oct 27, 2015 at 14:55 | history | asked | matheorem | CC BY-SA 3.0 |