Jump to content
  • Announcements

    • Rahul Ponginan

      Please click here for a short but important announcement   03/26/17

      Dear Users Our Commercial and Academic users around the world can use these same forums here as before i.e. the Altair Support Forum , Commercial users from India with solver queries can go to the Solver Forum for India Commercial Users , Academic Users from India and AOC India Participants are requested to go to the Forum for India Academic Users and AOC India Participants , We will be tending to all queries in all the forums promptly as before, thank you for your understanding. 
modimech

how to extract time step and corresponding contour value by using TCL/tk

Recommended Posts

1.) I want to extract data for only specific set of elements but  I am getting contour value all element. I don't know what is mistake

 

proc QueryAndExportELEM {FileName} {

    mh GetSelectionSetHandle ssh [mh AddSelectionSet element]
    ssh Clear
    ssh Add "dimension 2"
    ssh Add "dimension 3"
 
 foreach elem {11 22} {
     ssh Add "id $elem"
     mh GetQueryCtrlHandle qc
    qc SetSelectionSet [ssh GetID]
    qc SetQuery "element.id contour.value"
    qc GetIteratorHandle qciter
   
    puts "Element ID: $elem"
  
    set fp [open $FileName w]
  
    for {qciter First} {[qciter Valid]} {qciter Next} {
    puts $fp [regsub -all \{ [regsub -all \} [qciter GetDataList] ""] ""] }
    close $fp
   
     mh RemoveSelectionSet [ssh GetID"] 
  
     qc ReleaseHandle 
     qciter ReleaseHandle
 }
   ssh ReleaseHandle
 
 }

 

 2.)  How I can extract time step and corresponding contour value to .csv file by using TCL/tk. ??

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×