Hex Editor - Binary File Editing Software for Windows
Download Hex Editor Neo Hide this button

Arithmetic Operations

Arithmetic operations include Negation, Addition, Subtraction, Multiplication, Division and Remainder. The first operation does not require an operand, while all others require the operand of a given size. More information is provided in the table below (in the table below x is a variable that represents a current value):

NameOperandOperation Description
NegationN/Ax = -x
Additionax = x + a
Subtractionax = x - a
Multiplicationax = x * a
Divisionax = [x / a]
Remainderax = x % a
Set Minimumax = x < a ? a : x
Set Maximumax = x > a ? a : x

Arithmetic Operation Window

When you execute an arithmetic operation, the following window appears:

Arithmetic Operation Dialog

The operation you chose is automatically selected, but you can change it if you like.

If selected operation requires an operand, select its type and enter its value.

Alignment

Non-byte size operands are always aligned.

Scripting

Scripts may execute bitwise operations using the IDocumentView.arithmeticOpAsync method.