Counting the equal-differences of an permutation I'm interesting in calculating how many permutations of $[n]$ have a consecutive difference (in absolute value) equal. For instance if $n=6$ the permutation $613425$ have common difference $2$ because $|1-3|=|4-2|$ are both equal to $2$ while the permutation $162534$ does not possess them.
I tried counting for some particular cases when all the differences are different and I got that:
If $n=3$, then there are $4$. 
If $n=4$, then there are $4$. 
If $n=5$, then there are $8$.
How could I try to solve the count? Thanks for the suggestions.
P.S.: Sorry for my English, I'm not native. :v
 A: The key to these problems, when you don't see an immediate approach to analyzing a count, is to get data, and look for a pattern. 

Let $f(n)$ be the number of permutations of $[n]$ such that no two of the $n-1$ absolute differences of consecutive terms are equal.

You computed $f(n)$ for $n=3,4,5$, and you found
$$f(3) = 4,\;\;f(4)=4,\;\;f(5)=8$$
But it's not enough data to get a sense of a possible form for $f$.

My intuition was that there is no closed form expression for $f$, but in any case, more data is needed, which calls for writing a program. To analyze obscure counts, programming skills are a valuable asset.

In my case, I used Maple, and found
$$
f(1)=1,\;\;
f(2)=2,\;\;
f(3)=4,\;\;
f(4)=4,\;\;
f(5)=8
$$
$$
f(6)=24,\;\;
f(7)=32,\;\;
f(8)=40,\;\;
f(9)=120,\;\;
f(10)=296
$$
While the data doesn't suggest a clear pattern, at least it's more data.

An oeis lookup with the sequence
$$1,\,2,\,4,\,4,\,8,\,24,\,32,\,40,\,120,\,296$$
is a natural next step, and bingo, we find

$\qquad$https://oeis.org/A006967

which names these permutations as "graceful permutations".

A Google search on "graceful permutations", yields the link

$\qquad$http://mathworld.wolfram.com/GracefulPermutation.html

From these links, it's not clear to me as to whether a closed form for $f(n)$ is known. But such a scenario is not uncommon. There are many combinatorial counts which have a simple definition, but no known closed form.
