%% dry single BbarBrick element with pressure dependent material
% subjected to 1D sinusoidal base shaking
ops.wipe();
friction = 31.40; % friction angle
phaseTransform = 26.50; % phase transformation angle
E1 = 93178.4; % Young's modulus
poisson1 = 0.40;
G1 = E1 / (2 * (1 + poisson1));
B1 = E1 / (3 * (1 - 2 * poisson1));
gamma = 0.600; % Newmark integration parameter
dt = 0.01; % time step for analysis
numSteps = 1600; % number of time steps
rhoS = 2.00; % saturated mass density
rhoF = 0.00; % fluid mass density
densityMult = 1.0; % density multiplier
Bfluid = 2.2e6; % fluid shear modulus
fluid1 = 1; % fluid material tag
solid1 = 10; % solid material tag
accMul = 4; % acceleration multiplier
piVal = 3.1415926535;
inclination = 0;
massProportionalDamping = 0.0;
InitStiffnessProportionalDamping = 0.001;
bUnitWeightX = (rhoS - 0.0) * 9.81 * sin(inclination / 180.0 * piVal) * densityMult;
bUnitWeightY = 0.0;
bUnitWeightZ = -(rhoS - rhoF) * 9.81 * cos(inclination / 180.0 * piVal);
ndm = 3;
ops.model('BasicBuilder', '-ndm', ndm, '-ndf', ndm);
ops.nDMaterial('PressureDependMultiYield', ...
solid1, ndm, rhoS * densityMult, G1, B1, ...
friction, 0.1, 80, 0.5, ...
phaseTransform, 0.17, 0.4, 10, 10, 0.015, 1.0);
ops.node(1, 0.00000, 0.0000, 0.00000);
ops.node(2, 0.00000, 0.0000, 1.00000);
ops.node(3, 0.00000, 1.0000, 0.00000);
ops.node(4, 0.00000, 1.0000, 1.00000);
ops.node(5, 1.00000, 0.0000, 0.00000);
ops.node(6, 1.00000, 0.0000, 1.00000);
ops.node(7, 1.00000, 1.0000, 0.00000);
ops.node(8, 1.00000, 1.0000, 1.00000);
ops.element('bbarBrick', ...
1, 1, 5, 7, 3, 2, 6, 8, 4, ...
solid1, bUnitWeightX, bUnitWeightY, bUnitWeightZ);
ops.updateMaterialStage('-material', solid1, '-stage', 0);
ops.fix(1, 1, 1, 1, 0, 0, 0);
ops.fix(2, 0, 1, 0, 0, 0, 0);
ops.fix(3, 1, 1, 1, 0, 0, 0);
ops.fix(4, 0, 1, 0, 0, 0, 0);
ops.fix(5, 1, 1, 1, 0, 0, 0);
ops.fix(6, 0, 1, 0, 0, 0, 0);
ops.fix(7, 1, 1, 1, 0, 0, 0);
ops.fix(8, 0, 1, 0, 0, 0, 0);
% equalDOF: tied nodes around
ops.equalDOF(2, 4, 1, 3);
ops.equalDOF(2, 6, 1, 3);
ops.equalDOF(2, 8, 1, 3);