 Please. Thank you very much Vladimir. Good morning everyone. Welcome to this, I would say, practical introduction to containment form. So I do not want to go into all the theoretical details that we have, but I just would like to give you a flavor on what containment form actually is and what one could do with it and I leave the details for your own studying and of course questions in the coffee breaks or whatever. So you will see my name written here, but of course containment form has not been developed by me alone. I have a list of people we worked together since 2015, primarily on containment form. PhD students, master students, interns, we had trainees for software developing. All of them we came together contributing the one or the other part on containment form and this being said, in case you're interested to contribute, of course, you're very welcome just to get in touch and propose the one or the other detail. The mics are on, yeah. Okay, I can hardly do anything about it. Okay, I can try to speak louder. Maybe that's it. There were also a number of projects sponsoring the one or the other activity. I don't want to go in all these details, but just again to highlight that activities like Encore really help to to drive such a project forward by say enabling exchange among peers that are in the same situation, develop best practices and so on. And last but not least, also a number of personal collaborations helped us a lot to drive this thing forward. So if you want to get it, there's a very easy way. We put it into a short link go.fzj.de slash containment form and be aware this last four letters are capital where you can take this QR code and you will end up in the repository and it will follow the same way like you are used from yesterday. You will find the all-W make script. You just run it and it will install a containment form as an add-on to your open form version. And this time it's not ESI, but the foundation version 9 that we use as a basis. So unfortunately, you have to install a second one first. Okay, so for today for the next, I would say one hour, one hour 15, I would like to give you an overview on containment form being an example on how to tailor open form for a nuclear safety application. So we will discuss a bit on what containment form actually is, what we develop it for. And on this basis, we can also then see which kind of functionality open form gives us, which kind of functionality we need to tailor for our purposes and how actually we did it. So with this, of course, we have to discuss a bit about the background. I assume you're not that much familiar with CV accidents and containment analysis, so I will dive a bit into this. And I will also here and there have a quick look on the model, the equations, how we put this into the code and how it actually looks like from a user's perspective. And finally, also, I will highlight a bit where the journey with containment form will go to. So be aware, this is just the tip of the iceberg. Within 60 to 90 minutes, not much is possible, but there's much more hidden and of course, this is to be discussed. So the outline will be first a bit of practical introduction on the background, the applications we aim at, then briefly on the strategy we're following for developing containment form and the particularities. I will briefly touch the theoretical background. They have a lot of slides here, but I don't want to go, each of them explain deeply the physics, but I would just tell you that these are special models we have here for good reasons and how actually we did it. So a kind of example on the process. I will then at the end give you some insights in, let's say, the framework we build around containment form. So it's not just a code, it's for us. It's also a collection of best practices on how to use the code, how to do this developments together and how to work with the code on practical applications. So we have a kind of guided workflow tool that we've developed. We have a solution monitor that helps us to analyze the solution on runtime. I would like to show this to you before I conclude my talk on our work. Okay, so what's a severe accident? What's the target application? There are many ways to explain it. I would like to do it by the way of the defense in depth concept, which is probably well familiar to all of you. Actually, a concept of staggered barriers that should prevent the release of fish and products to the environment. These are the fuel metrics, the fuel claddings, the reactor cooling system, and finally the containment. So we have again also a set of staggered barriers on an organizational and technical level that will prevent that those barriers will fail. And we've seen these different levels you see here. The first three levels they are what we call in the design basis. So a lot of engineered safety features that will simply prevent that the accident is progressing and to try to stabilize the plant while when we are approaching or we are crossing this line, we are going into the level four. It's assumed that the engineered safety features also failed and the plant is going into a severe state, meaning that the fuel is being damaged. And in this what we will easily see is that the containment becomes the last barrier against the release of fish and products. And of course it is of utmost importance to make sure that it will stay intact and there's no release. So in order to do that we need to understand all the processes that happened in the containment and that may challenge its integrity. And one thing that's really a big threat to the containment is a combustion event, something like what happened in Fukushima. Here it happened not within the containment, it happened in the building around but at least it drove our attention to that kind of risk again. So you know whenever there's steam getting in contact with a hot metallic surface it can corrode this or oxidize this surface and produce a lot of steam. A hydrogen which is released to the containment and also in the later phase of an accident when the molten corium is getting in contact with concrete it will decompose the concrete and produce a lot of hydrogen carbon monoxide which are combustible gases. So if you look at this from the perspective of a ternary diagram so you see here on the lower axis the fuel on the left on the right axis the inert gases on the left axis the oxidizer we can characterize a kind of regime where the gas mixture itself is flammable and there's even a smaller regime where the gas mixture can undergo detonation. Then we can put our accident sequence in this plot and you see actually we will start here somewhere with a dry atmosphere in the top we will release a lot of steam for example in the loss of coolant will at some point start producing and releasing hydrogen so we are going a bit more away from the axis up to a point where the release of steam and the condensation of steam and the containment is balanced and then the atmosphere is drying out again and we will run into this potentially flammable regime. This is actually not a big problem as long as the combustion process that is resulting or can result is a slow process that means the energy is more or less transferred into heat but when it accelerates and becomes a fast combustion we can have dynamic effects of shock waves and at this point let's say the pressure may be higher than the PAICC the adiabatic isochoric complete combustion pressure that we use to to design the containment. So these things they heavily depend on the geometry on the turbulence of the flow and of course need some three-dimensional understanding. There can be other effects like standing flames which result from let's say continuous release these are local phenomena also again benefit from a three-dimensional representation. When we do CFD in such an environment of course it's not the standalone tool so it just embeds into an analysis chain starting from a very let's say quick running tools that help us to to screen out the most panelizing sequences to select those which are let's say of high interest for our analyzers to prepare source terms that we can use in the more detailed codes and then once those scenarios are found there will be also again let's say a set of analyzes with increasing detail to to understand where potential risk can be and how safety measures safety systems can be can be implemented. This step we can go and run CFD to study the three-dimension evolution of the flammable cloud and of course we can give this information to combustion solvers which are also for example made on basis of open form but we can also simply use imperial criteria to say acceptable non-acceptable and iterate the process of improving the safety concept and finally also this let's say three-dimensional combustion loads can be given to to fluid structure interaction for very refined assessment. So in this context CFD is I would say somewhere in between an experiment and a system code analyzes so it will not replace the system codes for sure but it will help us to to gain more understanding for example when we use experiments to validate the system codes so we can get insights where we don't have measurements we can help to design experiments we can help to design the nodalization scheme of of system codes we can help to let's say get the best out of the experiments by doing some preliminary design studies we can help upscaling experiments when you know CFD doesn't have any length scales in the equation so it's easier to scale up than the system codes and also it can help us to understand 3d effects which are simply ignored in the simple 1d or 2d approximations. The challenge here is of course that we have to isolate our problem and get the proper initial and boundary condition and these of course with a much higher level of detail than it would be needed for a system code often what we do here is apply CFD to something that's a bit off standard so it's not easy to use models that come from let's say IC engines or from aerodynamics turbo machinery and apply them to containment analyzes without questioning their validation basis and also getting a hand on the feedback of the system so this is for me everything that's coming from the the containment as its own from the operators from the safety systems that are installed this is something which is typically not a standard piece in a CFD simulation. So I would like to show you a few examples we did starting with an international standard problem that was run in a I would say quiet application oriented setting so this is the Batel model containment a former test facility in Frankfurt in Germany which had a volume of roughly 650 meter cube and it was compartmentalized in a way to mimic the rooms in a in a German PWR containment. The concrete building so there were some leakages which were not not really quantified this was not easy to to account for in the simulation and left some questions but at the end it was a nice setting for us to to test the model on some realistic application and at least with some experimental references. It was a complex transient you see here for roughly a hundred and something thousand seconds and what we did actually was we were just studying a quick injection of steam and aerosols agroscopic aerosol material and then a depletion phase where the system is coming to rest steam is condensing and the aerosols are settling and afterwards there are some other injection phases with different modes which we which we did not consider so far. See a CFD typical mesh so we have some refinements where we assume gradients like the jet flow here or the boundary layers close to the walls and a typical mesh size of roughly two and a half million cells in the fluid which I would say is some close to a standard CFD application in this case. Openform gives us a nice tool to initialize such a case so you can imagine we did not want to run 17 hours preconditioning of the facility just to come up with a good initial condition for doing this work so there's a tool that that Carlo already mentioned that we used in the in the very first tutorial which is called TOPPO set this allows us simply to pick pick up a set of cells and then do something to the cells so what we did here we we selected all those rooms the compartments we took a representative measurement of temperature concentration and so on and we applied this filter to select all the cells that are either in the volume or let's say within a certain thickness around the volume so we could give an initial field to the structures and the fluid then we let this diffuse to get some initialization for the solid structure temperatures we run a short transient to get an initialization of the three-dimensional flow field and with this we could jump directly into the interesting piece of the transient so this is a way we also think of using it later within application to containment get some initialization from the system side put it into containment form and then run a certain time frame of the transient looking at the experimental data I would say the results are okay still improvable but given the uncertainties we have I was pretty satisfied doing this so we were able to get a I would say reasonable agreement of the temperature field above the injection and below it was a bit difficult here we have a lot of stagnating flows and weak flows so it was giving us a higher differences all in all I was pretty satisfied looking at the distribution of aerosol material I would say we captured the initial peak during the injection phase but the depletion rates were somewhat looking different but yeah this just made based on three samples that we have during that time so there's a huge uncertainty here but still I would say the tool was generally able of capturing the phenomenology with the one or the other let's say overestimated or underestimated tendency what I would conclude is that this kind of first of its kind application of containment form with a lot of different physics inside was really challenging but it was possible and doable and over all the results were plausible and we could showcase that running such a transient of 20 000 seconds it's absolutely possible within a reasonable time and reasonable time here would mean 128 cores and something like a 20 days runtime for these 20 000 seconds so here we achieved something like 400 to 700 seconds per day depending on the phase so you can imagine if you have a fast injection time steps are small it's rather slow and in the stagnating phase you can easily ramp up with the time steps so I would say the method itself it's application ready but it's something that's still expensive for long transients and we need to find good approximations for modeling the the injection even or in particular when they are for high momentum we are currently putting this into um let's say a full-scale containment analysis within the amyco project a european project which aims at analyzing the combustion risk in let's say the the western types of containment in europe and we want to do this with particular focus on the late phase so where we have hydrogen and co and the idea is here to again screen two different scenarios using lampar meter codes having a fast analysis of them in a 3d code gothic to identify those let's say compartments and the time sequence which are of high interest and then go into a detailed assessment with cfd not to compute our combustion process at the end but to give some idea on how effective different mitigative strategies are and also to to see uh let's say if the instrumentation that the operators have will allow them to um to really understand the situation in the containment and and take the right decisions in a similar fashion we went together with colleagues from munich um to analyze the combustion process so they develop a solver which is called explosion dynamics form it's a compressible solver which allows to to really solve for these shock waves and the the way um the initial step was um similar to what i presented before running the system code mapping the information on a 3d mesh and then simply igniting it to assess the combustion loads but here we miss an important factor and this is the turbulent of the flow um shortly before the the combustion so turbulence leads to a wrinkling of the flame surface and this will then speed up the reaction rates and lead to acceleration of the flame so the idea we had here was simply to add another intermediate step after mapping the data a running containment form for a few minutes just to um develop a certain flow field develop um an initial turbulence level to um then give to the combustion code and assess the we do similar things in a non-nuclear field so um this is a technology demonstrator plant that we build in our campus um it's very prototypic in many senses and of course it combines a lot of hydrogen technologies and again here it's uh very important to make sure that no combustible mixtures can occur so we put this into containment form run different accident scenarios to see how the um the mitigation strategies in place something like active venting um safety shut shut off valves and so on they will um prevent formation of flammable mixtures so um i will not detail this but at the ncfd in such an application is really the tool to go since um this is completely um new the future will go a bit more into um direction of small and modular reactor concepts again more on the focus of light water reactors since this is what we developed most of the models in containment form for and we picked out representative types of those reactors um which have on the one side a dry containment with a lot of passive safety features like you see here the iris concept there's a small containment um which can go up to a higher pressure than a classical one and actually what happens if there's a a loss of coolant here is that um the drivel will be pressurized the gas let's say non-condensibles plus steam will be purged into this pressure suppression pool um the steam will be condensed the non-condensibles accumulate in this um gas space here will be purged partly into the liquid gravity makeup system and by this let's say the the pressure in the drivel will be a function of let's say um in balance with the pressure in these two gas spaces here so you can imagine you will never be able to predict this if you are not able to predict the pressure in those gas spaces here as well becomes a bit more complex in the later phase of this accident when there's a pressure equilibrium in the drivel and these gas spaces and the steam production rate the decay heat of the the fission products will go down that means um we will have a reversal of the flow so now um water will be purged over from the pressure suppression pool into the drivel and accumulate here in the cavity so this will enable some cooling external cooling of the reactor pressure vessel and also lead then to the fact that the part of the drivel is filled up with water so um it will affect the the free volume that we have so all in all this poses quite some challenges on the model so we have to somewhat consider the system feedback we have to go probably for a more complex way of modeling condensation and also we have to to consider um that there are no non-condensable gases they are simply purged over into this um these um volumes here another concept is um these uh submerged containments like we have it for new or the new scale which um rely on in the late phase of the accident on an external cooling of the containment a removal of the decay heat into the surrounding pool as an ultimate heat sink and here we have a a natural circulation on the outer side this is a very tall containment something like 25 meters tall um at a very high Rayleigh number and again this is something which is completely out of the the validation range of the empirical correlations that we that we use today so here's CFD can help to um to study this also in link with the processes on the inner side of the containment can help to study the effect of let's say a non-planar surface as you see here in the in the cut drawing and it will also help us to understand how to to feed this information then into system codes for more um comprehensive analysis so you see there are a lot of um challenges to solve uh when we wanted to address some problem like this with CFD and I briefly want to um highlight how we approach this with with containment for just to say it's um it's a coordinated R&D effort so um we try to develop all the things having the big picture in mind it's not like individual pieces here and there that we can plug and play but you will see later we will really have to interact with the different models uh that we are doing some multi-scale application and to some extent it's also multi-physics application as you will see later and it's very important I will stress that uh a couple of times is that if you do such an analysis there's no way of simplifying the problem isolating a single piece of physics but you really have to do all of these things to be representative so in this way let's say the whole or the the system model itself it is as strong as the weakest element and um that means let's say the slowest model determines the time we are running and the um courses model of course will determine the accuracy of the whole result so this is something to be addressed in the model set we came up with a baseline set of models so you will see containment form has not too many models at all but all the things we have um they are there for a good reason and we're trying to understand limitations of those models rather than optimizing them for a very specific purpose I think this limited set we can give a better guidance we can limit our maintenance efforts so again we will not put everything that's available into the code but we will stick to um something that's to our opinion the most useful model set and also we came across the point that um there are many things which are done by everyone it's repetitive um something like case setup uh monitoring and evaluating a solution so we provided some tools or we are developing within containment form some tools to um to ease this process and implement a certain set of standards so there are common post-processing functions for the basic things like heat and mass balance um there are recommendations for data handling and minimizing IO and also we are working on on a framework to um quantify uncertainties within the validation runs so that these sort of things they are standardized and if you look at the phenomenology we discussed the one or the other thing here is what you see clearly if you look at the containment is it's a very complex three-dimensional geometry multi-compartmented um some of the compartments they are separated by doors and burst discs so these sort of things can open during a transient and form new flow paths and also we have a wide range of lengths and time scales coming from the system as it all down to the physics um that we are solving similarly on the phenomenological side there are many things to consider um we are going through a broad range of flow regimes if we really start with the blowdown um we can end up very slow flows which are primarily driven by local differences in density and then they can be even stagnant zones in in the um containment so there are a lot of physical phenomena in the acting um with themselves but also with the system feedback so the effectiveness of passive safety features for example again to be loud here if we want to discuss all these things there's no way of um simplifying the problem too strongly we we really have to consider all of these things in the model so I wanted to brainstorm a bit but I will be fast on this to save some time there are a lot of things that will affect the containment atmosphere flows and mixing the let's say um a change of temperature composition which induces buoyancy and also the the pressure heat and mass balance and just to give a few things I had in mind of course this is heat transfer heat exchange with all the structures in the containment um this is heat transfer within the atmosphere primarily thermal radiation these are safety features like passive autocatalytic degree combiners containment coolers which are in many things they can be sprinklers uh we have these um doors and burst discs which will heavily affect the flow pattern when they open we have operator actions some logic something like if you reach that certain pressure activate the venting system that needs to be um considered and we have a lot of input from the primary system which is not part of containment form it's simply as an input from from a system code something like the the steam release rates um evaporation from some so you will see containment form is single phase so we are not um not modeling accumulation of water we just take it from the system side it losses from the reactor cooling system components heat and mass release from molten core in concrete interaction these are things we we cannot do we just rely on on external input of course all this is linked with the atmospheric mixing processes but also there are some interdependencies of the models so simply to say um bulk condensation fogging and aerosol transport are very very tightly linked um and at the end this will also drive then the distribution of the decay heat um the fission products in the containment atmosphere which will induce buoyancy locally drive the mixing processes but there are other things like radiation um and fogging this will um affect each other the safety systems like spa they could evaporate um the fog which is formed uh somewhere so at the end there are a lot of dependencies between the models where the models have to talk to each other provide their output as an input to the others we put this together in a set of models as you see here i won't go to all the details but um at the end we we defined a baseline model for all these um different phenomena uh the green checkmarks are simply saying this is within the release version we have for the moment the yellow ones is something that's still under work and will uh follow um soon so to summarize containment form is a package which contains some tailored solvers for um let's say fluid only and conjugate heat transfer solver solutions and also we are now putting this um two phase volume of fluid method solver here um we have a library of application oriented models which are really tailored for specific um let's say um thermo fluid dynamic conditions and and applications we have um done quite some verification and validation unfortunately we cannot share the validation cases since all the data is somewhat proprietary but at least the verification is um part of the repository and we have set up a framework for collaborative um development for collaborative use of the code that i will show at the end when designing containment form we um designed it not to be standalone part it's um an add-on to open form version nine at the moment it will be version 11 hopefully within half a year um and we we did this in two ways the first one was simply what Carlo mentioned yesterday identifying an interesting model in the code cloning it and then changing it so that we have a new version of it and the other one was creating um separate uh base classes that will um provide us functionality that was not there in open form before something like multi-species transport or condensation and while we did this we were pretty careful implementing a number of plausibility checks so if you run it and you will get a lot of errors and the code doesn't want to start this is simply because we did all these checks to guide the user and prevent that things are done which are inconsistent with respect to the design of the models so for example here you see that we we check a combination of boundary conditions just to make sure that someone who wants to run um condensation does not forget to specify the right boundary conditions for all of those um base classes they um and also their derivatives they hold a number of access functions which you can simply call in the the equations then something like here uh for example we get the diffusion coefficients from the the library we can get the condensation rates from the the class and add this as a new source term for example to to the equation okay with this I will quickly jump into the theory and we can run to this pretty fast I would say um but before I come to the physics I would have a very short excourse to the geometric modeling of the containment I mean a major feature driving the flow is more or less the geometry of the containment it's super complex and at the end we need to consider this in the geometric model but on the other hand it's pretty clear the more details the more features we involve in the geometry the harder it will be to to run this and the more expensive the computations will be so to give you some idea on how to approach this um we take the geometry here we specify a kind of maximum edge lengths this is a half a meter in this case so the large cells you see here in the bulk region and then we we specify refinement levels to resolve the the structures within the containment so a refinement means we are cutting a cubic cell into four so you can imagine by refining we rapidly increase the number of cells so I would not go more than two refinement levels that means my smallest cell as an edge length of 12.2 centimeters and if I imagine I need at least two cells to resolve a structure then this means the the geometric feature lengths that I can resolve is 25 centimeters so this is pretty large actually for a CFD simulation if I do this feature resolving you see it here for example then that means that I get a lot of small cells close to the features and again when I then want to extrude boundary layers to also resolve the flow near the the walls something like you see here I would just extrude those small phases I have into the bulk so this will multiply up again the number of cells so you can imagine that coming up with a a usable mesh here is um really a balance between a lot of different things to consider and in this particular example here I came up with something like six million cells for the fluid phase of the containment so this is I would say pretty coarse looking at the phenomenology but this is already something that is challenging for running transient analysis so we need to find models that can somehow handle on those kind of coarse grids so at the end we are trying to reduce the number equations to be solved we are going for a single phase we try to neglect all those um liquid parts we are using around equations not going for something fancy like les um we use wall function near the walls to um prevent a high boundary layer resolution we try to add effects that we cannot solve with the simple modeling into the um runs equations we have um the the tracers like fog or aerosols they are simply passive scalars transported along with the flow and wherever we have um very specific things like system models we we try to use um a coarse approach either porous media or some system coupling to to represent all this and you can imagine if you resolve the containment with uh let's say uh characteristic lengths of 25 centimeters you will lose a lot of structures walking grids handrails all these things piping a lot of heat capacity that we have that will condense steam and and prevent pressurization so at this point all these things um have to be con uh considered somehow in a porous media approach it's no way of of uh neglecting these things good so um quickly go through the models um we took a basic solver reacting form that was available with open form we extended it by um multi-species treatment so primarily adding molecular diffusion here doing so you you have to know that there will be another term coming up in the energy equation which accounts for the the enthalpy which is diffused by um the diffusive mass flux here and then we added some source terms which will um let's say be used to integrate the one or the other model um we set up a solver algorithm which is close to um what what reacting form was doing but at the end we um we had also to integrate all the models that we that we will link and we do this in an implicit manner so mostly the models are integrated and updated within the the pimple loop specific thing here when it comes to multi-species flows is that actually the density is um in any equation and um it will change by nearly any equation so it will change when we update continuity it will change when we update our species concentrations it will change when we update the temperature field and it will again change when we update the pressure field so we need to iterate around this a couple of times meaning um a piece of approach is not possible we have to go for pimple um we defined the baseline set of numerical settings i will not go into detail on this but if you look at our test cases you will find that these every solutions every schemes they are always looking the same this is a kind of consensus we had to make sure that um somehow these considerations are not leading to some user effects in the validation we put in some nice feature for um for system analyzes which i would like to highlight here this is a kind of extended time-stepping management so actually what openfoam does is looking at the current number to reduce or increase the time step and um this is a posteriori treatment so it will simply check what happened in the time step before and adjust the the current um current time stepping there's one issue with it meaning a large time step does not mean a fast simulation so technically you can have a large time step with many internal iterations or you can go for small time step with less internal iterations and in some the latter is faster so what we added was checking the number of pimple iterations the inner iterations we need and by this also adjust the time step and again this is something that happens a posteriori so whenever the convergence was not good enough it will reduce the time step but of course we already did this um convergence issues uh in our solution so the idea was to um to have some kind of um trigger where um our system models can tell the code something will happen very soon reduce your time step something like a burst disk will open so this will rapidly change the flow situation from a stagnant or close to stagnant flow to something that is very fast so um in this point we can change already before this event happens the time step to a small value and then come back uh afterwards to this automatic treatment and last but not least if you shoot a simulation it's not usually it's not fire and forget it's um you start it you have to monitor it and of course when it crashes this is a loss of of computation time so here we added another feature saying um that if a time step is not converging um redo it with a smaller time step size so this will help us to um prevent any kind of crashes that that may happen during runtime and um we put in these controls into the the control dig so we put in these um controls into the control dig and tested it on a quite typical transient i will come to this later it's a it's a pressurization transient um over 20 000 seconds we are running here again another international standard problem and if we do this with the classical treatment and the improved one what you actually will see is the the classical treatment here in red it runs partially on a larger time scale so you see here the curve is straightly going up um but it often reaches the maximum number of tolerable pimple iterations while if we choose this uh new treatment we will often have a smaller time step like here and here but it will remain at a low number of pimple iterations and at the end we do more time step integrations but we reduce the runtime simply because we are converging um better than before and this will let's see lead to some safement of computing time but also of course getting a more accurate solution since we are not exceeding our convergence limits here i told you the case of the burst disks so um we have the system events created by the user or by the system models themselves simply are reducing the time step keeping it on a low level and then giving control back to the time step management and again here we see that this is very beneficial in such system scale analysis as you see on this simple example so when we run here um pressurizing the first chamber um we can run on a pretty large time step and then when the the burst disk fails the time step will be reduced quickly um if you do it by the current number we can easily go up to current number 400 500 um and then we will have this fast flow which is equilibrating pressure between both volumes and you see here on on this pressure plot if we do it with the current number we accept this one time step with a high numerical error we will end up with a different pressure at the end so this is an indicator for problem with the mass balance while if we use the treatment here you will see that um actually we can much better capture the reference results um however at a somewhat larger cost so doing this is of course something one has to adapt carefully but um we will put this or we have put this into our solution monitor set so that the the time stepping strategy can be can be monitored and adapted according to the run so we'll not talk too much about the physics of modeling turbulence just tell you um we're adding some source terms here into the equations you find it in the source code in a very simple way just adding this function which at the end um allows us to compute this source term based on the model that we select in the dictionaries either simple or generalized gradient diffusion hypothesis and then return this value into the turbulence model so um not too tough to um to add this I will jump over this um for condensing flows I said we did our simplification which is reasonable for large dry containment it's not so reasonable for the small and modular reactor containment but what you assume here is we have a lot of non-condensable gases that will practically um pose the the strongest transport resistance of steam to the wall or to the condensing interface so here we can model condensation rates simply as a diffusion process let's say from the bulk to the interface and the challenge here is um modeling the turbulent diffusivity this is done using wall functions um you will see everywhere in cfd people using wall functions and um this is very um important for for that kind of application since this will directly affect the condensation rates that are predicted so the wall function does nothing else than linking the value at the face our saturation condition to the value at the cell center and it is not doing this by prescribing a value but prescribing a flux so in open form this is done by adopting the um the turbulent diffusivity um to match these kind of analytical profiles that are um specified in the wall functions so we can get the turbulent diffusivity from the wall function and of course for condensing wall we don't have to do this just for the species we have to do it for temperature for velocity for turbulence and so on so there's a set of um wall functions to be applied um along with the condensation model in order to make this kind of model work um another example um for open form uh for let's say the ease of putting a model into open form if you do it implement such a model in a in a commercial software what you typically do is add a source term to the governing equations um that's straightforward but at the end it does not really reflect the physics so you can imagine if this is a large cell things happening at the cell center where you evaluate the source terms are different than things on the face where the flux originally is so what we did in in containment form was simply putting the flux on the wall on the face this is nice because it appears as a convective term in the matrix post-term it's an implicit treatment and we simply model all the processes on the boundary itself so um again to highlight these models they they just work if you follow a very um specific way of specifying all related boundaries um for that patch wear condensation uh works we validated it it was um giving us good results and i i just want to conclude on this with an example of the isp 47 again um if you use wall functions and your measures to cause um your turbulent diffusivities will be wrong or let's say not correct enough and this may happen if it's to cause that you underestimate or overestimate condensation rates here um in these phases where high condensation is occurring you may overestimate the condensation rates significantly so be aware of these errors and try to um to understand this by visualizing for example the y plus values jump over to um fogging so actually what we do is we um take another simple model of the equilibrium equilibrium assumption we homogenize the fog in a cell we use it or we transport it as a passive scaler and we use a very simple model that's the return to saturation a constant timescale model to um pick the condensation or evaporation rates so we simply adopt our concentrations to match the saturation state in each cell the fog is then transported again um by a um by a means of a passive scaler here it's the fog volume fraction and um we allow the fog to drift relative to our mean flow to the gas flow based on this drift velocity term which is just resulting from the fog from the forces like drag or or gravity so it's not tough to implement such a model um what we see at the end of the day there's one parameter we have to give as an input this is the diameter of the fog droplets and it's a very hard in a in a let's say transient analyzes to specify a constant diameter so um what we went forward was to um to add a simple population balance model some piece of software available in open form we just put it into our framework um to to model also the growth and shrinkage of these fog droplets so actually what we do is we have the size distribution of fog we um separated into bins with a specific representative volume and some interval around it and then we have source terms that will um account for the coalescence of fog droplets so small droplets forming a larger ones and also the change of the um the bin due to evaporation condensation and we solve a number of these transport equations then for um each of those volume intervals so this is some giving us a quite physical representation it's slightly more expensive but it's giving us a physical representation as you see here in this experiment we're injecting hot steam in a cold environment we form a lot of fog in the area where it is um injected the fog has a small diameter and while it is settling down in the facility the fog drops are are growing in size and um and then settling down in the lower part of the facility if you look simply at the pressure you will see the red curve here this gives us the most consistent representation um of the heat and mass balance here um we're going forward as said for smaller modular reactors putting this into a volume of fluid method um or integrating that method in in our solvers and you see the same experiment here in a two phase treatment um so you see the the face fraction of fog here and in the lower part in the sun protection of the facility the fog um being accumulated and forming this this um sump when it comes to this I would say fog is not too much important for the water steam balance but it is very important for transport of aerosols and I would like to give one example here um uh related to the the release of decay heat by the aerosol particles so um when we talk about aerosols actually we have the same physics like for fog but we add up some other forces like thermal diffusel and turboforces and we have some other mechanisms that will change the the size of our particles like hygroscopic growth so um when we put these models together and um we were running another validation experiment so this is a same the the same test vessel there's a cooled wall a heated wall which will cause some natural circulation and the steam injection in the upper part we run this with uh without considering decay heat and with considering decay heat and uh you will see that the mixing behavior in both cases changes significantly right so this is something that we can investigate understand analytically using such a tool it is impossible to do this on an experimental site no one would like to put radioactive material in this test facility um that's a huge effort but this kind of analyzes it gives us some insights on the interactions of of the different flows and then mixing process so you see with decay heat the mixing seems to be faster but still the atmosphere is more stratified as we have it here in the case without decay heat so this is an important feature here and um we are currently harmonizing all this together in one library and as soon as this is done um it will also appear in the in the release version and the idea here is actually to um consider fog as an aerosol if it's just fog it will be um as it is but if it becomes an aerosol mixture we will compute the mixture properties of the aerosol first and then transport it either in a mono dispersed approach or with this population balance model solving uh the number of transport equations um briefly on radiation uh we saw this is a very important phenomenon in containment analyzes as it affects the gas temperature gas temperature means also saturation pressure of steam means water steam balance flammability all these features are somewhat associated with it and if we neglect it um we typically um predict the too hot atmosphere so this is really important since radiation um can transfer energy over a longer distance without having a flow while for convection you just need the flow you need the temperature gradients to transfer energy um I will be fast there are a number of models in open foam that can do that the discord ordinate method the um p1 non-sphurgical amonics method um they have all their pros and cons at the end um p1 it seemed too simple for us it's too diffusive FEDOM it was accurate enough but it suffers a bit from this kind of spatial discretization and it's also very expensive if you go for a multi-band model for the spectral properties so our way was to integrate a Monte Carlo solver um into it which is quite useful when it comes to complex geometries and also if you want to go for um spectral modeling of radiation simply since you can sample photons with their initial energy which um is much more effective than running an equation for each energy band so um yeah I will leave the slides for you for studying yourself what I should say is we um developed this Monte Carlo um solver based on the Lagrangian library in open foam so simply similar to tracking particles we track photons with the difference that photons will not interact with each other they are traveling um let's say from the source to their final target within one time step and um we can treat them in a somewhat different way than than particles so we implemented a number of improved methods to reduce variance uh I think it's pretty interesting but uh no time to go into much details uh on this side um what I should say is was much work done to paralyze all this um to make the method as efficient as possible in particular the the parallel treatment of um photon transport so here we used a lot of those things that are also done on on the neutron transport side we use similar to what we saw in gen form yesterday different meshes to compute radiation transport and um fluid motion and we map the information between both meshes so that we can also optimize the runtime we use a multi band model um to prescribe all the properties um of the the variable mixtures um the low temperatures we are having again you see in the um dictionaries how all those different modeling options that we have put can be specified in a very clear clear manner so the last thing I want to come to is um modeling of uh technical systems which is very high importance for for such an application um we already talked about burst discs or doors passive auto catalytic recombiners any kind of containment cooling systems um any structures that are distributed sprinklers um containment venting systems pressures of pressure systems emergency injection systems and so on so there are many of them and we have to find a way to get them into the CFD domain either um by using porous media by specifying specific boundary conditions by putting some point sources or let's say some um distributed source terms and so on so um yeah this is just a view back to reality um if you walk through a containment it looks like this if you look into an experimental facility it looks like this if we model it it's just an empty volume so we need to find a way to to account for all these small scale structures and the way to go is uh porous medium right I will not detail on this Carlo did it very well yesterday um just to say that there's a different way than changing the governing equations there's a function object in open form which will simply apply source terms in the equations so we will not account for the blockage of part of the volume it will simply add their effect to the equations so um this is um a very flexible way of doing it and I I would like to to showcase um this um by one example so we can specify such a porosity source it's called in open form by selecting a number of cells a cell zone we um can specify the Darcy and Foshama coefficients we can give uh let's say a specify a streamwise direction and a cross streamwise direction um so by this we can also change let's say the resistance in different flow directions by a very um short snippet of of model we can do this um of course also in um porous conjugate heat transfer simulation so we can have a heat transfer between two different meshes one porous domain on the fluid side one on the solid side we can use other source terms to um consider things like turbulence damping due to a porous structure and with this we can run a simulation like what you see here so this was a benchmark test we did um in a in a project where they had a jet flow impinging on a inclined walking grid being somewhat diverted and then mixing some light gas layer and you see on the left side this is the flow we predict by resolving uh the the walking grid something like three and a half million cells and on the right side you see the flow we are modeling simply with a porous medium and 800 000 grid cells and you can see more or less that the results are pretty comparable so we can speed up a lot the simulation by using such such kind of models and also represent things that may not be neglected we can do the same for heat exchangers we'll skip it um and I also said we have a model for burst discs which is a trick that openform gives us so openform has a functionality called baffles that are practically boundary conditions that can be connected in some kind of way so we have a zero thickness wall in a in a mesh and we can describe what happens between both sides of of this wall and what we do actually to mimic a burst disc is we create um two of those baffles one which is open one which is closed and we have a condition that switches between both so a very straightforward thing the only thing we have to do is a lot of mesh manipulation in the beginning to create these sets of um of phases that will represent the same thing um if we do it we have in each file again um the conditions for um the open phase and the conditions for the closed phase so it's a not a difficult thing in addition of course we have the burst disc telling our solver and the time step management when it will open and all these things um for modeling technical systems again we can come back to porous media I will show that on example of passive water catalytic recombiners but we can also go for um system coupling again show this on this this example what is such a recombiner um it's actually um a catalyst module here in terms of sheets but they can also have porous materials where hydrogen and oxygen can react form steam without the flame so it's a way to get rid of the hydrogen in the containment and um prevent any kind of combustion risk so this is a passive device that means there's no electricity driving it and if you want to know how efficient it is you have to do some analysis and really consider the position of the recombiner with respect to the flow in the containment so it's a multi-scale issue again these catalysts have a thickness of some millimetres um the spacing between centimeters the whole thing is one meter and it's in a 50 meter diameter containment so at the end um it's impossible to do this completely in cfd and we have to find some kind of a um corsa treatment and um we can do this with porous media as it's shown here using empirical correlations that's not my favorite way of doing it um what we did we linked some standalone code we had in our institute um as a detailed model into um containment form so this code has a lot of different physics for analyzing the operational characteristics of this device and it provides us the um relevant variables as boundary conditions so there are different ways of doing this coupling i won't jump too much into it uh just to say is what we do is we decompose the domain so we cut out the internal part of this recombiner we use an explicit coupling scheme here knowing that the recombiner is a very slow acting it's a thermal device so at the end this is the the easiest way to implement it and also the most uh simple one but depending on what you do always the the models of course there are other strategies to follow uh semi implicit coupling uh you may go for let's say subcycling of the one or the other code um meeting at some synchronization points and so on so we use a feature available in open form that's called external coupled so it's a file based coupler we write out the the coupling conditions to a file which is read by the external code we do some python around it to um make sure the data handling and all the logistics work and then we can couple any kind of executable um that we have into the code and just to show that this is um giving us useful um useful capabilities we run some validation case here um transient of 14 000 seconds in this 60 cubic meter test facility where uh different gases are injected in the bottom we have this recombiner mounted on the outer side and um if you walk through you can see that we with this coupled system are able to compute on the one hand what's happening with the recombiner so for example the flow rate in the recombiner but we can also um very well get the the overall heat and mass balance in in the vessel and all this at a relatively moderate cost of simply running c of d on the atmospheric mixing processes but not on the device itself there's another approach and uh i will be very brief on this since carl will present it this uh very soon on his poster this is a coupling containment form to a kind of system code which is called the open modellica this is a modeling language that is designed to study engineering systems there are a lot of libraries for different components one can link together to mimic the one or the other technical system the nice thing here is modellica can export what's called a functional mock-up unit so kind of exportable model that we can link following another standard as the functional mock-up interface with any kind of other code and also in this case um with containment form so what carl did was actually um creating a interface between containment form and the functional mock-up interface by um using some functionality that was available fmu for form and adding some extras like a semi implicit coupling uh subcycling of the fmu restarting of the fmu and so on and we built some some models that can uh mimic uh in our case it was a precious pressure system for this this iris concept i mentioned in the beginning and packaged it in a fmu so we could link this to to containment form just to show you how this looks like in reality we have the again coupling dictionary in open form we have this um simple system model which solves the constitutive equations the balances and all some initial conditions we put this together at a coupling interface and um and then through in this validation example a transient where um uh let's say steam non-condensable gases are perched into pressures of pressure system and if you look at the results um in particular in the in the pressurization here we we see the phenomenology we were expecting a pressure increase when the non-condensable gases are perched and a slower pressure increase when more or less only steam is perched which can condense in the uh in the water so this is a really flexible way of doing things and it will be the future where we go we will try to package this recombiner model also as a function mock-up unit and focus more on getting additional system models into container with this i have a few minutes left to to show you um how to get started with containment form what are the um the resources available which kind of helper tools we provide you and then i will conclude for today um if you go to the repository you will find all those things typically used for software engineering it's a version control management you can jump back the different versions we did see what we changed um it holds a continuous integration environment so we are running test cases every update we do to make sure results are not changing there's a ticket system you can use in case you observe problems you can also send emails of course um and if you want to get involved of course we can get you in via um using your github account um we put a lot of documentation into um markdown files so it holds links to uh source code links to examples figures and so on showing um the uh solver the governing equations we are solving are some details on the models um some technical modeling standard boundary condition types we are using material properties numerical methods references to our work um some useful helper tools we have some ideas on how to do troubleshooting um some ideas on what we are working on at the moment that may come up soon and also change log that will tell us um what was changed whether it was a minor change a major change that should require let's say some revaluation of test cases on your end or whether it was a bug fix that fixes something so this information is given in in the change log in a similar fashion um like Carlos showed yesterday we put all this together with some source code documentation on um a doxigen page which is also hosted in the repository so you can see this in line with the source code um and last but not least if you need information it's always a good way to to look in the header files of um of the models you will find again literature references here a kind of representation of the equations that are solved and so on um looking at the test cases you will see they are organized in a similar way like the models so we will have more or less for each model a specific test case there is a run script often it's called all run sometimes it's called run case when it holds some specific arguments to to specify the case there is some reference data post processing so you can easily walk through this process to get an idea on how to use the features and test the code um yeah last word on if you want to contribute um please uh collaborate with us don't take the code create your fork do something with it maybe publish it somewhere else this will just dilute all the efforts and it's better to um to get integrated um in the team so first step is of course get in touch with us um check on our guidelines that we have for contributions um and then there are two ways either you share your code it will be integrated or you create an add-on to containment form that we can link um and just refer to your own personal repository if there's a bug please get in touch with us um anything you feel it should be done in a better way is a very valuable feedback for us and also if you think there is some functionality missing for a specific case this would be also a good feedback for us briefly on two helper tools we have so i showed you that all those dictionaries they hold a lot of keywords some specifics for the models that we need to know and also put in the right uh right way so a lot of things have been done by people developing this for years and they put these keywords with a very specific purpose and it's not so easy to take the banana method just get the availability of all keywords and then put some this is um probably not the good way um the other thing is that if we look at such a case set up if we add a model for example um here it may happen that we have to modify several files and often if we forget one file this will not lead that the simulation will crash or not start it just may happen that the simulation is inconsistent incomplete and um we also see that everyone is doing somewhat was is uh his experience changing numerical schemes um and all these things so at the end comparing simulation that it became a very difficult so at the end our approach was to um to create a kind of guidance to to set up a base case this can serve as a reference for your own changes for your own things but at the end we always have a common setup we can refer to just to give an example here if you want to add radiation you have to specify different boundary conditions you have to go through the system code coupling um to add for example fork if you put this into on the model list so all these things can easily be forgotten and then you lack this term in the coupling so um just to say we developed this kind of guided user workflow to set up a case um it's a java-based thing simply since it's developed by software developing trainees who learned this from the very first day of their studies um which will guide you in a logical manner through this workflow so um at the end we have a lot of templated dictionaries behind that allow you to choose the one or the other model and there are a lot of rules that will help you to not do the wrong decisions and come up with an inconsistent specification so we have different ways to import mesh for multiple regions um we have templated properties or calculators that allow you to get the material data we have um model templates so that you can easily set up on the various models simple track down menus um all of this is done in a very consistent way to open form so that you can easily navigate between the dictionary file and these steps here we have ways to specify the system models so all these mesh manipulation for the burst disk it's done in the background um we have templates for initial and boundary conditions you can import CSV files table editors you can have global variables um we have a fixed set of um uh solver methods and um schemes and uh also some predefined function objects so with this it's very easy to create based on a mesh a case um and keep this as a reference for further um developments just a uh a trick here is um you can use a tool called meld or any kind of other um tool that allows you to div text and you can quickly visualize changes between these kind of reference setup that you created with the the GUI and the the version you developed on your own on this basis so it's good to keep this as a reference and come back later the last thing i would like to showcase is the solution monitor so in open form you will come up with a lot of text logs which are um really comprehensive but it's impossible to follow this on runtime so the thing we need actually um to go through the solver log uh the function output uh function object output the coupled code logs is we need some kind of visualization scheme and uh we put this solution monitor you see here which can visualize all this in terms of graphs um it can stream any kind of log even non open form logs uh are possible um it can have tapped a grid view um open different runs at the same time uh and we use some some filters or regular expression syntax to grab the information from those um those log files so anything that's not available here can be easily added and um make this a useful thing and there are a number of filters like a fast Fourier transformation if you want to see periodicity for example moving averages and so on that will help you to um analyze the results it now works also on remote systems using SSH you can stream the log files and um i think it's a very useful thing for any kind of simulation to to be aware what's happening while the simulation is running brings me to the end uh i showed you i think a quite comprehensive toolbox um that we developed for um any kind of containment phenomena in particular appreciation combustion risk aerosol behavior it's done to support experiments um to investigate in the actions of phenomena that we cannot do on the experimental side and also to assess effectiveness of passive safety systems it's um a tailored and well integrated model basis for the expected conditions if we go beyond of course we have to um extend this it holds physical models but also a number of um system models that we can use to to represent that feedback and um of course the future way will be to move away from this classical dry PWR containment towards smaller modular reactors which a bunch of new challenges and physics i also showed briefly summary of some best practices and um standard procedures that you can find on the repository within these tools um that will help you as a starting point and just to give you some task if you like to so there's no official hands on but i often mentioned this isp47 test case it's a let's say a fast-running transient you can do in one and a half day simulation time more or less i will share after this lecture the setup with you but um you will find the paper um on nED and uh you can easily set this up in containment form and run the transient if you're interested it's not too difficult using the GUI maybe 15 minutes to collect all things together and once run through and then one and a half days runtime so that you um can end up with some kind of evaluation like what i showed you that's it thank you very much okay thank you stefan for the great lecture perfectly in time also now we are open for the questions comments here and from online a few of them actually well one is the short one uh what tool to use for mashing um we have cf mesh plus so this is the commercial version of the open source cf mesh which is something like snappy x mesh but with an enhanced treatment for wall boundary layers so this is super important it has a um graphical user interface yeah it also has a graphical user in the face yeah is it a funny it's a good tool have you compared it like with tools from ansys or yeah i'm personally a isam user which is a very old tool but very powerful for structured meshes uh then i use for structured ones and for unstructured meshing i use cf mesh that's okay and i have another one um so your tool is is is extremely detailed and out there there are tools that are much less details like gotik and i feel like with your tool you have the possibility to transition gradually to have from a very accurate to a non-accurate kind of solution because in principle tools like gotik use a kf silent model on a coarse mesh which is something you would be able to do so you would have the same capabilities have you ever tried to do a kind of a study of using your own tool to transition from my accuracy to low accuracy i shouldn't see accuracy from low detail to high detail and see the effect of being detailed i think we we had this idea in mind but um we didn't plan to replicate uh gotik so at the end i think the the application case of such a tool is really having these details and providing feedback to coarser tools so um it may happen that we will integrate the one or the other coarse mesh feature to go a bit in this direction but i would not try to mimic the gotik approach in in containment form how different is the gotik approach because isn't it just kind of a coarse way of doing the same thing in the same equations it's k epsilon i think but okay they have a lot of empirics um for the i mean they use correlations for pressure draw for um muscle numbers a lot of things okay so i would say it's closer to uh gen form okay thank you we have questions from the online from masama ala that and first he asked if you will send the files to the drop to the drop box for sure i will do okay and like another question did you compare the results of a given simulation with other cv excellent codes like relapse as scud up if yes are the results approximately similar so have you maybe more extended about validation here here and there yes so i didn't show validation results simply since many of those experiments they are somewhat proprietary uh linked limited to a certain group so i i didn't add it on generally we um often compare among the cfd codes that i used and less compare system code and and cft code but there have been benchmarks um you will find some references for sure in the in the reference list where both have been compared and here and there of course due to the fundamental difference in the model formulation you will see uh that cfd will give some extra but um for generic cases like pressurization it's more or less the same okay thank you been in the radiation model actually we use uh this repeat the questions yeah okay okay i was asked how we do the mapping of the mesh i have to scroll back to that specific thing here so it is a similar thing like what the car looks presented yesterday so we have two different meshes one for the uh for the fluid flow and one for the radiation transport and in radiation transport we know that the gradients are far less steep than uh they are for the fluid so at the end we can use a much coarser mesh and then what we do is we will use the building mesh to mesh projection in uh in open form to transfer the information um let's say from the fluid side we give temperature pressure and mixture composition to the radiation mesh we will evaluate the spectral properties of the media and we transfer the the source terms back so yeah exactly excuse me excuse me it's it's 3d 3d yeah so it is 3d 2 3d mesh mapping for different uh um phenomena like uh fluid to radiation yeah not 2d 2 3d mapping you do that also 2d 2 3d some please mesh mapping either 1d to 3d when we do this system coupling um or 3d 3d here for the mesh to mesh mapping but 2d 3d i don't have an application any other questions i think there were a lot of details i i hope at least you you got some idea some flavor of of what is possible and uh i mean all the details you can of course see in the source code you can go through all those slides actually i skipped and uh of course come back and ask questions okay so saying i have also questions as i was just like do you is prepared i mean kind of applications we are doing also we're we're doing benchmark for sodium cold fast reactor for the containment accidents and of course it's different but uh theoretically i mean from the mesh point of view it's okay it's the same unless there is important sodium boiling and those types different types of boiling and so on can you extend or do can you and what about okay sodium cooled faster actors maybe more complicated what about bwr and fukushima type accidents with hydrogen production and something is it possible to extend that's actually what we're doing but with the uh simultaneous step on going down in scale for the smaller modular actors many features in bws like these linked volumes the dry well the wet well condensation chamber this is something we are we are currently doing for the smr's and they could also help for bws okay thank you any other questions or comments if not i'd like to thank you stefan again and we go we go for the coffee break now oh no oh sorry just one