nodeReaction command

Forum for OpenSees users to post questions, comments, etc. on the use of the OpenSees interpreter, OpenSees.exe

Moderators: silvia, selimgunay, Moderators

Post Reply
apapaso
Posts: 17
Joined: Sun Mar 19, 2017 1:19 am
Location: AUTh - Greece

nodeReaction command

Post by apapaso »

Hi everybody!

I am trying to use the command nodeReaction $node <-$DOF> for calculating the base reaction of a 2d model, but it returns zero forces at every node of the model (fixed or not). In fact, it returns zero forces in every node, in any model I make...

Any suggestion?
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: nodeReaction command

Post by fmk »

try issuing a 'reaction' command before it
apapaso
Posts: 17
Joined: Sun Mar 19, 2017 1:19 am
Location: AUTh - Greece

Re: nodeReaction command

Post by apapaso »

Thank you so much!

I added a node recorder and it worked perfectly.
But, isn't it weird for nodeReaction to have the need of an other command to be enabled?

I also noticed that while the bare "reaction" is not recognized as a command in the script, it is not rejected as "invalid command name" when it is given in the command line.
After running my model and giving <reaction> in the command line, the command "nodeReaction" worked perfectly...
userav
Posts: 7
Joined: Thu Oct 27, 2011 12:57 pm
Location: -

Re: nodeReaction command

Post by userav »

As a work-around for this weird issue, in scripts I add a node recorder.
Example: "recorder Node -xml output/R.out -node 91 92 93 94 -dof 3 reaction"
Then the command 'nodeReaction' works.
EricsonEncinaZ
Posts: 108
Joined: Mon Sep 16, 2013 1:14 pm
Location: University of Auckland

Re: nodeReaction command

Post by EricsonEncinaZ »

apapaso wrote:
> Thank you so much!
>
> I added a node recorder and it worked perfectly.
> But, isn't it weird for nodeReaction to have the need of an other command to be
> enabled?
>
> I also noticed that while the bare "reaction" is not recognized as a
> command in the script, it is not rejected as "invalid command name" when it
> is given in the command line.
> After running my model and giving <reaction> in the command line, the command
> "nodeReaction" worked perfectly...

I faced the same problem and this as a follow up on the topic: The reason why the command "reaction" does not work in the script is beacuse the correct command is "reactions", in plural. In OpenSees and TCL commands are auto-completed when executed in the command line (try "forea v {1 2 3} {puts $v}" it will work as if you were issued a "foreach" command :-D), but they are not when sourced from a script. Since OpenSees is an extension of TCL, the user can quickly check the available commands for any word root by just issuing it, i.e. In an OpenSees prompt type r and then enter, you will get: "ambiguous command name r: rayleigh reactions read record recorder recv regexp region regsub reliability remove rename reset return", which are all the possible commands that begin with an r.
Post Reply