Forgot to remove calc_freq variable :(. Now it is ok!