Sparse Array

Why Trust Techopedia

What Does Sparse Array Mean?

A sparse array is an array of data in which many elements have a value of zero. This is in contrast to a dense array, where most of the elements have non-zero values or are “full” of numbers. A sparse array may be treated differently than a dense array in digital data handling.

Advertisements

Techopedia Explains Sparse Array

As with other types of sparse information resources, such as, for example, a sparse matrix, a sparse array may be compressed or truncated to fit a particular storage space. Rather than holding all of the actual zero values in variables, the array could simply point to the number of zero values in a sequence or otherwise compress the array’s data storage.

In computer science, a sparse array is, in some ways, handled operationally just like any other array – an array is a set of variables each holding a specific value. Arrays are labeled in ways that show their sequence – for example, in common computer language notation, an array of six variables named A(6) can hold values for A1, A2, A3, A4, A5 and A6. If more than three or four of these values are zero, the array is said to be “sparse.”

Advertisements

Related Terms

Margaret Rouse
Technology Specialist
Margaret Rouse
Technology Specialist

Margaret is an award-winning writer and educator known for her ability to explain complex technical topics to a non-technical business audience. Over the past twenty years, her IT definitions have been published by Que in an encyclopedia of technology terms and cited in articles in the New York Times, Time Magazine, USA Today, ZDNet, PC Magazine, and Discovery Magazine. She joined Techopedia in 2011. Margaret’s idea of ​​a fun day is to help IT and business professionals to learn to speak each other’s highly specialized languages.