Exponential function calculator
The exponential function calculator evaluates f(x) = a·b^x in a single call: you provide the coefficient a, the base b and the exponent x, and it returns the computed value.
Run — free
It handles positive, negative and fractional exponents, applies the coefficient after the power, and rejects the one combination that is not a real number — a negative base with a non-integer exponent. Use it to model growth, decay or any scaled power relationship without writing the formula yourself.
What a·b^x actually means
An exponential function has three parts, and each one answers a different question. The base b is the growth factor: at 1.05 something grows by five percent per step, at 0.5 it halves. The exponent x is how many steps have passed — time periods, doubling cycles, compoundings. The coefficient a is the starting amount, the value when x is zero, because b raised to zero is one and only a remains. The exponential function calculator takes those three numbers and returns a·b^x directly, so a population that starts at 2 and triples for 4 periods comes back as 2·3⁴ = 162. Fractional exponents are supported too: 3·4^0.5 is 3 times the square root of 4, which is 6. Negative exponents give reciprocals, so 5·2^-3 is 5 divided by 8. Every combination that produces a real number is accepted and evaluated exactly as the formula states.
How the value is computed
The evaluation is a pure, deterministic computation with no approximation heuristics: the power b^x is computed first and the coefficient multiplies the result afterwards, which is the standard order of the formula. Inputs must be finite numbers, because an infinite or missing coefficient would make the output meaningless. Two input combinations are rejected with a clear error instead of returning nonsense. The first is a negative base with a non-integer exponent — something like (-2)^1.5 — which is not a real number, since it would involve an even root of a negative value. The second is a base of zero with a negative exponent, which is a division by zero. Results are rounded to twelve significant digits so the same request returns byte-identical output on any machine, which matters when you compare or cache responses. Nothing is stored, no network call is made, and the same code runs in the free browser widget and behind the paid API.
Where it fits in real work
Exponential models appear anywhere a quantity changes by a fixed factor rather than a fixed amount: compound interest, radioactive decay, bacterial growth, signal attenuation, viral spread. Teams wire this endpoint into spreadsheets, dashboards and scheduled jobs so the formula lives in one reviewed place instead of being retyped into every report. A pricing service can project usage that grows eight percent a month; a data pipeline can backfill the expected remaining mass of a decaying sample; a classroom tool can check hundreds of student answers against one reference evaluation. Because the evaluation is deterministic and side-effect free, it is safe to call at high volume and cheap to cache. It costs $0.002 per request through the API, and the identical calculation runs free in the browser on this page, so you can verify a value interactively before you automate it. No account data crosses the boundary: three numbers in, one number out.
What you can do with it
Project compound growth
Evaluate an investment or usage metric that grows by a fixed percentage per period: coefficient as the starting amount, base as 1 plus the rate, exponent as the number of periods.
Model exponential decay
Compute the remaining amount of a decaying quantity by using a base between 0 and 1, such as half-life with base 0.5 and the elapsed half-lives as the exponent.
Check answers at scale
Validate student work or generated datasets by evaluating a·b^x server-side and comparing against submitted values with one deterministic reference.
FAQ
What does it cost?
$0.002 per request via the API. The same calculation is free in the browser widget on this page.
What formula does it evaluate?
f(x) = a·b^x: the base is raised to the exponent first, then multiplied by the coefficient.
Why was my negative base rejected?
A negative base only produces a real number when the exponent is an integer. A non-integer exponent would require an even root of a negative value, so the request is rejected as invalid input.
Can the exponent be fractional or negative?
Yes. Fractional exponents give roots (4^0.5 = 2) and negative exponents give reciprocals (2^-3 = 0.125), as long as the base is not negative for fractional exponents.
Is anything stored or sent to a third party?
No. The evaluation is a pure local computation: the three numbers are processed and discarded, and only the result is returned.
For developers — API access
Everything on this page is available programmatically. This section is for teams who want to wire it into their own systems; everyone else can just use the tool above.
API endpoint
Prefer to automate it? One authenticated POST creates the task; the result comes back by webhook or a signed link. The same capability also runs here on the web, by email and from Telegram — and soon from our app too.
Call it from your stack
curl -X POST https://api.kit.forhosting.com/math/exponential-function \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"coefficient":2,"base":3,"exponent":4}'const res = await fetch("https://api.kit.forhosting.com/math/exponential-function", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"coefficient": 2,
"base": 3,
"exponent": 4
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/math/exponential-function",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"coefficient": 2,
"base": 3,
"exponent": 4
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/math/exponential-function", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"coefficient":2,"base":3,"exponent":4}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"coefficient":2,"base":3,"exponent":4}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/math/exponential-function", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"coefficient": 2,
"base": 3,
"exponent": 4
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "math.exponential_function",
"status": "queued",
"_links": {
"result": "/tasks/tsk_…/result"
}
}The API is asynchronous: the call returns a task_id immediately and the result arrives by webhook. Polling is capped at 1 req/s per task.
Pricing
Published price — no tokens, no invented credits. A failed task is never charged.
Errors
| HTTP | Code | Meaning |
|---|---|---|
401 | unauthorized | Missing or invalid API key. |
402 | insufficient_balance | Your balance doesn't cover the task price. |
404 | unknown_type | That task type doesn't exist. |
429 | rate_limited | Too many requests. Use the webhook instead of polling. |