suanPan
MVLEM.h
Go to the documentation of this file.
1/*******************************************************************************
2 * Copyright (C) 2017-2024 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 MVLEM_H
30#define MVLEM_H
31
33
34class MVLEM final : public MaterialElement1D {
35 struct Fibre final {
36 double eccentricity = 0., width, height, c_area, s_area;
37 unique_ptr<Material> c_material, s_material;
38 Fibre(double, double, double);
39 };
40
41 static constexpr unsigned b_node = 2, b_dof = 3, b_size = b_dof * b_node;
42
43 double shear_height;
44 double length = 0.;
45 double shear_height_a = 0.;
46 double shear_height_b = 0.;
47 double total_area = 0.;
48
49 mat trans_mat;
50
51 vector<Fibre> axial_spring;
52
53 const unsigned shear_spring_tag;
54
55 unique_ptr<Material> shear_spring;
56
57public:
58 MVLEM(
59 unsigned, // tag
60 uvec&&, // node tag
61 const vector<double>&, // width
62 const vector<double>&, // thickness
63 const vector<double>&, // reinforcement ratio
64 uvec&&, // concrete material tags
65 uvec&&, // steel material tags
66 unsigned, // shear spring tag
67 double // shear spring height
68 );
69
70 int initialize(const shared_ptr<DomainBase>&) override;
71
72 int update_status() override;
73
74 int commit_status() override;
75 int clear_status() override;
76 int reset_status() override;
77
78 vector<vec> record(OutputType) override;
79
80 void print() override;
81
82#ifdef SUANPAN_VTK
83 void Setup() override;
84 void GetData(vtkSmartPointer<vtkDoubleArray>&, OutputType) override;
85 void SetDeformation(vtkSmartPointer<vtkPoints>&, double) override;
86#endif
87};
88
89#endif
90
OutputType
Definition: OutputType.h:23
A Fibre class.
Definition: Fibre.h:34
The MVLEM class.
Definition: MVLEM.h:34
MVLEM(unsigned, uvec &&, const vector< double > &, const vector< double > &, const vector< double > &, uvec &&, uvec &&, unsigned, double)
Definition: MVLEM.cpp:28
int initialize(const shared_ptr< DomainBase > &) override
Definition: MVLEM.cpp:47
int update_status() override
Definition: MVLEM.cpp:114
int commit_status() override
Definition: MVLEM.cpp:183
vector< vec > record(OutputType) override
Definition: MVLEM.cpp:207
int reset_status() override
Definition: MVLEM.cpp:199
int clear_status() override
Definition: MVLEM.cpp:191
void print() override
Definition: MVLEM.cpp:216
Definition: MaterialElement.h:51