Search found 12 matches

by Andrew
Tue Apr 11, 2023 3:25 am
Forum: OpenSeesPy
Topic: Creating nodes from importing text file
Replies: 4
Views: 5354

Re: Creating nodes from importing text file

Thanks. I was aware of that script and had started to look at it. However, I noticed that the OpenSeesPy changelog included mention of a "Tcl to Python converter", and wondered it was somehow included in OpenSeesPy.
Version 3.4.0.2 (7/20/2022)
Update to commit abebbee.
Update sectionForce and sectionDeformation commands.
Update Tcl to Python converter.
If not then I will simply continue with the script you mentioned.
by Andrew
Tue Mar 28, 2023 11:03 pm
Forum: OpenSeesPy
Topic: Creating nodes from importing text file
Replies: 4
Views: 5354

Re: Creating nodes from importing text file

mhscott wrote: Wed Nov 09, 2022 9:47 am Use Tcl or Python to read the coordinates from the file and create nodes.
Sorry to ask a stupid question, but is it possible to import Tcl-format data into a Python Session, and if so, how?

I am using the OpenseesPy library with Python 3.9 on Windows 10.
by Andrew
Thu Aug 06, 2009 8:26 pm
Forum: OpenSees.exe Users
Topic: BuildingTcl and the MacOS
Replies: 5
Views: 4433

The Mac OS is based on the Mach kernel, which is derived from BSD Unix and NextStep, and I would have thought that Tcl/Tk code would work well with Unix-related systems. At the command line, creating folders/directories is the same as MS-DOS: mkdir newfolder.

