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.

2D radial distribution function

Please login with a confirmed email address before reporting spam


I am working with the PDE application mode, time dependant analysis.
I have a probability distribution in 2D on a circle. There is no symmetry. Nevertheless it would be important to create a radial distribution function of this problem. Is this possible with the help of projection coupling variables? I have not found a way yet.

Thanks a lot for any help.

3 Replies Last Post Jun 24, 2010, 10:06 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 24, 2010, 7:34 a.m. EDT
Hi

you can alsways define variables such as rxy = sqrt(x^2 +y^2) etc, or the full spherical definition and use thses for your functions, while leaving the model in cartesian corrdinates.

There are the full function set I believe on the knowledge base, search for "cylindical" or "spherical"

The basis for COMSOL (and it's strength) is that you can repleace each filed with a number by an equation, based on constants, or even other variables (up to the extent that you avoid loops, and make your system so non-linear that the solver does not manage to solve it anymore ;)

Have fun Comsoling
Ivar
Hi you can alsways define variables such as rxy = sqrt(x^2 +y^2) etc, or the full spherical definition and use thses for your functions, while leaving the model in cartesian corrdinates. There are the full function set I believe on the knowledge base, search for "cylindical" or "spherical" The basis for COMSOL (and it's strength) is that you can repleace each filed with a number by an equation, based on constants, or even other variables (up to the extent that you avoid loops, and make your system so non-linear that the solver does not manage to solve it anymore ;) Have fun Comsoling Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Jun 24, 2010, 9:53 a.m. EDT
Hi Ivar,

Thanks a lot, with the scalar expressions for r (sqrt(x^2+y^2)) and phi (atan2(y,x)) an projection coupling variable is possible.

Except the origin prepares some problems, because the divison by 2*r*pi in order to get the radial probability distribution diverges. But that is a smaller problem.

Thanks again,

Fabian
Hi Ivar, Thanks a lot, with the scalar expressions for r (sqrt(x^2+y^2)) and phi (atan2(y,x)) an projection coupling variable is possible. Except the origin prepares some problems, because the divison by 2*r*pi in order to get the radial probability distribution diverges. But that is a smaller problem. Thanks again, Fabian

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 24, 2010, 10:06 a.m. EDT
Hi

then try a if(r==0,0,your_fun(r)) or whatever it's called again in Comsol, check the doc, (I'm mixing to many software and get confused, but the idea works) you can use the bolean operators easily in postprocessing to get rid of singularities (its more tricky for dependent variables as this sometimes makes the solver having trouble)

have fun Comsoling
Ivar
Hi then try a if(r==0,0,your_fun(r)) or whatever it's called again in Comsol, check the doc, (I'm mixing to many software and get confused, but the idea works) you can use the bolean operators easily in postprocessing to get rid of singularities (its more tricky for dependent variables as this sometimes makes the solver having trouble) have fun Comsoling Ivar

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.