| 237 | //- Outer-product between two vectors |
| 238 | template<class Cmpt> |
| 239 | inline typename outerProduct<Vector2D<Cmpt>, Vector2D<Cmpt>>::type |
| 240 | operator*(const Vector2D<Cmpt>& v1, const Vector2D<Cmpt>& v2) |
| 241 | { |
| 242 | return Tensor2D<Cmpt> |
| 243 | ( |
| 244 | v1.x()*v2.x(), v1.x()*v2.y(), |
| 245 | v1.y()*v2.x(), v1.y()*v2.y() |
| 246 | ); |
| 247 | } |
| 248 | |
| 249 | |
| 250 | //- Return the trace of a tensor |