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.

COMSOL-Simulink for control design

Please login with a confirmed email address before reporting spam

Hello,

I'm interested in control design based on COMSOL models.

As far as I know, in the old COMSOL (FEMLAB) version, probably V3.5, there is a link that in Matlab simulink, the FEA model can be used directly as a simulink block. This FEA model could serve as a plant model and advanced controller such as model predictive control can be implemented easily in Matlab.

Here is a very nice work using the same idea:

www.comsol.com/paper/model-predictive-control-of-a-complex-rheological-forming-process-based-on-a-fin-1154
www.comsol.com/paper/download/9316/Bernard_pres.pdf


I'm wondering why the new version of COMSOL no longer provides such useful link to matlab simulink.

I got reply from COMSOL support team that says we can either use matlab function in COMSOL or access the COMSOL model via Matlab liveink, but these two alternative methods are not straightforward compared with the simulink block option.

Is anyone here facing the same problem?

Any suggestion about how to implement this is highly appreciated!

X. Cao



4 Replies Last Post 24 lug 2014, 22:20 GMT-4
Ivar KJELBERG COMSOL Multiphysics(r) fan, retired, former "Senior Expert" at CSEM SA (CH)

Please login with a confirmed email address before reporting spam

Posted: 10 years ago 24 lug 2014, 11:20 GMT-4
Hi

the best for control of mechanical systems is to do your analysis of the "Solid" physics, get a modal representation, and then REDUCE the K,D,M matrices (based on mass and inertia participation factors) and export these.
All this is possible within COMSOL, but they have not (so far, I hope it will soon come) automated this.
You need to tweak COMSOL manually via Matlab and do your processing. This is OK for simple models, but hopeless for a true Engineering models of a few Mdofs, where I cannot even catch the system matrices in Matlab, and then its tough to be sure you have reduced them well.

This should be ideally possible when using multiple physics, such as different Solid physics, rigid bodies, multi-body ... thermal expansion ... physics together

--
Good luck
Ivar
Hi the best for control of mechanical systems is to do your analysis of the "Solid" physics, get a modal representation, and then REDUCE the K,D,M matrices (based on mass and inertia participation factors) and export these. All this is possible within COMSOL, but they have not (so far, I hope it will soon come) automated this. You need to tweak COMSOL manually via Matlab and do your processing. This is OK for simple models, but hopeless for a true Engineering models of a few Mdofs, where I cannot even catch the system matrices in Matlab, and then its tough to be sure you have reduced them well. This should be ideally possible when using multiple physics, such as different Solid physics, rigid bodies, multi-body ... thermal expansion ... physics together -- Good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 10 years ago 24 lug 2014, 13:19 GMT-4
Hello, Ivar,

Thanks for your reply.

If I understand you correctly, you are suggesting to use the state space option from COMSOL. This seems to be an option.

Currently, I'm think to use input-output data from the complete model in COMSOL to calibrate a simplified model (lumped model from simplified physics). Basically the first step is parameter identification, identifying some parameters in the lumped model. Then, the next step is to use the identified model for control design.
My concerns is how to implement the control online with COMSOL model. Because I have to access COMSOL variables at each sampling time and feedback input into COMSOL as well. I'm not sure which method is handy to use, whether calling matlab function in COMSOL or controlling COMSOL by Matlab script.

Do you have any experience with such kind of control issues with COMSOL?

Or if anyone is interested in this kind of control applications with COMSOL, I'd be very glad to discuss with.

Thanks again.

X.Cao





Hello, Ivar, Thanks for your reply. If I understand you correctly, you are suggesting to use the state space option from COMSOL. This seems to be an option. Currently, I'm think to use input-output data from the complete model in COMSOL to calibrate a simplified model (lumped model from simplified physics). Basically the first step is parameter identification, identifying some parameters in the lumped model. Then, the next step is to use the identified model for control design. My concerns is how to implement the control online with COMSOL model. Because I have to access COMSOL variables at each sampling time and feedback input into COMSOL as well. I'm not sure which method is handy to use, whether calling matlab function in COMSOL or controlling COMSOL by Matlab script. Do you have any experience with such kind of control issues with COMSOL? Or if anyone is interested in this kind of control applications with COMSOL, I'd be very glad to discuss with. Thanks again. X.Cao

Ivar KJELBERG COMSOL Multiphysics(r) fan, retired, former "Senior Expert" at CSEM SA (CH)

Please login with a confirmed email address before reporting spam

Posted: 10 years ago 24 lug 2014, 22:19 GMT-4
Hi

not yet I need a "Big Fat project" to pay me the effort to validate correctly that approach, haven't got that yet ;)

One way to understand the modal selection is to use the modal time solver, select the modes you mean are interesting and see how the system responds, and compare it to a full time stepping solver solution

Once you know your controller, you might make a SPICE model of your control electronics and run that, at least if you can assume your actuator is a true current to Force device (i.e. Voice coil actuator)
--
Good luck
Ivar
Hi not yet I need a "Big Fat project" to pay me the effort to validate correctly that approach, haven't got that yet ;) One way to understand the modal selection is to use the modal time solver, select the modes you mean are interesting and see how the system responds, and compare it to a full time stepping solver solution Once you know your controller, you might make a SPICE model of your control electronics and run that, at least if you can assume your actuator is a true current to Force device (i.e. Voice coil actuator) -- Good luck Ivar

Ivar KJELBERG COMSOL Multiphysics(r) fan, retired, former "Senior Expert" at CSEM SA (CH)

Please login with a confirmed email address before reporting spam

Posted: 10 years ago 24 lug 2014, 22:20 GMT-4
doubled up ;)
doubled up ;)

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.