suanPan
F21.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 ******************************************************************************/
34#ifndef F21_H
35#define F21_H
36
39
40class F21 final : public SectionElement2D {
41 struct IntegrationPoint final {
42 double coor, weight;
43 unique_ptr<Section> b_section;
44 mat B;
45 IntegrationPoint(double, double, unique_ptr<Section>&&);
46 };
47
48 static constexpr unsigned b_node = 2, b_dof = 3, b_size = b_dof * b_node;
49
50 const unsigned int_pt_num;
51
52 const double length = 0.;
53
54 vector<IntegrationPoint> int_pt;
55
56 unique_ptr<Orientation> b_trans;
57
58 mat initial_local_flexibility;
59 mat current_local_flexibility, trial_local_flexibility;
60 vec current_local_deformation, trial_local_deformation;
61 vec current_local_resistance, trial_local_resistance;
62
63public:
64 F21(
65 unsigned, // tag
66 uvec&&, // node tag
67 unsigned, // section tags
68 unsigned = 6, // integration points
69 bool = false // nonlinear geometry switch
70 );
71
72 int initialize(const shared_ptr<DomainBase>&) override;
73
74 int update_status() override;
75
76 int clear_status() override;
77 int commit_status() override;
78 int reset_status() override;
79
80 vector<vec> record(OutputType) override;
81
82 void print() override;
83
84#ifdef SUANPAN_VTK
85 void Setup() override;
86 void GetData(vtkSmartPointer<vtkDoubleArray>&, OutputType) override;
87 void SetDeformation(vtkSmartPointer<vtkPoints>&, double) override;
88#endif
89};
90
91#endif
92
OutputType
Definition: OutputType.h:23
The F21 class.
Definition: F21.h:40
int initialize(const shared_ptr< DomainBase > &) override
Definition: F21.cpp:39
int clear_status() override
Definition: F21.cpp:106
void print() override
Definition: F21.cpp:148
int reset_status() override
Definition: F21.cpp:128
F21(unsigned, uvec &&, unsigned, unsigned=6, bool=false)
Definition: F21.cpp:34
int update_status() override
Definition: F21.cpp:71
vector< vec > record(OutputType) override
Definition: F21.cpp:139
int commit_status() override
Definition: F21.cpp:117
Definition: SectionElement.h:64