12v battery charger is terrible idea, they often cant handle normal use for over 2-3 days without catching fire. If its new one with trickle charging and all that, then it wont put any power into your electrolysis reaction as it requires current to flow out to determine how full a battery is. A generator creates AC, nothing will happen, High voltage will destroy your electrodes AC or DC, a solar cell requires sunlight and also wont generate a substantial amount of power, a wall transformer will often output a tiny amount of power at a high-ish voltage of 5-15v, 100-200ma, pretty useless, and if it shorts it will catch fire. the new switchmode wall warts however, providing 500-1000ma at any given voltage might prove useful.Best choice is salvage an ATX power supply from a PC. Depending on your electrodes, use the 5v setting. often in minimum power computers youll get like 15-20A out of the 5v rail. If you dont care about corrosion of your electrodes, then use 12v which is typically 10A minimum but as high as 30A. on an ATX to get it to work, you cut all wires comming out of it other than 1-2 red, 1-2 yellow , 1-2 orange , the green and at least 2 black.red is 5v+ , yellow is 12v+ orange is 3.3v+ green is the on signal, black is negative.to turn the atx on, connect green and black, and thats it. If you short circuit the ATX it will turn off automatically and youll need to disconect and reconect the green and black wire.All red yellow and orange use black as the negative. also all same coloured cables in the ATX all link up together, so 1 wire can output the full rated amperage for that voltage just fine, its not divided amongst all the wires.