suanPan
B31.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 B31_H
30#define B31_H
31
34
35class B31 final : public SectionElement3D {
36 struct IntegrationPoint final {
37 double coor, weight;
38 unique_ptr<Section> b_section;
39 mat strain_mat; // axial strain, curvature about the z-axis (major), curvature about the y-axis (minor)
40 IntegrationPoint(double, double, unique_ptr<Section>&&);
41 };
42
43 static constexpr unsigned b_node = 2, b_dof = 6, b_size = b_dof * b_node;
44
45 static const span b_span;
46
47 const unsigned orientation_tag, int_pt_num;
48
49 const double length = 0., torsion_stiff = 0.;
50
51 vector<IntegrationPoint> int_pt;
52
53 unique_ptr<Orientation> b_trans;
54
55public:
56 B31(
57 unsigned, // tag
58 uvec&&, // node tags
59 unsigned, // section tag
60 unsigned, // orientation tag
61 unsigned = 6, // integration points
62 bool = false // nonlinear geometry switch
63 );
64
65 int initialize(const shared_ptr<DomainBase>&) override;
66
67 int update_status() override;
68
69 int commit_status() override;
70 int clear_status() override;
71 int reset_status() override;
72
73 vector<vec> record(OutputType) override;
74
75 void print() override;
76
77#ifdef SUANPAN_VTK
78 void Setup() override;
79 void GetData(vtkSmartPointer<vtkDoubleArray>&, OutputType) override;
80 void SetDeformation(vtkSmartPointer<vtkPoints>&, double) override;
81#endif
82};
83
84#endif
85
OutputType
Definition: OutputType.h:23
The B31 class.
Definition: B31.h:35
int commit_status() override
Definition: B31.cpp:107
int clear_status() override
Definition: B31.cpp:115
int reset_status() override
Definition: B31.cpp:123
int update_status() override
Definition: B31.cpp:85
int initialize(const shared_ptr< DomainBase > &) override
Definition: B31.cpp:40
void print() override
Definition: B31.cpp:137
vector< vec > record(OutputType) override
Definition: B31.cpp:131
B31(unsigned, uvec &&, unsigned, unsigned, unsigned=6, bool=false)
Definition: B31.cpp:35
Definition: SectionElement.h:77