created at April 8, 2021

Creating a vector

to create a vector:

create new vector by listing all it's elements in angle brackets:

you can use a sequence of numbers using default step = 1:

or using specified step:

all these approaches can be combined together:

resultant vector will contain such elements:

0, 0.2, 0.4, 0.6, 0.8, 1, 2, 3, 4, 5, -4, 0.8

you can create new vectors by using existing vectors as inputs:

vector is actually a one-dimensional array of elements. Used in mathematical expressions "as is" vector is treated as geometrical entity, i.e. it can be multiplied by a number, added to another equal length vector, or scalar multiplied by another equal length vector. However, vector has several other useful applications, e.g. it is being used to control loops, to create other vectors or matrices.

to refer single element of a vector use indexes: