Wikipedia's definition of 'locally free sheaf' Let $R$ be a, say, noetherian ring and $M$ an $R$-module. The Wikipedia article on 'locally free sheaf' tells me that the following two statements are equivalent:


*

*The module $M$ is locally free (Edit: this means there is an open cover $\{U_i\}$ of $Spec R$ such that every $\tilde{M}_{|U_i}$ is free as an ${\mathcal{O}_{Spec R}}{|U_i}$-module.)

*$M_p$ is a free $R_p$-module for every prime ideal $p$ of $R$.


I see that these two things are equivalent if $M$ is finitely generated but I cannot see this in general, even if $R$ is noetherian. Am I missing something or is there a mistake on Wikipedia?
If the latter case is true, has anybody an example of a (non-finitely generated) $R$-module $M$ over a noetherian $R$ such that $M_p=(R_p)^{n_p}$ for every prime ideal $p$ of $R$ and such that $M$ is not locally free?
 A: I'm a bit confused about your question since an $R$-module $M$ is defined to be locally free if $M_{\mathfrak{p}}$ is a free $R_\mathfrak{p}$-module for all primes $\mathfrak{p}$.  I'll assume that you are asking for any example where $M_{\mathfrak{p}}$ is a free $R_\mathfrak{p}$-module for all primes $\mathfrak{p}$ but $M$ is not projective.  If this is not what you are after, just ignore this answer.
Let $R=\mathbb{Z}$ and let $M$ be the submodule of $\mathbb{Q}$ generated by all $\frac{1}{p}$ where $p$ is a prime number.  Then $M$ is not projective/free, but it is locally free since 
$ M_{(p)}=\mathbb{Z}_{(p)}\frac{1}{p}=R_{(p)} $ and $M_{(0)}=\mathbb{Q}=R_{(0)}$.
A: Dear roger123, let $R$ be a commutative ring and $M$ an $R$-module ( which I do not suppose  finitely generated). In order to minimize the risk of misunderstandings, allow me to introduce the following terminology:
Locfree The module $M$ is locally free if for every $P \in Spec (R)$ there is an element $f \in Spec(R)$ such that $f \notin P$ and that $M_f$ is a free  $R_f$  - module.
Punctfree The module $M$ is punctually free if for every $P \in Spec (R)$ the $R_{P} $ - module $M_P$ is free.
Fact 1 Every locally free module is punctually free. Clear.
Fact 2 Despite Wikipedia's claim, it is false that a punctually free module is locally free.
Fact 3 However  if the punctually free $R$- module $M$ is also finitely presented, then it is indeed locally free.
Fact 4 A finitely generated  module is locally free if and only it is projective.
Fact 5 A projective module over a local ring is free.This was proved by Kaplansky and is remarkable in that, let me repeat it, the module $M$ is not supposed to be finitely generated.
A family of counterexamples to support Fact 2 Let R be a Von Neumann regular ring. This means that every $r\in R$ can be written $r=r^2s$ for some $s\in R$. For example, every Boolean ring is Von Neumann regular. Take a non-principal ideal $I \subset R$.  Then the $R$- module $R/I$ is finitely generated (by one generator: the class of 1 !), all its localizations are free but it is not locally free because it is not projective (cf. Fact 4) .The standard way of manufacturing that kind of examples is to take for R an infinite product of fields 
$\prod \limits_{j \in J}K_j$ and for $I$ the set of  families $(a_j)_{j\in J}$ with $a_j =0$ except for finitely many $j$ 's. 
Final irony In the above section on counterexamples I claimed that the $R$ - module $R/I$ is not projective.This is because in all generality a quotient $R/I$ of a ring $R$ by an ideal $I$ can only be $R$ - projective if $I$ is principal . And I learned this fact in...Wikipedia !
