Let $k$ be a field and $A$ a nonnegatively graded ring over $k$. Assume $A\_0 = k.$ We have a bigrading on $\operatorname{Ext}(k,k)$ (one corresponding to homological degree, one corresponding to the grading on $A$). We assume $A$ is Koszul, i.e., that $\operatorname{Ext}^{ij}(k,k)=0$ whenever $i\neq j$. 


Following Beilinson-Ginzburg-Soergel, "Koszul duality patterns in representation theory", we can define the algebra $E(A)=\oplus\operatorname{Ext}^{ii}(k,k).$ They also define the quadratic dual, $A^{!}$. Their Theorem 2.10.1 then states that $E(A)=A^{!\operatorname{opp}}$.


On the other hand, the start of chapter $2$ of "Quadratic Algebras", Polishchuk&Positselski states instead that $E(A)=A^{!}$. Why is there this disparity? This is probably something stupid, but I can't figure it out.


(On a related note: I'm also confused as to how BGS is using the functor $\operatorname{RHom}(k,-)$ to go from $D(A-\operatorname{mof})$ to $D(A^{!}-\operatorname{mof});$ I would have assumed that applying that functor would give you a module over $\operatorname{RHom}(k,k)$, which is formal and thus should just correspond to $E(A)$, not $A^{!}$. Could someone clarify this as well?)



Compatibility of two definitions of Koszul dual
Let $A$ be a quadratic graded algebra over a field $k$ with finite-dimensional components $A\_n$ and $A\_0=k$. Then the construction of the quadratic dual algebra $A^!$ involves setting $A^!\_1$ to be the dual $k$-vector space to $A\_1$ and the subspace of quadratic relations in $A^!$ to be the orthogonal complement to the subspace of quadratic relations $R\subset A\_1\otimes A\_1$. The orthogonal complement is taken with respect to a natural nondegenerate pairing between the vector spaces $A\_1\otimes A\_1$ and $A\_1^\*\otimes A\_1^\*$.


Accordingly, the definition of the algebra $A^!$ depends on the choice of this pairing, or in other words, on the choice of a natural isomorphism $(A\_1\otimes A\_1)^\*\simeq A\_1^\*\otimes A\_1^\*$. There are, basically, two options: one can set $\langle f\otimes g, u\otimes v\rangle=\langle f,u\rangle\langle g,v\rangle$ or $\langle f\otimes g, u\otimes v\rangle=\langle f,v\rangle\langle g,u\rangle$. Switching between these two choices replaces the algebra $A^!$ with the opposite algebra.


In our book, the convention is to use the first of these two pairings, which leads to $E(A)=A^!$. This looks like the natural choice for as long as you work with quadratic algebras over a field. However, when you replace a field with a noncommutative ring (e.g., a noncommutative semisimple algebra) in the role of $A\_0$, the choice-of-pairing issue becomes the one of constructing a natural isomorphism
$$Hom\_{A\_0}(A\_1\otimes\_{A\_0}A\_1,A\_0)\simeq Hom\_{A\_0}(A\_1,A\_0)\otimes\_{A\_0} Hom\_{A\_0}(A\_1,A\_0),$$
where $Hom\_{A\_0}$ denotes the homomorphisms of (say) left $A\_0$-modules. Then it turns out that the only such isomorphism is a particular case of the natural isomorphism 
$$Hom\_{A\_0}(U\otimes\_{A\_0}V,A\_0)\simeq Hom\_{A\_0}(V,A\_0)\otimes\_{A\_0} Hom\_{A\_0}(U,A\_0)$$
for $A\_0$-$A\_0$-bimodules $U$ and $V$ that are finitely generated and projective as left $A\_0$-modules. Notice that $U$ and $V$ switch places from the left-hand side to the right-hand side of the latter formula, which basically means that the only one of the above two commutative pairings that admits a noncommutative generalization is the second one.


A simple way to distinguish between the two opposite versions of the quadratic dual algebra in the case of a noncommutative ring $A\_0$ is to look on the degree-zero components. Notice that $Ext^0\_A(A\_0,A\_0) = Hom\_{A\_0}(A\_0,A\_0)=A\_0^{opp}$ is the opposite ring to $A\_0$ (if $Ext\_A$ denotes the $Ext$ of left $A$-modules), while the algebra $A^!$ would be probably defined in such a way that $A^!\_0=A\_0$. Then the algebras $E(A)$ and $A^!$ cannot possibly be isomorphic, but only anti-isomorphic.


One of the consequences of these complications is that the functors $A\longmapsto A^!$ and $A\longmapsto A^{opp}$ do not commute with each other when the ring $A\_0$ is noncommutative. Furthermore, if the functor $A\longmapsto A^!$ is defined in such a way that $A^!\_0=A\_0$ rather than $A\_0^{opp}$, then this functor is not self-inverse when $A\_0$ is noncommutative. Instead, one has $(A^{!opp})^{!opp}=A$. One can also say that the functor $A\longmapsto A^!$ comes in two versions, the left and the right one, $A\longmapsto A^!$ and $A\longmapsto {}^!\!A$, with $(A^!)\_0=A\_0=({}^!\!A)\_0$ and ${}^!\!A=((A^{opp})^!)^{opp}$, which are inverse to each other, ${}^!(A^!)=A=({}^!\!A)^!$.


