Theory A: If there are K occurrences of a letter X in a sequence of length N, there are at least two occurrences of X such that the distance between them is less than N/K.
Find the min letter and arrange pointers to all of its occurrences in a sorted list. Call it A.
For a given r, find min of letters at A[i]+r, and filter out all the pointers for which element at A[i]+r is not equal to min. Also filter out all the pointers A[j] such that A[j]=A[i]+r for some i.
You will have to run the above statement at most N/K times and each run would cost at most O(K) time. Therefore, the complexity of this algorithm is O(N).
More detailed algorithm:
Assume Z is the circular list we are dealing with.
def filter(A,Z,r):
t = min( Z[A[i]+r] ) forall i
remove A[i] if Z[A[i]+r]!=t forall i
rmflag = [false if A[i]==A[j]+r else false for i in range(len(A)] //NOTE: This step can be done in O(len(A)) time since A is sorted
remove A[i] if rmflag[i]