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.

Integrate through arbitrary slice

Maxim Electromobility

Please login with a confirmed email address before reporting spam

Hi!

Does anyone know how to integrate en expretion through arbitrary slice of 3d model?

For example in 3D model I have cylindrical domain, and I want to integrate Power Flow (normPoav_rfw) through slice at z=0. I have tried to use "Subdomain Integration" dialog box and put expression normPoav_rfw*(z=0), but I get an error:

Error: 9171
Syntax error in expression
- Expression: normPoav_rfw*(z=0)
- Subexpression: =0)
- Column: 16

Is there other way to try?

Thank you!

3 Replies Last Post 2010/04/29 7:06 GMT-4

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago 2010/04/28 13:14 GMT-4
I hope with future improvements they will implement an easy and robust way of integrating along arbitrary surfaces or curves, but here is an approach I have used occasionally: If you know the position of your slice a priori, re-build your geometry to include an internal boundary at that slice (i.e. split your domain into subdomains along the internal surface you want to integrate on). Then you should be able to calculate the integral on the resultant internal boundary.
Good luck
Ozgur



Hi!

Does anyone know how to integrate en expretion through arbitrary slice of 3d model?

For example in 3D model I have cylindrical domain, and I want to integrate Power Flow (normPoav_rfw) through slice at z=0. I have tried to use "Subdomain Integration" dialog box and put expression normPoav_rfw*(z=0), but I get an error:

Error: 9171
Syntax error in expression
- Expression: normPoav_rfw*(z=0)
- Subexpression: =0)
- Column: 16

Is there other way to try?

Thank you!


I hope with future improvements they will implement an easy and robust way of integrating along arbitrary surfaces or curves, but here is an approach I have used occasionally: If you know the position of your slice a priori, re-build your geometry to include an internal boundary at that slice (i.e. split your domain into subdomains along the internal surface you want to integrate on). Then you should be able to calculate the integral on the resultant internal boundary. Good luck Ozgur [QUOTE] Hi! Does anyone know how to integrate en expretion through arbitrary slice of 3d model? For example in 3D model I have cylindrical domain, and I want to integrate Power Flow (normPoav_rfw) through slice at z=0. I have tried to use "Subdomain Integration" dialog box and put expression normPoav_rfw*(z=0), but I get an error: Error: 9171 Syntax error in expression - Expression: normPoav_rfw*(z=0) - Subexpression: =0) - Column: 16 Is there other way to try? Thank you! [/QUOTE]

Maxim Electromobility

Please login with a confirmed email address before reporting spam

Posted: 1 decade ago 2010/04/29 6:51 GMT-4
Thak you for your response Ozgur! But unfortunately, this is not an option for several reasons. I do not know the position of the slice a priori; the geometry is rather complicated it is not easy to generate mesh with additional slice; and I do not want to recalculate everything each time I need to integrate.

I know, that it is possible to use postcrossplot and meshintegrate functions to integrate through arbitrary slice. But I find it rather complicated, and, in addition, this way requires MATLAB license to run scripts.

Is there another option for doing such integration?

Thanks!


I hope with future improvements they will implement an easy and robust way of integrating along arbitrary surfaces or curves, but here is an approach I have used occasionally: If you know the position of your slice a priori, re-build your geometry to include an internal boundary at that slice (i.e. split your domain into subdomains along the internal surface you want to integrate on). Then you should be able to calculate the integral on the resultant internal boundary.
Good luck
Ozgur


Thak you for your response Ozgur! But unfortunately, this is not an option for several reasons. I do not know the position of the slice a priori; the geometry is rather complicated it is not easy to generate mesh with additional slice; and I do not want to recalculate everything each time I need to integrate. I know, that it is possible to use [i]postcrossplot[/i] and [i]meshintegrate[/i] functions to integrate through arbitrary slice. But I find it rather complicated, and, in addition, this way requires MATLAB license to run scripts. Is there another option for doing such integration? Thanks! [QUOTE] I hope with future improvements they will implement an easy and robust way of integrating along arbitrary surfaces or curves, but here is an approach I have used occasionally: If you know the position of your slice a priori, re-build your geometry to include an internal boundary at that slice (i.e. split your domain into subdomains along the internal surface you want to integrate on). Then you should be able to calculate the integral on the resultant internal boundary. Good luck Ozgur [/QUOTE]

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 2010/04/29 7:06 GMT-4
Hi
There is the "Draw plane for Cross section slice plot" (icon to the left of the graphics Postprocessing view) it is linked to the "Postprocessing - Cross Section Plot Parameters", where you can defien the coordinates of your plane, butthis ill only show you a variable, not integrate anything (its probably there in V4 though with the operator features still waiting impatiantly)

and in V3.5a integration coupling variales can only be done on existing boundaries, inside the GUI, else matlab

Hope this helps on the way

Ivar
Hi There is the "Draw plane for Cross section slice plot" (icon to the left of the graphics Postprocessing view) it is linked to the "Postprocessing - Cross Section Plot Parameters", where you can defien the coordinates of your plane, butthis ill only show you a variable, not integrate anything (its probably there in V4 though with the operator features still waiting impatiantly) and in V3.5a integration coupling variales can only be done on existing boundaries, inside the GUI, else matlab Hope this helps on the way 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.