| Home | Libraries | People | FAQ | More

#### dot_product

Computes the dot product (or scalar product) of 2 vectors (points).

###### Synopsis

    template<typename P1, typename P2>
    select_coordinate_type<P1, P2>::type dot_product(P1 const & p1, P2 const & p2)

###### Parameters

Type | Concept | Name | Description
--- | --- | --- | ---
P1 const & |  | p1 | first point
P2 const & |  | p2 | second point

###### Returns

the dot product

###### Header

Either

`#include <boost/geometry/geometry.hpp>`

Or

`#include <boost/geometry/arithmetic/dot_product.hpp>`