[][src]Module geomath::point

Point structures and documentation

A point encapsulates position, speed and trajectory.

It can be seen as a moving point where we store both the kinematic state of the point and it's trajectory.

Purpose

The main goal of the abstraction is to provide a handler for solving ODE of second order such as the 2nd law of Newton. It also provide some affine geometry features.

Conventions

  • The trajectory needs to be updated by the calling code
  • A vector 2N is seen as an upper part containing the position and a lower part containing a speed
  • Operations between points changes only position and speed
  • Operations between points of size N and vectors of size N changes only position
  • Operations between points of size N and vectors of size 2N changes position and speed
  • Metric space operations between points are perform between their positions
  • Equality between points checks at both positions and speed

Note : The trajectory is never updated, you have to call update_trajectory method to add the current position value to the trajectory.

Modules

consts

constant points

Structs

Point

Generic structure and documentation for points

Type Definitions

Point2

2D point

Point3

3D point

Point4

4D point