suanPan
🧮 An Open Source, Parallel and Heterogeneous Finite Element Analysis Framework
Loading...
Searching...
No Matches
Balloon.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 ******************************************************************************/
28#ifndef BALLOON_H
29#define BALLOON_H
30
31#include "BalloonUtil.h"
32
34
36 const double elastic; // elastic modulus
37 const double poisson; // poisson's ratio
38 const double kr; // plastic strain split ratio
39 const unsigned zr_size; // memory size
41
43
44 const std::vector<BalloonSaturation> bfc, bac, bna, bnd;
45};
46
47class Balloon final : protected DataBalloon, protected BalloonBase, public Material3D {
48 static constexpr unsigned max_iteration = 20u;
49 inline static const double root_two_third = std::sqrt(2. / 3.);
50 static const mat unit_dev_tensor;
51
52 BalloonBuffer current_zr{zr_size}, trial_zr{zr_size};
53
54 const double double_shear = elastic / (1. + poisson); // double shear modulus
55
56 [[nodiscard]] auto compute_isotropic_bound(double, double, double);
57 [[nodiscard]] auto compute_kinematic_bound(double, double, double);
58
59public:
60 Balloon(
61 unsigned, // tag
62 DataBalloon&&, // data
63 double = 0. // density
64 );
65
66 int initialize(const shared_ptr<DomainBase>&) override;
67
68 unique_ptr<Material> unique_copy() override;
69
70 int update_trial_status(const vec&) override;
71
72 int clear_status() override;
73 int commit_status() override;
74 int reset_status() override;
75
76 void print() override;
77};
78
79#endif
80
Definition BalloonUtil.h:96
Definition BalloonUtil.h:67
Definition BalloonUtil.h:24
Type
Definition BalloonUtil.h:33
A Balloon material class.
Definition Balloon.h:47
int commit_status() override
Definition Balloon.cpp:294
unique_ptr< Material > unique_copy() override
Definition Balloon.cpp:96
int clear_status() override
Definition Balloon.cpp:286
int update_trial_status(const vec &) override
Definition Balloon.cpp:98
void print() override
Definition Balloon.cpp:310
int reset_status() override
Definition Balloon.cpp:302
int initialize(const shared_ptr< DomainBase > &) override
Definition Balloon.cpp:88
The Material3D class.
Definition Material3D.h:35
Definition Balloon.h:35
const BalloonBound bound_am
Definition Balloon.h:42
const std::vector< BalloonSaturation > bac
Definition Balloon.h:44
const std::vector< BalloonSaturation > bna
Definition Balloon.h:44
const BalloonBuffer::Type zr_type
Definition Balloon.h:40
const BalloonBound bound_u
Definition Balloon.h:42
const double kr
Definition Balloon.h:38
const BalloonBound bound_ac
Definition Balloon.h:42
const unsigned zr_size
Definition Balloon.h:39
const std::vector< BalloonSaturation > bfc
Definition Balloon.h:44
const std::vector< BalloonSaturation > bnd
Definition Balloon.h:44
const BalloonBound bound_fm
Definition Balloon.h:42
const double elastic
Definition Balloon.h:36
const double poisson
Definition Balloon.h:37
const BalloonBound bound_fc
Definition Balloon.h:42