Perhaps the main strange thing about the Mac is the fact that the main menubar for each application sits on the main menubar, rather than being attached to a window. I note that many X-window applications on the Mac follow the normal Unix/Windows convention of having the main application menubar on the window itself. When you do look at the Mac version, perhaps you need to find a way of putting the menu onto your window rather than it sitting on the main menubar (although you probably still need to have the "File" and "Help" menu items there.
by Andrew
Thu Aug 06, 2009 7:07 pm
Forum: OpenSees.exe Users
Topic: BuildingTcl and the MacOS
Replies: 5
Views: 4433

I probably won't have time to work on this, but what makes you think that the mac doesn't like subfolders?

What are the routines that add the menu items to the menubar?
by Andrew
Wed Aug 05, 2009 8:41 pm
Forum: OpenSees.exe Users
Topic: BuildingTcl and the MacOS
Replies: 5
Views: 4433

BuildingTcl and the MacOS

I am waiting for IT at work to install Tcl/Tk, so instead I have tried to use BuildingTcl on my MacBookPro.

This posting is mostly about documenting my experience in case anyone else wants to try it.

I have modified the following scripts to make them point to the right folders, I have added the directory containing the OpenSees executables to the path, and I have managed to start BuildingTcl.

myBuildingTcl.tcl
myBuildingTclViewer.tcl

I copied the above files into a new directory (do I have to do that?), and I then ran the following command from that directory:

OpenSeesTk <BuildingTcl_scripts_directory_path>/myBuildingTclViewer

A window then appeared for the OpenSeesTk application. Unfortunately it is too large for my screen, but I think I can see everything that I need to. The menubar initially only has three menu items: OpenSeesTk, File & Help. I then went to File | Load, and I opened GettingStartedDataFile.tcl. At this point an additional item was added to the main menu - "Input", and the "Analysis" options appeared in the window. I selected a model and two load combinations. Since there was no "Analysis" menu item, I clicked on the "Analyze" button at the bottom of the page. At this point the analysis started and the frame appeared followed by some graphs.

At the end, I wasn't sure what to do, as there was no "Results" menu item (and no "Analysis" one either). Any idea why this might be the case? I wonder whether it is a problem with the Mac version of the OpenSeesTk executable?

Using the "Input" menu, I am able to look at Material definitions etc. Under the Help menu, there are subfolders for "Templates", OpenSees Models" and "Reference". If I select "About", I get an error, complaining that it "can't read Frame3Path, no such variable".
by Andrew
Wed Aug 05, 2009 7:44 pm
Forum: OpenSees.exe Users
Topic: Using XML output
Replies: 7
Views: 8442

Silvia,

As a matter of interest, how are you extracting the data for your BuildingTcl program?
by Andrew
Mon Aug 03, 2009 7:20 pm
Forum: OpenSees.exe Users
Topic: Using XML output
Replies: 7
Views: 8442

[quote="silvia"]why not just do it in Tcl/Tk?[/quote]

Yes, that would certainly make sense. However, the question remains as to what tools to use with Tcl/Tk to query XML data? Would you use parsing (and other) tools such as those in TclXML package on SourceForge (SAX, DOM or XSLT)? Do you have any sample code for extracting time domain results that could be used to write a graph? All that data under <data> needs processing as text, unless there is some way that the schema helps to interpret it (which I am not currently familiar with).

[url=http://tclxml.sourceforge.net/][/url]
(or perhaps tDOM - [url=http://wiki.tcl.tk/1948][/url])

I have taken a look at BuildingTcl. Can I use that on a Mac? What would I need to do? Should I rewrite the BAT files as a script?

Another thing that would be good would be if I could pull the data straight into excel. Presumably I could use something like MSXL, although I presume it is now superseded by a method in VSTO.

[url=http://msdn.microsoft.com/en-us/library ... 10%29.aspx][/url]
by Andrew
Mon Aug 03, 2009 11:24 am
Forum: OpenSees.exe Users
Topic: Using XML output
Replies: 7
Views: 8442

Using XML output

What are the ways that we can use the XML output? I can see that it is quite powerful, but I am not sure what tools are out there already. I would like to be able to graph the data, but also to be able to do text processing to generate output data that I can read into visualisation programs.

I am using a Mac, so I have been looking for programs that will work on that platform.

I have tried opening the .xml files in Excel, but they come in as text. I have been looking at XQuery, which seems quite promising, but I am not sure what sort of queries to run, particularly on the <data> blocks, which seem to need postprocessing with something like sed or awk. I have found a little program called AquaQuery, which allows me to play with queries, but doesn't really do any of the heavy lifting. It also doesn't reference the schema.

What are other people using? Am I going to have to do some programming in PHP using XQuery, or something like that? How do I use the schema... and should I be doing so...(presumably yes!)...
by Andrew
Mon Aug 18, 2008 1:18 am
Forum: Feature Requests/Future Directions
Topic: Complex Modes
Replies: 0
Views: 4545

Complex Modes

As a matter of interest, has anyone written an analysis method for OpenSees that calculates complex modes? Is anyone planning to?
by Andrew
Wed Apr 02, 2008 5:04 am
Forum: OpenSees.exe Users
Topic: GSA Recorder
Replies: 5
Views: 6977

OpenSees and Oasys GSA

I have checked back with Steve Hendry, and I understand that they are moving ahead. They are currently implementing appropriate data structures in GSA, and are working on XML export. Results import back into GSA is still a little way off.
by Andrew
Wed Jan 30, 2008 3:06 am
Forum: OpenSees.exe Users
Topic: GSA Recorder
Replies: 5
Views: 6977

GSA Recorder

Hi Silvia,

Greetings from Hong Kong!

Maybe I should have posted this in the developers part.

A few years ago, Frank kindly wrote a recorder to export OpenSees results in a format that is directly readable by "GSA", which is our (Arup's) analysis software. GSA (which incidentally is free for academic use) currently writes out geometry files in Tcl format, but it doesn't set up the analysis, and I haven't properly checked that everything works properly. I did manage to do an analysis in the past and to read the results back into GSA, where I was able to view the results.

After rather a long break from this, I am trying to see if I can get GSA working with OpenSees again, but I find that the recorder now does not work, and in fact it actually crashes OpenSees. Presumably there have been some changes to the way that recorders work, or perhaps in the way that the beam-column elements output results. However, I am not knowledgeable enough to identify this. Do you think Frank or someone could help me identify what has changed and why the input file is crashing OpenSees? In the meantime I have been getting more familiar with programming etc, but I am still not fully up to doing this myself.
by Andrew
Tue Jan 29, 2008 12:42 am
Forum: OpenSees.exe Users
Topic: GSA Recorder
Replies: 5
Views: 6977

GSA Recorder

I am just returning to OpenSees after a little time away (three years!), and I was trying to run some old scripts. I find that the GSA Recorder does not work any longer. Any pointers on how to get it working again?

http://opensees.berkeley.edu/cgi-bin/cv ... r/#dirlist