Photo AI

Last Updated Sep 27, 2025

Floating Point Addition & Subtraction Simplified Revision Notes

Revision notes with simplified explanations to understand Floating Point Addition & Subtraction quickly and effectively.

user avatar
user avatar
user avatar
user avatar
user avatar

435+ students studying

Floating Point Addition & Subtraction

Overview

Floating-point arithmetic is crucial for handling real numbers in computing, allowing for both very large and very small values. However, adding and subtracting floating-point numbers involves extra steps compared to integers due to the mantissa and exponent structure. It's important to understand how to correctly align and normalise floating-point numbers during arithmetic operations, especially when dealing with both positive and negative values.

Structure of Floating-Point Numbers

  • Mantissa: Represents the significant digits of the number.
  • Exponent: Determines the position of the binary point, effectively scaling the number.
  • Sign Bit:
    • 0 indicates a positive number.
    • 1 indicates a negative number (using two's complement for the mantissa).

Steps for Floating-Point Addition and Subtraction

To perform addition or subtraction with floating-point numbers:

  1. Align the Exponents:
  • If the exponents differ, shift the mantissa of the smaller exponent to the right until the exponents match.
  1. Add or Subtract the Mantissas:
  • Perform the addition or subtraction on the aligned mantissas.
  1. Normalise the Result:
  • Adjust the mantissa and exponent to ensure the mantissa is normalised (starts with 01 for positive or 10 for negative values).
  1. Handle Overflow or Underflow:
  • Ensure the result fits within the given bit constraints for mantissa and exponent.

Examples

lightbulbExample

Example 1: Addition of Two Positive Floating-Point Numbers Add 1.101×231.101 \times 2^3 and 1.001×211.001 \times 2^1


Step 1: Align Exponents:

Larger exponent: 232^3

Shift the mantissa of 1.001×211.001 \times 2^1 to match 232^3:

1.001×21=0.01001×231.001 \times 2^1 = 0.01001 \times 2^3

Step 2: Add Mantissas:

1.101+0.01001=1.111011.101 + 0.01001 = 1.11101

Step 3: Normalise:

The result is already normalised: 1.11101×231.11101 \times 2^3


Final Answer:

1.11101×231.11101 \times 2^3
lightbulbExample

Example 2: Subtraction of a Positive and Negative Number Subtract 1.101×241.101 \times 2^4 from 1.010×23-1.010 \times 2^3


Step 1: Align Exponents:

Larger exponent: 242^4

Shift the mantissa of 1.010×23-1.010 \times 2^3

1.010×23=0.1010×24-1.010 \times 2^3 = -0.1010 \times 2^4

Step 2: Subtract Mantissas:

1.101(0.1010)=1.101+0.1010=10.0101.101 - (-0.1010) = 1.101 + 0.1010 = 10.010

Step 3: Normalise:

10.010×24=1.001×2510.010 \times 2^4 = 1.001 \times 2^5

Final Answer:

1.001×251.001 \times 2^5

Note Summary

infoNote

Common Mistakes

  • Misaligning Exponents: Ensure the mantissas are adjusted correctly to match the exponents before adding or subtracting.
  • Ignoring Sign Bits: For negative numbers, remember to handle signs correctly (e.g., using two's complement).
  • Skipping Normalisation: Always normalise the result to maintain proper floating-point representation.
infoNote

Key Takeaways

  • Floating-Point Arithmetic: Involves aligning exponents, performing arithmetic on mantissas, and normalising results.
  • Positive & Negative Numbers: Be cautious with sign handling during subtraction and addition.
  • Normalisation: Ensures precision and correct representation after calculations.
Books

Only available for registered users.

Sign up now to view the full note, or log in if you already have an account!

500K+ Students Use These Powerful Tools to Master Floating Point Addition & Subtraction

Enhance your understanding with flashcards, quizzes, and exams—designed to help you grasp key concepts, reinforce learning, and master any topic with confidence!

90 flashcards

Flashcards on Floating Point Addition & Subtraction

Revise key concepts with interactive flashcards.

Try Computer Science Flashcards

9 quizzes

Quizzes on Floating Point Addition & Subtraction

Test your knowledge with fun and engaging quizzes.

Try Computer Science Quizzes

29 questions

Exam questions on Floating Point Addition & Subtraction

Boost your confidence with real exam questions.

Try Computer Science Questions

27 exams created

Exam Builder on Floating Point Addition & Subtraction

Create custom exams across topics for better practice!

Try Computer Science exam builder

12 papers

Past Papers on Floating Point Addition & Subtraction

Practice past papers to reinforce exam experience.

Try Computer Science Past Papers

Other Revision Notes related to Floating Point Addition & Subtraction you should explore

Discover More Revision Notes Related to Floating Point Addition & Subtraction to Deepen Your Understanding and Improve Your Mastery

96%

114 rated

Data Types

Primitive Data Types

user avatar
user avatar
user avatar
user avatar
user avatar

302+ studying

185KViews

96%

114 rated

Data Types

Positive Binary Numbers

user avatar
user avatar
user avatar
user avatar
user avatar

230+ studying

181KViews

96%

114 rated

Data Types

Negative Binary Numbers

user avatar
user avatar
user avatar
user avatar
user avatar

283+ studying

182KViews

96%

114 rated

Data Types

Binary Addition & Subtraction

user avatar
user avatar
user avatar
user avatar
user avatar

207+ studying

185KViews
Load more notes

Join 500,000+ A-Level students using SimpleStudy...

Join Thousands of A-Level Students Using SimpleStudy to Learn Smarter, Stay Organized, and Boost Their Grades with Confidence!

97% of Students

Report Improved Results

98% of Students

Recommend to friends

500,000+

Students Supported

50 Million+

Questions answered