# Advanced Calculator & Profiling (IVS Project 2)

Welcome to the developer documentation for the **Advanced Calculator** project. This application was developed as part of the IVS (Practical Aspects of Software Engineering) course.

The project consists of a robust mathematical library, a graphical user interface (GUI) built with PyQt5, and a standalone profiling application for statistical calculations.

---

## Key Features

### 1. Graphical Calculator

A fully featured desktop calculator that supports keyboard input and handles errors gracefully.

- **Basic Arithmetic:** Addition (`+`), Subtraction (`-`), Multiplication (`*`), Division (`/`)
- **Advanced Operations:** \* Factorial (`!`)
  - Exponentiation (`^`)
  - General Root (`√`)
  - Modulo (`%`)
  - Mathematical constants (e.g., `π`)

### 2. Standard Deviation Profiling

A command-line tool built on top of the shared math library. It reads floating-point numbers from standard input and calculates the sample standard deviation. It is optimized and profiled to handle up to 1,000,000 inputs efficiently.

---

## Building and Running

This project includes a GNU `Makefile` to automate common tasks. Open your terminal in the root directory of the project and use the following commands:

- `make run` - Launches the graphical calculator application.
- `make test` - Runs the automated unit tests for the mathematical library.
- `make stddev` - Compiles the standard deviation profiling program.
- `make doc` - Generates this Doxygen documentation.
- `make pack` - Packages the repository into a `.zip` archive for submission.
- `make clean` - Removes generated files and cleans the directory.
- `make help` - Displays instructions for compiling and running the project.

---

## Supported Environments

The application and its installers have been fully tested and are guaranteed to work flawlessly on the following provided virtual environments:

- **Ubuntu 24.04 (64-bit)**
- **Windows 11 (64-bit)**

---

## Authors (Team)

- **Jiří Hronský** (GUI & Event Handling)
- **Adam Bajtay** (Calculator Logic & State Management)
- **Daniel Prsek** (Unit Testing & Quality Assurance)
- **Jan Kostečka** (Math Library & Profiling Tool)

---

## License

This software is distributed under the terms of the **GNU GPL v3** License.
