possible function for frequency