Main Page | Class Hierarchy | Class List | File List | Class Members

sphere.h

00001 /***************************************************************************
00002                           sphere.h  -  description
00003                              -------------------
00004     begin                : Sun Feb 2 2003
00005     copyright            : (C) 2003 by Moritz Franosch
00006     email                : mail@Franosch.org
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018 #ifndef SPHERE_H
00019 #define SPHERE_H
00020 
00021 
00022 #include "geometry.h"
00023 #include "particle.h"
00024 
00025 
00030 class Sphere : public Geometry {
00031 
00032 private:
00033 
00034   Particle::vector_t position; // the coordinates and ...
00035   double radius; // ... the radius of the sphere
00036 
00037 public: 
00038   
00041   Sphere(const Particle::vector_t& p, const double r);
00042 
00045   void set_radius(const double r);
00046 
00049   const Particle::vector_t& get_position() const;
00050 
00053   double get_radius() const;
00054 
00055   virtual bool operator()(const Particle::vector_t& p) const;
00056 
00059   virtual void to_xml(std::ostream& o);
00060 
00061 };
00062 
00063 
00064 #endif // SPHERE_H

Generated on Fri Apr 22 11:06:42 2005 for partsim.kdevelop by doxygen 1.3.6