exp10

This page explains how to use the exp10 function in APL.

Use the exp10 function in APL to compute the base-10 exponential of a value: 10^x. It's the inverse of the common (base-10) logarithm function log10.

exp10 is useful when you work with data on a logarithmic scale expressed in powers of ten, such as decibel values, orders of magnitude, or log10-transformed metrics. Apply exp10 to reverse a log10 transformation and return to the original scale.

Usage

Syntax

exp10(x)

Parameters

NameTypeRequiredDescription
xrealYesThe exponent value.

Returns

The base-10 exponential of x: 10^x.

Example

Use exp10 to recover the geometric mean of request durations from a log10-transformed average.

Query

['sample-http-logs']
| where req_duration_ms > 0
| summarize geometric_mean = exp10(avg(log10(req_duration_ms))) by bin(_time, 1h)
| project _time, geometric_mean

Run in Playground

Output

_timegeometric_mean
2024-11-14 10:00:0085.3
2024-11-14 11:00:0092.7
2024-11-14 12:00:0078.1
  • log10: Returns the base-10 logarithm. Use it as the inverse of exp10.
  • exp: Returns e^x. Use it for natural-log-scale transformations.
  • exp2: Returns 2^x. Use it for binary-scale transformations.
  • pow: Raises any base to a power. Use it when the base isn't 10.
  • log: Returns the natural logarithm. Use it together with exp for natural-log-scale analysis.

Other query languages