Skip to content

Commit

Permalink
Store reaction forces into
Browse files Browse the repository at this point in the history
  • Loading branch information
mvanzulli committed Jan 16, 2023
1 parent e69df74 commit 98f703a
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/core/assembler.m
Expand Up @@ -350,10 +350,11 @@
fsCell{3} = Fmas ;
fsCell{4} = Faero ;


global globalFDrag
if ~isempty(globalFDrag) && (round(timeVar) == timeVar) && (timeVar ~= 0)
globalFDrag(timeVar) = sum(Faero(3:6:end)) ;
global globalReactionForces
global nodeReactionForces
if ~isempty(globalReactionForces) && (round(timeVar) == timeVar) && (timeVar ~= 0)
dofsRForces = (nodeReactionForces - 1) * 6 + 1 : nodeReactionForces * 6 ;
globalReactionForces((timeVar -1)*6 + 1: (timeVar)*6) = Faero(dofsRForces) - Fint(dofsRForces) - Fmas(dofsRForces) - Fvis(dofsRForces) ;
end
end

Expand Down

0 comments on commit 98f703a

Please sign in to comment.