Simplify logarithmic expressions
Type log(100x²/y) + log(y) and get 2 + 2 log(x): the logs are split by the standard rules, the log of 100 becomes exactly 2, and the opposite log(y) terms cancel. Free in your browser.
- Free
- Runs in your browser
- No sign-up
- Your data stays on your device
Run — free
Worked example
- Expression
- log(100*x^2/y) + log(y)
- Simplified
- 2 + 2*log(x)
- Exact constant
- 2
- Terms
- 2
This logarithmic expression simplifier turns a compact typed expression into a reduced, checkable result. Products, quotients, and integer powers inside each logarithm are separated by the standard log laws. Exact numeric components are evaluated when they are integer powers of the base, while symbolic components remain in exact form. Like logarithms are collected, opposite terms cancel, and the response includes a short sequence of steps.
What simplification means for a logarithmic expression
Simplifying a logarithmic expression means rewriting it into a shorter equivalent form without replacing useful exact structure with a decimal approximation. This calculator uses the product rule, which changes the logarithm of a product into a sum; the quotient rule, which changes the logarithm of a quotient into a difference; and the power rule, which moves an integer exponent in front of its logarithm. For example, log(100*x^2/y) becomes 2 + 2*log(x) - log(y) because log base ten of 100 is exactly two.
If another +log(y) appears in the original expression, those opposite symbolic terms cancel. The calculator collects terms only when both their base notation and argument match, so ln(x) is not incorrectly combined with log(x). Numeric arguments must be positive in the real-number setting.
Variables are treated as positive symbolic quantities, which is the conventional assumption behind classroom applications of these identities. The result therefore preserves exact algebra while exposing any constant part that can be proved from an integer power of the relevant base. It never silently converts an inexact logarithm such as log(3) into a rounded decimal.
How to enter expressions and read the response
Provide one expression as text. Each top-level term must be a logarithm, optionally preceded by a numeric coefficient and an asterisk. Join logarithms with plus or minus signs.
Inside a logarithm, use an asterisk for multiplication, a slash for division, and a caret followed by an integer for a power. Simple variable names may contain letters, digits after the first letter, and underscores. Parentheses delimit the logarithm argument; nested algebraic sums and arbitrary functions are outside this focused grammar.
Exact numeric evaluation is intentionally conservative: a positive numeric factor is converted to a constant only when its logarithm is, within strict numeric tolerance, an integer.
Useful checks, boundaries, and study strategies
A good way to check a hand solution is to predict the effect of each rule before submitting the expression. Count product factors as positive log terms, denominator factors as negative terms, and multiply each sign by the factor's integer exponent. Then identify numeric factors that are recognizable powers of the base.
Cancellation is another valuable check: log(x) - log(x) should disappear, and two copies of log(x) should become 2*log(x). For natural logs, powers of the literal factor e evaluate exactly, so ln(e^3*x) reduces to 3 + ln(x). Keep in mind that this tool works over the real numbers and assumes symbolic variables represent positive values; it does not calculate or report a full domain condition.
It also does not distribute a logarithm over addition, because log(a+b) has no corresponding sum rule. Expressions containing nested sums, roots written as radicals, symbolic bases, fractional exponents, equations, or complex values require a broader computer algebra system. The strict grammar is helpful in educational and production settings because every accepted form has one predictable interpretation.
For batch use, normalize generated input to explicit multiplication signs and balanced parentheses. Stay within one thousand characters and sixty-four top-level terms, and use the returned steps as an audit trail rather than treating the final string as an unexplained answer.
What you can do with it
Check algebra homework
Compare a manual application of logarithm laws with a deterministic reduced expression and concise steps.
Generate worksheet keys
Reduce consistent base-ten, natural-log, and numeric-base exercises into stable exact answers.
FAQ
Which logarithm rules are applied?
The calculator applies the product, quotient, and integer power rules, then evaluates exact numeric components and collects like terms.
Why does log(3) stay unchanged?
Only provably exact integer powers of the selected base are evaluated. The tool avoids replacing exact expressions with rounded decimals.
Can it simplify log(x+y)?
No. Logarithms do not distribute over addition, and this focused grammar accepts products, quotients, and integer powers inside arguments.
Why does the log of 100 turn into 2?
Because 100 is ten squared and a bare log uses base ten. Numbers that are whole powers of the base are evaluated exactly, so the constant part appears without being replaced by a rounded decimal.
Will ln(x) and log(x) be combined?
No. Terms are collected only when both the base notation and the argument match, so ln(x) and log(x) stay separate, while two log(x) terms are added together.
Related tools
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/algebra/log-simplify \
-H "Authorization: Bearer $KIT_KEY" \
-H "Content-Type: application/json" \
-d '{"expression":"log(100*x^2/y) + log(y)"}'const res = await fetch("https://api.kit.forhosting.com/algebra/log-simplify", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.KIT_KEY}`,
"Content-Type": "application/json"
},
body: JSON.stringify({
"expression": "log(100*x^2/y) + log(y)"
})
});
const { task_id } = await res.json();import os, requests
res = requests.post(
"https://api.kit.forhosting.com/algebra/log-simplify",
headers={"Authorization": f"Bearer {os.environ['KIT_KEY']}"},
json={
"expression": "log(100*x^2/y) + log(y)"
},
)
task_id = res.json()["task_id"]<?php
$res = file_get_contents("https://api.kit.forhosting.com/algebra/log-simplify", false, stream_context_create([
"http" => [
"method" => "POST",
"header" => "Authorization: Bearer " . getenv("KIT_KEY") . "\r\nContent-Type: application/json",
"content" => '{"expression":"log(100*x^2/y) + log(y)"}',
],
]));
$task = json_decode($res, true);body := bytes.NewBufferString(`{"expression":"log(100*x^2/y) + log(y)"}`)
req, _ := http.NewRequest("POST", "https://api.kit.forhosting.com/algebra/log-simplify", body)
req.Header.Set("Authorization", "Bearer "+os.Getenv("KIT_KEY"))
req.Header.Set("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)Example request
{
"expression": "log(100*x^2/y) + log(y)"
}Example response
{
"task_id": "tsk_a1b2c3d4e5f6a1b2c3d4e5f6",
"type": "algebra.log_simplify",
"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.
Limits
max_chars | 1000 |
max_terms | 64 |
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. |
Technical notes
Enter common logs with log or log10, natural logs with ln, or a numeric base with notation such as log_2. The algorithm is deterministic and runs without a network, random values, or time-dependent behavior, so the browser and API produce matching results for the same valid input.
What simplification means for a logarithmic expression
Bare log uses base ten, log10 explicitly selects the same base, ln uses the natural base, and log_2 or another positive numeric subscript selects that base.
How to enter expressions and read the response
Valid examples include log(100*x^2/y), 3*ln(x), log10(0.01), and log_2(8*a/b^2). A successful response repeats the submitted expression, supplies simplified as the reduced display string, reports exact_constant separately, counts the remaining output pieces, and lists the rewrite stages. Thus log(1000) becomes 3, log_2(8) becomes 3, and ln(e^4) becomes 4, but log(7) remains log(7). The flat API price is $0.002 per successful item. Invalid syntax, unbalanced parentheses, unsupported characters, non-positive numeric arguments, invalid bases, oversized input, and excessive term counts produce invalid_input rather than a guessed result. This makes failures explicit for worksheets, scripts, and automated grading systems.
Useful checks, boundaries, and study strategies
When the response arrives, compare its exact_constant and remaining logarithms with those predictions.
Integration use cases
Validate learning software
Use exact JSON results and explicit invalid inputs in automated tests for logarithm lessons.
Technical questions
What base does log use?
Bare log and log10 use base ten. Use ln for the natural logarithm or notation such as log_2 for another positive numeric base.
How much does the API request cost?
The browser calculator is free. A successful API request costs $0.002; invalid requests return invalid_input.