Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations cowski on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Extract nodeset coordinates in abaqus with python script

Status
Not open for further replies.

Tarhouni

Student
Mar 3, 2021
4
Hello,

I would like to extract the Node set coordinates using a python script. i tried with this method using odb file :

import sys
from odbAccess import *
from abaqus import *
from abaqusConstants import *
import __main__

odb = openOdb('C:/Temp/Job-1.odb')
set = odb.rootAssembly.instances['part-1'].nodeSets['Set-1']
numNodes = len(set.nodes)
partlabel=[];
partxcord=[];
partycord=[];
partzcord=[];
for curNode in a.nodes:
partlabel.append(curNode.label)
partxcord.append(curNode.coordinates[0])
partycord.append(curNode.coordinates[1])
partzcord.append(curNode.coordinates[2])
The error displayed is : keyerror : Set-1.
knowing that when I defined the same syntax for the coordinates of the instance nodes, it works correctly.
myInstance = odb.rootAssembly.instances['part-1']
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor