Correlation between 2 functions
If you want to merely compare the periods of the functions $f_1$ and $f_2$, you could use the following "metric" (it might not technically be one if it disobeys the triangle inequality, but someone else will have to check for that):

$\Delta (f_1, f_2) \equiv \dfrac{\left| T_1 - T_2 \right|}{\max {T_1, T_2}}$

Then the similarity can simply be defined as $s(f_1, f_2) \equiv 1-\Delta(f_1, f_2)$