Importing from tcl

Hello! In this section we'll talk about the post processing module and the data visualization.
Post Reply
Ali shafiee
Posts: 4
Joined: Mon Nov 04, 2019 4:28 pm

Importing from tcl

Post by Ali shafiee » Mon Nov 04, 2019 4:30 pm

Hi,
Can we import a TCL file to STKO and use it as a model for post proccessing?
Thank in advance :)

MassimoPetracca
Posts: 17
Joined: Wed Jul 24, 2019 11:10 am

Re: Importing from tcl

Post by MassimoPetracca » Tue Nov 05, 2019 12:12 pm

Dear Ali,

You cannot import a TCL file in STKO pre-processor. However I think that what you really want is to visualize the results of your model (made in TCL and not through the STKO pre-processor) in the STKO post-processor.

This can be done. Keep in mind that the pre-processor and the post-processor are two separated things: It is not mandatory to use the STKO pre-processor to produce an output that can be imported in the STKO post processor.

If you have an existing TCL file, and you want to post process it in STKO post-processor you need:
  1. An OpenSEES version >= 3.0.0 (you need the "mpco" recorder command)
  2. Use the "mpco" recorder command in your TCL script
The User manual for the MPCO recorder can be found in your STKO installation directory (for example in Windows "C:\Program Files\STKO\documentation\MPCO Recorder.pdf"). There you can find a detailed description of all command arguments, as well as some examples.

A last note: the "mpco" recorder can handle multiple analyis stages (for example when you do a push over, you first run a gravity analysis and then the pushover one). You just need to put the "mpco" recorder command right before the first analysis that you want to record, and it will automatically record all the subsequent analyses. Every analysis stage or every change in your model, will be correctly recorded in the output *.mpco database. So there is no need to create/remove recorders for each analysis stage.

If you have any doubt about the usage of the "mpco" recorder command, please post it here!, we will try to answer as soon as possible.

Best regards

Massimo Petracca

Ali shafiee
Posts: 4
Joined: Mon Nov 04, 2019 4:28 pm

Re: Importing from tcl

Post by Ali shafiee » Tue Nov 05, 2019 4:40 pm

Thank you very much Sir,
It helped me a lot.

Ali shafiee
Posts: 4
Joined: Mon Nov 04, 2019 4:28 pm

Re: Importing from tcl

Post by Ali shafiee » Thu Nov 07, 2019 1:05 pm

Hello again,
As you said I put the mpco. recorder in my TCL code,then I downloaded the "hdf5-1.10.5-Std-win10_64-vs14" and installed it, but when I run the TCL code,I get this error:""Warning! ***HDF5 library version mismatched error***""
and it does'nt create a mpco file,
In the mpco user manual it said that: ""The HDF5 shared library must be “visible” to the opensees executable (i.e. in the same directory of the opensees executable or in a known path where the system searches for shared libraries)""
and I don't know which files or folders should I put in the same location as Opensees.exe to solve this problem.
I'd be very thankful if you help me with this :)

Best regards

MassimoPetracca
Posts: 17
Joined: Wed Jul 24, 2019 11:10 am

Re: Importing from tcl

Post by MassimoPetracca » Thu Nov 07, 2019 3:07 pm

Dear Ali,

You don't need to install the HDF5 library by yourself. The necessary redistributables are located in the STKO install directory (typically in "C:\Program Files\STKO\opensees\bin\hdf5").

If for some reason you want to install HDF5 by yourself, you need a specific version: 1.10.1. Unfortunately the installer for that version is not available anymore on the HDF5 website, but the source cose is there and you can compile it.

If you downloaded the STKO+OpenSees package, then you already have OpenSees.exe (version 3.0.3) located in "C:\Program Files\STKO\opensees\bin\OpenSees_303".
There is also a batch script "C:\Program Files\STKO\opensees\opensees_303.bat" that takes care of setting up the necessary environment variables so that OpenSees can find HDF5 and all other dependencies.

So to summarize, what I suggest is to run your model in this way:
  • Go in the directory where you have your TCL files
  • Open a terminal window
    open_terminal.PNG
    open_terminal.PNG (56.23 KiB) Viewed 96 times
  • Type the following commad:
    "C:\Program Files\STKO\opensees\opensees_303.bat" your_tcl_script.tcl
    run_opensees_batch.PNG
    run_opensees_batch.PNG (67.92 KiB) Viewed 96 times
Note: If you downloaded STKO alone (no OpenSees.exe included) and you are using your own OpenSees.exe, you can just copy your OpenSees.exe in "C:\Program Files\STKO\opensees\bin\OpenSees_303" and you are ready to go, as all the other dependencies are already there.

Let me know if this solves your problem.

Best regards

Massimo Petracca

Ali shafiee
Posts: 4
Joined: Mon Nov 04, 2019 4:28 pm

Re: Importing from tcl

Post by Ali shafiee » Fri Nov 08, 2019 5:18 pm

Thank you very much sir,
I solved it,

Now I run the TCL code and it creates a mpco file which is about 1.7(GB),
then I open it in the Post Processor section with "OpenDB" command,
after that I get some warnings, for example:"" Warning: unsupported attribute "LAMBDA""
I can see the plots for Deformed shape and Gauss point and ... and they seem reasonable,
but I don't know if I'm doing right, because of the warnings.

Best Regards
Attachments
2019-11-08_20-46-49.jpg
2019-11-08_20-46-49.jpg (378.02 KiB) Viewed 89 times

MassimoPetracca
Posts: 17
Joined: Wed Jul 24, 2019 11:10 am

Re: Importing from tcl

Post by MassimoPetracca » Sat Nov 09, 2019 10:00 am

Dear Ali,

Don't warry about those warnings... You did an "eigen" analysis and requested the "modesOfVibration" output from "mpco" recorder. Now the "mpco" recorders also saves in the .mpco database the eigenvalues (and all derived quantities, OMEGA, FREQ PERIOD...) for each eigenmode.

The warning is simply due to the fact that the STKO post-processor does know how to treat those information yet:
we are still deciding where to put those infromation :lol: , probably we will put them in a table on the editor panel on the right, if you select the "modesOfVribration" result in the plot.

Post Reply