Planar Straight Line Graphs (PSLGs) in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:58:20

456 Views

In case of computational geometry, a planar straight-line graph, in short PSLG, (or straight-line plane graph, or plane straight-line graph) is defined as a term implemented for an embedding of a planar graph in the plane such that its edges are mapped into straight line segments. Statement of Fáry's theorem (1948) is that every planar graph has this kind of embedding.In case of computational geometry, PSLGs have often been termed planar subdivisions, with an assumption or assertion that subdivisions are polygonal.Without vertices of degree 1, a PSLG defines a subdivision of the plane into polygonal regions and vice versa. Absence ... Read More

Rectangle Data in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:55:26

2K+ Views

Multivariate cross-sectional data (i.e. not time-series or repeated measure) are indicated by rectangular data in which each column is a variable (feature), and each row is a case or record.First procedure of representing rectangle data is to map it onto a higher-dimensional point data and use point-based data structure procedures such as the grid file, PR quadtree, point quadtree, and k-d-tree. Procedure mapping of the rectangular data to a four-dimensional point can be performed in number techniques such as x and y coordinates of the opposite corners, or x and y coordinates of one corner and the width and height, ... Read More

Bucketing Methods in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:53:36

712 Views

Bucketing builds, the hash table as a 2D array instead of a single dimensional array. Every entry in the array is big, sufficient to hold M items (M is not amount of data. Just a constant).ProblemsLots of wasted space are created.If M is exceeded, another strategy will need to be implemented.Not so good performer for memory based implementations but doable if buckets are disk-based.For bucketing it is ok to have λ>1. However, the larger λ is the higher a chance of collision. λ>1 guarantees there will be minimum 1 collision (pigeon hole principle). That will enhance both the run time ... Read More

Optimal Lopsided Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:52:33

350 Views

The problem of finding optimal prefix-free codes for unequal letter costs consists of computing a minimum cost prefix-free code in which the encoding alphabet consists of unequal cost (length) letters, of lengths α and β, where α ≤ β. We restrict ourselves limited to binary trees.The code is represented by a lopsided tree, in the similar way as a Huffman tree represents the solution of the Huffman coding problem. Despite the similarity, the case of unequal letter costs is much difficult than the classical Huffman problem; no polynomial time algorithm is known or available for general letter costs, despite a ... Read More

Relative Positioning in CSS

AmitDiwan
Updated on 07-Jan-2020 12:48:08

580 Views

We can define positioning of an element in CSS as relative which renders the element normally. Elements with positioning method as relative are positioned by CSS Positioning properties (left, right, top and bottom).ExampleLet’s see an example for CSS Relative Positioning Method − Live Demo p {    margin: 0; } div:first-child {    position: relative;    top:20px;    background-color: orange;    text-align: center; } PostgreSQL PostgreSQL is a powerful, open source object-relational database system. It has more than 15 years of active development................. OutputFollowing is the output for the above code −ExampleLet’s see ... Read More

Height Limited Huffman Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:47:57

669 Views

The diagram of height limited or depth limited Huffman tree is given belowTree depth limitation is a non-trivial issue that most real-world Huffman implementations must deal with.Huffman construction doesn't limit the height or depth. If it would, it is not possible for it to be "optimal". Granted, the largest depth of a Huffman tree is bounded by the Fibonacci series, but that leave sufficient room for larger depth than wanted.What is the reason to limit Huffman tree depth? Fast Huffman decoders implement lookup tables. It's possible to implement multiple table levels to mitigate the memory cost, but a very fast ... Read More

Huffman Algorithm for T-ary Trees in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:45:40

645 Views

A simple algorithmA collection of n initial Huffman trees is prepared, each of which is a single leaf node. Keep the n trees onto a priority queue organized by weight (frequency).Remove or delete the first two trees (the ones with smallest weight). Combine these two trees to create a new tree whose root is associated with the two trees as children, and whose weight is the sum of the weights of the two children trees.Keep this new tree into the priority queue.Repeat steps 2-3 until and unless all of the partial Huffman trees have been joined into one.It's a greedy ... Read More

Remove Dotted Line Around Active Links Using CSS

AmitDiwan
Updated on 07-Jan-2020 12:35:32

3K+ Views

We can remove the default behavior of hyperlinks which is to show a dotted outline around themselves when active or focused by declaring CSS outline property on active/focused links to be none.Solutiona, a:active, a:focus {    outline: none; }ExampleLet’s see how to remove dotted line around active links with an example − Live Demo Remove dotted line around links using css div {    color: #000;    padding:20px;    background-image: linear-gradient(135deg, #dc3545 0%, #9599E2 100%);    text-align: center; } a, a:active, a:focus {    outline: none; } HTML Links Demo Go To Google ... Read More

Huffman Codes and Entropy in Data Structure

Arnab Chakraborty
Updated on 07-Jan-2020 12:34:25

2K+ Views

Huffman CodeA Huffman code is defined asa particular type of optimal prefix code that is commonly used for lossless data compression.The process of finding or implementing such a code proceeds by means of Huffman coding, an algorithm which was developed by David A. Huffman while he was a Sc.D. student at MIT, and published in the 1952 paper "A Method for the Construction of Minimum-Redundancy Codes".The output from Huffman's algorithm can be displayed as a variable-length code table for encoding a source symbol (such as a character in a file). The algorithm creates this table from the estimated probability or ... Read More

Static Positioning Using CSS

AmitDiwan
Updated on 07-Jan-2020 12:27:50

1K+ Views

We can define positioning of an element in CSS as static which does not renders the element in any special way, but in a normal way. Elements with positioning as static are not affected by any of the CSS Positioning properties (left, right, top and bottom).ExampleLet’s see an example of CSS Static Positioning Method − Live Demo p {    margin: 0; } div:first-child {    position: static;    background-color: orange;    text-align: center; } Demo text This is demo text wherein we are displaying an example for static positioning. OutputFollowing is the ... Read More

Advertisements