Fluids

Fluids

Topics relate to Fluent, CFX, Turbogrid and more

Varying Material Properties with position

    • vsjay3
      Subscriber
      Hi all,nI'm a beginner of Ansys Fluent and therefore I have a simple question:nI am modelling a solid which has a thermal conductivity that varies with the position of the solid (vertical direction). But the relationship between thermal conductivity and position is not complicated - it is polynomial in nature.nSo I know the obvious answer is the UDF creation. But since I am a beginner, instead of creating UDF, I am wondering if there is any other easier way to input a thermal conductivity that varies with position to the material properties dialogue box, since UDF would take some time to create.nYour kind advice in this regard is highly appreciated!nThank you!n
    • Rob
      Ansys Employee
      Expressions, they're a relatively new feature (taken from CFX) in Fluent and replace many of the more straightforward UDF functions. n
    • vsjay3
      Subscriber
      Thank you for your answer. But my Fluent version is 17.2 (my university is currently not willing to upgrade). So is the expression feature available in Fluent 17.2? If not is there any other option apart from UDFs?nThank you very much for your help!n
    • Rob
      Ansys Employee
      In R17.2 you're stuck with UDFs. You may want to point out to your University that they're now 5 major releases out of date and therefore missing out on 5 years of development. n
    • vsjay3
      Subscriber
      Hi Rob, thank you for your answer. Will try to upgrade. May I know what version did the expression feature first arrive in Fluent? Was it 19R1?n
    • Rob
      Ansys Employee
      2019R1 I think, but the functionality has been improving with each release so the range of usage in 2021R1 is massively increased. n
    • vsjay3
      Subscriber
      Hi, thanks Rob. May I know if I updated Ansys Fluent, say to 2021R1 version or 2020 version - will that 2021/2020 version of Ansys Fluent be able to accept a model created using the old 17.2 Designmodeler and 17.2 Ansys mesher? Will they be compatible?n
    • Rob
      Ansys Employee
      You can read files created in older versions of the code into newer versions of the same code. However, as you'd be jumping 5 versions there may be some errors as model defaults (and entire models) have been changed. Mesh files should be safe as the format is largely unchanged in about 20 years (assuming you're not using any of the new cell types). nYou will NOT be able to read files from 2020 or 2021 into R17 as there have been a lot of changes in the last few years. n
    • vsjay3
      Subscriber
      Thank you very much. Noted. I have requested for the update from my university already. But just have one more clarification: nI have watched some videos of ansys fluent latest version - but seems as if the expression feature can be only be used for material properties dependent on variables such as temperature, pressure etc.,and not spatial cordinates. My requirement is to enter material properties that vary by spatial cordinatesnHence just to confirm, are you positive that the expressionfeature can be used to establish a polynomial relationship between material properties and spatial cordinatesspecifically (such as y direction)?nThanks for the advice!n
    • DrAmine
      Ansys Employee
      Which properties do you want to change?n
    • vsjay3
      Subscriber
      I want to have thermal conductivity changing with y direction (vertical direction) of my solid and also specific heat capacity changing with y direction as well. The relationships between material properties and spatial cordinate will be simple polynomial functions:nEg : k = 2.3(y^2)+3y - 4nc = 2(y^2)+5y - 8nWhere k is thermal conductivity and c is specific heat capacity.n
    • DrAmine
      Ansys Employee
      For that in 21R1 you will need to use UDF. n
    • vsjay3
      Subscriber
      Thank you. If I use UDFs, then for specific heat capacity specifically I cannot useDefine PropertyUDF right ? Instead, I have to useDefine specific heatUDF ?
    • DrAmine
      Ansys Employee
      For heat conductivity you can use DEFINE_PROPERTY, for specific heat DEFINE_SPECIFIC_HEAT. Be aware that the specific heat udf does not allow for cell access. I recommend using UDRGM UDF to deal with this. UDRGM will allow you to code whatever you want.n
    • vsjay3
      Subscriber
      Hi, thank you for your answer.nI am modelling a solid, so I am not sure if I can use the UDRGM UDF since it seems like it is for gases.nAlso, more importantly, you mentioned that the specific heat UDF does not allow for cell access. I'm sorry, but since I'm new to the software, would you mind telling me what that means exactly? Do you mean to say that the DEFINE_SPECIFIC_HEAT UDF cannot possibly be used to link the specific heat material property to spatial coordinates of my solid since the DEFINE_SPECIFIC_HEAT UDF can not accept spatial coordinates of the cell centroids?nThank you!n
    • DrAmine
      Ansys Employee
      No Cell Access: you cannot make it dependent on x,y,z and other things. You can workaround that by using providing the quantity density*cp as density with cp=1 [K/kg/K]. For the density you can use DEFINE_PROPERTY and make it temperature and spatial coordinates dependent.n
    • vsjay3
      Subscriber
      Thank you DrAmine for your response. But I am a bit confused. The density of my solid is constant and cannot change with spatial coordinates. Also where do I insert the density x Cp UDF into? I cannot insert it into density value in materials window since density is constant for my solid.nn
    • DrAmine
      Ansys Employee
      For that reason the hint is to vary the density as density times cp as that is what is required if you look into a heat equation of solid. Fluent uses that density tome cp to solve the transient term. You now just tell Fluent that what it understands as density is actually what you provide as density ?cp.n
    • vsjay3
      Subscriber
      Thank you drAmine for your response. I will look into that.nAs another way around, I was wondering if instead of me modelling a single solid and trying to insert a varying material property, I could try modelling a series of seperate solid regions stacked on top of one another and then assigning different material property to each discrete solid region seperately (as constant values). That should also work yes?n
    • YasserSelima
      Subscriber
      nIf you do this, you will have heat transfer in the axial direction inside your wall. This will affect the accuracy of the results. It will become like one composite walln
    • vsjay3
      Subscriber
      nThank you for your kind response. But the wall/interface dividing the solids would not have any thickness ( zero thickness) and would be assigned coupled condition (i.e. wall-shadow wall). I believe the heat transfer would occur via pure conduction between the solid layers across the wall/interface. Since the wall has no thickness, there would not be any thermal resistance or any wall property that would effect the results i think.n
    • YasserSelima
      Subscriber
      True, if you are not simulating conduction inside the wall, you will not have heat transfer there ... Sorry, my fault, I understood from your first post that you want to change the solid thermal conductivity, not the fluid. Now there is another issue, is this natural convection? If yes, you can't play with the density .. will affect the flown
    • vsjay3
      Subscriber
      Hi no problem. There is no fluid in the simulation just a solid block with varying thermal conductivity and specific heat capacity across its depth. Density stays the same throughout the solid. Heat is applied to top surface of solid. The density should not change which is why I'm not sure I could implement the density varying solution drAmine mentioned. I guess ill model seperate solid blocks stacked on one another with different thermal properties but same density.n
    • YasserSelima
      Subscriber
      If you have no flow, the density is very smart solution. I believe it will work fine. Good Luck!n
    • vsjay3
      Subscriber
      Thank you. But what solution did you mean will work fine? DrAmine's density varying solution?n
    • YasserSelima
      Subscriber
      yes .. n
    • vsjay3
      Subscriber
      But my solid's density can not change and should be constant. Just my thermal properties should vary. Not really sure how changing density would solve the thermal properties issue.n
    • YasserSelima
      Subscriber
      The thermal capacity which controls how much energy is required to increase he temperature is equal to Density * Volume * Cp nAlso the thermal diffusivity k/(Density*Cp)nWhat DrAmine meant, if you control Density*Cp , you will have the same effect. And that is true if you have no flow. n
    • vsjay3
      Subscriber
      Thank you very much. I had a feeling that was what he was referring to but now you confirmed it. Appreciate it. That way works as long as density is always multiplied by Cp in the relevant equations. But I was looking at the energy equation in fluent (provided below) and I noticed that there are instances in the equation where only density is used (without being multiplied by Cp) and Cp is not even present. So in this case, I was wondering how the density × Cp term work...nn
    • YasserSelima
      Subscriber
      True ... the density is used in all transport equations without Cp .. but it will multiplied by the velocity. So. If you have no flow ... the momentum and continuity are redundant and the energy has a velocity = 0. Now all densities are multiplied by Cpn
    • YasserSelima
      Subscriber
      In the equation you put, first term, E includes Cp .. second term, has velocity n
    • vsjay3
      Subscriber
      Thank you very much for the detailed explanation. Still new to this field. I will look into it more deeply. However,just want to know your opinion on the other method I proposed - the one where I use discrete stacked solid regions with different thermal properties assigned to each solid region. Do you believe it would also work and that it is a suitable alternative solution?nThank youn
    • YasserSelima
      Subscriber
      I can not confirm until I see a sketch. But you can simplify it by yourself. Plot a sketch and see if there is undesired heat transfer will happen between the stacks. If NO, it should work. But you will need to define different origins as your equations are dependent on the position.nSorry, I have to go now. Will reply back when I join again. Good Luck!n
    • vsjay3
      Subscriber
      Thank you Array for the response. Appreciate it. Just for your reference, my sketch is attached below (k = thermal property):nThe coordinate system is same. On the left side is the ideal solution where I model one single solid block and employ UDF and make thermal property a function of y coordinate (k(y)). On the right side what is what I meant by discrete method where instead of using UDF, I model several solid layers on top of one another and assign separate individual constant thermal properties to each solid layer (no equation is used for varying thermal property in this approach). Thermal property variation across the solid layers won't be as smooth as UDF method, but I'm guessing it will be quite similar. I don't think I need to define different origins in the discrete method since I won't be using any k(y) equation in the discrete method (just assigning different constant thermal properties to each solid region). Let me know if you have any view on this ArraynThanks.n
    • DrAmine
      Ansys Employee
      My Cp workaround is for sure only for solid without solid motion. For fluids you can go the way of UDRGM which is more generalized.n
    • vsjay3
      Subscriber
      Thank you for your kind response. In the Cp workaround, I would have to learn to code UDF anyways. Just out of curiosity, instead of using UDFs do you think that the discrete method I have shown in the above image could also work as a viable alternative to using UDFs?n
    • DrAmine
      Ansys Employee
      Discrete method (what you are calling discrete) might work too but using UDF is much more elegant and easy to learn!n
    • Rob
      Ansys Employee
      yes, if the solids are connected with coupled walls then heat will transfer axially as expected. Just be aware of the cell count doing this as you may over-refine the solids depending on the thickness of the sections. n
    • vsjay3
      Subscriber
      and Thank you very much for your valuable advice. Appreciate it.n
    • YasserSelima
      Subscriber
      Yes it works. nTake it as a learning experience. Do both ... UDF and Your Discrete layers. And compare the results. So, you learn more from this project. n
    • vsjay3
      Subscriber
      Thank you for the explanations and advice. Appreciate it.n
    • YasserSelima
      Subscriber
      You are welcome! Good luck!n
    • vsjay3
      Subscriber
      Thank you!n
Viewing 42 reply threads
  • You must be logged in to reply to this topic.