 We're now going to solve another example problem using the Excel spreadsheet, which enables us to solve the heat diffusion equation using the finite difference technique and what we're going to do we're going to take a look at again a square plate. We're going to make it a little bit more complex than what we had in the last segment, the last segment of your call we just had constant temperature boundary conditions. We're going to mix it up a little bit this time and we're going to change the boundary conditions. The plate is going to be the same size so we're dealing with a plate that is 0.6 meters wide by 0.5 meters high and we will have a grid size of 0.05 meters and consequently in the x direction 0.6 divided by the 0.05 that gives us 12 plus 1 so 13 cells going across in the horizontal direction and then in the vertical direction the 0.5 divided by the 0.05 gives us 10 and remember we have to add one more and so that would give us 10 plus 1 cells that we have in the vertical direction. So let me begin by sketching out the plate and then I will describe the boundary conditions that we have around that plate. So what I am going to do I am going to color the first square orange just that we know where the upper corner is and then I am going to go across 13 cells. So there we have 13 cells I will color those orange and then in the vertical direction we said that we had 11 cells so there is 11 and now I will color in the entire plate. Alright so you can see it is a rectangular plate 0.6 meters wide 0.5 meters high and the boundary conditions that we are going to have on the upper surface we are going to have a convective boundary condition and on the right surface we will have another convective boundary condition with the same convective heat transfer coefficient and temperature and that being 25 degrees C and 100 watts per square meter. So what I am going to do just to color code and make it a little easier for us to remember what is going on with this I oftentimes like to color code the boundary conditions so that we can easily remember what we had there and we will do the same with that. That cell for some reason got colored so let's do a no fill. Okay so that is the upper and the right boundary condition now for the left boundary condition we are told that we have insulation so we have insulation over on this side so let's color code that and insulation I am going to pick fiberglass pink there we go and then for the lower surface we are told that we have a constant heat flux boundary condition so what is going on there we could have an electric resistance heater or something like that so that is hot or high temperature most likely so let's make it red. Okay so there we have all of our boundary conditions I am going to make that blue just to give us two there we go. Okay so we are interested in what is going on inside of the plate obviously and although I have drawn the boundary conditions on the outside really the boundary conditions are in these cells here because if you recall let me take a look at the picture our node the node where we are solving this is a convective boundary condition on a right hand surface so it would be perhaps a cell like that this node is on the surface and consequently the outer perimeter cells this is where we will be applying the boundary conditions when we build our excel model and then solve it so those are where the boundary conditions are so let's begin by entering in the values what I will do I will begin I always like to put a temperature at the starting point and sometimes the excel model has problems especially if you have a radiation boundary condition because when you paste in the boundary condition it will complain about a divide by zero error and by putting in these numbers I found that it actually alleviates that problem so whenever you use the excel model I recommend and not recommend that you need to do this or won't work put in these values and and then you can construct it from there so there we have our initial setup for this problem now what we need to do we need to enter in the boundary condition values over here and then find the appropriate cell and copy paste so what we're going to do let's begin by working these boundary conditions here and and here now another thing that I should say our corner cells sometimes if you recall from the last example where we had the fixed temperatures we just took the average between that wall and that wall when we were assigning the corner we're not going to be able to do that in this case and and so what I'm going to do I'm just going to assume that the corner because I don't think I have built any kind of boundary conditions that would have convection and insulation or insulation and constant heat flux or constant heat flux and convection so as a result of that what I'm going to do I'll probably just make that one convection I'll make this one maybe insulation and that one convection and then this one is going to be easy to do because that's convection on both sides so it's just convection on a corner but just be aware of that that you have to make a little bit of an approximation and your model will will have a little bit of error as a result of that but if you make your grid spacing really small as in all finite difference approaches the smaller the grid the better the solution that little error is going to be quite minimal and consequently it should not have significant impact on the solution that you produce but let's begin putting our convective boundary conditions in and we have to determine what material we're dealing with and and just for kicks what I'm going to do uh rarely in heat transfer are we salt or working with problems involving gold and so I'm going to say that we're dealing with gold and the thermal conductivity of gold is 317 so I'm going to put that in there I said the convective heat transfer coefficient was 100 so 100 watts per square meter kelvin delta x delta y that was 0.05 meters so we enter that there is no internal generation in this problem convective environment temperature in degrees c that is 25 degrees c so let's enter that and you can see when you do that you enter those values our grid grid values cells once we're going to copy and paste in they have all become populated now with values so what we now need to do is we need to scroll down and find the appropriate boundary condition that we can copy and paste in and the one that I'm going to begin with let's begin with this corner cell because that's kind of unique so let's scroll down and look for where we have an upper there we go so this one here is an upper right corner and what we do then is we click here and let's see yeah it is the upper cell the one that it pertains to the wording so top right convective corner I click there I can go in the formula box and it'll show us what it is computing that particular cell from and if we scroll up you'll see that it's also pulling in the values that we had up here for this particular problem so what I'm going to do let me do control c and I will paste that in here so you can see that it's changed color and it doesn't look as if it's done anything however in that cell if I go in the formula box you can see that it's taking in the values from in here for this particular problem and it hasn't changed anything because we said the external temperature is 25 and the initial temperature is 25 so there's no temperature differential so nothing's going to happen in excel as a result of that now let's work on these upper boundary conditions so there we go it would be this one right here so I'm going to click there I'll do control c and then what I'm going to do I'm going to copy and paste into that entire row and there we go and and you can see here it's doing something yeah the reason why it's doing something here let me click on that cell and yeah that's strange why it's starting to change there I thought it would have been 25 I guess it's because there's an edge effect and oh it's pulling in this cell you can't see it because that is pink but this cell is highlighted as well and we have no value there so when I said that there's going to be a little bit of an error you know what I should do what we're going to do in order to correct for that let's find the boundary condition for a left corner this one right here so let's click on that copy and we'll paste that in there and there you see it restores it back to 25 but that's because what it's doing is it's thinking that this is now a convective surface but it really isn't there's insulation there that as I mentioned earlier is a minor error in the way that the excel spreadsheet works now what we're going to do we're going to handle these boundaries here so let's look for convective on a right surface so that is this one right here it's right at the top so it's kind of an easy one to work with so what we're going to do we're going to click copy and then I'm going to control paste I'm not going to do the bottom one because it's going to give us that strange effect again for the bottom one what I'm going to do is I'm going to go down and look for a lower bottom right corner so I'll click on this one here and we paste in there we go okay so now what we're going to do let's work with these boundaries here this was all insulated and it was a left facing wall so what we need to now do is scroll down in the spreadsheet we don't need a second convective insulated boundary there we go so k we said the thermal conductivity we're dealing with gold so let's put that in delta x delta y point zero five and q dot there's no internal generation and it would be a case where we have this type of boundary where we have insulation on the left so I'm going to do a copy and then I'm going to go back up and I will paste in all of these cells and there we go and now the bottom one I'm going to look for the corner so let's look for insulation in a bottom corner uh yeah so what we're going to do we're going to assume there's insulation on the bottom we know there really isn't because that's a constant heat flux boundary uh but I haven't gone through and come up with insulated on the left and constant heat flux on on the bottom if if you're so inclined you could come up with all those boundary conditions but I did not do that when I created the spreadsheet uh and what I'm going to do I'm going to paste that one in and now what we need to do let's handle these ones these are constant heat flux from the bottom so we scroll down in the spreadsheet looking for constant heat flux it's not insulated uh constant heat flux with convection you know we don't have convection in this case constant heat flux boundary there we go and what was the value we were told it was 100 watts per square meter so I'll enter 100 there we said that we were dealing with a gold plate so 317.05 for delta x delta y there is no internal generation and so I leave that blank and now we look for the appropriate boundary condition it's this one right here because we have the bottom surface with constant heat flux so I click there I do control c and then I go up there we go there's our spreadsheet I drag across and I do control v to paste in the value for the boundary condition it's interesting with 25.01 not really sure why close to 25 there must be some sort of anomaly let me see here if I click there what is it pulling in it's pulling in those values so I'm not sure what would be driving that it could be round off error somewhere in the spreadsheet not a big deal it's close to 25 and the last thing we need to do now that we've done all of this we copy and paste the internal cells so what we do we click on the interior node and if we look at the formula bar we see the interior node is being represented by all of the adjoining ones so we click on that we'll do control c and then I'm going to copy and I'll select and then do control v and there we go look at that heat transfer taking place before our eyes and and so what this is going to do it's going to work trying to converge I will keep pushing f9 so there we go we're getting to convergence and that's a pretty boring looking solution the temperature going from 25.29 at the bottom to 25.23 at the top and I wonder if this is not because we've used such a high thermal conductivity so let's give something a try here what I'm going to do I'm going to drop the thermal conductivity in all of the boundary conditions that we've assigned let's drop it down to 100 so we'll change that and then let's look for all the other ones there's one 100 maybe that's why heat transfer textbooks rarely use gold there's a heat flux was 100 watts per square meter we'll put 100 there and let's see were there any other boundaries that we used you know I think those were all of them we didn't use radiation okay so let's go back up to our grid and I'm going to hit f9 again and we'll see where that takes us by changing the thermal conductivity of the plate again that's pretty boring not much going on let's try reducing the convective heat transfer coefficient so let's drop that to more of a natural convective heat transfer let's try 10 I see a lot of stuff going on there but were there any other places where we had to enter the convective heat transfer coefficient insulated boundary no that just had thermal conductivity that one surface heat flux you know we had nothing with the okay so I think that was the only one let me go back up so we've dropped the convective heat transfer coefficient now and I'll keep pushing f9 to see what we get on convergence so this is taking quite a while what I'm going to do let me go into options and what I'm going to do is look at options was it under yeah here we go under formulas older versions of excel might be under calculation but iteration I'm going to bump this up let's see maximum enable iterative calculation so I'll bump it up to 5000 and I'm going to reduce the minimum so minimum change I'll put it there now let's see what that does okay so there you can see now it's marching okay now that's only so interesting again you know what I'm going to do I'm going to bump up the surface heat flux let's make that a thousand so that's moving the temperature up well that's going what I'm going to do let's bump the convective heat transfer coefficient back up to 100 and were there any other places where we had convective heat transfer not insulated not there constant heat flux no okay I think that was the only one we'll go back up I hit f9 all right so that seems to be convergence now what I'm going to do let's select our data insert I'll do a contour that is what it is showing us now if you recall from before one of the things but excel is it flips this around so I got to go layout axis depth and then show reverse and so that is more like what we're simulating and so this surface over here is our insulated boundary this is the constant heat flux and you can see that that has the highest temperature we have convective and convective here the lowest temperature is in this upper corner which is where we have the largest amount of convective heat transfer so that is an example of using the excel spreadsheet to solve the heat diffusion equation where you have more complex boundary conditions and it also shows that you can really play around with this quite a bit and watch if I change this to 50 now we'll run that and so what it's doing is going through trying to converge and automatically our plot updates so it shows the utility of this because pretty much everybody has excel in their office computer or if you're a student and and it's pretty easy to use this you can share it you can do quick kind of back of the envelope calculations using finite difference and you don't need to have very expensive commercial software in order to do it the interface is not the greatest that's because I developed it but it works it's functional and it was originally based off of an excel code that was in the back of a textbook by Holman a McGraw-Hill textbook and and that's where this idea originally the motivation came from but then I added a lot more boundary conditions made it a little bit more user friendly I guess you could say so that is the excel model in the next segment we'll play around with radiation and see what that does