# Calculator and Converter

<figure><img src="https://3415716535-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRoaqpM3GSf9vXxRAagbV%2Fuploads%2Fgit-blob-74bf1e89d613ab98f9718110d6fe702dd4e5ad63%2Fimage%20(42).png?alt=media" alt=""><figcaption></figcaption></figure>

The calculator is used to perform arithmetic operations, ranging from the simplest operations to the most complex ones, powered by the StringMath library. Its syntax reference can be reviewed in the below link to the official library documentation.

{% embed url="<https://github.com/miroiu/string-math/blob/master/README.md>" %}

<figure><img src="https://3415716535-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRoaqpM3GSf9vXxRAagbV%2Fuploads%2Fgit-blob-48a832a019751b35c395e297cce04557edebf984%2Fimage%20(73).png?alt=media" alt=""><figcaption></figcaption></figure>

The unit converter, however, is used to easily convert the source units to different units, like centimeters to meters. It's powered by the UnitsNet library. You can consult the list of units UnitsNet supports here:

{% embed url="<https://github.com/angularsen/UnitsNet/tree/master/UnitsNet/GeneratedCode/Units>" %}

To use both the programs, refer to the command usages and individual explanations below.

* `calc <expression>`
  * Calculates the specific arithmetical expression
* `unitconv <unittype> <quantity> <sourceunit> <targetunit>`
  * Converts the unit by quantity and type from the source unit to the target unit

<figure><img src="https://3415716535-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FRoaqpM3GSf9vXxRAagbV%2Fuploads%2Fgit-blob-63d5e85be2fc996e540778634e8471ff1b7e7eba%2Fimage%20(47).png?alt=media" alt=""><figcaption></figcaption></figure>

You can use the `listunits` command to get all the available units by type.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://aptivi.gitbook.io/deprecated/nitrocid-ks-v0.1.0-beta-2-manual/fundamentals/simulated-kernel-features/calculator-and-converter.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
