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.
mesh data
Posted Jan 15, 2012, 11:25 p.m. EST Version 4.0 9 Replies
Please login with a confirmed email address before reporting spam
anyone can tell me how to get volume of each elements in comsol?, is it possible to get element numbers in comsol?, I hope 'dvol' give the element volume scale factor, from manual I understood its value of Jacobian not the volume of element.From previous forums I understood that we can export mesh data. since I am new to comsol not able to locate it in comsol GUI.
******improtant****
Can anyone give me the step by step procedure to get the volume of each elements in comsol?
Please login with a confirmed email address before reporting spam
You can get the volume, area, length number of items respectively of the geometrical ENTITIES by integrating with operand "1".
But from the GUI I do not know how to access each mesh elements. Probably via API or Matlab code, anyhow I'm interested in the physical results that can all be accessed via the GUI, and not the sampling of the mesh, outside "h" or dvol
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
thanks for your reply. Actually, I have to calculate mass over elements (=density*volume of element). Can I multiply density directly with dvol (i.e. = density*dvol) to get element mass. Is it correct approach?.
Please login with a confirmed email address before reporting spam
I do not think you have an direct access to the mesh "elements" from the GUI, its normally not needed.
The overall area or volume is obtained by integrating the operand 1, the mass by integrating rho and an integration is equivalent to a sum over the elements of the "operand * dx*dy*dz" and the "dx*dy*dz" is the element volume, but that is not directly the "dvol" (I suspect that the number of Dofs and hence shape function also interacts here).
Only "support" can give you the full image I believe
Anyhow, to resolve the physics I have never needed the mesh volume details, I can concentrate on the (my) essential, that obviously is not your essential today ;) Sorry I do not know more on that chapter I have given up exchanging COMSOL data with other FEM tools too, that annoys me more as I interact with other clients and subcontracts using other tools and here I loose time and $$. FEM is missing an accepted interface exchange format unfortunately
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
1.I modelled a cube of 12 m , and meshed it with 8 Hex elements. So, volume of each element is 12*12*12/8=216 which is equal to volume of the scale factor 'dvol'. Now you tell me in which way it differs from the actual volume of elements?. I totally confused with this.
2. Also, I don't know how to use the integration to evaluate volume. There are two integrations, one is in model definitions and another one is in derived variables.I think, by using the integration one can get the total volume of a domain not the element volume.
3. Some people did using Matlab. But I am not familiar with that.
4. Some people using Gauss evaluation of points while exporting the data. I don't know how to do it?
I think lot of questions. Please explain one by one.
Thank you for spending your valuable time.
regards
viswesh.......
Please login with a confirmed email address before reporting spam
sorry to confuse you, I'm confused myself I see ;)
one of the things is that dvol is dependent on meshtype, hence its value differs in edge, surface respectively volume plots, and if I use it in a global or local integration.
And I notice I got further "summation over nodes" and "summation over elements" mixed up (the latter is missing we have only "integration" that can be tweaked with different integration orders)
Also with a nice structural mesh its easier to see
And it looks directly mesh dependent and not linked to the shape function as I though earlier, which then is more compliant with the help info determinant of the Jacobian of the mapping
I see I need myself to dig into the theory again, to get some order on this ;) anyhow so far I have not used "dvol" as COMSOL treats it internally for me
Just to be curious, what do you want to use the element info for ?
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Actually, I want to know the mass distribution of a liquid over a domain.The content of liquid is not same over the domain.i.e. some regions have more liquid and some regions have less liquid with in a domain. So, I thought it is easy to calculate using the element volume. Is there any other way?
Please login with a confirmed email address before reporting spam
then if you integrate simply rho over a region (domain) or a domain*bolean_volume_limit or you cut your domain into smaller parts to make selection easier (it does not matter if you have a few internal boundaries)
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
One way to get a better feeling for the field variable Volume scale factor "dvol" (note without units !) is to
make a fresh new model, take a 1m^3 block geometry in 3D solid physics, mesh it in 3 variants:
extremely coarse: a) default tet, , b) tri on one face + sweep, and c) mapped on one face and sweep
then you take the average over the volume of "meshtype" to check the type of elements (=number of edges): 6,9,12 respectively,
you check the mesh statistics to see the number of elements per case,
and you integrate with a Derived value the field variable "1/dvol", you will see that it corresponds to 1:1 for the element volume with hex elements, 1/2 with prism, and 1/6 with tets which corresponds also to the ratio you can "pack" the different elements to get the same volume shape
So take care with the generality: dvol is not necessarily equal to the mesh volume it is what it says: a scale factor (hence no units) related to the volume
--
Good luck
Ivar
Please login with a confirmed email address before reporting spam
Regards,
RK
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.