Hardware Square-Root Circuit Using Bitwise Complement Iteration
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
In computer systems without hardware support for multiply-add operations, the Newton-Raphson method for performing divide and square-root operations requires an extra pass through an adder circuit, increasing the time required for these operations.
Innovation Solution
The system uses a multiplier circuit to iteratively solve the equations xi+1=xi(2−bxi) for division and xi+1=xi(3-bxi^2) for square-root, employing bit-wise complement and shift operations to avoid additional passes through the adder or multiply-add circuit, and utilizes a lookup table for initial estimates and fixed-point multiplication.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Adaptability or versatility
If the Newton-Raphson method is used for divide and square-root operations in systems without hardware multiply-add support, then the operations can be performed using only multiplication, addition, and subtraction, but an extra pass through the adder circuit is required, increasing operation time
Solution Approach 1:
The patent extracts the subtraction operation from the Newton-Raphson iteration and replaces it with a bitwise complement operation. Specifically, the term (2 - b*xi) is computed as the bitwise complement of (b*xi), eliminating the need for subtraction through the adder circuit. This extraction of the problematic subtraction step resolves the contradiction by maintaining compatibility with systems lacking multiply-add hardware while reducing operation time.
Solution Approach 2:
The patent substitutes the mechanical subtraction operation with a bitwise complement operation. Instead of using the adder circuit to perform subtraction (which requires an extra pass), the system uses bitwise complement (NOT operation) which can be performed in parallel with multiplication. This substitution replaces a sequential mechanical operation with a parallel bitwise operation, resolving the time penalty.
2Measurement precision
If standard Newton-Raphson iteration is implemented, then accurate divide and square-root operations are achieved, but the requirement for subtraction operations increases circuit complexity and operation time
Solution Approach 1:
The patent extracts the subtraction operation from the critical path of the Newton-Raphson iteration. By computing (2 - b*xi) as the bitwise complement of (b*xi) rather than through subtraction, the adder circuit is removed from the iteration loop. This extraction maintains computational accuracy while reducing device complexity and operation time.
Solution Approach 2:
The patent inverts the approach to computing (2 - b*xi). Instead of computing 2 minus (b*xi) through subtraction, the system computes the bitwise complement of (b*xi), which is mathematically equivalent in the context of fixed-point arithmetic and Newton-Raphson iteration. This inversion eliminates the need for subtraction hardware, reducing circuit complexity while maintaining accuracy.
Data Source
AI summary
One embodiment of the present invention provides a system that uses the Newton-Raphson technique to compute a square-root. During operation, the system receives a radicand b. Next, the system calculates the square root of b, √{square root over (b)}, by first using the Newton-Raphson technique to find 1/√{square root over (b)}, and then multiplying 1/√{square root over (b)} by b to produce √{square root over (b)}. While using the Newton-Raphson technique to find 1/√{square root over (b)}, the system first obtains an initial estimate x0 for 1/√{square root over (b)} and then iteratively solves the equationxi+1=xi(3-bxi22).Each iteration involves: (1) using a multiplier circuit twice to compute bxi2; (2) performing a bit-wise complement operation on bxi2, shifting the result, and modifying the first two bits of the result to compute3-bxi22,whereby an additional pass through an adder circuit or a multiply/add circuit is not required to perform the subtraction operation; and finally (3) using the multiplier circuit to multiply xi by3-bxi22to computexi(3-bxi22).


