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.
average of parametric sweep solutions.
Posted Jun 17, 2019, 8:58 a.m. EDT Electromagnetic Heating, Low-Frequency Electromagnetics, RF & Microwave Engineering Version 5.3a 2 Replies
Please login with a confirmed email address before reporting spam
Hi all,
I'm simulating the effect on heating uniformity of a sample by moving a stirrer within a microwave reactor.
The stirrer position is given by a parameter related to its rotation angle, and I want to average the power loss density (emw.Qe) of all stirrer positions to then evaluate the power loss uniformity over a full stirrer rotation.
I tried to do an operation based in "with" and "sum" operators of the form:
(sum(with(i,emw.Qe,i,1,37))/36
However, I can't use the "with" operator as it gives an error of the solution specification being nonscalar or out of range. I think this is because is not meant for parametric sweep, but for a parametric solver; however, giving that I'm changing the geometry of the problem, a parametric sweep should be the way to go.
I could use "withsol" operator to call all the specific solutions, but as this requieres to input a string tag of the form 'solN', something like
(withsol('sol3',emw.Qe)+withsol('sol4',emw.Qe)+...+withsol('solN',emw.Qe))/(N-2)
However, as I'm dealing a large number of solutions, this requieres a really long line of code for averaging them all, and COMSOL seems to limit the maximum extension on the expr boxes. I'm not sure if "sum" could be used to pass the tags to "withsol" to reduce the length of the expression).
Thanks