Often what you perceive as reality is not joyful. So when misery is there, you are sure it is real. This is knowing the real as unreal and unreal as real. A nightmare is a dream mistaken for reality. In fact, all miseries are unreal. A wise man knows that happiness is real, as it is your very nature.