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.

How to access materials property variable using material switch node

Please login with a confirmed email address before reporting spam

Hello all.

I want to access materials property variable(Cp,rho etc) in physics node.
When I use (nomal) material node, I can access this syntax : "comp1.mat1.def.Cp" .
Then, how should I access these variables when I use "switch for materials" node?
Ofcourse I can access each materials property in "switch for materials" node lile "comp1.sw1.mat1.def.Cp" ,
but I want to access mat1.Cp and mat2.Cp uniformly even if materials was switched.

node structure is lile this.

Materials
L sw1
...L mat1
......L def
.........L Cp
...L mat2
......L def
.........L Cp

Best regards
Hiroshi Yamashita

2 Replies Last Post Feb 16, 2015, 12:00 a.m. EST
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 9 years ago Feb 12, 2015, 7:54 a.m. EST
Hello,

I think that material.rho, for example, is what you are looking for. That set of variables (material.<property>) represents the current values of rho and other material properties for the active materials in the geometry.

Best regards,
Magnus Ringh, COMSOL

Hello, I think that material.rho, for example, is what you are looking for. That set of variables (material.) represents the current values of rho and other material properties for the active materials in the geometry. Best regards, Magnus Ringh, COMSOL

Please login with a confirmed email address before reporting spam

Posted: 9 years ago Feb 16, 2015, 12:00 a.m. EST
Thank you, Magnus Ringh, I was able to almost resolve by this way.
I was able to get materials property in "Output properties", but I havn't been able to get in "Local properties" yet.
These variables cannot get by using material.<variable> ?

Best regards,
Hiroshi Yamashita
Thank you, Magnus Ringh, I was able to almost resolve by this way. I was able to get materials property in "Output properties", but I havn't been able to get in "Local properties" yet. These variables cannot get by using material. ? Best regards, Hiroshi Yamashita

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.