Ignore:
Timestamp:
Apr 30, 2010, 10:07:23 AM (16 years ago)
Author:
Tillmann Crueger <crueger@…>
Children:
59e7832
Parents:
f70c2a
Message:

Declared the Vector class as single point spaces

File:
1 edited

Legend:

Unmodified
Added
Removed
  • molecuilder/src/vector.hpp

    rf70c2a r4eee8f  
    1818
    1919#include "defs.hpp"
     20#include "Space.hpp"
    2021
    2122/********************************************** declarations *******************************/
     
    2425 * basically, just a x[3] but with helpful functions
    2526 */
    26 class Vector {
     27class Vector : public Space{
    2728protected:
    2829  // this struct is used to indicate calls to the Baseconstructor from inside vectors.
     
    7980
    8081  // Methods that are derived directly from other methods
    81   double Distance(const Vector &y) const;
    8282  double Norm() const;
    8383  double NormSquared() const;
     
    9393  Vector const operator+(const Vector& b) const;
    9494  Vector const operator-(const Vector& b) const;
     95
     96  // Methods inherited from Space
     97  virtual double distance(const Vector &point) const;
     98  virtual Vector getClosestPoint(const Vector &point) const;
    9599
    96100protected:
Note: See TracChangeset for help on using the changeset viewer.