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.

Centroid/Center of mass

Please login with a confirmed email address before reporting spam

Hi,

We have a geometry which has lots of domains and we need to assign different material properties in an automated fashion to all the domains (using a script in MATLAB). Furthermore, the material properties depend on the location of the domain (this dependency cannot be described as a function). This mapping between the location and material property is available as a data file.

I have a COMSOL geometry composed of many different domains, each acting as an individual "grain" structure in a metal. I would like to find the centroid of each individual domain. I could find the centroid of the whole geometry numerically using MATLAB commands, but I need to find the centroid of each domain. Actually, as long as I can somehow retrieve the coordinates of ANY point in each domain, it would suffice. Is there a way to do this?

1 Reply Last Post Jul 3, 2015, 10:10 p.m. EDT
COMSOL Moderator

Hello Agam Mittal

Your Discussion has gone 30 days without a reply. If you still need help with COMSOL and have an on-subscription license, please visit our Support Center for help.

If you do not hold an on-subscription license, you may find an answer in another Discussion or in the Knowledge Base.


Please login with a confirmed email address before reporting spam

Posted: 9 years ago Jul 3, 2015, 10:10 p.m. EDT
Hi,

Did you eventually figure a way to find the centre of mass of each domain in the geometry?

Kindly reply

Thanks


Hi,

We have a geometry which has lots of domains and we need to assign different material properties in an automated fashion to all the domains (using a script in MATLAB). Furthermore, the material properties depend on the location of the domain (this dependency cannot be described as a function). This mapping between the location and material property is available as a data file.

I have a COMSOL geometry composed of many different domains, each acting as an individual "grain" structure in a metal. I would like to find the centroid of each individual domain. I could find the centroid of the whole geometry numerically using MATLAB commands, but I need to find the centroid of each domain. Actually, as long as I can somehow retrieve the coordinates of ANY point in each domain, it would suffice. Is there a way to do this?


Hi, Did you eventually figure a way to find the centre of mass of each domain in the geometry? Kindly reply Thanks [QUOTE] Hi, We have a geometry which has lots of domains and we need to assign different material properties in an automated fashion to all the domains (using a script in MATLAB). Furthermore, the material properties depend on the location of the domain (this dependency cannot be described as a function). This mapping between the location and material property is available as a data file. I have a COMSOL geometry composed of many different domains, each acting as an individual "grain" structure in a metal. I would like to find the centroid of each individual domain. I could find the centroid of the whole geometry numerically using MATLAB commands, but I need to find the centroid of each domain. Actually, as long as I can somehow retrieve the coordinates of ANY point in each domain, it would suffice. Is there a way to do this? [/QUOTE]

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.