TITLE: Formal consequences of Riemann-Roch (multiple answers welcome)
QUESTION [22 upvotes]: This question aims to pin down what Riemann-Roch can tell us about a divisor on a curve, without any "geometric thinking".  It can be annoying to wonder if there is some clever trick you're missing out on in a problem, and it would be nice to know the limits of Riemann-Roch formalism the way we know we can't solve a system of 2 linear equations in 3 variables.
If someone prefers a different formalization of this question, I'd be happy to get an answer to that one instead.  Here is mine: 
Situation:
S1) Div is a free abelian group generated by an infinite set of letters P. [like points] 
 S2) D ∈ Div is "effective" if all its coefficients are non-negative.
 S3) deg: Div -> Z is the sum of coefficients map.
 S4) Prin is a distinguished subgroup of ker(deg). [like principal divisors]
 S5) l: Div/Prin -> N is a function to the non-negative integers. [like the dimension of global sections]
 S6) K is an element of Div. [like a cannonical divisor]
Relations (g:=l(K)):
R1) l(D)-l(K-D) = deg(D) + 1 - g. [Riemann Roch]
 R2) l(D+P) = l(D) or l(D)+1 for any generator P.
 R3) l(D)>0 iff D is equivalent mod Prin to an effective divisor.
 R4) If l(D)>0 and deg(D)=0 then D ∈ Prin.

Question A (hopefully manageable): What exactly can be inferred here about one of l(D) or deg(D), given the other?  

Maybe someone already knows the answer to this, from experience with solving RR-related problems, or from literature.  
Awesomely, many other concepts can be reformulated in this context, and we can ask more...
Optional definitions:
O1) D is "free" if l(D-P) = l(D)-1 for any generator P.
O2) D is "very ample" if l(D-P-Q) = l(D)-2 for any generators P,Q (not nececesarily distinct)
O3) D is "ample" if nD is very ample for some n>0.
O4) D is "big" if for some c>0 and all large n, l(nD) ≥ cm^n

Question B (partial answers welcome): What exactly can be inferred here about l(D), deg(D), effectiveness, freeness, (very) ampleness, and bigness of D given information about the others?  

Some examples (see Hartshorne chapter IV): 

l(0)=1
deg(K) = 2g-2
If D is very ample then deg(D)>0
If deg(D) ≥ 2g then D is free
If deg(D) ≥ 2g+1 then D is very ample 
D is ample iff deg(D)>0

So, yeah!  What's the deal with Riemann-Roch?

REPLY [4 votes]: Dino Lorenzini has a preprint in which he considers "Riemann-Roch structures", roughly as you've laid them out. http://www.math.uga.edu/~lorenz/RRNovember11.dvi
Namely, he considers the situation of 
(S1) The free abelian group $\mathbf{Z}^n$ (okay, so not infinite... Riemann-Roch also works over a finite field)
(S2) $R\in \mathbf{Z}^n$ an "effective" vector or divisor with coprime integer entries
(S3) degree of a divisor $D$ with respect to $R$ is simply the dot product $R\cdot D$
(S4) the "principal divisors" are chosen to be a lattice $\Lambda$ inside of $\Lambda_R$, the lattice of vectors or divisors perpendicular to $R$
So that if (S6) a canonical divisor exists, there exists a function (S5) $h: \mathbf{Z}^n/\Lambda \to \mathbf{Z}_{\ge 0}$ which satisfies some of your relations and optional requirements called a "Riemann-Roch structure".(This is proposition 2.4)
Of interest and proved by Baker and Norine is that if we take $\Lambda$ to be the image of the LaPlacian matrix of a graph with $n$ vertices and $m$ edges, we get such a structure.