Philosophy: An attempt to understand ourselves, the external world and the relationship between the two.
Science: An attempt to understand each aspect of ourselves and the external world by means of the empirical method.
Philosophy is an integral aspect of science because non-empirical thought always preceeds empirical inquiry. For example, the reason why the empirical method exists is because at one point (when it did not exist) someone has conjured an abstract model to represent this entity. Before the empirical experiments are carried out in the laboratory, such an abstract design is also necessary.
Thus the chief utility of philosophy consists in the quest for better understanding. Scientific method is more reliable because it links our abstraction with the specific problems we have embarked upon solving. However, in entirety it owes its existence to philosophy and the abstract nature of such a methodology presupposes that it is to a very significant degree philosophical. After all science is highly complex, there is much more to scientific inquiry than merely going into the laboratory and seeing what happens. Properly interpreting the results requires a rigorous philosophical scrutiny.
Philosophy is also the visionary of scientific endeavors, as in order to advance the scientific methodology, or even discover the new practices to engage in (e.g new experiments), non-empirical abstract thought is necessary.
Scientific discoveries in their own right are barren. They would be hardly of any use to us if we did not know how to factor them into our big picture worldview. Sciences ask what is, philosophy asks what relevance does the aforementioned discovery hold to our worldview as a whole?
Psychology is interested in the human mind. Philosophy of Psychology is interested in how the problems of human mind relate to our broader worldview, in a loose context, such an enterprise could be regarded as Philosophy of mind.
Mathematics is interested in problems of arithmetic in their own right, yet philosophy of mathematics is interested in what role those problems ought to play in our worldview. Such examples could be drawn for the relationship of philosophy to all other sciences.
Why is understanding ourselves, the external world and the relationship between the two useful? Because understanding the two allows for us to elect the adequate methods to deal with problems both internal to ourselves and external. We shall no longer fear them as we will have come to terms wih them. If we are unable to solve them, for the very least we have reasons to believe that we have reliable ways to minimize their hazardous affects upon us, and our past success in problem solving gives us reasons to hope we may accomplish a solution of the currently unsolved problems in the future.