Column major representation, Data Structure & Algorithms

Column Major Representation

In memory the second method of representing two-dimensional array is the column major representation. Under this illustration, the first column of the array occupies the first set of the memory locations kept for the array. The second column occupies next set & so forth. The representation of a column major representation is illustrated in Figure

Assume the following two-dimensional array:

1518_Column Major Representation.png

To make its equivalent column major representation, we carry out the following procedure:

Transpose the elements of the array. After that, the representation will be alike as that of the row major representation.

Through application of above denoted process, we get {a, e, i, b, f, j, c, g, k, d, h, i}

Col 0

Col 1

Col 2

.....

Col i

 

 

Figure: Schematic of Column major representation of an Array

1) In which array can be stored?

2) In which, the elements of array are stored row wise.

3) In which, the elements of array are stored column wise.

 

Posted Date: 4/4/2013 6:48:27 AM | Location : United States







Related Discussions:- Column major representation, Assignment Help, Ask Question on Column major representation, Get Answer, Expert's Help, Column major representation Discussions

Write discussion on Column major representation
Your posts are moderated
Related Questions
Program segment for All pairs shortest paths algorithm AllPairsShortestPaths(int N, Matrix C, Matrix P, Matrix D) { int i, j, k if i = j then C[i][j] = 0  for ( i =

Write a program for reversing the Linked list

what algorithms can i use for the above title in my project desing and implmentation of road transport booking system

There are three kinds of tree traversals, namely, Postorder , Preorder and Inorder. Preorder traversal: Each of nodes is visited before its children are visited; first the roo

A common person's faith is that a computer can do anything. It is far from truth. In realism computer can carry out only definite predefined instructions. The formal illustration o

The class Element represents a single node that can be part of multiple elements on a hotplate and runs in its own thread. The constructor accepts the initial temperature and a hea

We might sometimes seek a tradeoff among space & time complexity. For instance, we may have to select a data structure which requires a lot of storage to reduce the computation tim

Each data record contains a fixed place in a relative file. Each record ought to have associated with it in integer key value which will help identify this slot. Therefore, this ke

nested for loop for (i = 0; i for (j = 0; j sequence of statements } } Here, we observe that, the outer loop executes n times. Every time the outer loop execute

what is tree