CALCULATOR(1)

πŸ“¦ version 1.6.59, in fedora 43, fedora 44

πŸ’– CALCULATOR(1) πŸ’–

okay so bestie, welcome to the CALCULATOR(1) page from the General Commands Manual β€” yes, the FOX Calculator one, and yes, it's giving "I'm a programmer's calculator and I know it" ✨ let's get into it πŸŽ€


🌸 NAME 🌸

calculator β€” a simple desktop calculator πŸ¦‹


πŸ¦‹ SYNOPSIS πŸ¦‹

calculator

✨ DESCRIPTION ✨

The FOX Calculator is a simple desktop calculator that is geared toward the programmer, fr fr. It's not just out here doing your basic math β€” it supports a whole full complement of scientific functions, plus all the stuff programmers actually need, like bitwise operations, bitwise shifting, base-2 logarithm and exponents, and numeric conversion between hexadecimal, octal, binary, and decimal. she does it all πŸ’…

The FOX Calculator implements correct operator precedences, so expressions like 2+3*5 yield the correct result, which is 17, and not 25. (the way that matters... iconic.) Also featured is a constant memory, which permanently stores its value even if you exit the calculator and restart it later. she remembers. she always remembers 🧚


πŸŽ€ CONFIGURATION πŸŽ€

Pressing on the calculator icon brings up the Calculator Preferences dialog. That dialog comprises three settings:

  • settings for the calculator itself;
  • color settings of the button groups;
  • information about the calculator.

🌈 Calculator settings 🌈

In the Calculator settings panel, you can change the font used for the display, by pressing the Set... button to bring up the standard Font Selection Dialog.

You can change the way numbers are printed as well:

  • checking Always show exponent will cause the calculator display always to display the number in exponential notation;
  • checking Never show exponent will cause the calculator to render the number in simple dot notation.

The precision can be set by means of the spin button; the default precision is set to 16. Finally, the calculator can be set to beep when errors occur πŸ””

🎨 Color settings 🎨

In the Color settings panel, you can change the colors of the various button groups. The buttons are grouped by function; the numbers are in one group, and the operators are in another, and so on. very aesthetic, very curated πŸ’œ

πŸ‘‘ About 🌟

In the About panel, some information is presented about the calculator, like version number and author's contact.


πŸ’… ENTERING NUMBERS πŸ’…

You can enter a number by clicking on the digit buttons, or simply hit the right digit on the keyboard. easy.

Numbers in exponential notation are entered by entering the mantissa first, then hitting the EXP button, and then entering the exponent. Up to 3 digits may be entered for the exponent; entering more than 3 will cause the digits to shift, i.e. the first digit entered will be dropped and replaced by the second, the second digit will be replaced by the third, and the third will be replaced by the new input. she slides, she shifts, she moves on πŸ’«

ngl bestie, the original page just stops mid-sentence right here: "Changing the sign of the exponent is accomplished by hittin the" and then it jumps straight to the next thing. I'm not about to invent the rest of that sentence for you, so that's literally all it says πŸ™ˆ

At any time, you can hit the Backspace key to delete the last digit entered.

Two numbers, pi and e (euler's number) may be entered with a single button:

  • pi β€” enters the number 3.1415926535897932384626433833
  • e β€” enters the number 2.7182818284590452353602874713 (hit the inv button first)

πŸ”₯ OPERATORS πŸ”₯

The operators in the FOX Calculator are the usual suspects:

  • + β€” addition
  • - β€” subtraction (the original page spells it Substraction and honestly? we stan a typo πŸ’€)
  • * β€” multiplication
  • / β€” floating point division

In addition, FOX Calculator also includes bitwise operators, such as:

  • AND β€” bit-wise logical and
  • OR β€” bit-wise logical or
  • XOR β€” bit-wise logical exclusive or
  • NOT β€” bit-wise logical not
  • SHL β€” bit-wise shift left
  • SHR β€” bit-wise shift right
  • SAR β€” bit-wise signed shift right (hit the inv button first)

Also nice for programmers is the inclusion of integer operations:

  • mod β€” integer modulo
  • div β€” integer division (hit the β€” and yeah, the page cuts off right there too, bestie, that's genuinely all it says 😭)

All the operators have certain precedence relations with each other, so that an expression is evaluated correctly. no chaos, only order ✨


🌈 TRIGONOMETRIC FUNCTIONS 🌈

The Calculator incorporates the usual trigonometric functions:

  • sin β€” sine
  • cos β€” cosine
  • tan β€” tangent
  • asin β€” inverse sine or arc sine (hit the inv button first)
  • acos β€” inverse cosine
  • atan β€” inverse tangent
  • sinh β€” hyperbolic sine (hit the hyp button first)
  • cosh β€” hyperbolic cosine
  • tanh β€” hyperbolic tangent
  • asinh β€” inverse hyperbolic sine (hit the hyp and inv buttons first)
  • acosh β€” inverse hyperbolic cosine
  • atanh β€” inverse hyperbolic tangent

For the first 6 functions, the angle mode determines whether the argument is specified in terms of degrees, radians, or grad. Note that the angle mode is preserved across invocations of the Calculator. she keeps her settings, periodt πŸ’œ


⭐ OTHER FUNCTIONS ⭐

Other functions supported by the calculator are the following:

  • log β€” base 10 logarithm
  • ln β€” natural logarithm
  • 2log β€” base 2 logarithm
  • x! β€” factorial
  • nPr β€” permutations
  • nCr β€” combinations
  • sqrt β€” square root
  • x^y β€” x raised to the power y
  • 1/x β€” reciprocal
  • 10^x β€” base 10 exponentiation (hit the inv button first)
  • e^x β€” exponentiation
  • 2^x β€” base 2 exponentiation
  • x^1/y β€” x raised to the power 1/y
  • x^2 β€” x squared

πŸ‘‘ LIMITS πŸ‘‘

The calculator works in IEEE 746 double precision mode; for bit-wise operations, it uses 32 bit integers. Thus, the numeric limits are as follows:

Smallest real number: 2.2250738585072010e-308
Largest real number:  1.7976931348623158e+308
Smallest integer number: 0
Largest integer number: 4294967295

🫢 AUTHOR 🫢

This manpage was originally written by Bastian Kleineidam <calvin@debian.org> for the Debian distribution of the FOX Toolkit.

The main author of FOX is Jeroen van der Zijp <jeroen@fox-toolkit.org>. For a list of contributors see /usr/share/doc/libfox0.99/AUTHORS.


okay that's the whole page, bestie, and we're closing it out on 30 January 2002 β€” the date on the original footer, with CALCULATOR(1) sitting right there in the corner like the main character she is πŸ‘‘ thanks for reading, ily, go do some bitwise math πŸ¦‹πŸ’–βœ¨

πŸ“¦ where this page comes from