edited by
410 views
0 votes
0 votes
For disk size of $768 \hspace{0.1cm}MB$ and block size of $384 \hspace{0.1cm} bytes$ what would be the bitmap size in bytes(as a power of $2$)

iI represented $768 \hspace{0.1cm} MB$ as $3*2^{28}$ and $384$ as $3*2^7$ and then $\dfrac{3*2^{28}}{3*2^7}= 2^{21}$ but the correct answer given was not $2^{21}$ but $2^{18}$ because he divides $2^{21}/2^3$ and the explanation is $2^3$ is how many bits are in a byte, but why do this division isnt representing $768 \hspace{0.1cm} MB$ as $768*2^{20}$ or $3*2^{28}$ already in bytes, after all MB has $2^{20} \hspace{0.1cm} bytes$ so the answer $2^{21}$ should already be in bytes, right?
edited by

3 Answers

0 votes
0 votes
i am getting  256KB

total number of bolck in File is  = 768MB / 384B

                                                        =  2 M  blocks

and each Block Need  1 bit in Bit map then total 2 M bit are needed to represent Bit Map in memory

memory for Bit map in Byte  = 2 M bit / 8 bit

                                                   =  256 KB
0 votes
0 votes
here they are asking about size of bitmap ,

you got total no of bits required to represent i.e 2^21

so size of  bit map is 2^21 bits and they want answer in bytes

and 1byte=8bits so 2^21/8 = 2^18 is the size of bitmap
0 votes
0 votes
This ans will not be in Bytes, Because when you will divide Block size by block size, the ans will be (x Bytes)/(y Bytes). Here Bytes/Bytes cancelled hence answer will not have any unit. Neither Bytes nor Bits it will be just a number.

Related questions

4 votes
4 votes
3 answers
1
Shivangi Parashar 2 asked Nov 27, 2018
5,624 views
A bit-map can be used to keep track of which blocks are free in a file-system’s partition on disk.Assuming, 1 KB block size and a disk size of 40 GB, what is the size o...
0 votes
0 votes
2 answers
2
2 votes
2 votes
4 answers
3
iarnav asked Apr 15, 2017
4,051 views
A $1$TB Disk with $4$-KB blocks require $32$MB to store its bit map?Kindly explain how.
2 votes
2 votes
2 answers
4
pC asked Dec 12, 2015
5,225 views
For a Hard disk of Capacity 20 MB . Disk block address of 16 bits and disk block size of 1 KB . The number of disk blocks required to store all the Free Blocks using Bitm...