Vectorized type conversion for autocorrelation
If this code goes into production then the asserts for the success of calloc() will be optimized out of the code if the code is optimized. Prefer if statements with calls to fprintf(stderr,.
The parameter rate is never used, this can lead to maintenance errors in the future.
For maintenance reasons the ability of someone else to understand the code I would suggest using &amp;input[i] rather than input+ in the function call.