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 implement "nonzero" condition

Please login with a confirmed email address before reporting spam

Dear All,

I'm trying to solve boundary integral for Maxwell's equations following the thread (www.comsol.com/community/forums/general/thread/3389) where weak form boundary integral is presented as,

-1/(2*pi)*u*(nx*(x-dest(x))+ny*(y-dest(y))+nz*(z-dest(z)))/nonzero(((x-dest(x))^2+(y-dest(y))^2+(z-dest(z))^2)^(3/2))

Here a function nonzero() is used in the denominator to avoid the case "r=dest(r)", however this gives an error as,

Unknown function
- Function: nonzero
Failed to evaluate expression.
- Expression: diff(1/(2*pi)*u*(nx*(x-dest(x))+ny*(y-dest(y))+nz*(z-dest(z)))/nonzero(((x-dest(x))^2+(y-dest(y))^2+(z-dest(z))^2)^(3/2)),u)

Also I couldn't find a function called "nonzero" in comsol user guide. Thus I'm much thankful if anyone can suggest me an alternative method.

I've attached my model to your perusal.

Thanks in advance.

Best Regards,
Ind



0 Replies Last Post 1 giu 2014, 19:16 GMT-4
COMSOL Moderator

Hello Ind Atan

Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.

If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.

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.