suanPan
B2DL.h
Go to the documentation of this file.
1 /*******************************************************************************
2  * Copyright (C) 2017-2022 Theodore Chang
3  *
4  * This program is free software: you can redistribute it and/or modify
5  * it under the terms of the GNU General Public License as published by
6  * the Free Software Foundation, either version 3 of the License, or
7  * (at your option) any later version.
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program. If not, see <http://www.gnu.org/licenses/>.
16  ******************************************************************************/
29 #ifndef B2DL_H
30 #define B2DL_H
31 
33 
34 class B2DL : public Orientation {
35 protected:
36  mat trans_mat;
37 
38  void form_trans_mat(const vec&);
39  void update_transformation() override;
40 
41 public:
42  explicit B2DL(unsigned = 0, double = 0., double = 0., double = 1.);
43  B2DL(unsigned, vec&&);
44 
45  unique_ptr<Orientation> get_copy() override;
46 
47  [[nodiscard]] vec to_local_vec(const vec&) const override;
48  [[nodiscard]] vec to_global_vec(const vec&) const override;
49  [[nodiscard]] mat to_global_mass_mat(const mat&) const override;
50  [[nodiscard]] mat to_global_stiffness_mat(const mat&) const override;
51 };
52 
53 #endif
54 
A B2DL class.
Definition: B2DL.h:34
B2DL(unsigned=0, double=0., double=0., double=1.)
Definition: B2DL.cpp:31
void update_transformation() override
Definition: B2DL.cpp:39
mat to_global_mass_mat(const mat &) const override
transform anything from local to global system e.g., stiffness -> stiffness.
Definition: B2DL.cpp:57
unique_ptr< Orientation > get_copy() override
Definition: B2DL.cpp:37
vec to_local_vec(const vec &) const override
transform anything from global to local system e.g., disp -> disp, vel -> vel, acc -> acc,...
Definition: B2DL.cpp:53
void form_trans_mat(const vec &)
Definition: B2DL.cpp:22
mat to_global_stiffness_mat(const mat &) const override
Definition: B2DL.cpp:79
mat trans_mat
Definition: B2DL.h:36
vec to_global_vec(const vec &) const override
transform anything from local to global system e.g., disp -> disp, vel -> vel, acc -> acc,...
Definition: B2DL.cpp:55
A Orientation class.
Definition: Orientation.h:40