XC Open source finite element analysis program
ParticlePos3d.h
1 //----------------------------------------------------------------------------
2 // XC program; finite element analysis code
3 // for structural analysis and design.
4 //
5 // Copyright (C) Luis Claudio Pérez Tato
6 //
7 // This program derives from OpenSees <http://opensees.berkeley.edu>
8 // developed by the «Pacific earthquake engineering research center».
9 //
10 // Except for the restrictions that may arise from the copyright
11 // of the original program (see copyright_opensees.txt)
12 // XC is free software: you can redistribute it and/or modify
13 // it under the terms of the GNU General Public License as published by
14 // the Free Software Foundation, either version 3 of the License, or
15 // (at your option) any later version.
16 //
17 // This software is distributed in the hope that it will be useful, but
18 // WITHOUT ANY WARRANTY; without even the implied warranty of
19 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 // GNU General Public License for more details.
21 //
22 //
23 // You should have received a copy of the GNU General Public License
24 // along with this program.
25 // If not, see <http://www.gnu.org/licenses/>.
26 //
27 #ifndef ParticlePos3d_H
28 #define ParticlePos3d_H
29 
30 #include <iostream>
31 
32 class Pos2d;
33 class Pos3d;
34 
35 namespace XC {
36 
38 //
41  {
42  protected:
43  double r;
44  double s;
45  double t;
46 
47  public:
48  ParticlePos3d(const double &r_coord = 0,
49  const double &s_coord = 0,
50  const double &t_coord = 0);
51  ParticlePos3d(const Pos2d &);
52  ParticlePos3d(const Pos3d &);
53  void set_coordinates(const double &r_coord = 0,const double &s_coord = 0,const double &t_coord = 0);
54  void set_coordinates(const Pos3d &);
55  void set_coordinates(const Pos2d &);
56 
57  inline const double &r_coordinate(void) const
58  { return r; }
59  inline void set_r_coordinate(const double &r_coord)
60  { r= r_coord; }
61  inline const double &s_coordinate(void) const
62  { return s; }
63  inline void set_s_coordinate(const double &s_coord)
64  { s= s_coord; }
65  inline const double &t_coordinate(void) const
66  { return t; }
67  inline void set_t_coordinate(const double &t_coord)
68  { r= t_coord; }
69  void Print(std::ostream &) const;
70  };
71 
72 std::ostream &operator<<(std::ostream &, const ParticlePos3d &);
73 
74 } // end of XC namespace
75 
76 #endif
77 //
Natural coordinates of an element&#39;s particle.
Definition: ParticlePos3d.h:40
void set_coordinates(const double &r_coord=0, const double &s_coord=0, const double &t_coord=0)
Asigna valores a las coordenadas.
Definition: ParticlePos3d.cc:49
================================================================================
Definition: ContinuaReprComponent.h:34
ParticlePos3d(const double &r_coord=0, const double &s_coord=0, const double &t_coord=0)
Constructor.
Definition: ParticlePos3d.cc:33