Full Command and Function Reference 3-169
SR
Type: Command
Description: Shift Right Command: Shifts a binary integer one bit to the right.
The least significant bit is shifted out to the right and lost, while the most significant bit is
regenerated as a zero. SR is equivalent to binary division by 2.
Access: !´
BASE L BIT SR ( ´ is the left-shift of the Pkey).
…ã
L BIT SR (ã is the right-shift of the 3key).
Flags: Binary Integer Wordsize (-5 through -10), Binary Integer Base (-11, -12)
Input/Output:
Level 1/Argument 1 Level 1/Item 1
#n
1
→
#n
2
See also: ASR, SL, SLB, SRB
SRAD
Type: Command
Description: Spectral Radius Command: Returns the spectral radius of a square matrix.
The spectral radius of a matrix is a measure of the size of the matrix, and is equal to the absolute
value of the largest eigenvalue of the matrix.
Access: !Ø
OPERATIONS L L SRAD (Ø is the left-shift of the 5key).
!´
MATRIX NORMALIZE SRAD ( ´ is the left-shift of the Pkey).
Input/Output:
Level 1/Argument 1 Level 1/Item 1
[[ matrix ]]
n×n
→
x
spectralradius
See also: COND, SNRM, TRACE
SRB
Type: Command
Description: Shift Right Byte Command: Shifts a binary integer one byte to the right.
The least significant byte is shifted out to the right and lost, while the most significant byte is
regenerated as zero. SRB is equivalent to binary division by 2
8
(or executing SR eight times).
Access: !´
BASE L BYTE SRB ( ´ is the left-shift of the Pkey).
…ã
L BYTE SRB (ã is the right-shift of the 3key).
Flags: Binary Integer Wordsize (-5 through -10), Binary Integer Base (-11, -12)
Input/Output:
Level 1/Argument 1 Level 1/Item 1
#n
1
→
#n
2
See also: ASR, SL, SLB, SR
SRECV
Type: Command
Description: Serial Receive Command: Reads up to n characters from the serial input buffer and returns them
as a string, along with a digit indicating whether errors occurred.
SRECV does not use Kermit protocol.
If n characters are not received within the time specified by STIME (default is 10 seconds),
SRECV “times out”, returning a 0 to level 1 and as many characters as were received to level 2.