TITLE: If M is not a free A-module, can tensoring with a bigger field make it free?
QUESTION [9 upvotes]: I need a simple commutative algebra lemma for a paper, but can't find a reference. Maybe I don't know the right keywords. Here's the setup. $F:K$ is a field extension, $A$ is an algebra over $K$, and $M$ an $A$-module. If $M \otimes_K F$ is a free $A \otimes_K F$ module, must $M$ have been a free $A$-module?
I can do the particular case I need: $K = \mathbb{F}_2$, $F$ a finite extension, $A = 1 \oplus N$ for $N$ nilpotent, $M \otimes_K F$ free of rank one. But I suspect that something more general holds, and it would be nice to quote rather than reprove.
Thanks!

REPLY [12 votes]: Yes, there are such examples even with invertible $M$ and smooth $K$-algebras of dimension 1, with $K$ any field that is not algebraically closed. 
Choose such a $K$, so we may and do also choose a nontrivial primitive finite extension $F$ of $K$.  Consider the projective line over $K$ and remove a closed point $\xi$ such that $F = K(\xi)$.  This is an affine open $U = {\rm{Spec}}(A)$ for a Dedekind $A$, and let $M$ be the maximal ideal of $A$ corresponding to an $K$-point.  This is invertible as an $A$-module (as for any Dedekind domain) but cannot be principal. Indeed, if $a \in A$ were a generator of $M$ then its divisor on $\mathbf{P}^1_K$ has restriction to $U$ that is a single point of degree 1 yet the condition ${\rm{deg}}_K({\rm{div}}(a)) = 0$ forces the "negative" part of the divisor to have degree $-1$ over $K$, contradicting that this negative part is supported at the closed point $\xi$ with $K$-degree larger than 1.
Clearly $A \otimes_K F$ is the coordinate ring of the complement in $\mathbf{P}^1_F$ of ${\rm{Spec}}(F \otimes_K F)$, which contains an $F$-point, so $A \otimes_K F$ is the coordinate ring of a non-empty affine open in the open complement $\mathbf{A}^1_F = {\rm{Spec}}(F[t])$ of an $F$-point in $\mathbf{P}^1_F$. Thus, $A \otimes_K F$ is the localization of the PID $F[t]$ at some nonzero element, so $A \otimes_K F$ is a PID and hence its nonzero ideal $M \otimes_K F$ (corresponding to a single $F$-point) is principal.

REPLY [8 votes]: The implication does not hold.
Let $K$ be the real numbers, $F$ the complex numbers, $A=K[X,Y,Z]/(X^2+Y^2+Z^2-1)$, and $M$ the kernel of the map $A^3\rightarrow A$ given by the unimodular row $(X,Y,Z)$.
Then $M$ cannot be free, by the same argument I gave in my answer to this question.
But $M$ becomes free after tensoring with the complex numbers.  To see this, write $U=(X+iY)/2$, $V=(X-iY)/2$.  Then it suffices to show that $(X,Y,Z)=(U+V,-iU+iV,Z)$ can be transformed via elementary operations to $(1,0,0)$ (so that its kernel is isomorphic to the kernel of $(1,0,0)$, which is evidently free).
To construct such a series of elementary transformations, first transform $(U+V,-iU+iV,Z)\rightarrow (2U,-iU+iV,Z)\rightarrow (2U,iV,Z)$ and then note that $2U$ is equal to 1 mod $(iV,Z)$.

REPLY [3 votes]: Example 4.7 in [Guralnick, Robert; Jaffe, David B.; Raskind, Wayne; Wiegand, Roger. On the Picard group: torsion and the kernel induced by a faithfully flat map. J. Algebra 183 (1996), no. 2, 420--455. MR1399035 (97c:14002)] is an example of an algebra $A$ —A Dedekind domain in fact— such that after an extension $K/k$ the map $Pic(A)\to Pic(A_K)$ has non-finitely generated kernel. Each element in the kernel gives a counterexample.