Cube root on x87 FPU using Newton-Raphson method
问题 I am trying to write an assembly program using the 8086 processor that will find the cube root of a number. Obviously I am using floating points. Algorithm based upon Newton-Raphson method: root := 1.0; repeat oldRoot := root; root := (2.0*root + x/(root*root)) / 3.0 until ( |root – oldRoot| < 0.001; How do I divide (2*root + x) by (root*root)? .586 .MODEL FLAT .STACK 4096 .DATA root REAL4 1.0 oldRoot REAL4 2.0 Two REAL4 2.0 inttwo DWORD 2 itThree DWORD 3 three REAL4 3.0 x DOWRD 27 .CODE main