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.

Comparing analytic and numerical solutions

Please login with a confirmed email address before reporting spam

I want to check a numerical solution of a PDE (2-D) against an analytic function by plotting both, and taking the difference. I can plot each separately, but I cannot reference (join etc) both a Solution and an Analytic function to perform an operation. Is there a way to map the analytic function onto a mesh, for example, so I can difference them? The analytic equation is radially symmetric:
arg(besselk(0,sqrt(x^2+y^2)*sqrt(i*om/D)))

1 Reply Last Post 20.02.2015, 09:29 GMT-5
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 9 years ago 20.02.2015, 09:29 GMT-5
Hi,

A way to compare them would be to use an expression that is the difference between the analytic and numerical solutions by plotting an expression such as

an1(x,y)-u

where an1 is the name of the analytic function, and u is the dependent variable for the numerical solution. You may have to run Update Solution from the Study node (or press F5) if you added or updated the analytic function after computing the numerical solution.

Best regards,
Magnus Ringh, COMSOL
Hi, A way to compare them would be to use an expression that is the difference between the analytic and numerical solutions by plotting an expression such as an1(x,y)-u where an1 is the name of the analytic function, and u is the dependent variable for the numerical solution. You may have to run Update Solution from the Study node (or press F5) if you added or updated the analytic function after computing the numerical solution. Best regards, Magnus Ringh, COMSOL

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.