Skip to content

Commit

Permalink
Merge pull request #667 from mhscott/dbnl3dinitialK
Browse files Browse the repository at this point in the history
Fixing initial stiffness calculation
  • Loading branch information
mhscott committed Sep 21, 2021
2 parents 9039f7c + 11e942b commit 193d18d
Showing 1 changed file with 23 additions and 2 deletions.
25 changes: 23 additions & 2 deletions SRC/element/dispBeamColumn/DispBeamColumnNL3d.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -870,23 +870,44 @@ DispBeamColumnNL3d::getInitialBasicStiff()
ka(k,2) += (xi6-2.0)*tmp;
}
break;
case SECTION_RESPONSE_MY:
for (k = 0; k < order; k++) {
tmp = ks(k,j)*wti;
ka(k,3) += (xi6-4.0)*tmp;
ka(k,4) += (xi6-2.0)*tmp;
}
break;
case SECTION_RESPONSE_T:
for (k = 0; k < order; k++)
ka(k,5) += ks(k,j)*wti;
break;
default:
break;
}
}
for (j = 0; j < order; j++) {
switch (code(j)) {
case SECTION_RESPONSE_P:
for (k = 0; k < 3; k++)
for (k = 0; k < 6; k++)
kb(0,k) += ka(j,k);
break;
case SECTION_RESPONSE_MZ:
for (k = 0; k < 3; k++) {
for (k = 0; k < 6; k++) {
tmp = ka(j,k);
kb(1,k) += (xi6-4.0)*tmp;
kb(2,k) += (xi6-2.0)*tmp;
}
break;
case SECTION_RESPONSE_MY:
for (k = 0; k < 6; k++) {
tmp = ka(j,k);
kb(3,k) += (xi6-4.0)*tmp;
kb(4,k) += (xi6-2.0)*tmp;
}
break;
case SECTION_RESPONSE_T:
for (k = 0; k < 6; k++)
kb(5,k) += ka(j,k);
default:
break;
}
Expand Down

0 comments on commit 193d18d

Please sign in to comment.