angle = sinpi(2*0.25) / cospi(2*0.25)
That is, there is no tanpi() function but there is a sinpi() and cospi() that are intended to be more accurate for these kinds of boundary cases.
If you have the symbolic toolbox you could also
Pi = sym(pi);
angle = tan(2 * Pi * 0.25)