The JQuery library provides selected functions for your script to use. Where your script needs to perform many of the tasks that these functions provide then using the jQuery library means that you have to write far less code yourself. Of course if you are only going to use a small fraction of the functions that JQuery provides then you are adding quite a bit of unnecessary overhead to the loading of your page in order to use just a small part of what is in a rather large file but then if you use one of the common copies of the library then many of your visitors will already have the JQuery file cached and so only some visitors will be hit with the extra download. Alternatively when you only need a small fraction of what JQuery provides then using alternative functions to perform just those tasks actually required may be a better option.
This article written by Stephen Chapman, Felgall Pty Ltd.