I have the need for a function to predict the sequential value of the decimal part of a communication frequency.

So in the table below I need to be able to derive the "n" value from knowing the "f".

I suspect it is something to do with divide by 4 and the modulus of 5 but can't crack it.

Every 4th it increments by 10 instead of 5.

n f

0 0

1 5

2 10

3 15

4 25

5 30

6 35

7 40

8 50

9 55

10 60

11 65

12 75

etc till

159 990