Daily DAX : Day 393 EXP
Power BI DAX: The EXP Function
The EXP function in DAX returns e raised to the power of a given number (i.e., the mathematical constant ex).
Syntax
EXP(<number>)
- <number>: A scalar numeric expression (column, measure, or literal value).
Note: e ≈ 2.718281828459 (Euler's number).
EXP(1) returns e.
How It Works
The EXP function computes:
ex where x is the input value.
Examples:
EXP(0)→ 1EXP(1)→ 2.71828...EXP(2)→ 7.38905...EXP(-1)→ 0.36787...
Use Cases
1. Exponential Growth Modeling
Simulate compound growth, population increase, or investment returns.
Projected Population =
INITIAL_POPULATION * EXP(GROWTH_RATE * YEARS)
2. Financial Calculations (Continuous Compounding)
Calculate future value with continuous interest:
Future Value =
PRINCIPAL * EXP(RATE * TIME)
3. Logarithmic Transformations (Inverse of LN)
Reverse natural log operations:
Original Value = EXP(LN(Value))
4. Statistical & Scientific Modeling
Used in probability density functions, decay models, etc.
Real-World Example: Continuous Compounding Interest
Monthly Interest FV =
1000 * EXP(0.05 * 3) // £1,000 at 5% continuous rate for 3 years
// Result ≈ £1,161.83
Tips
- Use
EXPwithLNfor transformations. - Avoid very large inputs (>700) to prevent overflow.
- Pair with
POWERfor base-10 exponentials:EXP(x * LN(10)) = 10^x
Pro Tip:
EXP is more accurate than POWER(E(), x) due to optimized internal computation.
Comments
Post a Comment