hello all, im on the post processing to automate the results data. im done with automation of contour vaules of every nodes for each subcase(centrifugal force distributions in Rotor depends on RPM). and now i want to also query vector values of each node for each subcase. but i couldnt find any TCL Commend for it.
do you guys have idea for automation to query vector? thanks
here is my automation TCL commend.
hwi GetSessionHandle session
session GetProjectHandle project
project GetPageHandle page [project GetActivePage]
page GetWindowHandle window [page GetActiveWindow]
window GetClientHandle client
client GetModelHandle model [client GetActiveModel]
model GetResultCtrlHandle result
result GetContourCtrlHandle contour
contour SetDataType "Element Stresses (2D & 3D)"
contour SetDataComponent component vonMises
contour SetAverageMode advanced
contour SetLayer Max
contour SetEnableState True
contour SetResultSystem 0
contour SetDimensionEnabled solid True
contour SetDimensionEnabled shell True
contour SetEnableState True
client GetMeasureHandle measure 1
model GetQueryCtrlHandle myQueryName
model GetSelectionSetHandle mySetName [model AddSelectionSet node]
mySetName Add all
lappend max_stress
set subcases [result GetSubcaseList "Base"]
puts "Subcaselist: $subcases"
foreach i $subcases {
result SetCurrentSubcase $i ;# nächsten Subcase auswählen
client Draw ;# refresh View
result SetCurrentSimulation $i
myQueryName SetDataSourceProperty result datatype Stress
myQueryName SetDataSourceProperty result shelllayer Upper
myQueryName SetQuery "node.id, node.coords, contour.value"
myQueryName SetSelectionSet [mySetName GetID]
myQueryName WriteData {D:/junhyeong/Spannungsdaten/test.csv}
file rename -force

/junhyeong/Spannungsdaten/test.csv

/junhyeong/Spannungsdaten/${i}.csv
lappend max_stress [measure GetMaximum scalar] ;# Maximum an Liste anhängen
}
# Export der maximalen Spannungen
set responses_file [open "struct_responses.json" "w"]
set line "\[[join $max_stress ", "]\]"
puts -nonewline $responses_file $line
close $responses_file