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
14.06.2012, 02:00 GMT-4
Hi
To understand your question and to get the "right" response, I believe I should ask you first:
Have you really understood the differences about:
- "Global Parameters & Variables",
- Local (model) Variables and Operators,
and why some are dependent on the "Entities" (Domains, Boundaries, possibly Edges, and Points), but other not ! and what this really means (in terms of full or correct mathematical notation) ?
Check that carefully, I agree this is not pointed out very specifically, in the doc, and there are many things implicit and that I find far from trivial in the COMSOL notation (at least it took me too long to understand).
Then identify which of these variables, operators etc are dependent and which are independet on the space coordinates (x,y,z,r and time t) and what does the operators (such as intop1(), aveop1()) do w.r.t. these (hiden and implicit) spatial dependences ?
So should I understand your equation for spatial variables x,y,z, and time t
then is it:
a(x,y,z,t,T(x.y.z.t))*x^3 + b(x,y,z,t,T(x,y,z,t),c_ij(,,,)*x^2+d(,,)*x = 0
because if you define a Variable on an Entity you are in fact stating it is depending (implicitely) on the spatial variables of the dimension of the Entity (+ time if applicable)
Once you really master these points, you will find COMSOL easy and you will become as most COMSOL experts, they even forget it and forget to tell the newcomers how it really is ("it's so trivial", indded once you know and understand ;)
--
Good luck
Ivar
Hi
To understand your question and to get the "right" response, I believe I should ask you first:
Have you really understood the differences about:
- "Global Parameters & Variables",
- Local (model) Variables and Operators,
and why some are dependent on the "Entities" (Domains, Boundaries, possibly Edges, and Points), but other not ! and what this really means (in terms of full or correct mathematical notation) ?
Check that carefully, I agree this is not pointed out very specifically, in the doc, and there are many things implicit and that I find far from trivial in the COMSOL notation (at least it took me too long to understand).
Then identify which of these variables, operators etc are dependent and which are independet on the space coordinates (x,y,z,r and time t) and what does the operators (such as intop1(), aveop1()) do w.r.t. these (hiden and implicit) spatial dependences ?
So should I understand your equation for spatial variables x,y,z, and time t
then is it:
a(x,y,z,t,T(x.y.z.t))*x^3 + b(x,y,z,t,T(x,y,z,t),c_ij(,,,)*x^2+d(,,)*x = 0
because if you define a Variable on an Entity you are in fact stating it is depending (implicitely) on the spatial variables of the dimension of the Entity (+ time if applicable)
Once you really master these points, you will find COMSOL easy and you will become as most COMSOL experts, they even forget it and forget to tell the newcomers how it really is ("it's so trivial", indded once you know and understand ;)
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Posted:
1 decade ago
14.06.2012, 11:55 GMT-4
Hi Ivar,
Thank you so much for your kind reply.
Right now, I am running a model with mainly the structural mechanics module with time dependence model. To reduce the complexity, temperature has been calculated and assumed to be not changing with time. So, T -> T(x,y,z) is defined as a global variable.
The coefficients, a, b and d all depends on T and therefore have spatial dependences. Furthermore, a depends on the hydrostatic stress (hydro(x,y,z,t)), which is spatial and time dependent. d is also time dependent explicitly. Therefore, we have,
a(hydro(x,y,z,t),T(x,y,z))*x^3+b(T(x,y,z))*x^2+d(t,T(x,y,z))=0
x is then explicitly used in a creep model set up with the general form PDE. This algebraic equation has analytical solution. However, there is a ^(1/3) (cube root) term in the denominator which has been giving me a lot of problems as the initial value of this term is zero (even when I added an eps term, it didn't work. I am still trying to figure out why).
Also, I wonder if there is an easy way in COMSOL to handle cube root operation? Right now I have to take an absolute value and multiply by a sign function as it doesn't allow me to do (negative number)^(1/3).
Best regards,
Di
Hi Ivar,
Thank you so much for your kind reply.
Right now, I am running a model with mainly the structural mechanics module with time dependence model. To reduce the complexity, temperature has been calculated and assumed to be not changing with time. So, T -> T(x,y,z) is defined as a global variable.
The coefficients, a, b and d all depends on T and therefore have spatial dependences. Furthermore, a depends on the hydrostatic stress (hydro(x,y,z,t)), which is spatial and time dependent. d is also time dependent explicitly. Therefore, we have,
a(hydro(x,y,z,t),T(x,y,z))*x^3+b(T(x,y,z))*x^2+d(t,T(x,y,z))=0
x is then explicitly used in a creep model set up with the general form PDE. This algebraic equation has analytical solution. However, there is a ^(1/3) (cube root) term in the denominator which has been giving me a lot of problems as the initial value of this term is zero (even when I added an eps term, it didn't work. I am still trying to figure out why).
Also, I wonder if there is an easy way in COMSOL to handle cube root operation? Right now I have to take an absolute value and multiply by a sign function as it doesn't allow me to do (negative number)^(1/3).
Best regards,
Di
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
14.06.2012, 16:07 GMT-4
Hi
first of all if you say T is not a dependent variable, but has beeen calculated separately and is a field of the type T(x,y,z) then for me it is NOT a GLOBAL varaible, but its a model LOCAL variable (that is spatial coordinate depedent).
Then you need to define it either as a solution from a previous HT solver data set, or from an spatial interpoaltion function. The hydro model variable must also be defined as a model local variable from COMSOl solver data.
Finally you must enter the interpolation functions for a, b and d in your material data node, and link them to "hydro" and "T" variables
I believe hat is all.
Then for the ()^-1/3, it's tricky, but perhaps, as you treat it a s a separate PDE, you can multiply by ()^1/3, and then solve, and divide the results by ()^1/3 or some other clever variable remapping to avoid the singularity for the solver sequence. Now ()^-1/3 is giving correct sign if you enter a negative value, but clear it wil lgive a NaN if the argument = 0
That is how 2D-axi is created, by multiplying and dividing repsectively by "r" to remove the r=0 singularity, ut it implies quite some equation writing and validation
--
Good luck
Ivar
Hi
first of all if you say T is not a dependent variable, but has beeen calculated separately and is a field of the type T(x,y,z) then for me it is NOT a GLOBAL varaible, but its a model LOCAL variable (that is spatial coordinate depedent).
Then you need to define it either as a solution from a previous HT solver data set, or from an spatial interpoaltion function. The hydro model variable must also be defined as a model local variable from COMSOl solver data.
Finally you must enter the interpolation functions for a, b and d in your material data node, and link them to "hydro" and "T" variables
I believe hat is all.
Then for the ()^-1/3, it's tricky, but perhaps, as you treat it a s a separate PDE, you can multiply by ()^1/3, and then solve, and divide the results by ()^1/3 or some other clever variable remapping to avoid the singularity for the solver sequence. Now ()^-1/3 is giving correct sign if you enter a negative value, but clear it wil lgive a NaN if the argument = 0
That is how 2D-axi is created, by multiplying and dividing repsectively by "r" to remove the r=0 singularity, ut it implies quite some equation writing and validation
--
Good luck
Ivar