DEG uses degrees: sin(30) = 0.5. RAD uses radians: sin(pi/6) ≈ 0.5. Explicit angle units override this choice.
Find a task
No matching tools. Try a different word.
Bisection · real numbers · 64 working digits. Tolerances: xAbs = xRel = fRel = 1e−12.
Syntax & example
Uses Calculator arithmetic, angle and word settings. Definitions stay in this page unless needed by saved history.
No definitions yet. Define rate = 0.21, then total(netAmount) = netAmount*(1+rate).
Names, dependencies & examples
Names are case-sensitive ASCII letters, then letters, digits or underscores; up to 32 characters. Built-in functions, units, constants, Ans and M are reserved. Define a name before referring to it. Cycles and recursion are refused; a rejected edit keeps the previous definition.
Variables: rate = .21. Functions: name total, parameter netAmount, formula netAmount*(1+rate). Calculate total(100) for 121. Functions have 1–8 unique parameters. Ans/M are not allowed in definition formulas: save an explicit named value instead.
Bit operations & word wrapping
Ordinary +, −, *, / and ^ are mathematical operations: 127+1 is 128. Use word(x) to wrap explicitly; wadd(a,b), wsub(a,b), wmul(a,b) wrap their arithmetic result to the chosen width. Signed words use two’s complement. Overflow and lost bits are reported.
Bit functions require exact integers in the selected range or explicitly constructed words. Shift counts must be integers from 0 to one less than the width. word(255,8,signed) is −1 with pattern 0xFF; lshr(-2,1) in 8 signed is 127, while ashr(-2,1) is −1. ^ remains power; % remains percentage.
Base syntax & examples
0b101.01 = 21/4, 0xA.F = 175/16. Repeating digits use parentheses: decimal 0.1 converts to 0b0.0(0011). The selected source base reads free digits such as FF; a prefix must agree with it. Copied output includes the prefix.
Convert result retains the evaluated value and its approximation status; it does not reinterpret display digits in From.
Saved inputs and variables
Result
Rounded display
Working digits
Up to 64 working digits; these are not guaranteed correct or exact.
Steps for your calculation
Last operations shown. Open Step details for every available step.
Step details
Powers & logsTrigonometryMore functions
History
Off by default. Up to 50 calculations, for 30 days each, within 1 MiB. Datasets, matrices, methods and only needed variables/settings are saved with each calculation. Older open versions need a reload before Clear can affect all history versions.
No calculations yet.
Keep word width and signedness explicit
Choose 8, 16, 32 or 64 bits and signed or unsigned interpretation. Operands must be exact integers within that word range. Use word(value) for an explicit wrap; a word from a different width or signedness must be recast explicitly.
A word keeps the lowest selected number of bits. Unsigned interpretation reads those bits as a nonnegative integer. Signed two’s complement subtracts 2^width when the highest bit is 1. Word addition, subtraction and multiplication show both the mathematical intermediate and the wrapped result, including overflow.
A left shift fills low bits with zero and discards high bits outside the width. Logical right shift fills high bits with zero. For signed words, arithmetic right shift copies the sign bit; for unsigned words it fills with zero. The shift count must be an integer from zero to width−1.
Widening a signed negative word preserves its value by filling added high bits with 1; this is sign extension. Details retain the actual masks, bit patterns and discarded bits. Copy value includes the word’s width and signedness, so later reuse keeps its interpretation.
Worked example: 127 + 1 in a signed 8-bit word
Ordinary 127+1 gives 128. With Word size 8 and Signed selected, wadd(127,1) first produces the same mathematical value 128. Its retained pattern is 10000000, or 0x80. Signed interpretation gives 128−256=−128, so the calculation reports arithmetic overflow.
In the same context, −2 has pattern 11111110. lshr(−2,1) gives 01111111, or 127. ashr(−2,1) gives 11111111, or −1, because the signed right shift copies the leading 1. Extending −2 to 16 signed bits gives 1111111111111110 and keeps the value −2.
For band(12,10), combine 00001100 and 00001010: their shared 1 bit gives 00001000, or 8. XOR keeps the differing bits instead, giving 00000110, or 6. A 64-bit unsigned word can hold 18446744073709551615 exactly.
Load example fills the form without calculating. Choose its primary action to work it out.
The method and worked example here are original. Sources describe the underlying mathematics or notation; calculation choices and limits are in the precision and syntax guide.