11.07.2015 Views

Data Structures and Algorithm Analysis - Computer Science at ...

Data Structures and Algorithm Analysis - Computer Science at ...

Data Structures and Algorithm Analysis - Computer Science at ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

266 Chap. 8 File Processing <strong>and</strong> External SortingMedium 1996 1997 2000 2004 2006 2008 2011RAM $45.00 7.00 1.500 0.3500 0.1500 0.0339 0.0138Disk 0.25 0.10 0.010 0.0010 0.0005 0.0001 0.0001USB drive – – – 0.1000 0.0900 0.0029 0.0018Floppy 0.50 0.36 0.250 0.2500 – – –Tape 0.03 0.01 0.001 0.0003 – – –Solid St<strong>at</strong>e – – – – – – 0.0021Figure 8.1 Price comparison table for some writable electronic d<strong>at</strong>a storagemedia in common use. Prices are in US Dollars/MB.Access Memory (RAM), while secondary storage refers to devices such as harddisk drives, solid st<strong>at</strong>e drives, removable “USB” drives, CDs, <strong>and</strong> DVDs. Primarymemory also includes registers, cache, <strong>and</strong> video memories, but we will ignorethem for this discussion because their existence does not affect the principal differencesbetween primary <strong>and</strong> secondary memory.Along with a faster CPU, every new model of computer seems to come withmore main memory. As memory size continues to increase, is it possible th<strong>at</strong> rel<strong>at</strong>ivelyslow disk storage will be unnecessary? Probably not, because the desire tostore <strong>and</strong> process larger files grows <strong>at</strong> least as fast as main memory size. Pricesfor both main memory <strong>and</strong> peripheral storage devices have dropped dram<strong>at</strong>icallyin recent years, as demonstr<strong>at</strong>ed by Figure 8.1. However, the cost per unit of diskdrive storage is about two orders of magnitude less than RAM <strong>and</strong> has been formany years.There is now a wide range of removable media available for transferring d<strong>at</strong>aor storing d<strong>at</strong>a offline in rel<strong>at</strong>ive safety. These include floppy disks (now largelyobsolete), writable CDs <strong>and</strong> DVDs, “flash” drives, <strong>and</strong> magnetic tape. Optical storagesuch as CDs <strong>and</strong> DVDs costs roughly half the price of hard disk drive spaceper megabyte, <strong>and</strong> have become practical for use as backup storage within the pastfew years. Tape used to be much cheaper than other media, <strong>and</strong> was the preferredmeans of backup, but are not so popular now as other media have decreased inprice. “Flash” drives cost the most per megabyte, but due to their storage capacity<strong>and</strong> flexibility, quickly replaced floppy disks as the primary storage device fortransferring d<strong>at</strong>a between computer when direct network transfer is not available.Secondary storage devices have <strong>at</strong> least two other advantages over RAM memory.Perhaps most importantly, disk, “flash,” <strong>and</strong> optical media are persistent,meaning th<strong>at</strong> they are not erased from the media when the power is turned off. Incontrast, RAM used for main memory is usually vol<strong>at</strong>ile — all inform<strong>at</strong>ion is lostwith the power. A second advantage is th<strong>at</strong> CDs <strong>and</strong> “USB” drives can easily betransferred between computers. This provides a convenient way to take inform<strong>at</strong>ionfrom one computer to another.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!