OCT2BIN in Collabora Office: Expand Octal Strings into Explicit Binary Fields
Expand octal strings to binary in Collabora Calc, preserve three-bit field boundaries and check small positive conversions with explicit padding.
Verification status: See the evidence and test scope described in this guide. How formula examples are checked
Quick answer: OCT2BIN returns binary text for an octal string. The documented control =OCT2BIN("3";3) returns 011. Explicit Places makes the intended output width reproducible.
Availability and version history
- Introduced: the original Collabora release and launch date are not established by the reviewed sources.
- Availability: documented in Collabora Office 26.04 desktop help.
- Platform scope: online and mobile deployment support is not inferred from the desktop documentation.
- Checked: October 14, 2026. Function-specific documentation and independent controls; no native Collabora execution.
Syntax and unverified destination limits
=OCT2BIN(Number [; Places])
Number is an octal string with at most ten characters. The source describes a sign bit and two’s-complement notation for negative inputs. Places is the optional number of output positions.
The section does not state the complete numeric conversion interval, omitted Places default, negative-output width, overflow behavior or exact native errors. Ten octal input characters can describe many more bits than a short binary output; input length alone is not a destination-capacity promise.
The worked examples therefore use small positive values within the separately documented BIN2DEC positive range and supply sufficient integer widths. They do not certify negative cross-conversion behavior.
Example 1: expand a small octal import
Set A2:A6 to Text before entering the following strings. In B2 enter =OCT2BIN(A2;9) and fill down.
| Octal input | Expected nine-bit text | Decimal control |
|---|---|---|
| 003 | 000000011 | 3 |
| 012 | 000001010 | 10 |
| 052 | 000101010 | 42 |
| 144 | 001100100 | 100 |
| 526 | 101010110 | 342 |
The decimal values are explanatory checks. Put =OCT2DEC(A2) in C2 and fill down to independently decode the source quantity.
Each octal digit expands into three binary positions. Octal 526 becomes 101 010 110, giving 101010110. The grouping preserves the octal digit boundaries exactly because 8=2^3.
Example 2: compare explicit widths
For the positive quantity 42:
=OCT2BIN("52";6)
=OCT2BIN("52";8)
=OCT2BIN("52";9)
Independently expected strings are 101010, 00101010 and 000101010. Leading zeros change the representation’s width, not its numeric value.
The first example uses six bits because octal 52 has two three-bit groups. Width 8 might serve a separate byte-oriented display; it does not turn the input into an eight-bit signed value.
Advanced example: preserve independent three-bit fields
A record specification defines three octal digits as three separate small fields. Put 526 in E2 as text. Use:
=OCT2BIN(LEFT(E2;1);3)
=OCT2BIN(MID(E2;2;1);3)
=OCT2BIN(RIGHT(E2;1);3)
Expected outputs are 101, 010 and 110. Concatenating those strings gives 101010110, equal to the independently expected result of =OCT2BIN(E2;9).
The complete numeric quantity is 5×64+2×8+6=342. The field values are 5, 2 and 6; their simple sum 13 is not the complete positional quantity. LEFT, MID and RIGHT implement the declared layout.
Advanced check: decode both representations
For the first table, put =BIN2DEC(B2) in D2 and fill down. Expected results are again 3, 10, 42, 100 and 342, matching C2:C6.
The largest value here, 342, is below the paired BIN2DEC positive endpoint 511. Its nine-bit representation beginning with 1 is still positive in that converter’s full ten-bit signed system.
The source allows an octal representation up to ten characters, but this cross-check does not generalize to every such input. A value too large for the paired binary format requires a separately verified conversion plan.
Validation and related functions
Octal uses digits 0–7; binary uses only 0 and 1. A string containing octal digit 8 is outside the input model. The cited section does not provide the exact native error code for invalid digits or insufficient Places, so those behaviors remain unverified.
Keep both the source string and its explicit width when an external record requires leading zeros. OCT2DEC produces the numeric quantity, while BIN2OCT converts back under its own ten-bit input contract.
Omitted width, fractions, negative-output formatting, coercion and error precedence remain outside this documentation-and-model review. The complete small fixtures show successful grouping and decoding without assuming another spreadsheet’s destination limits.
References and verification
Complete function-specific documentation reviewed. Outputs are independently calculated positional, equality or arithmetic models, not captured native application results. Formulas use English names and semicolon separators; optional-argument brackets describe syntax and are not typed into a working formula.