OPTION A:- INCORRECT
For the welfare of our ecology to prevent the contaminating of water resources.
Wrong choice of verb, contaminating which is a present participle of contaminate is not the right verb to be used, however the noun form is preferred.
OPTION B:- INCORRECT
For the welfare of our ecology to prevent "contamination" of water sources.
We need to be specific in the type of contamination that we need here. Article 'the' which is a definite grammatical articles that implies necessarily that an entity it articulates is presupposed; something already mentioned, or completely specified later in this same sentence, or assumed already completely specified. "the contamination is required' is required.
OPTION C:- CORRECT
To prevent the contamination of water resources, for the welfare of our ecology.
Well arranged, concise and not verbose, we can see that the use of article 'the' makes this option unique.
OPTION D:- INCORRECT
For our ecology and welfare to prevent the contamination of water resources.
Who does the prevention? It is not done by our ecology and welfare so this option gives s different expression about the whole sentence and thus incorrect.
OPTION E:- INCORRECT
To prevent the contaminating of ...
This is correct use of contaminating- an infinite verb of contaminate is irrelevant and illogical. The noun form will be chosen over.