how does one intersect the diagonal with a graph on the surface $X\times X$ I want to do a concrete example of an intersection product for myself.
Consider the endomorphism $f:\mathbf{P}^1_k\to \mathbf{P}^1_k$ given by $(x:y)\to (y:x)$. It has precisely two fixed points: $(1:1)$ and $(1:-1)$. I want to compute that the intersection product on $\mathbf{P}^1\times \mathbf{P}^1$ is two. 
I think I can somehow see that this is the length of the module $k[x,y]/(x-y,x+y)$...Can somebody explain or correct me?
I also wish I was capable of doing something similar with the morphism $(x:y)\mapsto (x^n:y^n)$. Can somebody explain how this works? 
 A: To be perfectly clear, I'll choose a different copy of $\mathbb P^1_k $ for the target, with coordinates $(u:v)$.
The morphism $f$ is then described by $u=y, v=x$  and its graph $\Gamma$ has  equation $ux-vy=0$ in $\mathbb P^1_k \times \mathbb P^1_k$.
The fixed points are given by the intersection with the diagonal $\Delta$ of  equation $uy-vx=0$ in  $\mathbb P^1_k \times \mathbb P^1_k$.
An  intersection point clearly satisfies $x\neq 0$ and $v\neq 0$, so that the intersection  takes place in $\mathbb A^1_k \times \mathbb A^1_k$, the product of the affine lines with coordinates $y=(1:y)$ and $u=(u:1)$.
There $\Gamma$ has equation $u-y=0$ and $\Delta$ has equation $uy-1=0$.  
The intersection $\Gamma\cap \Delta$ is the affine scheme $X=Spec(A)$ of the $k$-algebra    $A=k[u,y]/(u-y,uy-1)\simeq k[u]/(u^2-1)$ (of dimension 2 as you correctly said)
You get (if $char.k\neq 2$)  two reduced points  for the intersection $\Gamma\cap \Delta=\lbrace (1,1), (-1,1)\rbrace$  
A family of morphisms
If you want to study the morphism $(x:y)\mapsto (x^n:y^n)$, you will similarly get a curve  $\Gamma$  with equation $uy^n-vx^n=0$ to be intersected with the diagonal $\Delta$ with equation $uy-vx=0$.
The intersection  $\Gamma\cap \Delta$ can now be decomposed in two parts: 
I) In the affine plane  $\mathbb A^1_k \times \mathbb A^1_k$ with coordinates $(x,u)$ obtained by setting $ y=v=1$ there are $n$ reduced points.
They are  given by the equations $u=x$ and $u=x^n$ and consist
 of the  point $(0,0)$ and of the $n-1$ pointe $(\zeta,\zeta)$   with $\zeta^{n-1}=1$.   
II) The reduced point $((1:0),(1:0))\in \mathbb P^1_k$
[I have assumed $n-1$ prime to $char.k$]
