Skip to content

Commit

Permalink
Merge branch 'master' of github.com:OpenSees/OpenSees
Browse files Browse the repository at this point in the history
  • Loading branch information
fmckenna committed Dec 1, 2023
2 parents 8182bee + aecd6de commit bc2c4c9
Show file tree
Hide file tree
Showing 14 changed files with 1,146 additions and 6 deletions.
2 changes: 1 addition & 1 deletion EXAMPLES/ExampleScripts/RCFrame5.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ set displayMode "displayOFF"
set g 386.4
set P 192
set m [expr $P/$g]
set mR 1.0e6
set mR 0
set PI [expr 2.0 * asin(1.0)]
set period 2.5;
set mag 5.0;
Expand Down
1 change: 1 addition & 0 deletions SRC/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -871,6 +871,7 @@ MATERIAL_LIBS = $(FE)/material/Material.o \
$(FE)/material/uniaxial/TDConcreteEXP.o \
$(FE)/material/uniaxial/TDConcreteMC10.o \
$(FE)/material/uniaxial/TDConcreteMC10NL.o \
$(FE)/material/uniaxial/CreepMaterial.o \
$(FE)/material/uniaxial/DegradingPinchedBW.o \
$(FE)/material/uniaxial/HystereticPoly.o \
$(FE)/material/uniaxial/HystereticSmooth.o \
Expand Down
5 changes: 3 additions & 2 deletions SRC/classTags.h
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,7 @@
#define MAT_TAG_TDConcreteMC10NL 227
#define MAT_TAG_CoulombDamperMaterial 228
#define MAT_TAG_FlagShapeMaterial 229
#define MAT_TAG_CreepMaterial 230

#define MAT_TAG_FedeasMaterial 1000
#define MAT_TAG_FedeasBond1 1001
Expand Down Expand Up @@ -350,7 +351,7 @@
#define SEC_TAG_LayeredShellFiberSectionThermal 35 //L.Jiang[SIF]
#define SEC_TAG_BiaxialHysteretic 36
#define SEC_TAG_ElasticTube3d 37

#define SEC_TAG_CreepSection 38

#define SEC_TAG_MCFTFiberSection2d 7601

Expand Down Expand Up @@ -633,7 +634,7 @@
#define ELE_TAG_ZeroLengthContactNTS2D 24
#define ELE_TAG_ZeroLengthInterface2D 25
#define ELE_TAG_CoupledZeroLength 26
#define ELE_TAG_BiaxialZeroLength 260
#define ELE_TAG_BiaxialZeroLength 2626
#define ELE_TAG_ZeroLengthRocking 27
#define ELE_TAG_NLBeamColumn2d 28
#define ELE_TAG_NLBeamColumn3d 29
Expand Down
3 changes: 3 additions & 0 deletions SRC/interpreter/OpenSeesUniaxialMaterialCommands.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ void* OPS_TDConcrete(void);
void* OPS_TDConcreteNL(void);
void* OPS_TDConcreteMC10(void);
void* OPS_TDConcreteMC10NL(void);
void* OPS_CreepMaterial(void);

