371
MAX, MAXP, DMAX, DMAXP
1
2
3
4
4
6
7
8
7.5
D
ata pr
ocessin
g instru
ctions
7.5.10
MAX, MAX
P
, DMAX
,
DMAXP
: Head number of the devices where a maximum value is searched (BIN 16/32 bits)
: Head number of the devices where the maximum value search result will be stored (BIN 16/32 bits)
n
: Number of data blocks to be searched (BIN 16 bits)
Function
MAX
(1) Searches in the n points of 16-bit BIN data, from the device designated by , for the maximum value and stores the
searched maximum value at the device designated by . Starts the search from the device designated by and stores
the location, specified in the number of points counted from , of the device where the maximum value is found first at
+1 and stores the number of the found minimum values at +2.
DMAX
(1) Searches in the n points of 32-bit BIN data, from the device designated by , for the maximum value and stores the
searched maximum value at the device designated by and +1.
Starts the search from the device designated by and stores the location, specified in the number of points counted
from , of the device where the maximum value is found first at +2 and stores the number of the found minimum
values at +3.
MAX, MAXP
Maximum value search for 16-bit data
DMAX, DMAXP
Maximum value search for 32-bit data
7.5.10
MAX, MAXP, DMAX, DMAXP
Setting
Data
Internal Devices
R, ZR
J \
U \G
Zn
Constants
K, H
Other
Bit
Word
Bit
Word
––
––
––
––
––
––
n
––
Basic
Process
High
performance
Redundant Universal
LCPU
n
Command
Command
P
S
D
S
D
MAX, DMAX
MAXP ,DMAXP
n
indicates an instruction s
y
mbol of MAX/DMAX.
S
D
S
D
S
D
S
S
D
D
1234
(
BIN
)
n
5678
(
BIN
)
5678
(
BIN
)
-5214
(
BIN
)
5555
(
BIN
)
5678
(
BIN
)
2
2
Location
Maximum value
Q
uantit
y
S
S
D
D
D
S
S
S
+1
+1
+2
+2
+
(
n-2
)
+
(
n-1
)
S
D
D
S
S
D
D
S
S
D
D
D
S
S
S
1
2
54321000
(
BIN
)
4321000
(
BIN
)
3254000
(
BIN
)
54321000
(
BIN
)
12345678
(
BIN
)
n
54321000
(
BIN
)
Maximum value
Location
Q
uantit
y
D
S
S
S
S
S
+1
,
+1
,
+3
,
+3
+5
,
+7
,
+9
,
+2
+2
+4
+6
+8