40 MG_DLL_DECLR
friend double operator%(
const MGVector& vec1,
const MGVector& vec2);
82 MG_DLL_DECLR
friend double MGDeterminant(
95 MGVector(
double x,
double y ,
double z);
98 MGVector(
double x,
double y,
double z,
double w);
107 MGVector(
int sdim,
const double* v);
131 MGVector(
const std::vector<double>& darrays);
148 double operator() (
int i)
const{
return ref(i);}
151 double operator[] (
int i)
const{
return ref(i);}
156 double& operator()(
int i);
182 MGVector& operator/= (
double scale);
189 double angle(
const MGVector&)
const;
205 double cangle(
const MGVector&)
const;
211 const double*
data()
const{
return m_element;};
212 double*
data(){
return m_element;};
237 )
const{
return (*this).parallel(v2);}
252 bool is_unit_vector()
const;
255 bool is_zero_vector()
const;
271 bool orthogonal(
const MGVector& )
const;
277 int SubordinateEntitySwitch=0
287 bool parallel(
const MGVector& )
const;
295 if(i<sdim())
return m_element[i];
301 void resize(
int new_sdim);
306 double sangle(
const MGVector& )
const;
309 int sdim()
const {
return m_sdim; };
339 void swap(
int i,
int j);
343 int dump_size()
const;
364 double&
set(
int i) {
return m_element[i];}
double m_length
For vector data of space dimension less or equal to 3.
Definition: Vector.h:357
double * m_element
Definition: Vector.h:355
void negate()
Negate the vector.
Definition: Vector.h:262
double anglepai(const MGVector &v2) const
Definition: Vector.h:193
double ref(int i) const
Reference to i-th element.
Definition: Vector.h:294
MGIfstream is a class to read the serialized data generated by MGOfstream.
Definition: Ifstream.h:30
friend bool operator<=(const MGVector &v1, const MGVector &v2)
Definition: Vector.h:63
std::ostream & operator<<(std::ostream &ostrm, const MGisect &is)
Debug Function.
Definition: isect.h:95
friend bool operator!=(const MGVector &v1, const MGVector &v2)
Definition: Vector.h:75
MGLBRep is a class for B-SPline representation.
Definition: LBRep.h:41
bool is_null() const
Test if this is null.
Definition: Vector.h:248
MG_DLL_DECLR MGVector & operator*=(MGVector &v, const MGMatrix &m)
Vector of a general n space dimension.
Definition: Vector.h:26
MG_DLL_DECLR MGVector project(const MGVector &V1, const MGVector &V2)
V1をベクトル(v2)に射影したベクトルを求める。
double * data()
Definition: Vector.h:212
~MGVector()
Definition: Vector.h:140
MG_DLL_DECLR bool is_collinear(const MGPosition &P1, const MGPosition &P2, const MGPosition &P3)
Test if P1, P2, and P3 are on a single straight line.
MG_DLL_DECLR MGVector operator*(const MGVector &v, const MGMatrix &m)
Represent a positional data.
Definition: Position.h:28
int sdim() const
Get the space dimension.
Definition: Vector.h:309
int m_sdim
Friend Function.
Definition: Vector.h:354
MGOfstream is a class to serialize all of the subclasses of MGGel.
Definition: Ofstream.h:31
bool is_collinear(const MGVector &v2) const
Definition: Vector.h:235
friend bool operator<(const MGVector &v1, const MGVector &v2)
Definition: Vector.h:61
friend bool operator>(const MGVector &v1, const MGVector &v2)
Definition: Vector.h:65
friend bool operator>=(const MGVector &v1, const MGVector &v2)
Definition: Vector.h:67
MGOgesIfstream write out to *.iges file, transforming MGCL objects to IGES objects.
Definition: IgesOfstream.h:26
double & set(int i)
When length not computed, negative value will be set.
Definition: Vector.h:364
Defines Surface B-Representation, that is , B-Spline surface.
Definition: SBRep.h:48
Define a unit vector, is a MGVector.
Definition: Unit_vector.h:17
const double * data() const
Return the 1st address of the array of the vector double data.
Definition: Vector.h:211