Description
Look up the supplied exponent exactly; return its prefix or empty text with matched false.
A unit label is text describing a quantity's intended scale. Joining tokens, adding powers or choosing spacing changes presentation; it does not convert the quantity, validate dimensional compatibility or verify a unit registry entry.
Look up the supplied exponent exactly; return its prefix or empty text with matched false.
When to use this tool
Use Engineering Exponent Prefix Choice when you need a specific quantity-and-unit text convention.
How to use the tool and how it works
- Enter exponent, exponents, prefixes. Keep parallel arrays aligned. Use the units and conventions below.
- Run the tool. Correct any format, range, or cross-field input error before interpreting the output.
- Read prefix, matched. Inspect matched before interpreting the associated values.
Require aligned exponent/prefix lists with unique exponents. Look up the supplied exponent exactly; return its prefix or empty text with matched false.1
| Input field | Meaning and units | Accepted input |
|---|---|---|
| exponent | Exponent | Required. Safe integer. |
| exponents | Exponents | Required. Array of safe integer; maximum items 256. |
| prefixes | Prefixes | Required. Array of text; maximum UTF-16 length 8192; maximum items 256. |
| Output field | Interpretation | Returned shape |
|---|---|---|
| prefix | Mapped prefix or empty placeholder; inspect matched because a mapped prefix may also be empty. | Required. Text; maximum UTF-16 length 8192. |
| matched | Matched | Required. Boolean. |
{
"input": {
"exponent": 3,
"exponents": [
-3,
0,
3
],
"prefixes": [
"m",
"",
"k"
]
},
"output": {
"prefix": "k",
"matched": true
}
} Limitations and assumptions
- The caller supplies the mapping; SI prefixes are not built in or validated. A known mapping can also have empty prefix, so inspect matched.
- Inputs must satisfy both the field types and the cross-field conditions above. Invalid input causes an error; a successful false flag or documented placeholder is a different result.
- Numeric calculations use binary floating point unless exact decimal-integer arithmetic is explicitly stated. No hidden measurement tolerance or decimal rounding is added; nonfinite or out-of-contract results are rejected. Numeric signed-zero results are exported as zero.
Alternative or Complementary methods
Use a unit-aware calculation for actual conversion and dimensional checks. Select a destination-appropriate typography and retain the intended unit meaning when preparing labels.
References
Similar or alternative tools
- Formatting: Unit Power Superscript Token
Append superscript signed exponent digits, omitting an exponent of one.
- Binary Unit Symbol Spacing
Accept KiB, MiB, GiB, TiB, PiB or EiB.