Finite Field Arithmetic - Arithmetic Example (where The Characteristic Is Not 2)

Arithmetic Example (where The Characteristic Is Not 2)

Addition: (A + B) mod Characteristic
Subtraction: (A - B) mod Characteristic
Multiplication: (A * B) mod Characteristic

This code is vulnerable to timing attacks when used for cryptography.

Read more about this topic:  Finite Field Arithmetic

Famous quotes containing the word arithmetic:

    Under the dominion of an idea, which possesses the minds of multitudes, as civil freedom, or the religious sentiment, the power of persons are no longer subjects of calculation. A nation of men unanimously bent on freedom, or conquest, can easily confound the arithmetic of statists, and achieve extravagant actions, out of all proportion to their means; as, the Greeks, the Saracens, the Swiss, the Americans, and the French have done.
    Ralph Waldo Emerson (1803–1882)