 We continue our look into SMPI and we're going to deal with limits in this video lecture. As per usual in my first block of code, I'm going to import SMPI as this abbreviation SYM, so I have to refer to it, one of its functions there, init underscore printing, opening and closing parenthesis, and I'm setting, as per usual, the variable X as a symbol. Limits quite easy. Here we have uppercase L. You might imagine that this is just going to do the printing for us, as opposed to doing the calculation. It goes into opening and closing parenthesis and it takes three arguments here. I've used three arguments here. It is my expression first, comma, and then the variable of the limit, and then what the limit is approaching, the value that it approaches. So here I have the sine of X over X, but because I only imported SMPI in this fashion, later on I'll show you other ways to do this. I have to refer to SMPI or the abbreviation that I've saved here. So SIM dot SIN of X over X, and let's execute this block of code and look at that. So the printing is going to be done like this one over X times the sine of X, which you can just obviously imagine is sine of X over X, but look at the beauty here. The limit as X approaches zero of the sine of X over X. As per usual, there's more than one way to do the actual calculation. Yeah, I'm still stuck with the case L, so it would just invoke the pretty printing for me, but I have the dot do it section at the end, open and close parenthesis, and if I do that, it'll actually do the limit for me. So the solution to this limit is one. The limit as X approaches zero of the sine of X over X being one. Now, we can execute it in a second manner. Here we've just used do it with the capital L, but as with integral and integrate, I have the slower case L here as in limit, and that is just going to do the calculation for me. Indeed, the solution to this limit is one. Now, I just want to introduce to you the infinity symbol, and that's quite easy to do in SMPI. I'm going to have SYM dot capital L limit up a case L, so that's just going to do the printing for me. One over X as X approaches infinity. The infinity symbol is two lower case O's. So just the O on the keyboard, but I have to refer to SMPI first to do that, SMPI SYM dot double O. And lo and behold, there's a beautiful infinity symbol there, so the limit as X approaches infinity of one over X. I'm going to execute this code to look for an answer by using the lower case L in this instance, and I have the solution to this limit being zero as we know. Now, is it really zero? Indeed, we can look at the left and right hand sides as we approach the limit from the left and the right hand side. So yeah, I'm just going to print this limit. I'm saying one over X, and remember, yeah, in this instance of my Python notebook, I'm using Python 2.7.6. So, perhaps not important here, but just to remind us all of the fact that you have to put this dot off to the one so that this one is not seen as an integer. It's not the point here. It's one over X as X approaches zero from the right hand side. So another argument I have, one argument, two argument, three argument, fourth argument. So after the third comma, I have a fourth argument, DIR for direction equals, and then in single or double quotes, I use single quotes. Plus there, so I'm approaching it from the right hand side. So when I print this out, you can't actually see anything, other than the fact that this one is now represented as a floating point value instead of represented as an integer, so we see the 1.0. So in the printing, we're not going to have anything here. But now I'm going to execute it. I've used the uppercase L there, so I've got to have the dot do it if I want it to be executed. So if I run that, we see approaching the limit from the right hand and the positive side now gives me infinity. And I can also approach it from the left hand side by putting a negative there as my fourth argument, DIR equals, and then in quotes, negative sign. And if I run that, approaching the limit from the left hand side or the negative side is negative infinity. Just on the matter of infinity, how to refer to negative infinity in your code in Sympi. In here, we have one over X squared. Just make things a bit interesting. It doesn't matter, and X goes to negative, so that negative sign doesn't go there. It's not some dot negative OO. It's negative SyM dot OO, and if we execute that code nicely, the limit as X goes to negative infinity of one over X squared. So that's a look at limits, prints beautifully, and can be calculated very easily.