Note: This discussion is about an older version of the COMSOL Multiphysics® software. The information provided may be out of date.
Discussion Closed This discussion was created more than 6 months ago and has been closed. To start a new discussion with a link back to this one, click here.
Matlab - COMSOL show progress window fails to load
Posted 20 lug 2011, 12:39 GMT-4 Interfacing Version 4.2a, Version 4.3 15 Replies
Please login with a confirmed email address before reporting spam
Anyone else using matlabs live link with comsol and finding it slightly less robust then they would hope :).
For some reason calling ModelUtil.showProgress(true); will 40% of the time actually work and cause it to come up while the rest it fails to do anything.
Anyone know of any other commands that might be useful in bringing up the main Comsol window?
I need it up sadly because the solver can hang, generally at meshing, and therefore i need to cancel it.
Is this not a really silly way to go about it, I would have thought there might have been some way to cause it to time out and return null or something, kind of makes automated linking redundent.
Regards MF
Please login with a confirmed email address before reporting spam
I have the same issue. Could you find a solution? I already contacted Comsol support, but I am not able to create a reproducable example. If you have an example file where the progress window always does not show up, this could help to solve the issue. I use Comsol 4.2.0.187 together with Matlab R2010a on a WinXP platform.
Sunny regards,
Stefan
Please login with a confirmed email address before reporting spam
Yes, I do have the same problem. I am using exacty the same matlab and comsol version as you Stefan. I would also be interseted if you can find a solution
Best Regards
Vincent
Please login with a confirmed email address before reporting spam
I might have find a way to make the progress bar appear more often. Even if Matlab was started using the 'COMSOL with Matlab' application, I start with the comand line mphstart before creating my model with 'model = ModelUtil.create('Model');' It should not be required since a server connection already exist but in my case the progress bar appeared all the time so far. But I haven't tested it for a long time so I cannot tell if it totally solve the problem. Let me know if it has helped you, so I will know if I only had chance or if I have to keep looking for a solution.
Best regards
Vincent
Please login with a confirmed email address before reporting spam
has anyone in the meantime solved the issue or able to report it to Comsol? I probably got a reproducible case, so before contacting Comsol I'd like to know how's going with you.
BTW: I tried Vincent workaround but, at least in my case, does not work.
Best,
J
Please login with a confirmed email address before reporting spam
I can now confirm that my workaround does not work all the time. In my case it actually works better but nevertheless the progress bar does not appear in every situation. However I was not able to find out when it works and when not.
Let me know if the comsol support can help you on that one.
Regards
Vincent
Please login with a confirmed email address before reporting spam
I'll keep you updated...
J
Please login with a confirmed email address before reporting spam
I'll keep you updated...
J
Please login with a confirmed email address before reporting spam
Dear Stefan,
Thank you for your detailed answer. I have used your M-file in order to reproduce this behavior. But I can see the progress bar each time I solve a problem, even if I do certain changes and/or restart MATLAB. I use MATLAB 2011a and Windows Vista.
Note that this kind of unexpected behavior can in several cases depend on the version you are using. In order to fully support this case, we ask you to upgrade your MATLAB version to one of the supported ones. Version 2010a is not officially supported by COMSOL 4.2. I would recommend you to try version 2011a instead (or 2010b).
Check with your colleague the MATLAB version he is using. If this problem appears in the supported versions of MATLAB, please let us know.
Best regards,
Pablo Vallejos
COMSOL AB, Sweden
----- Original Message -----
> Hi Pablo,
>
> thank you for your answer. I already attached an example file to my
> last eMail. Today I tried this file again and the progress window has
> been shown correctly. Later I used the same file and the window was
> missing again.
>
> I thought the issue might have to do something with the way I start
Matlab
> or with the java classes I use for GUI programming, but this does not
> seem to be the origin of the issue.
>
> I tried to build a reproducible example, but I could not.
> Sometimes the progress window is shown and sometimes not.
> I attach the example file of my last email again.
>
> I fully understand that it is hard to correct an error that is not
> reproducible...
>
> I use Comsol 4.2.0.187 together with Matlab R2010a on a WinXP platform.
>
> - Do you have any other issues with the LiveLink for MATLAB?
> No.
>
> Please run the attached file in Matlab several times and see If the
> progress windows always pops up. If it works well, please start Matlab
> again and try it again a few times.
> I guess this is all you can do for me to understand the issue.
>
> If I can find out more about it, I will give you an update.
>
> At least I am not the only person having this issue, because there is
> already a forum entry:
> www.comsol.com/community/forums/general/thread/20922/
>
> I am going to answer it and ask him for more details, too.
>
> Sunny regards,
>
> Stefan
Please login with a confirmed email address before reporting spam
J
Please login with a confirmed email address before reporting spam
However, even when minimizing all other windows I can not always see a progress bar with R2010a.
Please login with a confirmed email address before reporting spam
Sadly I have had no luck in solving this issue.
I can somewhat get arround it by having task manager up, this allows me in some way to tell whether the server has stalled, in which case I can close it and my program automatically restarts the process. At that point I cross my fingers and hope I get the progress bar :).
There almost needs to be a Bool on whether the progress bar is visibile, that way checking it and the ability to call it up seperately would be nice.
Regards Mike F
Please login with a confirmed email address before reporting spam
Since I have the same problem I would be interested if there has been a solution to this problem.
Thanks,
Robert
Please login with a confirmed email address before reporting spam
in my case (running on Windows 7 and Mac) the task bar appears almost any time I call it. The only issue is that is covered by all the other windows; is there, but is hidden. Try to, if not already done, to have just the m-file window on the desktop and also have it really small, run the code and probably you would be able to see the task bar. Perhaps you have already tried so this post will not be of much help.
There is the new version now, v4.2a, perhaps in this version the task bar works smoothly.
J
Please login with a confirmed email address before reporting spam
I am having the same issue of the progress window not showing up most of the time.
In my case I am using comsol 4.2a with matlab 2011a on a 64 bit Linux machine.
Even when I set
ModelUtil.showProgress(true);
The progress bar does not show up most of the time.
It looks from the previous posts that there is no solution to this problem yet.
Please login with a confirmed email address before reporting spam
In the bowels of the .comsol directory, in a file called '.log', the following error is being thrown by COMSOL:
org.eclipse.swt.SWTException: Invalid thread access
at org.eclipse.swt.SWT.error(SWT.java:4282)
at org.eclipse.swt.SWT.error(SWT.java:4197)
at org.eclipse.swt.SWT.error(SWT.java:4168)
at org.eclipse.swt.widgets.Display.error(Display.java:1258)
at org.eclipse.swt.widgets.Display.checkDevice(Display.java:764)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3743)
at com.comsol.guimph.progress.ServerProgressHandler$a.run(Unknown Source)
It looks like COMSOL is having a threadng issue with the progress window accessing the screen.
Note that while COMSOL employees may participate in the discussion forum, COMSOL® software users who are on-subscription should submit their questions via the Support Center for a more comprehensive response from the Technical Support team.
Suggested Content
- FORUM Comsol with matlab progress window
- KNOWLEDGE BASE COMSOL Does Not Start with the Latest MATLAB Version
- KNOWLEDGE BASE Error: Failure Loading MATLAB Libraries. This model requires that MATLAB is available.
- KNOWLEDGE BASE Update for LiveLink™ for MATLAB® on macOS with Apple Silicon Processors Applicable to COMSOL Multiphysics® Version 6.2
- BLOG Best Practice for Working with Model M-Files