whats the reasoning on why a pencil appears broken in water

The phenomenon where a pencil appears broken in water is known as refraction. Refraction occurs because light travels at different speeds in different mediums, such as air and water. When light passes from one medium to another, it changes direction, and this change in direction causes the pencil to appear broken.

Specifically, when light enters the water from the air, it slows down and bends towards the normal (an imaginary line perpendicular to the water surface). This bending of light is due to a change in the speed of light in the water compared to air. When the bent light rays reach our eyes, we perceive them as coming from a different position, making the pencil appear broken or bent.

However, the pencil itself remains intact. It is just an optical illusion caused by the way light bends as it passes from air to water.