The influence of nanoparticles on phase formation and stability of liquid crystals and liquid crystalline polymers