3 Replies - 919 Views - Last Post: 21 December 2010 - 01:35 AM Rate Topic: -----

#1 snimmagadda3  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 5
  • Joined: 10-December 10

Need help in writing python code to find Reaction force

Posted 20 December 2010 - 11:37 PM

I ran macro manager and found the following script to find the reaction force.
odb = session.odbs['necking.odb']
  session.viewports['Viewport: 1'].odbDisplay.display.setValues(plotState=(
    DEFORMED, ))
  session.xyDataListFromField(odb=odb, outputPosition=NODAL, variable=(('RF', NODAL, ((COMPONENT, S+C), )), ), nodePick=(('PART-1-1', 1, ('[#0:2 #2000 ]', )), ), ) 
  xy1 = session.xyDataObjects['RF:RF3 PI: PART-1-1 N: 85']



I tried to replace this number '85' with a variable(so that i can find out when the node index changes accordingly with the dimensions of the structure) but i am unable to replace.And there is a relation with the part '[#0:2 #2000]'it changes accordingly with the node index ,so please help me with this.Or is there any other script available to find out reaction force.

Is This A Good Question/Topic? 0
  • +

Replies To: Need help in writing python code to find Reaction force

#2 Guest_c.user*


Reputation:

Re: Need help in writing python code to find Reaction force

Posted 21 December 2010 - 12:32 AM

you could use 'RF:RF3 PI: PART-1-1 N: ' + '85' expression
and then
node = str(85)

  ...

objs = 'RF:RF3 PI: PART-1-1 N: ' + node

  ...

xy1 = session.xyDataObjects[objs]



This post has been edited by c.user: 21 December 2010 - 12:33 AM

Was This Post Helpful? 1

#3 snimmagadda3  Icon User is offline

  • New D.I.C Head

Reputation: -3
  • View blog
  • Posts: 5
  • Joined: 10-December 10

Re: Need help in writing python code to find Reaction force

Posted 21 December 2010 - 12:54 AM

View Postc.user, on 20 December 2010 - 11:32 PM, said:

you could use 'RF:RF3 PI: PART-1-1 N: ' + '85' expression
and then
node = str(85)

  ...

objs = 'RF:RF3 PI: PART-1-1 N: ' + node

  ...

xy1 = session.xyDataObjects[objs]



Thanks for helping me with that but what about its dependence on '[#0:2#2000]'??The node index has specific type of this usage.It changes with this node index.
Was This Post Helpful? 0
  • +
  • -

#4 Guest_c.user*


Reputation:

Re: Need help in writing python code to find Reaction force

Posted 21 December 2010 - 01:35 AM

snimmagadda3 said:

And there is a relation with the part '[#0:2 #2000]'it changes accordingly with the node index

write an example
nodeindex1 -> changedpart1
nodeindex2 -> changedpart2
how is it changing
Was This Post Helpful? 0

Page 1 of 1