suanPan
Degradation.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 DEGRADATION_H
30#define DEGRADATION_H
31
33
34class Degradation : public Material1D {
35 const unsigned mat_tag;
36
37protected:
39
40 [[nodiscard]] virtual vec compute_positive_degradation(double) const = 0; // positive region
41 [[nodiscard]] virtual vec compute_negative_degradation(double) const = 0; // negative region
42
43public:
45 unsigned, // tag
46 unsigned // material tag
47 );
49 Degradation(Degradation&&) noexcept = delete;
50 Degradation& operator=(const Degradation&) = delete;
51 Degradation& operator=(Degradation&&) noexcept = delete;
52 ~Degradation() override = default;
53
54 int initialize(const shared_ptr<DomainBase>&) override;
55
56 int clear_status() override;
57 int commit_status() override;
58 int reset_status() override;
59};
60
62public:
64
65 int initialize(const shared_ptr<DomainBase>&) override;
66
67 int update_trial_status(const vec&) override;
68
69 vector<vec> record(OutputType) override;
70};
71
73public:
75
76 int initialize(const shared_ptr<DomainBase>&) override;
77
78 int update_trial_status(const vec&) override;
79
80 vector<vec> record(OutputType) override;
81};
82
83#endif
84
OutputType
Definition: OutputType.h:23
The Degradation class.
Definition: Degradation.h:34
virtual vec compute_negative_degradation(double) const =0
Degradation(Degradation &&) noexcept=delete
int commit_status() override
Definition: Degradation.cpp:54
int reset_status() override
Definition: Degradation.cpp:62
virtual vec compute_positive_degradation(double) const =0
int initialize(const shared_ptr< DomainBase > &) override
Definition: Degradation.cpp:31
int clear_status() override
Definition: Degradation.cpp:46
Degradation(unsigned, unsigned)
Definition: Degradation.cpp:22
unique_ptr< Material > base
Definition: Degradation.h:38
The DomainBase class is a template.
Definition: DomainBase.h:104
A Material1D class.
Definition: Material1D.h:36
vector< vec > record(OutputType) override
Definition: Material1D.cpp:24
int update_trial_status(double)
Definition: Material.cpp:147
Definition: Degradation.h:61
Definition: Degradation.h:72