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.

Maximum Operator of Domain in an Assembly

Please login with a confirmed email address before reporting spam

Hello Everyone,

I am not sure how to put this problem, so I will try with bullet points:

- I have an assembly consisting of an array of circles in a rectangular matrix (please see picture).
- I have a Heat Transfer Physics and I need to define a global ODE. The ODE should read the maximum temperature of a single domain (whether circles or rectangle)
- I would like to set a maximum operator for the entire assembly (including the circles and the rectangle domains)
- In the ODE, I would like to read the maximum temperature of a single domain, but using the maximum operator for the entire assembly.
- It is possible to "split" the maximum operator in different domains? Something like maxop(circle1.T), maxop(circle2.T), maxop(rectangle,T) etc., maxop being the overall operator.

That is, I would like to have the option to read the maximum temperature on each domain, without the need of creating multiple operators?

Paul


10 Replies Last Post Nov 10, 2015, 2:23 p.m. EST

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 12:06 p.m. EST
I have added another picture to describe my question. I hope this helps!
I have added another picture to describe my question. I hope this helps!


Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 1:31 p.m. EST
Hello Paul,
You could use a boolean expression in your integrand, something like
maxop(u*(dom==1))
to compute the max on domain 1, etc.
Best,
Jeff
Hello Paul, You could use a boolean expression in your integrand, something like maxop(u*(dom==1)) to compute the max on domain 1, etc. Best, Jeff

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 1:47 p.m. EST
Hey Jeff,

Thank you very much for the answer. I have tried this command with the temperature:

maxop1(T*(dom==1))

but I get 0 [K]. I have also tried to input dom==6 (I only have 5 domains) and it gives the same results. Any idea what am I doing wrong?

Paul
Hey Jeff, Thank you very much for the answer. I have tried this command with the temperature: maxop1(T*(dom==1)) but I get 0 [K]. I have also tried to input dom==6 (I only have 5 domains) and it gives the same results. Any idea what am I doing wrong? Paul

Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 2:00 p.m. EST
Hard to say without seeing your file. Please post it if possible.
Jeff
PS: That it returns 0 with dom==6 makes sense since the boolean expression is false and therefore evaluates to zero.
Hard to say without seeing your file. Please post it if possible. Jeff PS: That it returns 0 with dom==6 makes sense since the boolean expression is false and therefore evaluates to zero.

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 2:08 p.m. EST
Oh, I have just realized that because of the way the geometry is built, the assembly is split in even more domains. But still, if I plot dom==1, I have 0 [K], which is weird.
Oh, I have just realized that because of the way the geometry is built, the assembly is split in even more domains. But still, if I plot dom==1, I have 0 [K], which is weird.


Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 2:08 p.m. EST
Oh, I have just realized that because of the way the geometry is built, the assembly is split in even more domains. But still, if I plot dom==1, I have 0 [K], which is weird.
Oh, I have just realized that because of the way the geometry is built, the assembly is split in even more domains. But still, if I plot dom==1, I have 0 [K], which is weird.

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 2:12 p.m. EST

Hard to say without seeing your file. Please post it if possible.
Jeff
PS: That it returns 0 with dom==6 makes sense since the boolean expression is false and therefore evaluates to zero.


Oh, I had the selection of the maximum operator only on the circles. Now it works! Thank you very much, Jeff! You have saved me hours of time spent for setting different formulae and operators.
[QUOTE] Hard to say without seeing your file. Please post it if possible. Jeff PS: That it returns 0 with dom==6 makes sense since the boolean expression is false and therefore evaluates to zero. [/QUOTE] Oh, I had the selection of the maximum operator only on the circles. Now it works! Thank you very much, Jeff! You have saved me hours of time spent for setting different formulae and operators.

Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 9, 2015, 2:14 p.m. EST
No problem!
No problem!

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 10, 2015, 9:20 a.m. EST
Hey Jeff,

In the same topic, do you know if it is possible to implement a similar artifice for a domain ODE? Something like maxop(T*dom), where the domain is chosen automatically?

Paul
Hey Jeff, In the same topic, do you know if it is possible to implement a similar artifice for a domain ODE? Something like maxop(T*dom), where the domain is chosen automatically? Paul

Jeff Hiller COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 8 years ago Nov 10, 2015, 2:23 p.m. EST
Sure, you can use the same idea in any of the interfaces, including Domain ODEs. It's easy for you to check for yourself by building a toy model for which you know the solution, like the one attached, which correctly returns that the time integral from t=0 to t=1 of the max of x*y over[0;1]x[0;1] is 2.
Jeff
Sure, you can use the same idea in any of the interfaces, including Domain ODEs. It's easy for you to check for yourself by building a toy model for which you know the solution, like the one attached, which correctly returns that the time integral from t=0 to t=1 of the max of x*y over[0;1]x[0;1] is 2. Jeff

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.