---
title: Tag Formula Variables
slug: manufacturing-connect-edge-v2/tag-formula-variables
docTags: 
createdAt: 2023-05-29T17:36:47.000Z
---

When you [Add Tags](docId:-5nFrBQ-uriWOY3GACnPt), you have the option of adding a formula to process the generated data.&#x20;

You can use the following variables:

- `value`: The current tag value.&#x20;
- `timestamp`: The time the tag value was generated represented in UNIX time in milliseconds.&#x20;

You can use the following functions.

:::hint{type="info"}
**Note**: For additional functions on tag values such as rounding and data conversions, you can use [Analytics](docId\:WhB1M3UmJKbHXxzyf6tFT) or the [Flows Manager](docId\:eCK0tQfoy_d2ywgK4h1wq).&#x20;
:::

| **Function**            | **Description**                                                                                                                                                            | **Use**                                                                                                                              |
| ----------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------ |
| sin<br />(sine)         | The ratio of the side opposite a given angle (in a right-angled triangle) to the hypotenuse.                                                                               | Analysis and control of periodic processes.                                                                                          |
| cos<br />(cosine)       | The ratio of the side adjacent to an acute angle (in a right-angled triangle) to the hypotenuse.                                                                           | Analysis and control of periodic processes.                                                                                          |
| sqrt<br />(square root) | The square root of a number is the factor that you can multiply by itself to get that number.                                                                              | Identify deviations from expected values or detect abnormal conditions.                                                              |
| tan<br />(tangent)      | The ratio of the sine of an angle to the cosine of that angle.                                                                                                             | Used in calibration formulas to correct or compensate for non-linearities.                                                           |
| power                   | A function with a single term that is the product of a real number, a coefficient, and a variable raised to a fixed real number. <br />power(`x`) is equivalent to `10^x`. | Perform exponentiation when converting values between different units or applying non-linear scaling.                                |
| log<br />(logarithm)    | The inverse function to exponentiation.<br />log(`x`) is equivalent to the natural logarithm of `x` (a logarithm with base `e`).                                           | Perform logarithmic scaling or conversion when there is a non-linear relationship between the register value and the desired output. |
| exp<br />(exponential)  | Calculates the exponential growth or decay of a given set of data.<br />exp(`x`) is equivalent to the exponential function `e^x`.                                          | Perform exponential scaling or conversion when there is a non-linear relationship between the register value and the desired output. |

