Approximate the perfect fifth

05AB1E, 19 18 bytes

µ¯ßNLN/3.²<αßDˆ›D–

Try it online!

µ                      # repeat until counter == input
 ¯                     #  push the global array
  ß                    #  get the minimum (let's call it M)
   N                   #  1-based iteration count
    L                  #  range 1..N
     N/                #  divide each by N
       3.²             #  log2(3)
          <            #  -1
           α           #  absolute difference with each element of the range
            ß          #  get the minimum
             Dˆ        #  add a copy to the global array
               ›       #  is M strictly greater than this new minimum?
                D–     #  if true, print N
                       #  implicit: if true, add 1 to the counter

Wolfram Language (Mathematica), 62 60 bytes

Denominator@NestList[Rationalize[r=Log2@3,Abs[#-r]]&,2,#-1]&

Try it online!


JavaScript (V8), 81 80 78 bytes

-2 bytes thanks Arnauld!

n=>{for(d=g=1;w=Math.log2(3),w+=~(w*g-.5)/g,n--;g++)w*w<d?d=print(g)||w*w:n++}

Try it online!