suanPan
🧮 An Open Source, Parallel and Heterogeneous Finite Element Analysis Framework
Loading...
Searching...
No Matches
B31OS.h
Go to the documentation of this file.
1/*******************************************************************************
2 * Copyright (C) 2017-2026 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 ******************************************************************************/
33#ifndef B31OS_H
34#define B31OS_H
35
38
39class B31OS final : public SectionOSElement3D {
40 struct IntegrationPoint final {
41 double coor, weight;
42 unique_ptr<Section> b_section;
43 sp_mat strain_mat;
44 IntegrationPoint(double, double, double, unique_ptr<Section>&&);
45 };
46
47 static constexpr unsigned b_node = 2, b_dof = 7, b_size = b_dof * b_node;
48
49 const unsigned orientation_tag, int_pt_num;
50
51 const double length{0.};
52
53 std::vector<IntegrationPoint> int_pt;
54
55 unique_ptr<Orientation> b_trans;
56
57public:
58 B31OS(
59 unsigned, // tag
60 uvec&&, // node tags
61 unsigned, // section tag
62 unsigned, // orientation tag
63 unsigned = 6, // integration points
64 bool = false // nonlinear geometry switch
65 );
66
67 int initialize(const shared_ptr<DomainBase>&) override;
68
69 int update_status() override;
70
71 int commit_status() override;
72 int clear_status() override;
73 int reset_status() override;
74
75 [[nodiscard]] std::vector<vec> record(OutputType) const override;
76
77 void print() override;
78
79#ifdef SUANPAN_VTK
80 [[nodiscard]] vtkSmartPointer<vtkCell> GetCell() const override;
81
82 mat GetData(OutputType) override;
83 mat GetDeformation(double) override;
84#endif
85};
86
87#endif
88
OutputType
Definition OutputType.h:23
The B31OS class.
Definition B31OS.h:39
int commit_status() override
Definition B31OS.cpp:169
void print() override
Definition B31OS.cpp:199
int update_status() override
Definition B31OS.cpp:133
std::vector< vec > record(OutputType) const override
Definition B31OS.cpp:193
int clear_status() override
Definition B31OS.cpp:177
int initialize(const shared_ptr< DomainBase > &) override
Definition B31OS.cpp:90
int reset_status() override
Definition B31OS.cpp:185
Definition SectionElement.h:112