Reversible and irreversible hydrogen trapping in metals: new computer based code: THYDA