|
[Sponsors] |
interpolate transient solution into one domain only |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 30, 2020, 05:59 |
interpolate transient solution into one domain only
|
#1 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
Hello,
let's say I have two domains. Domain1 and Domain2. I have result file from the first simulation. I want to use the result file to interpolate results into domain 1 and want to be able to initialize domain2 with my value for the second simulation. I specified initial values file in the execution control, left Initial values control unchecked, didn't use interpolation mapping and disabled domain initialization for the domain 1. I left domain2 with domain initialization checked with automatic value however ansys seems to ignore this and interpolate results into both domains. Mesh is the same in both simulations What are my options here? Am I doing something wrong or it is just not possible to do it this way. Thanks in advance |
|
October 30, 2020, 16:11 |
|
#2 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143 |
I don't understand your question. Are domains 1 and 2 in different locations? Then of course you can't interpolate one onto the other. Or do they lie on top of each other? Then why have you done that?
If you want to do more sophisticated initial conditions you can use a CEL function calling an interpolation routine, or calling a user fortran function.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
October 30, 2020, 16:26 |
|
#3 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
Imagine a cube that is cut in a half (each half is one solid). Bottom solid is domain1 and upper solid is domain2. domain 2 has some initial conditions at 0s. after simulation is finished I need to do another simulation but this time I have to interpolate result from domain1 into domain1 and domain2 has to start with some initial conditions thus I do not want to interpolate result from domain2 into domain2 but i want to use initial conditions that I had specified.
You mentioned that I can call initialization routine. Is this even possible during simulation? for example Can I call init routine at step number 20? My case is that I have cyclic process where upper half of the cube starts at certain temperature (whole volume has for instance 500C) every 100 seconds. I need to simulate heat transfer into the bottom half and need result for first 10 cycles. So at each cycle bottom half is at different condition but upper half has always 500C at each start |
|
October 30, 2020, 16:36 |
|
#4 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143 |
In my experience on this forum, about 90% of unusual requests like this are actually XY problems (https://en.wikipedia.org/wiki/XY_problem). Please explain what you are trying to model and what you are trying to achieve with this model.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
October 30, 2020, 16:47 |
|
#5 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
I think I described it but maybe too complicated because english is not my mother tongue and it is difficult for me to precisely express my thoughts.
So once again and simple. My transient simulation will have 200 seconds and after every 20 seconds I need to initiliaze one domain with temperature of 500C. The other domains cannot be initialized. |
|
October 30, 2020, 16:53 |
|
#6 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
Or the other question was that if I want to use previous result file for the initialization and want to exlude one domain from that interpolation and use Domain initiazation option instead
|
|
October 30, 2020, 21:13 |
|
#7 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143 |
You can control which domains get initialised by setting the initial conditions tab on the domain in CFX-Pre.
Yes, you have said that you have a transient simulation and every 20s you initialise one domain to 500C. But these details are vague and I have no idea what they mean. So what is this device? What resets it to 500C? How does it reset it? And what are you trying to learn by doing this simulation? For instance, if you want to reset your domain to 500C each 20s a far easier way of doing it is by using a source term. This is what I mean by an XY problem - it is likely that your initial condition setting proposal is not the best way of doing it. But for us to suggest a better way I have to know what you are doing and why.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
October 31, 2020, 05:43 |
|
#8 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
Ok I get it. Sorry for my vague explanation.
this is the process: it is glass pressing into cast iron mold. The process starts when mold has ambient temperature. at first mold is heated for 10 seconds up to 400 C. after 10 seconds gob of molted glass drops into the form (glass temperature is around 1400 C). The glass stays in the form for 20 seconds. after 20 seconds glass is removed from the form and process idles for another 20 seconds (form is cooled by natural convection). The process starts again. My aim is to simulate temperature profile in the form and also in the glass. I can simulate one cycle because initial conditions are: form has 25C and glass has 1400C. But I don't knnow how to simulate the second cycle where the form is heated from the previous cycle but glass has again 1400C (initial conditions). I tried using .res file from the first simulation but the problems is that ansys interpolates results into the form domain and glass domain even thought Glass domain has domain initialization checked. Ansys just ignores it and uses temperature profile from the first simulation result. You suggested using the source but I am afraid that is not possible because it would mean that glass would have 1400 C the whole time. There is an interface between the glass and the form so after the initial condition for the glass it is rapidly cooled by the heat transfer into the form domain. I need to do at least +-10 cycles because after that number of cycles the form will be heated to the desired temperature. I hope you understand my problem right now. If ansys would not interpolate results into the glass domain and use domain initialization instead all would be fine. |
|
October 31, 2020, 05:59 |
|
#9 |
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143 |
If you just want to set the glass to a constant 1400C every 40s (or 20s or whatever the period is) then just use a source term. It is very simple. You can set the temperature to 1400C using a source term like:
S(T) = -C(T-1400[C]) with a source term coefficient of -C Set C to be large relative to the other parameters. To make it act every 40[s] then multiply it by a function which is zero most of the time and 1 for a short period every 40s (but at least one time step long). You can do this with an interpolation function, but more elegantly using the mod function, something like: t_in_cycle = mod(t,40[s]) f = if(t_in_cycle<0.1[s],1,0) This will turn the function on for 0.1s every 40s, and repeat this pattern every 40s forever. and modify your source term to: S(T) = -C(T-1400[C]) * f Now the function f turns the source term on and off. Easy. And you don't need to do any weirdness with the initial conditions at all.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|
October 31, 2020, 07:19 |
|
#10 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
thank you for your answer. I really appreciate it.
Will this source term "heat" the domain up to 1400 C within 0.1s? I am asking because the glass domain will have some temperature profile and the average temperature in the domain before I turn the source on will be around 100 C. I am trying to set this up so I can test it but the source term unit has to be in [W m^-3] and if I use -C(T-1400[C]) where C=50000[W m^-3] i get this error message: Expression resolves to invalid units ('kg m^-1 s^-3 K') in value set for parameter 'Source' in object '/FLOW:Flow Analysis 1/DOMAIN:Glass/SUBDOMAIN:Subdomain 1/SOURCES/EQUATION SOURCE:energy'. Expected units: 'W m^-3'. |
|
October 31, 2020, 07:59 |
|
#11 |
New Member
Join Date: Nov 2017
Posts: 25
Rep Power: 8 |
this is how it's set
and this is the temperature profile of the glass during simulation I can see that it does something but the effect is too low and the formula depends on temperature difference in the domain. If the difference is low the source is also low and I think that 0.1s for its effect is too short. I am worried that it wont be possible to do it this way |
|
October 31, 2020, 20:37 |
|
#12 | ||||
Super Moderator
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,703
Rep Power: 143 |
Quote:
Quote:
Quote:
Quote:
You just have some problems with the way you implemented it. It will work fine when you implement it correctly. One problem I can see straight away is that you have not included a source term coefficient, like I said you needed. This will make convergence MUCH harder. Include the source term coefficient and convergence will be much better. And a small correction to my post #9: The source term coefficient should be -C*f now that we have added the "f" function. Read the documentation if you want to know why.
__________________
Note: I do not answer CFD questions by PM. CFD questions should be posted on the forum. |
|||||
Tags |
result interpolation |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Convergence | Centurion2011 | FLUENT | 48 | June 14, 2022 23:29 |
Solution domain modification of results | maksay | FLUENT | 0 | September 15, 2020 03:44 |
Turbomachinery Mass imbalance | sheaker | CFX | 12 | September 5, 2019 08:09 |
Can CFX model periodic heat transfer problem | Ethan_Sparkle | CFX | 41 | June 14, 2017 07:22 |
Error finding variable "THERMX" | sunilpatil | CFX | 8 | April 26, 2013 07:00 |