### NumPy: Fundamentals Of Python Data Science

Introduction
Linear Algebra Basics
Tensors
Array Fundamentals
Working with multidimensional arrays
Our example dataset and basic plotting
ndarray methods
Array Axes
Vectorized Computing
Universal Functions (ufuncs)
Randomness
Selected Topics in Mathematics and Statistics

# Scalars and Vectors

Before starting with NumPy, we need to know and understand some basic linear algebra concepts. Perhaps these are well known to you. If so, I still recommend you still skim through this section.

## Scalars

Scalars are quantities that describe magnitudes. They have no dimensions. For example, real numbers are scalars. Physical examples of scalars are temperature, volume, and mass, among many others. Any function which returns a single number is called a scalar function.

In the spirit of generalization, we say that scalars have dimension zero.

NumPy treats scalars as Python does. Scalars in NumPy follow the four commutative operations we all know about:

1. sum
2. subtraction
3. multiplication
4. division

## Vectors

Vectors are ordered collections of one or more scalars with a variable number of elements. From here on, we will define a vector’s length as the number of elements in that vector.

As a data structure, vectors have one dimension, even if its length is m. This is because a single index can express the position of any element.