**Divide** :/

Hi,

Im hoping someone can help me out here, Im blowing the dust off my maths knowledge, the little that there is

I know that an understanding of the maths behind the perspective divide isint really needed, but I found it interesting, but unfortunatly I have got stuck on something basic, and while I am awating the maths book I have bought off amazon ( taking 3 weeks longer to come from america, but strangly still €30 cheeper ) I tought i could ask here.

I am currently following along a great guide here:

I can follow along with this:

tan( fovy / 2 ) = y / -z y = tan( fovy / 2 ) x -z

( Nothing compliticated.. Its the next jump I dont understand )

We can simplify the following maths if we define:

f = 1 / tan( fovy / 2 ) then y = -z / f

Now from what I have read, the 1/tan is the cotangent of the angle, but im just not sure how the tan of an angle multiplied to -z, is the equivalant to -z divide cotangant of angle.

This may make perfect sense to others, but as someone who had never heard of a cotangent before .. it was a bit confusing

From what i under stand, the cotangent is just cos flipped. I have tried looking up some trig to help me along, but I cant seem to find what relates here, Im either getting too basic trig, or jumping onto what i would consider advanced.

If someone could point me in the right direction, i would appreciate it

Thanks