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 16 feb 2015, 00:00 GMT-5
Magnus Ringh COMSOL Employee

Please login with a confirmed email address before reporting spam

Posted: 10 years ago 12 feb 2015, 07:54 GMT-5
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: 10 years ago 16 feb 2015, 00:00 GMT-5
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.