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.

How to input the square of a differential?

Please login with a confirmed email address before reporting spam

comsol version 4.0 or higher
How to express (?u)^2, ? represents differential here, u is a dependent variable, u(x, y)
Is this right: (ux+uy)^2 ?

3 Replies Last Post Jan 19, 2011, 1:48 a.m. EST
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 Jan 18, 2011, 2:40 p.m. EST
Hi

I do not believe so, if your vector field "_u_(x,y,z)" (_in bold_) is in fact the vector field of scalar values (u,v,w) for 3D then what do you really mean by du ?

In COMSOL notation

(ux+uy)^2 = (du/dx+dudy)^2

I agree I find too that using "u" for the general vector field and for the 1st part of the vector is confusing, normally they were using bold case for the full vector field and normal case for u,v,w. tehn if you look up the doc, you will see that ux=du/dx, uy=du/dy vx=dv/dx and wt=dw/dt, just as uxx=d^2u/dx^2 vxy=d^2u/dx/dy
This means als that one need to take some precautions when inventing variable names with COMSOL and not to redefine internal ones, the results might be strange ;)

--
Good luck
Ivar
Hi I do not believe so, if your vector field "_u_(x,y,z)" (_in bold_) is in fact the vector field of scalar values (u,v,w) for 3D then what do you really mean by du ? In COMSOL notation (ux+uy)^2 = (du/dx+dudy)^2 I agree I find too that using "u" for the general vector field and for the 1st part of the vector is confusing, normally they were using bold case for the full vector field and normal case for u,v,w. tehn if you look up the doc, you will see that ux=du/dx, uy=du/dy vx=dv/dx and wt=dw/dt, just as uxx=d^2u/dx^2 vxy=d^2u/dx/dy This means als that one need to take some precautions when inventing variable names with COMSOL and not to redefine internal ones, the results might be strange ;) -- Good luck Ivar

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago Jan 18, 2011, 9:50 p.m. EST

Hi

I do not believe so, if your vector field "_u_(x,y,z)" (_in bold_) is in fact the vector field of scalar values (u,v,w) for 3D then what do you really mean by du ?

In COMSOL notation

(ux+uy)^2 = (du/dx+dudy)^2

I agree I find too that using "u" for the general vector field and for the 1st part of the vector is confusing, normally they were using bold case for the full vector field and normal case for u,v,w. tehn if you look up the doc, you will see that ux=du/dx, uy=du/dy vx=dv/dx and wt=dw/dt, just as uxx=d^2u/dx^2 vxy=d^2u/dx/dy
This means als that one need to take some precautions when inventing variable names with COMSOL and not to redefine internal ones, the results might be strange ;)

--
Good luck
Ivar


Sorry, maybe I didn't say what I want to say clearly.
the "?" refer to the vector differential operator (gradient), ?u=(ux, uy) or ?u=(du/dx, du/dy)
and I want to know how to express (?u)^2 in comsol.
(?u)^2=(ux)^2+(uy)^2, or (?u)^2=(ux+uy)^2, which is right in comsol?
[QUOTE] Hi I do not believe so, if your vector field "_u_(x,y,z)" (_in bold_) is in fact the vector field of scalar values (u,v,w) for 3D then what do you really mean by du ? In COMSOL notation (ux+uy)^2 = (du/dx+dudy)^2 I agree I find too that using "u" for the general vector field and for the 1st part of the vector is confusing, normally they were using bold case for the full vector field and normal case for u,v,w. tehn if you look up the doc, you will see that ux=du/dx, uy=du/dy vx=dv/dx and wt=dw/dt, just as uxx=d^2u/dx^2 vxy=d^2u/dx/dy This means als that one need to take some precautions when inventing variable names with COMSOL and not to redefine internal ones, the results might be strange ;) -- Good luck Ivar [/QUOTE] Sorry, maybe I didn't say what I want to say clearly. the "?" refer to the vector differential operator (gradient), ?u=(ux, uy) or ?u=(du/dx, du/dy) and I want to know how to express (?u)^2 in comsol. (?u)^2=(ux)^2+(uy)^2, or (?u)^2=(ux+uy)^2, which is right in comsol?

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 Jan 19, 2011, 1:48 a.m. EST
Hi

for me that is pure maths, no ?

the norm of a gradient is the sum of squares of the components (and not the square of a sum)

or have I missed something ?

--
Good luck
Ivar
Hi for me that is pure maths, no ? the norm of a gradient is the sum of squares of the components (and not the square of a sum) or have I missed something ? -- Good luck 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.