Contact

BITLSHIFT in WPS Spreadsheet: Shift Numeric Masks and Audit Lost Low Bits

Engineering Intermediate WPS Spreadsheet

Use WPS BITLSHIFT with decimal numeric inputs, check signed shift directions and separate packed fields from arithmetic addition and native overflow claims.

Verification status: See the evidence and test scope described in this guide. How formula examples are checked

Quick answer: BITLSHIFT shifts a numeric value’s binary representation. =BITLSHIFT(13,3) has independently expected numeric result 104: binary 1101 becomes 1101000.

Availability and version history

  • Introduced: documented by 2019-05-17 in the official WPS lesson; the first release is not established.
  • Availability: Current WPS Windows documentation confirms the function; the historical lesson’s edition field is blank.
  • Scope: exact current supported builds and other WPS clients remain unverified.
  • Checked: October 14, 2026. Documentation and independent calculations; no native WPS execution.

Syntax and product-specific bounds

=BITLSHIFT(number,shift_amount)

The May 17, 2019 WPS lesson says number must be nonnegative and shift_amount must be an integer. It documents #NUM! for number above 2^48−1, or 281474976710655, and for an absolute shift count above 53. Nonnumeric arguments receive documented #VALUE!.

A positive shift moves left; a negative shift moves right. The original number is a decimal numeric input, not a string of binary digits. The lesson’s walkthrough explicitly emphasizes that distinction.

The historical edition field is blank. Separate current WPS documentation identifies the function on Windows. This does not establish a first release, an exact current build range or mobile/cloud equivalence.

Example 1: multiply by powers of two through left shifts

Enter values 3, 5, 13 and 21 in A2:A5 and shift count 3 in D2. In B2 use =BITLSHIFT(A2,$D$2) and fill down.

A, input number B, shifted result Independent multiplication
3 24 3×8
5 40 5×8
13 104 13×8
21 168 21×8

A left shift by three appends three binary zeros. For these small inputs, multiplication by 2^3 provides an exact independent check.

The WPS source’s explicit control shifts four left by two to give sixteen. Its walkthrough also uses decimal three shifted by three. Those are numeric outputs, not the displayed binary strings 10000 or 11000.

Example 2: a binary-looking decimal input is a different quantity

=BITLSHIFT(13,1) has expected number 26. But =BITLSHIFT(1101,1) has expected number 2202, because 1101 is supplied as a decimal quantity.

The digits 1101 happen to be the binary spelling of thirteen, but BITLSHIFT is not being asked to parse that spelling. Keep imported representations and actual numeric mask values in separate columns.

DEC2BIN can display a small decimal quantity in binary under its own documented contract. Do not use a display representation as though it were the original numeric value.

Advanced example: reverse direction and inspect discarded bits

For decimal 13, compare =BITLSHIFT(13,-1), =BITLSHIFT(13,-2) and =BITLSHIFT(13,-3). The independently expected right-shift results are 6, 3 and 1.

Binary 1101 becomes 110, then 11, then 1 as low positions are discarded. The first result corresponds to integer division by two with a remainder of one, not a fractional 6.5 output.

Shifting six left by one gives twelve, so a right shift followed by a left shift does not recover thirteen. The lost low bit is the reason. Conversely, shifting thirteen left by three and then right by three recovers thirteen in this small non-overflowing fixture.

Zero is explicitly permitted by the historical nonnegative-input wording: =BITLSHIFT(0,3) has expected result 0. This WPS rule is independently sourced and is not inferred from another product’s bit-function input wording.

Advanced example: pack a high field and a low field

A record uses two four-bit fields. Enter high field 6 in F2 and low field 11 in G2. Compute:

=BITLSHIFT(F2,4)+G2

Expected packed number: 107, because 6×16+11=107. Its binary form is 01101011. The low field must be an integer from zero through fifteen so it stays in its allotted positions.

For a deliberately invalid low field 27, the expression gives 123, the same quantity as high 7 and low 11. The arithmetic cannot remember the intended invalid boundary. Validate the field before packing.

Limits and error interpretation

The source limits the input number and shift count, but does not fully specify output-overflow handling, fractional number behavior, negative-number errors or error precedence. These controls use small nonnegative integers and shifts within the documented interval.

A shift of 54 or −54 follows the stated excessive-count #NUM! rule; a numeric input of 281474976710656 exceeds the documented input maximum. Those error controls do not imply that every allowed input and count combination yields a representable shifted result.

All bit outputs here are independently calculated models, not captured native WPS results. Keep the original mask and field definitions beside the derived numbers for an auditable transformation.

References and verification

Complete function-specific documentation reviewed. Worked outputs are independently calculated expectations, not captured native results. Formulas use English names and comma separators; check the installed locale. Product/client and source gaps retain their explicit scope.