Back to index

See source file

PHFrame.h

 
#ifndef PHFRAME_H 
#define PHFRAME_H 
 
//--------------------------------------------------------------------------------------- 
//  
// Class:  PHFrame.h 
// 
// Created by:  Jane M. Burward-Hoy and Federica Messer 
// 
// Purpose: The reference frame class. 
//  
// Last update:  10/19/99 
// 
// 
// Adapted from Jeff Mitchell's luxFrame.hh and luxFrame.cc 
//---------------------------------------------------------------------------------------- 
 
#include <math.h> 
#include "phool.h" 
#include "PHVector.h" 
#include "PHPoint.h" 
 
class PHFrame 
{ 
  
public: 
   
  PHFrame(); 
  ~PHFrame(); 
  PHFrame(PHPoint, PHVector, PHVector); 
  PHFrame& operator=(const PHFrame&); 
   
  void print() const; 
  PHBoolean checkOrthogonal() const; 
  
  PHPoint getOrigin() const { return origin;}  
  PHVector getU() const { return u; } 
  PHVector getV() const { return v; } 
  PHVector getW() const { return w; } 
  
  PHVector getUfromVW() const {return v.cross(w);} 
  PHVector getVfromUW() const {return w.cross(u);} 
  PHVector getWfromUV() const {return u.cross(v);} 
 
  void setOrigin(const PHPoint &p) { origin = p; } 
  void setU(PHVector); 
  void setV(PHVector); 
  void setW(PHVector); 
 
 private: 
  PHPoint origin; 
  PHVector u, v, w; 
 
}; 
 
#endif // PHFRAME_H // 

Back to index

See source file