Is there a cohomology theory for algebraic groups which captures the variety structure and restricts to the ordinary group cohomology under certain conditions.

For a full treatment of the foundations it's best to consult Part I of the book Representations of Algebraic Groups by J.C. Jantzen (2nd ed., AMS, 2003) even though it's not easily available online. Rational (or Hochschild) cohomology has been well developed, including the broader scheme framework (DemazureGabriel book and Jantzen). What CPS and van der Kallen do in their important paper is to relate indirectly the algebraic group cohomology with finite group cohomology for related finite groups of Lie type. This theme has been much further developed in many later papers, but is subtle. For the algebraic groups themselves, this kind of cohomology theory has also been studied in many papers; but relating it to abstract group cohomology for the algebraic (rather than finite) groups such as the special linear group is not at all obvious. By the way, the Inventiones paper and some others by CPS et al. are freely available online through http://gdz.sub.unigoettingen.de (just do a quick search for Parshall). ADDED: Maybe I can answer the original question in more detail and respond to Ralph's further question. For an affine group scheme $G$ over a field $k$, rational (Hochschild) cohomology is defined as usual in terms of derived functors of the fixed point functor. But everything is done in the category of rational $G$modules; for an affine algebraic group over an algebraically closed field and finite dimensional modules this means that representing matrices have coordinate functions in $k[G]$. Hochschild realized that for groups with added structure, one must use injective resolutions (there are usually not enough projectives). in any case, rational cohomology tends to diverge a lot from the usual group cohomology. In characteristic 0, you are essentially getting Lie algebra cohomology. Studying rational $G$modules is equivalent to studying modules for the Hopf dual of $k[G]$ (hyperalgebra, or algebra of distributions). So the answer to Ralph's question is yes: the notions of cohomology agree. Jantzen's main focus is on prime characteristic and reductive algebraic groups, where powers of the Frobenius map yield kernels which are finite group schemes. Roughly speaking, injectives for $G$ are direct limits of injectives for finite dimensional hyperalgebras, starting with the restricted enveloping algebra of the Lie algebra of $G$ (whose cohomology usually differs from the ordinary Lie algebra cohomology). Relating rational cohomology of $G$ to ordinary cohomology of finite subgroups gets even more subtle, as discussed above. By now there is a lot of literature on these matters but many unanswered questions. 


This is largely redundant with Jim Humphrey's answer, but I thought I'd add the following remarks. Ordinary group cohomology is defined via derived functors, but can be described using cocycles  this amounts to taking an explicit free resolution of the trivial module. In the setting of an algebraic group, you can also describe cohomology via cocycles; here the cocycles you should take are regular functions. More precisely: If $G$ is a (linear) algebraic group over a field $k$, and if $V$ is a finite dimensional linear representation of $G$ as $k$algebraic group ("rational repr"), one can consider the group $C^i(G,V)$ of all regular functions $$\prod^iG=G \times \cdots \times G \to V;$$ using the "usual" boundary mappings for group cohomology, $C^\bullet(G,V)$ can be viewed as a complex. The key feature is that the cohomology of the complex $C^\bullet(G,V)$ coincides with the derived functor cohomology of $V$ in the category of rational representations of $G$. (I'm suppressing here the correct definition of $C^\bullet(G,V)$ for infinite dimensional rational representations $V$ of $G$). This point of view makes (more?) clear how this "algebraic" cohomology can diverge from "ordinary" cohomology. Consider e.g. the additive group $G = \mathbf{G}_a$ over $k$, and consider the trivial repr. $V = k$. The algebraic cohomology $H^1(\mathbf{G}_a,k)$ identifies with the set of additive regular functions $\mathbf{G}_a \to k$; this is 1dimensional if $k$ has char. 0, while if $k$ has char. $p>0$ this cohomology has a $k$basis of the form {$T^{p^i} \mid i \ge 0$ } (for a suitable regular function $T:\mathbf{G}_a \to k$). On the other hand, the "ordinary" first cohomology for the group $k = \mathbf{G}_a(k)$ is just the set of all "abstract" group homomorphisms $k \to k$. In general, there are many such homomorphisms which are not regular functions (e.g. take $p$throots of the function $T$ in positive characteristic). 


Yes, it's called "rational cohomology"  not to be confused with cohomology with rational coefficients... see eg "Rational and Generic cohomology" by Cline, Parshall, Scott and van der Kallen, Inventiones. By using google I have even found a link, make sure it is legal for you to download this file: 

