 z praktykno tradukče in vsega začočnja, na serega odličkega vrstva in vsi začočnje. Do vrstva. Čaušenje. Čaušenje, Vladimir. Tako, nekaj prezentacija za vsega lektu je, da je vsega zelo vsega in kako modulati problemu in vsega vsega in vsega in daj imač sem operaj. So, for the people that are already, let's say, well-skilled, sorry, this will be quite very basic lecture, but I think it's good to have a common background. So, the objective of the lecture will be – we'll just give you a brief overview of the reasoning why we want to do multi-physics in modeljenje in simulacije. Danes izgleda smo na metodologiji, ki smo v nuklearne inginerje vsega, tako, kako je zelo izgleda problem, od vsega vsega vsega vsega, od vsega vsega vsega vsega vsega vsega, tako, vsega vsega vsega, kako so zelo izgleda problemem in zelo izgleda skratenje numerika vzela, ki smo vsega vsega inginerje, tk pa začeli smo vsega dramatija, načeva druga inginerja, zelo, kako brzišimo problem, da smo vsega vsega problem, tako, da smo na bilo synetistik formu. Stajem izgledati, in vznemo do vznjenju na vsočenje vseh, in se zelo, da jel je vseh, prej zelo, izgledajte idej, se pa bo nekaj, oče počet, da se je izgledaj, nekaj, da se je izgledaj, nekaj, da se je izgledaj, nekaj, da se je izgledaj, nekaj, da je izgledaj, nekaj, da je izgledaj, Taj lektor je nekaj vzvečen, da se prihvali v počke na pd solično, finitivne volume, metode in so ono so počke. Taj leko se prihvali vzvečen, da se vzvečen, da se počke nače, da se vzvečen, da se prihvali vzvečen, da se prihvali vzvečen. When will try to make a link between a little bit of few and which parameter are the input that you have to provide to open form to solve your case. And then we'll see the financial structure order where to find a question in your solver, parameters, the boundary condition, the initial condition. You will see just from here da njih nekaj karakter, nekaj elementov vseho modelat, v tem izgovoru, ki vam prezikaj nekaj zelo izgledne problem, in v tem, da je kaj, ki sii jel tjeli ljubi izgledne problem vse. Danes se zelo se začetiti in nisi zelo se pričevalo in nekaj poslutiti. Tukaj je to, da je izgleda modeljnega in izgleda modeljnega in izgleda za nukleara sistem. V klasiku vihljeg je ovo načinoma nukleara, je to dobro. To je zelo zelo zelo zelo znacil, zelo nožite. Nuklearna zelo plana je najbolj QUARTA. Nuklearne vse sve prana všeč, načine ki je vse komponent, nekaj nekih komponent, nekaj nekih rečev. Neutroniko, nekaj termolithik, nekaj elektrija inginering, nekaj mekanika inginering. So there are not just only multiphasics, but also multiscalys, if you think about the different scales in time and in space that you need to consider for modeling the nuclear system, they span a quite huge, let's say amount of decades. So, at the end of the day, when you want to simulate a nuclear system, should be able to simulate from the neutrons in the core to the electron that are delivered to the grid. And this is for sure something which is complex. And when we deal with complex system, the first questions that we want to answer is how to study nuclear reactor. They want just to quote to statement. najbolj srednik je, da je izvanja, čečen, simple in dobro. In druga je, že čečen eštečni zelo prezipa. Kaj so pričeš, da se prišli površanje, najbolj, da se prišli površanje, ne kako se prišlo, kako se prišlo, in prišlo površanje na pravko razvoj. In vse, da sam ga izgleda, prizaljo se, da sem tudi nekaj zelo, da bilo ima vse prav, ne za kajštih, da je saj vso, da je za kajštih, da je za njiho. In na samih pravi, da se je zašal, da je za njiho, da je inšta, ne za kajštih, da se nekajnih se zelo, da je to nekajšta. The first thing you have to ask yourself is which is the purpose of my analysis, what we want to know about the problem, and then which are the limits of the analysis approach. Every approach, every methodology has some limits. This is totally okay, but the first thing as a nuclear scientist that you have to realize is knowing which are the limits of your analysis. So this is a simplified sketch and simplified picture of the, let's see, the two sides of the apple of the reality versus the model. So on one end we have our system here in which we can do some experiment and try to get some experimental result. On the other end we can try to model our system, try to perform some simulation in order to compare the simulation with the experimental result and try to validate our model. So in general the advantages of doing, why do we want to do a model and the simulation activity, usually it's because we want to, or design, especially if you think about generation for reactor, these are a system that doesn't exist up to now, right now. So we need a tool that allows us to design this kind of system or to analyze the system. So increasing the understanding, the optimization of the system, safety and control are all some tasks that we can do thanks to the modeling and the simulation. On the other end we know that modeling and simulation has some advantages especially compared to the experimental results. So experiments usually are expensive, dangerous and cannot be performed on a system that cannot exist. You cannot, let's say, be scared to reach a multiplication factor greater than one with your simulation. Then the other great advantage is that we can, let's say, take advantage from the time scale. Let's think about barnap analysis. Barnap analysis may take in real, let's say, for real time years to be performed. With a simulation you can shorten this time. You can also access some variable that usually you cannot direct, let's say, directly. For example the reactivity. There is no reactivity meter in which that you can put in your reactor and measure directly the reactivity. But with a model you can extract this variable. So there are for sure some advantages in doing modeling and simulation. On the other end we have to be aware of some critical issues. The first one is that you don't have to fall in love with your model. A model is not the real world, is still a model. You don't have to stretch the reality into the constraints of a model. Once happens to me to discuss with one of my students that was a simulation of a boiling channel in which the bubble, instead of rising up, they are rising down. So he tried to explain to me, yes, they are rising down because there is this phenomenon, this phenomenon and so on and so forth. And then it came out that it's just basically get the direction wrong of the gravity. So let's try to avoid to force the reality in your model and try to analyze the results of your model with a critical way. The other two possible issues are already been mentioned. So forget the model's levels of accuracy. For example, you cannot calibrate control road with a point kinetics approach. But this does mean that point kinetics is bad. This is simply not the work of point kinetic analysis. The last one is also very important because especially in the recent time in which we have a large availability of the computational resources, they are still not unlimited. So you have to carefully calibrate your analysis to comply with your computational resources. It's quite clear also from this, let's say, overview that in order to tackle the modeling and simulation we need to start from the physics. You have already seen this in the first lecture in which in order to derive a solver before deriving a solver, before, let's say, doing some numerics you have to know in a quite good way the physics behind the problem. Without knowing the physics behind the problem you are not only, let's say, missing some point but you will not be able to correctly implement the numerical part. And this is clear, this is especially true when we talk about multi-physics. I reported here a quote from Wikipedia actually I found that this is an old one luckily for us because I think it's a very bad definition of multi-physics. The multi-physics was defined as a computational discipline which treats simulation that involves a multi-fold physical model, blah, blah, blah. This is not true. Multi-physics is not just a computational discipline. The multi-physics is really the study of the mutual interaction of different physical models. So before talking about simulation we need to analyze the physics. And especially for a nuclear system this means that we have to consider if we want the fluid dynamics, so the coolant, the fluid dynamics of your coolant then they transfer from the fuel pin to the coolant, the neutronics, the problem related to the mechanics, to the chemistry and so on and so forth. And most important, your purpose as nuclear scientist is also to decide which are the phenomena that are more important in your analysis. You cannot just take all this physics put in your solver and that's it. So this is really your work in order to decide and to discriminate which are the most important physics which are the one that you cannot neglect or not. This is very important if you want to and really implement something that is reasonable. So let's start with some questions to you. So you have said that more or less you have tackled the problem of modeling a nuclear system problem. So which are the steps required to model a nuclear engineering problem? So you have a problem, let's say Karlo mentioned that we'll have the exercise on the molten salt fast reactor. So if you want to study the molten salt fast reactor which are the steps that you have to take in order to study it? Question for you. I will say physical parameter, right? OK, boundary condition, then assumption, machine tool, so I'll put here. Thank you. What quantity I want to calculate? OK, the variable of interest, OK. Numerical solver, that's good also. So we said, yes, good. You are a good student. Numerical method. And then we put here thematical. OK, so basically when you will perform an open form case, an open form simulation you will follow this step. Nothing more than what you have just said. So I will need the physical and mathematical modeling. I need to which is the modeling approach for my problem. Should I calculate the PDs and the CFD good for my problem or not? Which kind of assumption should I consider? I will neglect the thermal part. I will consider buoyancy effect or not and so on and so forth. And this is the very first, let's say, step. Then we have the domain modeling. We will need to model the object of our simulation which will be to create the geometry and also the mesh. So the third point is the domain plus equation discretization. We have already said that for our problems of interest for the majority of the case unfortunately we are not able to have an analytical solution. And especially we will not have an analytical solution with a complex geometry. Probably for sure we know to solve, let's say, heat equation on a cylinder, heat equation on a square. Unfortunately we cannot have an analytical solution for the free dynamics in the multi-soul first reactor. So that's why we have to, let's say, call for the numerical modeling. And the numerical modeling will require the domain discretization. We will need to go from basically an infinite number of degrees of freedom to a finite number of degrees of freedom and then we will need to discretize the equation. We will need to divide the, to apply a numerical method in order to solve the problem. At the end of the day the main, let's say, work of a numerical method is try to transform the partial differential equations that are governing the mathematical modeling in some linear set of equation. Then the first step is the solution of this discretized equation. I have the mathematical equation, I discretize both the equation and the domain, I get a discretized set of equation that I need to solve with some linear algebraic equation. And that's it. I almost finished actually my work because then there is the fifth one, which is the post-processing. Once I solve the problem that I need to visualize the result to understand and to find the behavior of my quantity of interest. Actually, this is useful in order to understand the two, let's say, element of an open form simulation. One is the solver, and the second one is the simulation case. The solver will be, let's say, will be needed for the physical modeling. In the solver you will find all the, let's say, instruction to solve the PDs. This means that you can, let's say, take advantage from the solvers that has been already prepared from other people. And as we have seen, this is a huge advantage and a huge plus for the open form toolkit. On the other hand, for the simulation case, the other, let's say, step are, let's say, devoted for the simulation case. So, for the system that you want to study, you need to create the geometry, the mesh. Luckily for us, the equation discretization has been already done by open form, but then you will need to probably provide which kind of discretization scheme you want open form to use and which kind of linear algebra solver you want open form to use. But if you have linear PDs, then you get linear... If you are solving Navier-Stokes equation, you will need to linearize your equation, because we are very good to solve linear problem, but we are very bad to solve nonlinear one. So the only way that you can solve a nonlinear problem is just linearizing it and then iterate on some loops. We'll see also this. So, actually, as already mentioned, this is something that you have seen in the previous... In the previous lecture, we'll have the geometry, mesh, setup, solution and post processing. And this is more or less the same, let's say, work path. So, once again, we start from the physical system, we'll need to choose the proper modeling approach, which is the solver, we'll create the geometry, we'll create the mesh, we'll apply some numerical methods, we'll apply the initial and boundary condition, we'll decide to which kind of linear algebra solver we are using and that's it. Let's try to make an example. So, this is an example, which is taken from this book, which I personally suggest. This is very, let's say, useful, especially if you are tackling for the first time CFD and openform. So, let's imagine that our problem is to study the transfer in an electronic device. So we have this electronic device, in which we have the microprocessor, need sinker to evacuate the heat and then the copper base. Our aim is to try to understand, from an engineering point of view, our aim is to try to understand if we are, let's say, exceeding some temperature limit. So this means that we need to know which is the temperature distribution in the copper base. We'll know that probably will be higher here because there is the microprocessor that will produce some heat, but here there will be dissipation, so there will be something in the middle. So let's try to understand which is the process in which we can get the solution. So, first question that we have to ask, how do we model the heat transfer? Sorry. I will define firstly the physical phenomena. It is force convection or natural convection or radiative convection. Exactly, so we need to define which are the physical phenomena. You see that once again, so, which is your suggestion here? Which are the important phenomena that should be considered here? Basically, I will rank force convection as a first phenomena and then conduction through the BCB solid part. Ok, right. Probably if we are talking about a normal computer we can get rid of the radiative heat transfer. We are not at high temperature to consider this, let's say, important. Once again, you could also consider the radiative heat transfer here, but it makes no sense. So, once again, as a nuclear scientist remembered to perform appropriate analysis not to overflow your problem with details or with physics that doesn't make any sense from a physical point of view. Ok, so, let's imagine that, so we have mentioned that probably with the heat sink we will consider force convection then conduction through the bases. So, let's imagine for the moment that we will just consider the conduction, so. Then what we need to consider. So, in terms of mathematical modeling, which is the mathematical modeling for the conduction. Discoritize and solve the heat conduction equation. We have to know the amount of heat generation in the source and the amount of heat absorption in the sink and only the heat conduction equation. So, basically, from the mathematical point of view what we need is just the heat conduction equation with a source which is probably due to the microprocessor. And that's it. So, once you have identified your mathematical problem, the second, let's say, question that you have to ask yourself is, ok, let's see if in open form someone else has already prepared a solver that I can use to solve this equation. And you can have a look on that going in the main installation folder in the open form you will find an applications folder in which there are the solvers that are already available with the basic open form version. And actually, you can discover that actually there is a solver for this kind of problem. The open form expert knows which kind of solver we can use. No, it's more simple. What's the operator there? Ok, that's a good point. So, actually there is a Laplaciana FOMA solver that is exactly the solver that could be used for your problem. You can use also other ones, but, once again, you will overkill your problem without any reason. So, let's continue with the example. Ok, we have identified the mathematical modeling in the equation. We have also found the solver, then we need to go for the modeling, for the domain modeling. So, we need to approximate the real geometry. Once again, here we are dealing with assumptions. Especially if you are looking at a real object, then you have to realize that probably the best way is try to have an approximate geometry of it. And once again, here it's the process that involves you as a nuclear scientist. Try to understand which are the elements that you can approximate or not. So, the first step when you do the simulation case is to build the geometry. For open form, you can use an internal custom routine which is called block mesh. Or you can also use some external programs, some external CAD or other meshing, geometry and meshing tool and then import the geometry and also the mesh. Then we have the domain discretization. We have said, OK, let's... we have the geometry, but then we need to discretize the domain because we need to apply our numeric tool. And in this case you will need also to create the mesh, which is nothing more than creating these elements or better, this volume on your geometry in which for defining volume you will apply your, let's say, your discretized version of the equation. So, then we say that we need to discretize the equation. So, this has been, it's already done by the, let's say, the tools of the open form but what we need to do is to impose the right boundary condition and the right initial condition. Once again it's due to the discretization process. So, if you... if you divide your geometry in different meshes, then when you stop, let's say, your geometry you have to provide something, an information in order to, let's say, close the numerical discretized system and these are more than the boundary condition. You need to impose which are the condition at the boundary of your system. So, here we have the microprocessor, here you have the fun. So, for all the boundary you will need to prescribe a condition which could be a Dirichlet boundary condition so this means that you are imposing a value of the variable of interest, in this case the temperature, or you are prescribing a certain condition, for example, a Neumann boundary condition. So, actually you could also impose if you are not, you see that you cannot mesh the part related to the fun and to the microprocessor so I have decided to exclude them from my domain so if this is the case I will need also to impose some boundary condition here. So, which are the some possible boundary condition for my problem adiabatic so we can put adiabatic boundary condition so this is nothing more than imposing a nul Neumann boundary condition so this means that we are not, we are considering that the boundary here are adiabatic and are not exchanging the no, it's not it's like this, it's a gradient yeah, it's a gradient but we need to impose here also the boundary condition and we can decide to impose for example here a given temperature and here another temperature even if it's not really the case because we have seen that here you have the fun so in principle you should consider the let's say the forced convection but this is up to you this is up to the assumption that you want to to consider and that's it not sure but anyway, yeah this is a 2D in openform you can also do not only 3D but also 2D then in this case you will have to prescribe the empty condition from the bottom and the top if you want to just do 2D calculation or better openform always understand the geometry as a 3D if you want to do 2D calculation you have to impose the empty boundary condition in order to say ok, you are not solving the equation in a given direction the same solution empty is clever in the sense that it doesn't solve in that direction so you spare solving things in one direction in principle if you are solving a vectorial field imagine you are doing displacements and you have imagine you are solving for displacement and you have a component in the imagine that is the z direction the empty boundary condition is telling openform do not solve for dz, so actually you spare computational time but you would get the same with zero gradient you are just standard way to do is you do it with empty is the way in openform to say do not solve that this is a 2D thing you can even do 1D if you do empty empty empty but this is the standard way to do things ok, we have imposed the boundary condition the initial condition then we need to discretize our equation this will be up to the openform as already mentioned in the previous lecture usually this is the quite classic standard form and general form of your PDEs in which you have convection term and diffusive term what will openform do is just to discretize and at the end of the day a linear system a linear system that you will be able for better openform will be able to solve with different approach actually usually for linear system you can select iterative or direct solver I think that almost all the linear algebra solver in openform are iterative all of them this is mainly due to the fact that this this matrix has the more or less the size of your mesh element especially when you do a big problem this will be a big matrix that as already mentioned by Stefan will be mainly diagonal predominant and these are the kind of matrices that in which an iterative solver it's very good to find a solution so actually in a direct solver you just simply invert the equation on the other end in the iterative solver you will find an algorithm conjugated gradient preconditioned conjugated gradient that with several step will approach an approximated solution but you don't have to be scared of that what you have to know is how to provide the parameter for the linear system and then openform will do for you we have already mentioned that this is a simple case just one physics what about if we are doing multi physics actually as already mentioned in openform the standard approach is to do an operator splitting so I will solve one equation at time and then I will iterate until a full convergence it's obtained this is pro and cons as we mentioned but this is the way how to how openform solve the multi physics problem and that's why you will probably need to input to provide a value for in your simulation case these loops are mainly related to some operator splitting approach or some predictor-corrector approach or you could need to provide some residual control so at which level of error you want your simulation to stop otherwise openform will continue to iterate the calculation ok do you have any question up to now so if not let's just continue with a short overview on the finite volume once again this is just meant to allow you to understand which are the parameter that you will put in your openform case so, as already mentioned we need to deal with partial differential equation we need to discretize that and then the purpose of any discretization method is try to transform these PDs in a system of algebraic equation and for the finite volume this is simply made by creating the equation over each volume so vp stands for the finite volume so your mesh element instead of considering the global let's say expression of this you will consider the integral over each mesh element and then the finite volume has two main ingredients once again domain discretization and equation discretization so in the finite volume domain is divided in a control volume in which the solution is calculated by integrating the PD so and here you can see some let's say nomenclature p is the centroid of the control volume and it's the centroid of the neighborhood control volume d is the distance f is the control volume phase sf is the phase area vector which is normal to the phase with the magnitude equal to the area of the phase so, I mean by the way if you want to have a more sorry a more specific introduction you can have a look on this let's say material from Joel Guerrero which is very good so why we are interesting to let's say to this kind of information it's because then we need to to transform our our equation in a discretize one so, in the finite volume you have mainly two main hypothesis you have a linear variation in space and times this means that you can let's say calculate the value of your variable of interest at each point of your domain just simply doing an expansion over the center the centered value of in your control volume plus the gradient and the same more or less the same it's for the time these it's as the let's say the drawback that the finite volume can be just second order accurate second order accurate then the second step is the gauss or the divergence theorem which transform volume integral into surface integral so if we go here then we apply the gauss theorem and you can see that our volume has been transformed in a surface integral here and here so up to now this is an exact let's say manipulation of the equation but here comes the first let's say approximation will approximate our surface integral this is let's say a surface over the an integral over the surface will approximate this integral with the summation over the faces and you can start seeing here that your equation discretization will start to strongly depend on the quality of your mesh and the quality of mesh will be I would say it's one of the unknown of your system you don't know a priori which is a good mesh for your problem trial and error problem or let's say skills that you can get over years and years of simulation but here in practice the first let's say impact of the mesh so if we go from the surface integral to the summation then we get this value pay attention that here on the previous slide why you say that it's now mesh previous just okay here why the mesh plays role here because what I see it's exact it's exact transformation without any assumptions but here if you have a 3D let's say geometry this will be the summation over the flux will be not just the integral surface but the problem is here you don't know what is the value of this flux at the surface then there will be also another problem yeah in principle it's true that the equal is an equal there is no approximation and the trick is that that flux yeah it's not that and that's the linear approximation yeah but but I mean if we keep the the surface this will be no problem right? so the problem is that if you go from the stay with the integral here you will not have the face flux because you are not discretizing over the what it was saying is that once you decide what your control volume is and if your control volume is done in straight faces that the integral of that thing is exactly the summation of the fluxes over the faces so that part is exact the problem is how you calculate the fluxes this one what you mean by this one? the fact that here you are having the the value at the face flux and not the center which comes from the previous one actually in principle if you had the exact value someone gave it to you the exact value of the flux at the faces that expression was exact yeah I think it's a philosophical point because you don't have it when you do discretization but yes this is the problem then you end up with something this is the value at the face but then you need the value at the center so you have to need to connect these two two variables and especially for the convective and the diffusive flux for which you need a kind of interpolation from the centroid to the side of the face and here arrives the discretization part and then also the dependence on the mesh so you can think about to connect the value at the face flux with the value of the center in a linear way and then this is the classic linear interpolation or central differentiating approach it's second order accurate this is sorry for the convective flux second order accurate but it may create some oscillatory solution otherwise you can go just with a point which is dependent on the direction of the flux which is one order accurate it's bounded solution but it's diffusive so this means that you are introducing some numerical diffusion that let's say will pollute your numerical solution the same for the diffusive flux here it's quite important you can get again linear interpolation it's the classic one but then there is a connection between your mesh and the schema that you will select because if you your mesh it's not orthogonal so this means that the distance it's not orthogonal to the face so you add a corrective term in your discretization of the diffusive flux and this is something that you have to tell to open form through the selection of a specific discretization scheme otherwise you will lose something then you have also the time discretization classic one you can select an Euler explicit which is not I think it's not available in open form directly because it's very bad you don't even solve a matrix usually what you can get it's the Euler implicit or the Crank Nikonson one or otherwise it's usually very bad because you are using the old solution to go for the new one I think you cannot choose explicit but you will find open form solvers where explicit is implemented like typically shock capturing solvers for compressible fluids they are typically solved with the explicit solution the reason is that you have to use very small time steps and you have to do a lot of time steps and explicit solution can be much faster than implicit so if you look at solver called raw central form you will see that it is solved as explicit but it's pretty much hard code it's not using the keyword implicit explicit that you can find on the case folder Ahmed, please mute please mute your microphone so so be careful when you drive so then we end up once again with the linear system we say that it's a sparse matrix you can see here that actually these coefficients are related to the topology of your mesh so if you are doing a very good mesh which means a structured mesh this means that you will have also a good matrix to solve and this will improve your numerical let's say numerical property of your system so we are more or less so let's try to find where are the I don't know how much let's try to see which are the location so we have seen this methodology for solving a case then let's see how to find this in open form geometry and mesh for the geometry mesh you will find some variables some folder sorry in this constant folder so usually the classic structure of an open form case you will create your I don't know MSFR folder in which you will find in which you have to folder called system one folder called constant and the time directories so this means that you will have the zero folder which will see that will be very important the ten folder which contains the value of your variable of interest at t equal to ten second then you will have 300 and so on and so forth so the main structure will be like this system constant and the time directories so for the geometry mesh we will have the information in the constant folder so if you go in an already solved case you will find all the information related to the mesh but here we are let's say retrieving the same nomenklatur as we have spoke before so the faces, the neighborhood the owner, the boundary and so on and so forth so these will are the all the information related to the geometry and mesh then we will need to prescribe the initial condition the initial and boundary condition are usually prescribed in the zero folder of the open phone case in particular in the zero folder you will find different file many files are your variable of interest so for example this is the u file stand for the velocity so when you are solving a case which involves the velocity you will find a u file with start tool you will find a file like this so these are the typical structure of the variable of interest you will find the dimension this will prescribe the dimension of the field these are the seven let's see SI unit the first is kilogram the second is meter the third is second the fourth is kelvin and then the scandal I think there is a scandal there is the current then but I mean if you google I would say that the first four are the important ones kilogram, meter, second and kelvin then here you have internal field uniform these will prescribe your initial conditions so if you find this file under u this will means that you are telling open form that your initial condition for the velocity will be a field which is uniform and as x component y component z component equal to zero so everything is at rest then you will need to provide the boundary condition so for each boundary you remember your geometry you can also get the information of the boundary from this from this file so here you will find also the list of the boundary for each of the boundary you will need to provide which is the condition so this is taken from the cavity yeah no open form I will give you the chance to repeat the question give any boundary condition for the slip is there any default value no we will provide you we will give you an error so you will really need to prescribe the boundary condition and there is also a trick let's imagine that you don't know which kind of he is laughing he you don't know which is type which kind of boundary condition you want to input you can just type any kind of word here I don't know banana this is a classic example open form will provide you with an error but with a list of possible boundary condition and not all the boundary condition the boundary condition that applies for the velocity field so this is very useful if you are not sure which kind of boundary condition you want to input then you can have a look on the list that open form proposes you so for example this is once again taken from the cavity example and here we are imposing to the moving wall so the cavity example is just to the cavity in which you are imposing a velocity on the top let's say side of the cavity and then the moving wall is this one so basically here we are prescribing that our velocity it's a fixed value so it's a Dirichlet boundary condition we are prescribing the value of the velocity and the value will be uniform 1 0 0 so this is the x component this is the y and this is the z and this is the other for the fixed value walls type fixed value so once again it's a Dirichlet boundary condition but in this case it's set to 0 so basically it's a no slip condition and here we have the front and back boundary condition this is exactly the example that we mentioned before the cavity it's a 2D 2D simulation but you will build a 3D geometry and then you will impose on the front and then the back boundary the empty condition there's something about the banana method before it's not just about boundary conditions in general in open form when you want to figure out what keywords to use you can use that you write whatever you want and it will tell you like for instance choosing a linear solver you might not be an expert of linear solver you can type whatever you want and it will say look this is a nasimetric matrix these are the solvers you can use and it will list them so for any pretty much any keyword which is one of the reasons why at the beginning people didn't put much efforts into documenting everything in open form it's because people were using the banana method a lot no, you can use whatever you want you can use non-empty so for what is my mistake it will coincide with some real boundary condition that will be probably lucky because if you put a name that is consistent with a method and it works it's what you want it to have may I just on this point also explain the empty what is the empty boundary condition it's like periodical or zero derivative no, basically will not solve the equation in that direction in the z direction so actually the real geometry of this it's like that if you want to make it as 2D will mean that this face and the opposite one you will not need to solve for the direction which is entering in the blackboard there is a double action of this empty imagine you have a volume and you are doing your finite volume discretization this is just a volume not the geometry and you know when you do the divergence in the field inside say the vertices of phi you do the sum over the faces of area and phi basically do this face and the back face they are completely ignored they are simply ignored and there is another check that if you are solving for a vectorial field like I said before like a displacement field which is in 3 direction open form as a check and says if imagine this is z and you have empty do not solve for dz so you spare solving a field that you don't need so it's a double action of the pen do the keywords are categorized as optional and mandatory or usually there are mandatory keywords and non-mandatory keywords empty boundary condition is equivalent to the symmetry boundary condition in other safety codes open form as a symmetry boundary condition symmetry is a tricky one because depending on whether you are doing gradients and vectorial fields it can do slightly different things but the very fundamental difference is that empty will literally avoid solving for a field in one direction it cuts its off, it doesn't solve for that equation symmetry is gonna correspond more or less to a zero gradient more or less there is slight differences in the same for periodic so like physically the same but computationally the same it can be tricky because if you start from the physics and then you say I can use zero gradient everywhere no you can but it's better to use dedicated boundary conditions how in open form to assign differential equation to certain part of the mesh for example in other commercial safety code they could ask about this region is it fluid or solid or something so how to for example in this problem if we have two material between the same consort how to assign thermal conductivity in certain part of the mesh and another thermal conductivity for certain part of the mesh I think it's two different questions you asked equations and different properties so the different equations part well most of the time solvers in open form are dedicated to a specific physics so you solve just one set of equations except one solver that is called CHT multi region that allows you to solve fluid and solid you want to do more complicated things where you solve neutronics there fluid there and whatever you have to build your own solver you have to create your own solver this is how CHT was born we wanted to simulate neutronics and thermal hydraulics sometimes on the same areas sometimes on different areas you can do it but you will have to build your solver about the different properties that's the different story there is a standard way that we discussed in the next few days and this is based on something that is called cell zones basically it's like assigning materials in other tools cell zones are simply you have your cells and you attach a label a label to each cell and that label could be I don't know fuel and cladding and then you have a file where you say fuel should have these properties cladding should have these properties so this is the standard way and I think recently standard open found distribution was provided with termophysical properties that can be given cell zone wise so it's very similar to commercial no these are just the names of the boundaries could be as far as as far as you call them the same in the mesh in the initial condition so if you have a mesh where your boundary is called when you build your mesh you will build a mesh that has fixed walls as the name of the boundary if you call the fixed walls then in the initial condition you will have to take fixed walls as this condition so there has to be a correspondence but it's completely up to you how you call it thank you Carlo and I think that's it for the then we have the physical and the parameter so always in the constant in the constant folder you will find different files which are called something properties transport properties turbulence properties these are the files in which you want to prescribe your parameter for example the conductivity of the material the laminar viscosity for CFD and so on and so forth then you have the for the discretization the file in which you let's say provide the information of the discretization scheme it's FV schemes which in the system folder and here you will find all the let's say different pieces that we have seen before the scheme for the time derivative the scheme for the gradient you can see here Gauss linear the divergence for the scheme so for the convective dilaplation one you remember that I talk about here orthogonal orthogonal means that you are aware that your mesh is made of orthogonal elements so you don't need the correction non-orthogonality and so on and so forth so if you have a problem with the discretization scheme if your system your solution is becoming unstable one possible solution is to change the discretization schemes especially for the CFD this is very important and the solution is quite sensitive to the simulation scheme that you will use once again you can also use the banana method we took banana just for a void to take a correct boundary condition or a correct discretization scheme and you have also plenty of different discretization scheme but once again it's up to you to define which are the scheme the suggestions and the tips is just have a look on the tutorial cases and try to see which kind of discretization scheme are used for the tutorial one but be aware that this could be not the same situation for your case then the solver parameters you can find it in FV solution FV solution basically will provide you with the information about the linear solver Carlo mentioned the different solver precondition and conjugate gradient this could be I think this is the one used for symmetric matrices so if you have for example time derivative this is not ok open form will tell you that the matrices actually once again the linear algebra matrix it's not symmetric and so on and so forth and here you will have to provide the the information of on the tolerance once again I mean we say that we will use iterative solver so you have to say to open form to stop at a given value and here for example you are saying that ok stop iterating the solver for the pressure just the linear solver for the pressure when the residual of the linear set linear matrix for the pressure reach the relative residual of 1 to the minus 6 actually you can have also a relative tolerance and the max iteration so actually the stopping criteria are mainly three tolerance, relative tolerance and max iteration if one of each is reached basically open form will stop to iterate the linear solver actually in the FV option and then you have to provide this information for each variable that you want to solve in this case pressure and the velocity it's a standard laminar fluid dynamics problem you can also have some information on the under relaxation factor in order to improve the stability of your of your solution you may want to add some under relaxation in order to get converged solution this is the right place to put this relaxation factor then actually in this file this is once again it's FV solution file you will find the information related to the method for the Navier stock equation this is the piezo method which is used for the piezo form which is used for transient simple form which is used for stationary stationary problem we will go back to this piezo pimpol and the simple one then the last one is the control dict this will provide this will allow you to provide some simulation parameter for example the start time of your simulation, the end time the right interval it's every every thought second you will have the let's say the writing of the solution of your quantity this is not, it's different from the delta t which is the delta t it's really the time step for your solution then the writing interval it's the writing time time for which you get the solution and we are almost done let's try just to see so what we are missing is just the solver let's have a look on the possible solver structure so let's imagine that we have a laminar free dynamics problem these are the well known navistok equation you can see a possible structure for an incompressible navistok solver in pimpol form so once again applications solvers incompressible pimpol form and you will find this file usually the main file is the same name of the solver dot c dot point c and here you can really see which is the structure of the solver which will usually include different includes so different file that are useful for the solver but mostly will have the core of the solver as you can see here we have a different loop runtime so this is the loop for the time then you have pimpol loop pimpol correct but what is important here is to see that this is really the core of the solver in which you will solve the velocity equation and then the pressure equation and if we add a loop on the u equation you can really see that as has been mentioned before you can find the let's say if you add a look on the equation then you will find more or less the same structure here so this is the diffusive then the diffusive term plus the gradient p you can see that here you have fvc and here you have fvm that's something that you may wonder why but if you remember that we are solving just let's say in a segregate way this means that if this is the u equation you will just solve for u and p will be just a computation or let's say a constant term will be not in the ax equal to b here and everything for the fvm which is the m stands for the matrix and here you will find the known term so for the u equation the gradient of p it's a known term which you retrieve from previous time step for previous step in general then for the actually this is one of the first peculiarity so we are solving in some numerical and difficulties of the free dynamics you cannot solve actually if you have a look on the equation you will not find a pressure equation for the pressure so in order to solve for the pressure then you have to manipulate a little bit the equation so take advantage of the incompressibility constraint and with some manipulation you will get this which is the Poisson equation for the pressure so this is a little bit more complicated because it involves the way how the free dynamics is solved in this case for the pimple algorithm so I will so we have said that so in the previous if you have seen we have a different loop runtime loop pimple loop pimple correct and non orthogonal correction so actually these are four loop then other characteristic of this structure it is that there is a not at all straight way for the velocity and pressure coupling and we have also already mentioned the use of FVM and FVC this is mainly due to the fact as we have said before that the Navistok equation it is a non linear equation so for this for this reason it is quite difficult to solve discretize the equation and solve with the linear algebra so the main two problem is the non linearity of the convective term and then the second one there is no pressure equation that's why one of the loop that we have seen before it's due to discretize this term so we take one of the two velocity and we just simply take the first step that we have already solved so the unknown will be just this and this will become a linear term because the unknown is this one this is known and that's it then the second problem as mentioned is that we don't have the pressure equation so we have to manipulate a little bit the equation or better not the equation but the way how to solve the problem and this is another example with respect to Carlo mentioned you so not always usually you can type your equation directly in open form and it works but in some cases this is more difficult because if then you learn the numerics you will have to let's say you will realize that you have to face some problem the rich hole let's say interpolation to avoid the check board problem of velocity and for the velocity and pressure coupling and so on and so forth so be aware that it's not always straightforward to go from the mathematical modeling to the numerical one you may need some let's say some attention and these are let's say concentrated in the solver that will prescribe this this way to numerically solve an equation and this is the example of the of the pimple loop the pimple algorithm with the different loop the outer correction the momentum predictor and so on and so forth this is just to say that all these these are additional parameter that you have to prescribe to your solver so in the FV solution if you want to use the pimple form and then the pimple algorithm you will have to prescribe the number of outer corrector sorry the number of outer corrector which will help the convergence of the nonlinear terms the number of the corrector which are the one related to the pressure velocity coupling and then the non-orthogonal corrector which is due to formation non-orthogonality you remember the four loops that we have seen for the pimple one is for the time and the other three are just because Navistok equation are difficult to solve from a numerical point of view and then we need to iterate simple it's more simple it's for steady state calculation but also in this case we will have to to prescribe some some value for example the non-orthogonal correctors if you have a non-orthogonal mesh and then as mentioned before you can provide some relaxation factor in order to help the convergence of your solution and you can see here an example for the simple it's called dictionary so the information that you have to provide when you run the simple algorithma once again you will find it in the FB solution so it's just three minutes left right so some hints and tips you maybe are aware that there are two main versions of openform openform.com openform.org they are similar but they are not identical so and especially the portability between the two versions could be problematic so let's try to have a look on both if you have a very specific proven to solve and see which are the one which is more suited for you for this course we will use the openform.com the version 2306 then you can use your openform on Linux systems this is the native environment for openform you can also use MAC or the WSL app of windows they work well I would say but in general if you want to let's say if you are just performing some professional simulation just install your Linux partition and install openform on Linux then how to get the openform how many of you have already openform installed in your laptop ok quite a good ok we will see in the group activity so you can you have a lot of resources online also for let's say guiding you through the installation this is the example from the .org version but then you have also the the example for the .com version and here there is the link that you can follow if you want to install this is the main let's say structure of the location of the installed openform you will see application we mention a lot this folder because in this folder you will find the solver then you have sourcing which will be the main openform library then the tutorials which are very good there are also let's say a decent official documentation both for the two versions this is still improving through the time but just in case you can have a look on that if you have a problem there are also a lot of resources online just type and you will find a lot of educational resources this is for example an overview of finite volume method from Orville Yazak which is one of the father the openform there is the famous three week tutorial this is also very good for the beginners to start with openform because for each day you will be guided through a step step by step through the use of openform there are a lot of presentations for example from Wolf Dynamics very useful there is the book that I've mentioned before the finite volume method in computational free dynamics there are also the C++ guide in which you may want to dig a little bit if you want to improve your knowledge of the C++ structure of openform just some tips in we have already mentioned you have a lot of tutorials and lecturers just have a look on google and youtube there are a lot of master and pitch this thesis as also mentioned by Carlo and Stefan there are the forums not only for the gem forum but in CFD in general and usually you can have a quite good it's a communication with the solver developer so if you are in trouble and especially if you are using a customized solver just send an email to the main developer some other suggestions don't get frustrated there is also a way to let's say to get out with openform probably someone else has the same problem of you and he will be happy to help you don't get discouraged especially if you are get used to the commercial software there is a quite steep barrier to enter in the openform let's say world but then what you will learn through this let's say PAF will work the effort because then this will provide you let's say an approach and a methodology that will be also useful for other field and if possible do not do it alone this is something that we will try to do also in our course in which you will be divided in small group that will perform the assignments and that's it if you have any questions questions now and then we can continue after the coffee break everybody is ready for the coffee break we had a lot of questions during that I think that we will move to the other room it's up to we will see, let's try there are several options and one we want to split you in four groups but we will do now before the coffee break by the way and we will see if we stay all in the same room it's big one you can just one, two, three, four split yourself or like this one, two, three, four close to the power socket it's the most important for the high performance computing rules you need some extra power we will see, if not we have several other rooms that we can go and see but this here will have access to all our lectors and experts to go through now I would like to ask Kaleta, could you share maybe we should ask could we share on the big screens from Zoom excuse me could you help us to it works perfect, thank you hope you can see the screen Kaleta, please you can see here the group it's one, two, three, four we will just go through quickly and just please tell me that you are present so we are then Ali you are the second so the first Osama, Mohammed is not here that's you, the first one then Sherwine I'm sorry for now, wrong friends