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.

Trouble exporting variables during parameter sweep

Please login with a confirmed email address before reporting spam

Hello,
I'm working with v3.5a on a very simple geometry (a cylinder in a 2-D axial-symmetric model). I make the top side move to make the geometry change (due to compression/strain). I want to run a parameter sweep, and see how the changes in my variables affect the radius of the cylinder vs time. Thing is I have no control over the point where the output variables are calculated. Do you have any clue on that matter ?
Thanks.
Y.

4 Replies Last Post Jul 1, 2010, 6:18 a.m. EDT
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: 1 decade ago Jun 30, 2010, 1:35 a.m. EDT
Hi

If you are talking abouit the position of a "max" or "min" value, I believe in 3.5a we do not get any other feedback than the "point" shown on the graph. You must use matlab, I beleive, to extract it's location.

In V4 you have operators, but I do not believe they give you the poition.

but on the other hand, COMSOL is a math tool, you can define the average radius as a variable, then have COMSOL to derive it and find the zero that should give you the location, no ?

Good luck
Ivar
Hi If you are talking abouit the position of a "max" or "min" value, I believe in 3.5a we do not get any other feedback than the "point" shown on the graph. You must use matlab, I beleive, to extract it's location. In V4 you have operators, but I do not believe they give you the poition. but on the other hand, COMSOL is a math tool, you can define the average radius as a variable, then have COMSOL to derive it and find the zero that should give you the location, no ? Good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Jun 30, 2010, 3:25 a.m. EDT
Hello,
Actually my problem is a bit simpler : I don't want to find a max or min position, I'm interested in exporting the radius in a specific spot, but I don't know how to tell Comsol to do that.
Thanks for the reply anyway
Hello, Actually my problem is a bit simpler : I don't want to find a max or min position, I'm interested in exporting the radius in a specific spot, but I don't know how to tell Comsol to do that. Thanks for the reply anyway

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: 1 decade ago Jun 30, 2010, 3:41 p.m. EDT
Hi

Well the radius is linked to the second derivative (locally) or you can, for a cylinder calculate the average radius by integrating over a loop.
Something like, if the cylinder axis is along Z, you define the variable

Rxy=sqrt(x^2+y^2)
and
Rxuyv=sqrt((x+u)^2+(y+v)^2)

and integrate these for different heights Z.
To define the loop Z height, either you split up your volume/domain to have edges to integrate along, or I believe (would have to try/check) that in V4 you can define split surfaces and integrate along these border.

test it carefully first, these are ideas I come to, as first thoughts, to be verified.

good luck
Ivar
Hi Well the radius is linked to the second derivative (locally) or you can, for a cylinder calculate the average radius by integrating over a loop. Something like, if the cylinder axis is along Z, you define the variable Rxy=sqrt(x^2+y^2) and Rxuyv=sqrt((x+u)^2+(y+v)^2) and integrate these for different heights Z. To define the loop Z height, either you split up your volume/domain to have edges to integrate along, or I believe (would have to try/check) that in V4 you can define split surfaces and integrate along these border. test it carefully first, these are ideas I come to, as first thoughts, to be verified. good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Jul 1, 2010, 6:18 a.m. EDT
Hello,
Thanks for the answer.
I've managed to get what I wanted, here is how I did it :

Using the *Integration Coupling Variables > Boundary Variables* under the *Options* menu, I got back the radius change, integrating the following expression over the top side of the cylinder :

dR = -d(uaxi_smaxi,r)

Thus I have the radius over time by subtracting dR to my initial radius.

I've set up a Point variable integration too, in order to have the variation of height over time, by defining :

dH = -w

on one of the top corners of my cylinder (which is a square, given the model is in a 2-D, axial-symmetric mode).
And thus I can have the height over time by subtracting dH to the initial height.

I've a couple more variables defined, for various needs, and it seems to work pretty well.

Thanks for your interest in this matter Ivar, it was much appreciated.

Y.
Hello, Thanks for the answer. I've managed to get what I wanted, here is how I did it : Using the *Integration Coupling Variables > Boundary Variables* under the *Options* menu, I got back the radius change, integrating the following expression over the top side of the cylinder : dR = -d(uaxi_smaxi,r) Thus I have the radius over time by subtracting dR to my initial radius. I've set up a Point variable integration too, in order to have the variation of height over time, by defining : dH = -w on one of the top corners of my cylinder (which is a square, given the model is in a 2-D, axial-symmetric mode). And thus I can have the height over time by subtracting dH to the initial height. I've a couple more variables defined, for various needs, and it seems to work pretty well. Thanks for your interest in this matter Ivar, it was much appreciated. Y.

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.