IP Library › Granted Patent US 10,417,208
Granted Patent B2
US 10,417,208 · App. 15/380,985 · Granted Sep 17, 2019

Constant range minimum query

Inventors: Alejandro Lopez-Ortiz (Walldorf, DE); Daniela Maftuleac (Walldorf, DE); Alejandro Salinger (Walldorf, DE); Jeffrey Pound (Walldorf, DE)
Assignee: SAP SE
G06F16/2237G06F16/2246G06F16/2455
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 10,417,208
App. No.
15/380,985
Granted
Sep 17, 2019
Kind
B2
Abstract

A plus-minus-one array in which adjacent entries vary by no more than positive one and no less than negative one is accessed. A range minimum query directory tree including blocks and subblocks of the plus-minus-one array is determined. Blocks are contained in the plus-minus-one array and subblocks are contained in the blocks. A data structure characterizing positions of minimum elements within the range minimum query directory tree is generated. The characterization includes positions of minimums within each subblock, between subblocks in a respective block, within each block, and between blocks. The data structure is stored. Related apparatus, systems, techniques and articles are also described.

Claims (52)

1. A method comprising:

accessing a plus-minus-one array in which adjacent entries vary by no more than positive one and no less than negative one;

determining a range minimum query directory tree including blocks and subblocks of the plus-minus-one array, wherein blocks are contained in the plus-minus-one array, subblocks are contained in the blocks, and the subblocks contain two or more elements of the plus-minus-one array;

generating a data structure characterizing positions of minimum elements within the range minimum query directory tree, the characterization including positions of minimums within each subblock, between subblocks in a respective block, within each block, and between blocks; and

storing the data structure;

wherein the data structure includes a first structure storing, for each block, a position of a local index of a subblock inside each block in which a minimum element of the block is contained.

2. The method of claim 1 , wherein the data structure includes:

a second structure storing, for each subblock, a position of a minimum element within each subblock;

a third structure storing, for each subblock, a position of a minimum element between elements of the subblock;

a fourth structure storing, for each block, a position of a subblock containing a minimum element between multiple subblocks within the respective block; and

a fifth structure storing a block containing a minimum element between multiple block.

3. The method of claim 2 , wherein each stored position is the local index in a respective block or subblock.

4. The method of claim 1 wherein at least one of the accessing, the determining, the generating, and the storing is performed by at least one data processor forming part of at least one computing system.

5. A method comprising:

receiving data characterizing a plus-minus-one range minimum query for a plus-minus-one array, the plus-minus-one range minimum query including a start position and an end position;

searching a data structure characterizing a range minimum query directory tree associated with the plus-minus-one array to find a minimum element in the plus-minus-one array between the start position and the end position,

the range minimum query directory tree including blocks and subblocks of the plus-minus-one array, wherein blocks are contained in the plus-minus-one array, subblocks are contained in the blocks, and the subblocks contain two or more elements of the plus-minus-one array,

the data structure characterizing positions of minimum elements within the range minimum query directory tree, the characterization including positions of minimums within each subblock, between subblocks in a respective block, within each block, and between blocks; and

providing the position of the minimum element in the plus-minus-one array between the start position and the end position;

wherein the data structure includes a first structure storing, for each block, a position of a local index of a subblock inside each block in which a minimum element of the block is contained.

6. The method of claim 5 , wherein the data structure includes:

a second structure storing, for each subblock, a position of a minimum element within each subblock;

a third structure storing, for each subblock, a position of a minimum element between elements of the subblock;

a fourth structure storing, for each block, a position of a subblock containing a minimum element between multiple subblocks within the respective block; and

a fifth structure storing a block containing a minimum element between blocks.

7. The method of claim 6 , wherein searching the data structure includes determining if the start position and the end position are: within a same subblock, within different subblocks of the same block, or within different blocks.

8. The method of claim 7 , wherein searching the data structure includes finding the position of the minimum element from the third data structure.

9. The method of claim 7 , wherein searching the data structure includes finding, using the fourth structure, a subblock containing the minimum element and finding, using the second structure, the position of the minimum element within the subblock containing the minimum element.

10. The method of claim 5 , further comprising:

receiving a range minimum query, the range minimum query including an input array, a second start position within the input array, and a second end position within the input array;

determining the plus-minus-one array from the input array by computing a reduced bit vector that characterizes a binary tree of the input array, the bit vector including a 1-bit for every leaf in the binary tree; and

determine the start position and the end position using select operations on the reduced bit vector with the second start position and the second end position.

11. The method of claim 5 , wherein at least one of the receiving, the searching, and the providing is performed by at least one data processor forming part of at least one computing system.

12. A system comprising at least one data processor and memory storing instructions which, when executed by the at least one data processor, causes the at least one data processor to perform operations comprising:

receiving data characterizing a plus-minus-one range minimum query for a plus-minus-one array, the plus-minus-one range minimum query including a start position and an end position;

searching a data structure characterizing a range minimum query directory tree associated with the plus-minus-one array to find a minimum element in the plus-minus-one array between the start position and the end position,

the range minimum query directory tree including blocks and subblocks of the plus-minus-one array, wherein blocks are contained in the plus-minus-one array, subblocks are contained in the blocks, and the subblocks contain two or more elements of the plus-minus-one array,

the data structure characterizing positions of minimum elements within the range minimum query directory tree, the characterization including positions of minimums within each subblock, between subblocks in a respective block, within each block, and between blocks; and

providing the position of the minimum element in the plus-minus-one array between the start position and the end position;

wherein the data structure includes a first structure storing, for each block, a position of a local index of a subblock inside each block in which a minimum element of the block is contained.

13. The system of claim 12 , wherein the data structure includes:

a second structure storing, for each subblock, a position of a minimum element within each subblock;

a third structure storing, for each subblock, a position of a minimum element between elements of the subblock;

a fourth structure storing, for each block, a position of a subblock containing a minimum element between multiple subblocks within the respective block; and

a fifth structure storing a block containing a minimum element between multiple block.

14. The system of claim 13 , wherein searching the data structure includes determining if the start position and the end position are: within a same subblock, within different subblocks of the same block, or within different blocks.

15. The system of claim 14 , wherein searching the data structure includes finding the position of the minimum element from the third data structure.

16. The system of claim 14 , wherein searching the data structure includes finding, using the fourth structure, a subblock containing the minimum element and finding, using the second structure, the position of the minimum element within the subblock containing the minimum element.

17. The system of claim 12 , further comprising:

receiving a range minimum query, the range minimum query including an input array, a second start position within the input array, and a second end position within the input array;

determining the plus-minus-one array from the input array by computing a reduced bit vector that characterizes a binary tree of the input array, the bit vector including a 1-bit for every leaf in the binary tree; and

determine the start position and the end position using select operations on the reduced bit vector with the second start position and the second end position.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Dec 19, 2016
From: LOPEZ-ORTIZ, ALEJANDRO; MAFTULEAC, DANIELA; SALINGER, ALEJANDRO; POUND, JEFFREY
To: SAP SE
Reel/Frame 040671/0930 →
Continuity (1)
Related Publication 20180173738A1 · Jun 21, 2018