Theoretical investigations on the phase transition of pure and Li-doped AlH3