Let $X$ be a locally ringed space (or a scheme) and $M,N$ two $\mathcal{O}\_X$-modules such that $M \otimes N \cong \mathcal{O}\_X$. Does it follow that $M$ is invertible in the usual sense, namely that $M$ is locally free of rank $1$?


It is true if $M$ is locally of finite type (which is, of course, also necessary). 


Proof: Let $x \in X$. Then $M\_x \otimes N\_x \cong \mathcal{O}\_{X,x}$. Now tensor with the residue field of $\mathcal{O}\_{X,x}$ and use linear algebra to conclude that $M\_x / \mathfrak{m}\_x M\_x$ is $1$-dimensional. Since $M\_x$ is of finite type over $\mathcal{O}\_{X,x}$, Nakayama shows that $M\_x$ is generated by just one element. Since $M$ is of finite type in a neighborhood of $x$, it follows that the generator at $x$ is also a generator in a neighborhood of $x$. Also $N$ has one generator, and their tensor product is a generator of $M \otimes N \cong \mathcal{O}\_X$, which must be free. Thus also the generators of $M$ and $N$ are free.


But I don't know what happens in the general case. Here are some intermediate questions:


* Does it follow that $M$ is flat?
* Is the resulting morphism $M \to Hom(N,\mathcal{O}\_X)$ an isomorphism?
* Is the claim true for $X$ a point, i.e. a local ring?
* Is the claim true if $X$ is an affine scheme and $M,N$ are quasi-coherent? (Thus in the question, replace $\mathcal{O}\_X$ by a usual ring.)



Justification of the term "invertible sheaf"
Any $M'\to M$ that induces an epi after tensoring with $N$ must also induce an epi after tensoring with $N\otimes M$ and therefore must be an epi. And locally such a finitely generated $M'$ must exist.


