First-principles investigation of thermodynamic and kinetic properties in Ti-H system and B2-NiAl compound: Phase stability, point defect complexes and diffusion