Found 510 Articles for Algorithms

Static Finger Theorem in Data Structure

Arnab Chakraborty
Updated on 13-Jul-2020 09:16:10

125 Views

STATIC FINGER THEOREM − Let f is treated as a specific element called the finger.Then the below expression is a bound on the cost of splaying a sequenceO(m + n log(n) + Σ Sum log (|f - i[j]| + 1))jNOTE − |f-i| is denoted as the distance in the symmetric ordering of the items between the finger and item i.Where m is denoted as number of update or access operations on a tree having at most n nodes.Observe that, at least in amortized sense, the time taken for first m operations on a tree that never exceeds more than n ... Read More

Optimality of Splay Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:05:50

76 Views

Dynamic optimality conjectureIn addition to the proven performance guarantees for splay trees there is an unproven conjecture with great interest. Dynamic optimality conjecture denotes this conjecture. Let any binary search tree algorithm such as B accesses an element y by traversing the path from the root to y at a cost of d(y)+1, and that between accesses can make any rotations in the tree at a cost of 1 per rotation. Let B(s) be the cost for B to perform the sequence s of accesses. Then the cost for a splay tree to perform the same accesses is O[n+B(s)].There are ... Read More

Adaptive Merging and Sorting in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:01:27

536 Views

ADAPTIVE MERGE SORTAdaptive Merge Sort performs the merging of sorted sub-list merge sort does. However, the size of initial sub-list is depended upon the existence of ordering among the list of elements rather than having sub-list of size 1. For example, consider list in the figure.It consists of 2 sorted sub-lists.sub-list 1 with elements 16, 15, 14, 13.sub-list 2 with elements 9, 10, 11, 12.The sub-list 1 is sorted but in reverse order. Thus, the sub-list 1 is reversed as shown in the figure.Once the sub-lists are found merging process starts. Adaptive merge sort starts merging the sub-lists. Adaptive merge ... Read More

Skip Lists in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 11:53:27

394 Views

In a skip list, one can finger search for element a from a node containing the element b by simply continuing the search from this point a.Note that if a < b, then search proceeds at backward direction, and if a > b, then search proceeds at forward direction.The backwards case is symmetric to normal search in a skip list, but the forward case is actually more complicated.Normally, search in a skip list is expected to be fast because the sentinel at the start of the list is considered as the tallest node.However, our finger could be associated with a ... Read More

Randomized Finger Search Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 11:51:31

116 Views

Two randomized alternatives to deterministic search trees are the randomized binary search trees, treaps and the skip lists. Both treaps and skip lists are defined as elegant data structures, where the randomization facilitates simple and efficient update operations.In this section we explain how both treaps and skip lists can be implemented as efficient finger search trees without changing the data structures. Both data structures support finger searches by consuming expected O(log d) time, where the expectations are taken over the random choices created by the algorithm during the construction of the data structure.Skip listsIn a skip list, one can finger ... Read More

Level Linked (2,4)-Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 11:35:38

433 Views

In this section we explain how (2, 4)-trees can support efficient finger searches by the introduction of level links. The ideas explained in this section also implements to the more general class of height-balanced trees denoted (a, b)-trees, for b ≥ 2a.A (2, 4)-tree is defined as a height-balanced search tree where all leaves have the same depth and all internal nodes have degree two, three or four. Elements are stored at the leaves, and internal nodes only store search keys to guide searches. Since each internal node has degree at least two, it follows that a (2, 4)-tree has ... Read More

Dynamic Finger Search Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 11:29:21

259 Views

A dynamic finger search data structure should in addition to finger searches also perform the insertion and deletion of elements at a position given by a finger.Finger search trees is defined as a variant of B-trees supporting finger searches in O(log d) time and updates in O(1) time, assuming that only O(1) moveable fingers are maintained.Traversing a finger d positions requires O(log d) time.The finger search trees (that means AVL-trees, red-black trees) constructions either consider a fixed constant number of fingers or only support updates in amortized constant time.Constructions supporting an arbitrary number of fingers and with worst case update ... Read More

Finger Searching in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 09:42:30

262 Views

A finger search on a data structure is defined as an extension of any search operation that structure supports, where a reference (finger) to an element in the data structure is given along with the query. While the search time for an element is most frequently denoted as a function of the number of elements in a data structure, finger search times are treated as a function of the distance between the element and the finger.In a set of m elements, the distance d(a, b) between two elements a and b is their difference in rank. If elements a and ... Read More

Multi-Way Trees

Arnab Chakraborty
Updated on 03-Jan-2020 06:14:24

13K+ Views

A multiway tree is defined as a tree that can have more than two children. If a multiway tree can have maximum m children, then this tree is called as multiway tree of order m (or an m-way tree).As with the other trees that have been studied, the nodes in an m-way tree will be made up of m-1 key fields and pointers to children.multiway tree of order 5To make the processing of m-way trees easier some type of constraint or order will be imposed on the keys within each node, resulting in a multiway search tree of order m ... Read More

Multidimensional Binary Search Trees

Arnab Chakraborty
Updated on 03-Jan-2020 06:10:57

1K+ Views

Basic conceptThe multidimensional binary search tree (abbreviated k-d tree) is defined as a data structure for storing multikey records. This structure has been implemented to solve a number of "geometric" problems in statistics and data analysis.A k-d tree (short for k-dimensional tree) is defined as a space-partitioning data structure for organizing points in a k-dimensional space. Data structure k-d trees are implemented for several applications, for example, searches involving a multidimensional search key (e.g. range searches and nearest neighbor searches). k-d trees are treated as a special case of binary space partitioning trees.Informal descriptionThe k-d tree is a binary tree ... Read More

Advertisements