Next: Sets, Previous: Objects [Contents][Index]

### 2.2 Vectors

Vectors are stored using their Cartesian coordinates.

#### Vector operators

`u + v`

  Sum of u and v.

`u - v`

  Difference of u and v.

`k * u`

  Scalar product of u by k.

`u / k`

  Scalar quotient of u by k.

`u * v`

  Dot product of u and v.

#### Vector related functions

`vector(x, y)`

  Vector of Cartesian coordinates (x, y).

`vector(r, a)`

  Vector of polar coordinates (r, a).

`vector(A, B)`

  Vector going from point A to point B.

`abscissa(u)`

  Abscissa of u.

`ordinate(u)`

  Ordinate of u.

`length(u)`

  Length of u.

`arg(u)`

  Polar angle of u (in degrees).

`angle(u, v)`

  Angle between u and v (in degrees).