Solving for the Partial Pressures in a Stellar Atmosphere

We begin by using carbon to illustrate:

We let n'(C) = number density of all carbon atoms, n(C) = number density of carbon atoms not bound into molecules, n(C2) = number density of C2 molecules, n(CN) = number density of CN molecules, etc.  It follows that

n'(C) = n(C) + 2n(C2) + n(CN) + n(CO) + . . . , and, since p = nkT

p'(C) = p(C) + 2p(C2) + p(CN) + p(CO) + . . . ,

where p(M) is the partial pressure associated with molecule M and p'(A) is the total partial pressure associated with all atoms and molecules containing atom A.  Since p(AB) = p(A)p(B)/K(AB), it follows that

 p'(C) = p(C) + 2p2(C)/K(C2) + p(C)p(N)/K(CN)+ p(C)p(O)/K(CO) + . . . , or

 p'(C) = p(C)[1 + 2p(C)/K(C2) + p(N)/K(CN)+ p(O)/K(CO) + . . . . ]

Similarly,

 p'(N) = p(N)[1 + 2p(N)/K(N2) + p(C)/K(CN)+ p(O)/K(NO) + . . . ], and

p'(O) = p(O)[1 + 2p(O)/K(O2) + p(C)/K(CO)+ p(N)/K(NO) + p(Ti)/K(TiO) + . . . . ]

If it is assumed that the star in question has standard abundances of the chemical elements, then n'(C), n'(N), n'(O), . . .  are known and therefore, if T is known, p'(C), p'(N), p'(O), . . . are known.  Furthermore, if T is known then K(C2), K(O2), K(N2), K(CN), . . . can be calculated.  So, if m is the number of different elements involved in a significant number of molecules, then the problem is one of solving m equations in m unknowns.  The solution can often be obtained iteratively.