Use app×
Join Bloom Tuition
One on One Online Tuition
JEE MAIN 2026 Crash Course
NEET 2026 Crash Course
CLASS 12 FOUNDATION COURSE
CLASS 10 FOUNDATION COURSE
CLASS 9 FOUNDATION COURSE
CLASS 8 FOUNDATION COURSE
0 votes
32.7k views
in Computer by (79.4k points)

A matrix A[m][m] is stored in the memory with each element requiring 4 bytes of storage. If the base address at A[1][1] is 1,500 and the address of A[4][5] is 1,608, determine the order of the matrix when it is stored in Column Major Wise.

1 Answer

+1 vote
by (76.5k points)
selected by
 
Best answer

Formula for finding out address of A[J] [K] element is column-major order of Matrix (MXN) order.

LOC (A[J] [K]) = Base (A) + w (M(K– 1) + (J–1))

Given : M = N = m, w = 4 bytes

Bass address = 1500

address of A[4] [5] = 1608

LOC (A [4] [5]) = 1500 + 4(m (5 – 1) + (4 – 1))

1608 = 1500 + 4(4 m + 3)

1608 – 1500 = 16 m + 12

16 m = 108 – 12 = 96

m = 6

Therefore,

Order of the matrix is (6 × 6)

Welcome to Sarthaks eConnect: A unique platform where students can interact with teachers/experts/students to get solutions to their queries. Students (upto class 10+2) preparing for All Government Exams, CBSE Board Exam, ICSE Board Exam, State Board Exam, JEE (Mains+Advance) and NEET can ask questions from any subject and get quick answers by subject teachers/ experts/mentors/students.

Categories

...