OpenSeesSP + MATLAB

This forum is for issues related to parallel processing
and OpenSees using the new interpreters OpenSeesSP and OpenSeesMP

Moderator: selimgunay

Post Reply
AHARSHIAN
Posts: 87
Joined: Tue Apr 03, 2012 3:34 am
Location: Germany, Weimar
Contact:

OpenSeesSP + MATLAB

Post by AHARSHIAN »

Hi,

I have problem in coupling matlab with OpenSeesSP. When I run my code with direct use of OpenSeesSP executable, everything goes well. However, when I try to run it through matlab platform, it doesn't recognize "mpiexec". Generally speaking, I have problem in commanding "mpiexec -np i OpenSeesSP code.tcl" through matlab.

Why I need to use matlab? Because my simulations are kind of restarting analysis. That is, I need to do post processing (using matlab) of analysis number i, and then use the results for the analysis number i+1.


I guess that the problem is because I don't have license for the parallel toolbox in matlab! Isn't that so?


Thanks for you help!
Best Regards,
A.H.Arshian
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: OpenSeesSP + MATLAB

Post by fmk »

don't know .. did you try giving the full path to matlab ..
AHARSHIAN
Posts: 87
Joined: Tue Apr 03, 2012 3:34 am
Location: Germany, Weimar
Contact:

Re: OpenSeesSP + MATLAB

Post by AHARSHIAN »

Thanks for the comment,

Actually, the executable can be run without any problem. The problem is the "mpiexec" command! Matlab reports it as invalid command ...


Best regards,
Best Regards,
A.H.Arshian
fmk
Site Admin
Posts: 5884
Joined: Fri Jun 11, 2004 2:33 pm
Location: UC Berkeley
Contact:

Re: OpenSeesSP + MATLAB

Post by fmk »

did you try
!mpiexec
AHARSHIAN
Posts: 87
Joined: Tue Apr 03, 2012 3:34 am
Location: Germany, Weimar
Contact:

Re: OpenSeesSP + MATLAB

Post by AHARSHIAN »

I tried the two following ways:

1) Calling the OpenSeesSP executable from MATLAB:

clear all
clc
fname = tempname;
while exist(fname, 'file')
fname = tempname;
end
fid = fopen(fname, 'wt');
fprintf(fid, 'mpiexec -np 4 OpenSeesSP Test.tcl');
system(['OpenSeesSP < ' fname]);

Then MATLAB responded:

invalid command name "mpiexec"
Master Process Running OpenSees Interpreter 0


OpenSees -- Open System For Earthquake Engineering Simulation
Pacific Earthquake Engineering Research Center -- 2.4.6 (rev 6062)

(c) Copyright 1999-2013 The Regents of the University of California
All Rights Reserved
(Copyright and Disclaimer @ http://www.berkeley.edu/OpenSees/copyright.html)


Process Terminating 0


2) Callin OpenSeesSP from the cmd:

clear all
clc
dos('mpiexec -np 4 OpenSeesSP Test.tcl')

Then MATLAB says:

Aborting: unable to connect to "my computer ID", smpd version mismatch

ans =

-1


So, in the first try, it doesn't recognize the mpiexec (!mpiexec also didn't work). In the second try, there is a mismatch between the smpd of OpenSeesSP and MATLAB.


I will appreciate your help in this issue!
Best Regards,
A.H.Arshian
Post Reply