TITLE: An example of a space which fails to be compactly generated
QUESTION [16 upvotes]: Does anyone know of an example of a topological space which is not compactly generated? I am using the definition in May's book "A Concise Course in Algebraic Topology." The definition is that a space $X$ is compactly generated if for any continuous map $g:K\to X$ from a compact Hausdorff space $K$, we have $g(K)$ is closed in $X$ (i.e. $X$ is "weak Hausdorff") and for any subset $A$ of $X$, $A$ is closed if an only if for any map $g:K\to X$, the preimage $g^{-1}(A)$ is closed in $K$ (i.e. $X$ is a "$k$-space").
Of course, any compactly generated space is at least $T_1$, as compact Hausdorff spaces are $T_1$, so I am really interested in an example which has $T_1$-separation (or even better, one which is Hausdorff) but which fails to be a $k$-space.

REPLY [4 votes]: Here is a very simple example.  Let $X=\mathbb{N}\times\mathbb{N}\cup\{*\}$, where a subset $U\subseteq X$ is open if either 

$*\not\in U$, or,
for all but finitely many $n\in \mathbb{N}$, $U$ contains all but finitely many points of $\{n\}\times\mathbb{N}$.

Clearly $X$ is Hausdorff (in fact, it is normal).  It is easy to see that every infinite subset of $X$ contains an infinite closed discrete subset (choose either a subset contained in $\{n\}\times\mathbb{N}$ for some $n$ or a subset which contains only finitely many points in each $\{n\}\times\mathbb{N}$), so every compact subset of $X$ is finite.  Thus the compactly generated topology on $X$ is just the discrete topology, so $X$ is not compactly generated.
(More generally, you could replace the second bullet above with "$U\in F$", where $F$ is any filter on $X$ which is not contained in the cofinite filter on any infinite subset of $X$.  The case when $F$ is a nonprincipal ultrafilter is a useful example for many questions in pointset topology.)