void* OPS_CoulombDamperMaterial();
void* OPS_GMG_CyclicReinforcedConcrete();
Expand Down Expand Up @@ -599,6 +600,8 @@ static int setUpUniaxialMaterials(void) {
std::make_pair("TDConcreteMC10", &OPS_TDConcreteMC10));
uniaxialMaterialsMap.insert(
std::make_pair("TDConcreteMC10NL", &OPS_TDConcreteMC10NL));
uniaxialMaterialsMap.insert(
std::make_pair("Creep", &OPS_CreepMaterial));
uniaxialMaterialsMap.insert(
std::make_pair("CoulombDamper", &OPS_CoulombDamperMaterial));
uniaxialMaterialsMap.insert(std::make_pair(
Expand Down
16 changes: 15 additions & 1 deletion SRC/material/section/FiberSection2d.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -926,6 +926,13 @@ FiberSection2d::setResponse(const char **argv, int argc,
OPS_Stream &output)
{
Response *theResponse = 0;

if (strcmp(argv[0],"fiberIndex") == 0) {
if (argc < 3)
return 0;
int key = atoi(argv[1]);
return theMaterials[key]->setResponse(&argv[2], argc-2, output);
}

if (argc > 2 && strcmp(argv[0],"fiber") == 0) {

Expand Down Expand Up @@ -1163,9 +1170,16 @@ FiberSection2d::setParameter(const char **argv, int argc, Parameter &param)

int result = -1;

if (strcmp(argv[0],"fiberIndex") == 0) {
if (argc < 3)
return 0;
int key = atoi(argv[1]);
return theMaterials[key]->setParameter(&argv[2], argc-2, param);
}

// Check if the parameter belongs to the material
if (strstr(argv[0],"material") != 0) {

if (argc < 3)
return 0;

Expand Down
4 changes: 2 additions & 2 deletions SRC/material/section/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@ OBJS = SectionForceDeformation.o \
LayeredShellFiberSection.o \
LayeredShellFiberSectionThermal.o \
FiberSection3dThermal.o \
FiberSectionGJThermal.o \
MembranePlateFiberSectionThermal.o
MembranePlateFiberSectionThermal.o \
FiberSectionGJThermal.o

all: $(OBJS)
@$(CD) $(FE)/material/section/repres; $(MAKE);
Expand Down
32 changes: 32 additions & 0 deletions SRC/material/uniaxial/Bilin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
#include <Vector.h>
#include <Channel.h>
#include <cfloat>
#include <MaterialResponse.h>

#include <OPS_Globals.h>

Expand Down Expand Up @@ -1977,6 +1978,37 @@ Bilin::Print(OPS_Stream &s, int flag)
}
}

Response *Bilin::setResponse(const char **argv, int argc, OPS_Stream &theOutput)
{
// See if the response is one of the defaults
Response *theResponse = UniaxialMaterial::setResponse(argv, argc, theOutput);

if (theResponse != 0)
return theResponse;

if (strcmp(argv[0], "RSE") == 0)
{
theOutput.tag("ResponseType", "RSE");
theResponse = new MaterialResponse(this, 101, CRSE);
}

theOutput.endTag();
return theResponse;
}

int Bilin::getResponse(int responseID, Information &matInformation)
{
if (responseID == 101)
{
matInformation.setDouble(CRSE);
}
else
{
return UniaxialMaterial::getResponse(responseID, matInformation);
}
return 0;
}

//my functions
void
Bilin::interPoint(double &xInt, double &yInt, double x1, double y1, double m1, double x2, double y2, double m2)
Expand Down
2 changes: 2 additions & 0 deletions SRC/material/uniaxial/Bilin.h
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,8 @@ class Bilin : public UniaxialMaterial
FEM_ObjectBroker &theBroker);

void Print(OPS_Stream &s, int flag =0);
Response *setResponse(const char **argv, int argc, OPS_Stream &s);
int getResponse(int responseID, Information &matInformation);

virtual double getEnergy(void) { return CEnrgtot; } //by SAJalali

Expand Down
2 changes: 2 additions & 0 deletions SRC/material/uniaxial/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ target_sources(OPS_Material
ConcreteZBH_smoothed.cpp
ConfinedConcrete01.cpp
ContinuumUniaxial.cpp
CreepMaterial.cpp
CubicSpline.cpp
DamperMaterial.cpp
DegradingPinchedBW.cpp
Expand Down Expand Up @@ -220,6 +221,7 @@ target_sources(OPS_Material
ConcreteZBH_smoothed.h
ConfinedConcrete01.h
ContinuumUniaxial.h
CreepMaterial.h
CubicSpline.h
DamperMaterial.h
DegradingPinchedBW.h
Expand Down
Loading

0 comments on commit bc2c4c9

Please sign in to comment.