Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
bestappr(sqrt(13),30)给出18/5了我尝试过的任何精度,但更接近的近似值是101/28. 有什么我错过的吗?
bestappr(sqrt(13),30)
18/5
101/28
对于 PARI/GP,
根据定义,如果 |bx - a|,则 a/b 是 x 的最佳有理逼近。< |vx-u| 对于所有 0 < v <= B 的整数 (u,v)。(参见??bestappr)。
??bestappr
所以在这种情况下
|5x - 18| < |28x - 101|
所以 gp 认为 18/5 是更好的近似值。它认为更好的下一个近似值是 119/33,然后是 137/38。