Jump to content
Geochemist's Workbench Support Forum

export total molality of Np(+V) with python


Helge

Recommended Posts

I am trying to write the log10 total molality of Np(V) to file using python. The present line looks like this:

fobj_ResultFile.write(Testcase + '\t' + '1180' + '\t' + 'log10(conc_oxidationstate(NpO2<+>))' + '\t'+ str(math.log10(myGWB.results('concentration "NpO2+"', 'molal')[0])) + '\n')

A normal export for a single species looks like this

fobj_ResultFile.write(Testcase + '\t' + '1181' + '\t' + 'log10(conc_solute(Ca[NpO2(OH)2]<+>))' + '\t'+ str(math.log10(myGWB.results('concentration aqueous "Ca[NpO2(OH)2]+"', 'molal')[0])) + '\n')

My opinion was that by omitting the "aqueous" behind "concentration" would cause GWB to export the total molality of the given oxidationstate, as defined by the redox species (NpO2+ in this case). Instead, what I observe, is that the concentration of the species NpO2+ is exported. What I would like to have is the total sum of all Np(V)-species in solution.

Any ideas appreciated.

Helge

Link to comment
Share on other sites

Hello Helge,

If you had decoupled NpO2+ and set it as a basis species entry with no other oxidation states for your model, then you can use the command "report concentration original fluid" to get the total concentration of that component in the fluid. If you are running a redox equilibrium model, where NpO2+ species concentration is calculated, then you would need to retrieve the concentrations of aqueous species with the desired oxidation state (e.g. Np(V)) and sum them in python. 
 
Hope this helps,
Jia Wang
Link to comment
Share on other sites

Hello Jia,

I cannot believe that there is no way to retrieve the total concentration of all species being formed from a single redox species. But I cannot see any way to get this result in gtplot either. Also in Tedit I don't see product species grouped into their respective oxidation state. In the present (very special) case the total element concentration gives indeed the correct answer. But this doesn't offer a general solution to the problem, e. g. for those cases, where you have two oxidation states of one basis species in comparable concentration.

Thank you for the replay anyway.

Helge

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...