 So, let's go ahead and go to the home directory here everything we have already in the source file. So, now the first thing is let's have a location for you to save your no solvers. So, for that let's create a directory. We have that one project this is this will take you to the source location of your user line folder. These are directly you want to go. And in there let's say I create folder of applications and solvers. Please make sure you don't do any mistake in line I mean in the spelling of this because later on then I get new test issue. So, what I have done is just created one new folder in my run directory. In my user directory I created this new folder applications solvers. And WM project source user directory is taking you to this location. Then anyone can say done yes. So, now that we have copied the solvers. So, let's copy our we are going to modify the icofoam solver. So, it's like incompressible solver and based on ISO piece of algorithm. And we are going to incorporate temperature equations in it. Okay, so you and P will be solved by piece of algorithm icofoam and we will add a new temperature equation. So, we will obviously take our maybe a stock solver piece of solver and then modify it to add the temperature equation. So, for that I am going to copy my from foam solvers foam solvers. I will copy incompressible icofoam copy it where we are going to copy it to our new solver location. That is WM project user directory applications solvers and let's say I rename my new solver as my foam. Any issue till here, copying this file done till here. So, let's go to this new location where our solvers are my foam. So, I will go inside my my foam and let's check what are the files inside this. So, this is very basic solver just the nearest of solver which has found the main directory create fields and icofoam see. So, the first step we will do is this replace this C file because our new solver will be my foam. So, I will move my icofoam C to my foam C. You need to make a new name because otherwise you will when you will run icofoam you will run your own solver. I mean, difficult to, I mean you will replace the icofoam previous which has come with 54. So, for that my foam C I will replace it. So, now let's go to the make folder. This is the I think previous tutorial also you have got some idea when you have do the turbulence modeling tutorial. So, let's actually we need to edit it right. So, the first thing we need to add it is in the make folder where you are setting the locations of your new files. So, here I will mine you for C file is my foam and executable will be in the user bin. And then we have this our folder is also named as my foam. So, please make sure you make these changes to files done someone. So, okay, so let's take it once again. So, we have we have not modified anything yet. So, let's do wmech so that we know that our new solver is ready. If I do wmech it will compile this new solver depending on your system it will take some time. So, it compiled without any error make sure you are on the same page. I am clearing my screen give me a thumbs up or something so that I know people are following. Don't clear. Okay, don't clear. This you don't need this is automatic. I mean why you are worried. Okay, someone don't want to clear. Okay, carry on. Not bad. So, let's say inside this there is another pile and we are not going to modify anything but let us just see that folder. So, later on when you will have let's say you want to couple your say all area and some of us. So, there the time you may need to change your options. So, here you are actually you just see the create fields and one C file. But actually it is this options. We are actually locating all the files that are present in the source folder of finite volume include and mess tools on all the libraries in the finite volume and mesh tools. So, later on let's say you want to incorporate a turbulence model you need to source the turbulence thing you need to say Lagrangian multiple model. If you see those solvers you will see few more lines and you can you can estimate that how you are going to modify your own solvers whether you need to incorporate new things or some things. So, this is very basic thing we just need to add equation. So, we don't need to add anything else. I'm closing it. Okay. So, we have done that turbulence thing. So, now we can add it in the create fields. In this file what are the things I need to add? Can anyone tell me? I need to add a temperature equation. Come on. Not bad. So, I need to add a temperature equation. So, it will have a material property that is thermal diffusivity. So, for that I need to and here you can see the open form in this file. It reads the files so input output dictionary that is transfer property. In the transfer property it is actually reading already a user defined function which are defined value of dynamic viscosity. So, similarly I will add a thermal. So, I will just copy this and paste it here and let's say I rename this new variable as dt. And in the transfer property it will be read with the term dt. Dimensions are same as dimension of viscosity. So, I don't need to change in there. Here also look up for the term dt. These changes if you have made and you have incorporated and we have added the variable thermal diffusivity. So, this is an input output dictionary how you read take values from user one way to take define a variable. Now, let's say there is another way to define the variable. Density we don't we are solving incomprehensible. So, we don't need to worry about density here and it is not a dynamic viscosity. It is already a kinetic viscosity. So, let's say the other variable that has independent variable that we have already pressure and velocity. So, you can see the one is a scalar value and one other is a vector value. But you can see the syntax. Syntax is remain same. Just in the first line you need to define volume scalar value and vector value. Another is this the size and all in which variable in which mess you are defining the variable. These things are taken care over here. And then you have some options over here input output objects. This is needed whether to read the boundary condition and whether when you want to get the output. So, the first thing is if it is must read then it means that it will ask for a boundary condition. The other option is no read then it will it won't ask for the boundary conditions. And you auto write or no write. If you don't want to get save that as an output you can keep it as no write. And otherwise keep it as auto write. It will automatically present on your control field dictionary what to define in your control parameters it will write. So, what we are going to do is we are going to copy this because temperature is a scalar value. Let me copy it from the presser to the size. Okay. I am replacing the P with P. Yes. People followed. I am going to close it. So, we have added some new variables. One was independent variable T and one is like user defined variable that is DT. So, after that we I will go to map add actually and change what then add the equation in the my form. So, where I need to add this temperature equation. So, if you see here I mean before this this is the main file main solver run directly. So, this is the main function and before this it's like you set the initial conditions. You set the calculate the initial continuity error, create mesh, create time. So, set up your control parameters and set up your root cache file so that you can do the post processing things. And from this line your time loop starts. Can somebody tell me where should I add this temperature equation? Outside the time loop, where should I add my temperature equation? Here I have controlling the current number from that I am calculating the delta T. We are setting the new equation solving the new equation and this is the PISO algorithm. So, I will maybe in the slides I will discuss with all this PISO algorithm works. So, once you get the pressure and you equation. So, we are solving temperature as a specific scale. So, I don't need to be incorporated in that like PISO algorithm. After the PISO algorithm when I will get my UNB field I will add the temperature equation inside the time loop. So, that it solves at every time. So, what I am going to do is I am going to copy this every scale of function here. Paste it over there. But I need to modify this in this. So, it is everything at SMP. Something you can do famously and add before. So, FBN, DT. It is the DT term for temperature. And the MPM divergence term for temperature. The volume plus 5 temperature T. And that question. So, that question should be between the people followed. And then I will begin this equation as T equation. And I am going to solve this equation. I will give some time here people to add this term. Then I will save this. Krishna, can you repeat that my form is hitting once again? So, like the description of the solver that I said something. Yeah, I mean the editing that you did. Someone lost it. Editing only? Yeah. Editing. So, after this PISO loop I am getting my velocity and pressure field. So, and I want to solve my temperature equation inside the time loop. So, before this run time and after getting the velocity that this PISO loop is ending in this passage. So, after that I have added this temperature equation here. You can see. This is the non-orthogonal loop. And before that it is the PISO correction loop that is ending over here. So, after that I am writing the temperature equation. There is no source term in this temperature equation for simplicity. So, in this I am solving the temperature without the coupling. So, if you want to do the coupling then I think you need to add a source term in your U equation. Here you will come with a function of t. And also if you have added something here then you need to take care of that in here also in getting the fluxes here. So, that modification also you need to do. And then you will have a coupled velocity and temperature function. Solver. So, if okay then I will close this file. Good. So, I have added these things. So, I have done the modification in my solver. So, let's do the loop and compile it once again. So, let's see. There is no error. I am hitting the problem. I am clearing it. So, from here now that I have made my new solver I need to define a new case file. Hello, Mr. Krishnan. Yes. I am getting an error. What error? Erase, permission denied. Okay. So, then you might have the app user being there. You need to modify it. So, the main folder, the files. Here you need to make it own user app. Make sure you are too distant. Can you please zoom it a bit? I mean I am not going to. Yeah. Okay. One second just. Thank you. Good. So, let's go to the run directory to make a case file for this new solver. So, now I am in the run directory. So, I will again copy my cavity case and modify in there. So, I will copy it from point to point. And let's say I copy it to my cavity. So, let's set it. My cavity is there. So, let's go into the my cavity. So, what are the things that I need to do here? Can somebody tell me? So, first of all, I have defined a user defined function that is DT. So, I need to define it somewhere, right? But let's see. That is in the constant property file. Constant transfer properties. I need to define DT term here. And the dimensions are going to be same as me. So, I am taking that previously. And let's say previously, in the previous case, I have followed it. So, I keep it 2e minus 3. But let's say, I mean, in the previous case, I have not make those changes. So, for me, I will do this 4e minus 5. That was previously when I run the cases 4e minus 5. Okay. So, and then I need to change this to DT. Okay. You people followed at this line? Yes. So, I think you people did this, right? So, what are the changes again I need to do? Can somebody comment? I have defined a new equation. T file, yes. Other than that, we will do that later. Other than that, I have defined a new equation. So, for this new equation to solve, I need to define the boundary conditions. Okay. I need to define the schemes and solver also. So, to do that, I will go and take my schemes. So, what I need is, I have defined a divergence term for temperature. So, for that, I need to copy this. I have this IT term in my equation. So, for that, it is this. And let's say my divergence scheme for temperature will be okay. So, after this Laplacian scheme, I don't need to, I mean, I can define separately Laplacian DTT. But by default, it is Gaussian and orthogonal. And for all the Laplacian's command, it will take that orthogonal. And that is what I want. So, I don't need to add the Laplacian scheme here for temperature. So, let me close this file if you guys have done till here. Yes, no. So, after this, I need to define a solver also for this solution. So, the new equation, the algebraic equation that will be created, I need to define a solver for that. So, for that, I will copy this new whole command, do this here. So, the T equation will be you solve this set of commands, smooth solver, a smoother. Let us replace it with Gauss-Seidel. Okay, rest of the things say as it is, I think I need to define the final. So, I will do that. If not required also, it won't harm also. So, the final is defined. This changes if you have done. Then I will close this. I have defined a solver for temperature equation. In notepad typo, so open form, I mean notepad won't know what you want to type. So, the typo error type and all those things, I mean once you will be like getting used to it, use it frequently, those things won't happen. So, don't worry about that. So, I am saving this. So, now boundary conditions that you just told me, I need to define that. I go inside the zero directory. And here I have this U and P file. So, I will copy this P file to a T file. So, that I don't need to create P file again. So, just a little modification I need to do now. P file, not required. So, what are the changes I need to do? This looks easy. P should be T. After that, dimensions. Temperature equation. And it is like the previously that without source term that we have done the case. So, let me keep the boundary conditions same as that. So, I will define it as 300. I will define this as its value. So, I will keep some time here. If people have done, I am okay. Everybody following? Yes, sir. So, I will control it and I have not done any modification, not required. So, I will run the case now. My phone. Because the new solver is named as my phone. So, to run this new solver, the new command will be my phone. So, okay, the time question and time also is different. So, maybe we won't be able to compare it. But still, so, you can see that we have this solved for the, you know, solved for the temperature equation. So, like that, we will do this. Check it in the paraform. So, like this, you may just touch my phone. Especially like this in temperature. So, I think I made a mistake somewhere. The temperature of I should not come like this. Can anyone guess where is the mistake? I think I should change the solver itself. You don't need to repeat it. The process is done. So, let us see if I do this change what will be the result. Meanwhile, if you people have any doubts, you can shoot on me. So, I just made the modification of Laplacian term that is negative to positive. So, those changes, let's see what will be the result. Did it other result? It is overwriting. So, now you got the procedure right for how to modify it in all temperature. Adding equation, user defined variable and adding equation. So, maybe I need to like check once again what is the equation and all. But this is the overall procedure. Let me just go in order. So, the previous term was on the right anyway. So, you have created the solver. Let me show you some of the links of the quotes. Someone is asking me why didn't you change the control dict? My application in control dict. My application because I am running directly through the command. You need not to change it, right? You need not to change it. If you want to run it through the shell files that you create, all run script files, then in that you use underscore get application. So, if you want to use the script file, then you need to read that application. There you need it. So, I have some glimpse of other quotes that you may, I mean you may find it anywhere in the CFP of your domain and all, but it will help you to accelerate. So, how you can do your coding like the first thing you need to a cell loop. So, in here you can see how a cell loop is written in your code, how a face loop is written in your code, and how you can loop over the cells and the faces inside it. So, that is the code. So, you will have the video. So, you don't need to save it or anything. This is how you do it. Already in the previous tutorial, people have defined how you can use a different function but I also included it. But let's say you have some mathematical functions inside your boundary equation then to include those functions, then you need to make, then you may use this snippet of code. So, this is a sample of that. Any questions you can ask? So, let's say another function that I want to write is to, let's say I want to get an output function. I want to get output of, let's say, kinetic energy of the system and also I want to get the dissipation energy of the system. So, in here you can see that the first line is actually when you have parallel processing then you use this to get the total number of cells from counting all the processes. So, the total number of cells will do the summation of the velocity vector field in parallel and you get an average reward. So, some examples only the motivator just show you some examples of how you can proceed and how you can do these things. So, that is my motivator. So, to show you, you can define just inside a volume new scalar field where just inside the code itself, you're going to slip through also in the volume of the scalar field and you can use the U component X component to define the new variable U X, U Y and then you need to know that once you copy, once you get a gradient of a scalar field then it becomes a vector field. So, to say that you need to define the volume vector field, similarly to get the magnitude of the vector becomes a scalar. So, some steps are that I am showing you here and a cell loop to calculate the kinetic energy of all the cells and the dissipation energy of all the cells. And this is a two phase flow. So, it is a problem with the volume fraction alpha and one-one cell flow. So, and then I have to save that first. So, let's say if kinetic energy to, I have already in the cell here, I have already defined the pointer for kinetic energy. So, this is the snapshot of how you can get the output in a file with the file name, let's say KDAT. Just inside the time loop if you can keep it at each time step, you can get something. So, this is not big thing. It is small itself. It may accelerate your work other than this. I need out if you people are having, then you can ask. I can show some more quotes. Let's say sometimes you need, when you define the equation dimensions, open form was with dimensions. Sometimes in your equations, you may need to change, add a dummy variable, which will change the dimension of your equations. So, let me show you how you can do that. So, here I have my solver. This is middle form. I will show you in the create fields. So, let's say here I have this, how you can define dummy variables. So, let's say beam change in this color. So, this will be of dimension length. Otherwise, you can in the bracket inside, you can define all the fundamental dimension and define a new variable with even dimension. So, once you, how you will modify it, let's say on your equation. So, here you can see that I am adding the dummy variable because my level, this is the equation for levels such as colorful or multi-phase flow. So, for that, I am adding this, because the gradient, it is delta T, the grid function, it is multiplying with the grid function, but the variable is non-dimensional variable. So, I need to divide it so that the gradient and the multi-designed will lead up to a non-dimensional variable. So, this is one way. I mean, very frequently, actually you need to do distance. As you develop the solvers. That is a given name for my solver. That is, I am just showing you, it's not mean for you to do it. That is my customized solver, you won't find it. So, if anything you may ask, or I will ask. So, then we, I can show you how to define, what is your algorithm? Now that I have time, then I will describe it. So, in the equation that you see in the, the first equation, the first thing that you see is the u matrix was solved. So, in that, it is defining the matrix without the pressure term, which will lead up to a matrix form of this. And very frequently you will see terms h by a and all in all the incompressible solver at this, which is, h is here is the residual part, which is the source term of the equation, minus the non-diagonal terms of the, from the matrix of the u, which is defined as the h. And h by a will be the diagonal term of u, when divided by h, h by a is there. So, to solve the u equation, when you solve it, you add the source term and you get a predicted velocity field, which will be solving this h by u minus a diagonal term of u. Okay. So, and then in incompressible flow, I think you all might be aware, like we have this continuity equation, which converts to the pressure and equation for pressure. And it comes from this equation, but when you do the integration of this continuity equation, then you control volume, it changes to a divergence here. And the sf.uf, where then the predicted velocity field, if you keep that uf, which will be interpreted from the velocity field, calculated previously. So, if you do that, and then you will get the Laplacian equation for pressure, which will be solved in the p equation. If someone has doubt, they can ask, if someone is asking you, can you explain the part where you edited the minefoam.c file to add the t equation? Okay. So, let's go to the location. So, here, I mean, here you see the time loop is beginning over here. And here I am defining the u equation that I said without pressure term, it is defined over here. And then we have, we solve the equation with the adding pressure as a system. And then first of all, I get the ap, like that is the diagonal term of the u equation matrix that is stored in here. And then this is the h by a term. And then we calculate from this vector field, it is just a velocity field. And then we calculate it as flux, pi by a and u on the temperature. So, after further solving of the non-absorbent part, non-absorbent loop, and the piece of loop is ending here. So, I am adding temperature equation here. So, that it is inside the time loop, but after getting the velocity and pressure field, I can start. Yeah, this is it. Here, we are making somebody sometime ask, like, why, what is the error that it is representing continuity? So, this is a file where we calculate the continuity error. And it should be less than power minus 8 or as less as possible. So, your system is stable. Any more question in this? What is this FBB flux is doing? Can somebody tell me? So, the flux is nothing but u dot s of vector. So, that is what it is doing. And once we get the flux, again, we have this term here. And that is for, like, say, because you are interpreting the points velocity field to the phase velocity field. So, the interpolation has some errors. So, to reduce that error, we have this additional term. At this file, constant pressure, these are two of the various boundary conditions to remain stable and consistent. So, we need this term, this one here, that you remember sometimes, like in the fluent, we define the external pressure field. So, that is what also is defined in open form. Also, that line is over here, equation set reference. For the given reference cell, you define the reference value. Flux is calculated after the pressure correction step and the velocity level. So, I am closing it. You can even have any question. Then I am here. You have to search it. You can spend some time. Actually, you people are doing great for the TDA workshop, but to get the glimpse of all the solvers, you need to spend some time and read some tutorials, some files. Like, Chandan Boussar has shared some links, right? You can go through the links. Other platforms are here, the online, and then open form, it has its own user guide. So, you can go through that and then you will get the idea of solvers that you want to. You can put your instruction manual to write our own solver. I think Chalmers' website is a very good starting point for the basics to start your own development part. So, you can go through that website. They are giving a lot of tutorial on how you can merge one solver with another. And of course, I think it will be a strange problem that you have the solidification part. So, I think most of you have the question like which solver to use and to get the idea of which solver you need to work on. So, actually you can just in the open form website there is a description of all the solvers, basic solvers, what it does, and from that you will come to know. The actual answer to this will come with experience and related to your topic experience. It will be a plus if you have the better understanding of C++ but to do like basic amount of coding like depending the user different condition and some sort of report you can start doing it and once you start doing it you will automatically learn. So, start doing it and you are good to start and basically with little knowledge you are able to start. Reference regarding solver beach solver, I mean there are a lot of references for a lot of solvers. User open form user guide will be a good starting point for all of you. Okay, I will share that link. Yeah. I think which actually this gives the description of all the solvers I will share once this presentation my session on this. So, I hope there are no more questions so we can take a tea break of 15 minutes. So, please come back by 3.40 then 3.45 we will start with Mr. Divesh Bariya's session.