Jump to content
Geochemist's Workbench Support Forum

Frank Bok

Members
  • Posts

    46
  • Joined

  • Last visited

Posts posted by Frank Bok

  1. Dear Jia,

    thanks for your help! The problem was within the environment variables. Since my companies computers are not maintained by the user but by the administration team, the environment variables were set to the admin account (and were labeled GWB instead of GWB_BIN_PATH). After setting this into the systemwide environment variables, it now works again.

    Many many thanks and best regards,
    Frank

  2. Dear Jia,

    I did as recommended in the GWB-Pyhton support page and re-run the installer. I also checked the system environment variables, the settings there are ok. But the problem remains, somethin is wrong with the loading of the GWBplugin:

    Quote

    Traceback (most recent call last):

    File "c:\users\fb5950\desktop\python\gwb-test.py", line 13, in <module>

    from GWBplugin import *

    File "C:\Program Files\Gwb\src\GWBplugin.py", line 14, in <module>

    gwbdll = cdll.LoadLibrary(bin_path + 'gwbplugin')

    File "C:\Users\fb5950\AppData\Local\Programs\MUEDIT~1\Python\lib\ctypes\__init__.py", line 451, in LoadLibrary

    return self._dlltype(name)

    File "C:\Users\fb5950\AppData\Local\Programs\MUEDIT~1\Python\lib\ctypes\__init__.py", line 373, in __init__

    self._handle = _dlopen(self._name, mode)

    FileNotFoundError: Could not find module 'gwbplugin' (or one of its dependencies). Try using the full path with constructor syntax.

    >>>

     

    ---------- FINISHED ----------

    exit code: 2 status: 0

    I also tried to give Python the path directly via:

    sys.path.append("c:/program files/gwb/src")

    Same effect.

    I will try it on my second device this afternoon.

    Thanks and best regards,
    Frank

  3. Dear GWB team,

    In the past I have used the GWBplugin in Python using this synthax in my Python scripts:

    import GWBplugin  # class
    from GWBplugin import *
    # Call GWB
    myGWB = GWBplugin()
    print ("Hello")

    This now (even in my old unchanged examples) brings the error message:

    Quote

    "FileNotFoundError: Could not find module 'gwbplugin' (or one of its dependencies). Try using the full path with constructor syntax."

    Adding the full path does not work and brings:

    Quote

    "    import c:\Program Files/gwb/src\GWBplugin  # class
                ^
    SyntaxError: invalid syntax"

    What can I do here (I am far away from beeing an Python expert), so any help is highly appreciated!

    Many thanks in advance and best regards,
    Frank

  4. Hello Jia,

    thanks for explaining me where I am wrong! I am looking forward for the Kinetic workshop.

    I have reduced my calculation by precalculating the rate constant in Excel and directly adding the rate constant for Fe(OH)3(ppd) in the input file. Even then, at lower temperatures and lower rate constants (K = 2.0875E-8 mol/cm s @ T = 20 °C vs. K = 8.4319E-9 mol/cm s @ T = 10 °C) the reaction is calculated to be faster at lower temperatures. This should not be the case?!

    Many thanks,

    Frank

    10C.png

    20C.png

    Pyrite-oxidation_10C.rea Pyrite-oxidation_20C.rea

  5. Dear Jia, dear Brian,

    my knowledge in kinetic modelling is still limited. So maybe this is a trivial question but I cannot solve it on my own:

    I want to model the (calcite buffered) pyrite oxidation with ferrihydrite precipitation including the dissolution kinetics of ferrihydrite and the following formation of goethite. My colleaques have come up with the function for the kinetic rate constant of the form

    log10(k) = a·T + b·pH² + c·pH + d

    with T is the temperature in °C.

    Can you help me setting up this equation in React?!

    Attached is my current status of the calculation, the kinetics data inside are only dummy data to make the script executable so far.

    Many thanks in advance and best regards,
    Frank

    Pyrite-oxidation.rea

  6. Dear GWB team,

    I tried TEdit zu transform a PHREEQC database into GWB format (both attached). From the PITZER block in the PHREEQC, the ETA (NCC / NAA combinations) as well as from the MU (NN'C / NN'A) interaction parameter have not been imported. Specifically, I am referring to these entries from the PHREEQC file:

    -ETA
    O2                  Cl-                 SO4-2               -0.01709 0 0 0 0 0
    O2                  Na+                 Mg+2                -0.01445 0 0 0 0 0
    -MU
    O2                  H+                  H3PO4                -0.1637 0 0 0 0 0
    Does GWB not handle these kind of (rare) interactions? Or did I something wrong?

    Many thanks and best wishes,

    Frank

    P.S.: Sorry for the incomlete translation!

    PHRQ.dat PHRQ.tdat

  7. Hello Jia,

    thanks for your answer. Actually I want to model the retardation of ions in a natural soil sample where I know the mineral composition: Quartz (76.0%), Albite (5,7%), Orthoclase (3,4%), Microcline (6,6%), Illite (2,6%), Kaolinite (2,6%), Montmorillonite (3,1%). With your help I managed to include them all into a calculation at the same time using kinetics. I also created an surface complexation modelling dataset using an bottom-up approach. But wand to include ion-exchange for several minerals - at least Montmorillonite, Illite and Kaolinite - because Ion-Exchange is a major contribution process on retadration. So my problem is to include mineral specific Ion-exchange data and I am looking for a way to simultaniously include Ion-exchange data for Montmorillonite, Illite and Kaolinite. Is this somehow possible?

    I just wonder if this could be realized by having different exchange-sites (>X:Na, >Y:Na, >Z:Na)? But then the exchange capacity is not mineral-specific.

    Many thanks and best regards,

    Frank

  8. Hello,

    I would like to model a scenarion involving several minerals that are capable of cation exchange (Montmorillonite, Illite, Smectite, ...). I also collected some mineral-specific exchange parameters and want to set up a Ion-Exchange surface file (*.sdat). Is there a way to connect the different exchange reactions and their coefficients to the corresponding minerals? For surface complexation modelling data, this can be done quit nicely in one single file by defining different minerals with their surface groups. But for Ion-Exchange reactions I haven't found a solution. Any help is highly appiciated!

    Many thanks in advance and all the best!

    Frank

  9. Dear Jia,

    many thanks for the quick answer, I will try it. My other concerns are on data consistency for the sorption data. Not only the available SCM data is far from beeing complete (here I have to finde a way using chemical analogues) but it is also scattered over several surface complexation models (most double layer and triple model). Here I have to check in the consequences of mixin different models in a sumilation. But that's just part of my work.

    Many thanks and best regards,

    Frank

  10. Hello,

    I would like to set up a calculation of a natural scenario that includes sorption (SCM) onto several natural occuring mineral phases (Quartz, Albite, Orthoclase, Microcline, Illite, Kaolinite, Montmorillonite). Including so many minerals using swap 'mineralname' for SiO2(aq), Al+++ etc. does not work. There are simply not enough elements to swap all in.

    Can you give me a hint how to do this?

    Many thanks in advance and best regards,
    Frank

  11. Dear Forum members,

    recently I tried to model a seawater evaporation and I ended up with different results (using the same Pitzer database) with the identical .rea-files input just with different order of entries n(concerning the species in Basis) in the two files. One file I had created in my own in React (Working_example.rea), the other one (Aborting_example.rea) was created by launching React from GSS. The chemical composition is the same in both files but the one from the GSS-launched React instance stops much earlier.

    I would like to understand the different behavior, in principle, it shouldn't do that.

    Thank you in advance and best regards,

    FrankTHEREDA_PIT_GWB_r03.dat

    Working_example.rea

    Working_example.png

    Aborting_example.rea

    Aborting_example.png

    React_output_aborting.txt

    React_output_working.txt

  12. Hello,

    I have prepared a database (attached) and both TEdit and React are loading the file without any warning. But even the simplest calculations fail and give an error message like this:

    Quote

    Solving for initial system.

     Loaded:    5 aqueous species,
                0 minerals,
                0 gases,
                0 surface species,
                4 elements,
                0 oxides.

    Newton-Raphson did not converge after 999 iterations, maximum residual =           1, Xi = 0.0000
    Largest residual(s):
                           Resid     Resid/Totmol   Cbasis
    ---------------------------------------------------------
     Cl-                1.007e+200            1   3.406e-109
     Na+                2.007e+200            1   6.813e-109
    ---------------------------------------------------------

    Is there a way to locate the error to make it work?

    Thank you in advance and best regards,
    Frank

    thermo_test.tdat

    Test.rea

  13. Hi Brian et al.

    I would like to learn using the new Phase2 program and to do so, I started with something simple: the Eh-pH diagram of Uranium using thermo.tdat. With Act2 this works over the whole range (pH = 0 to 14, Eh = -0.9 to 1.25 V). Trying to do the same with Phase2, I run into several problems:

    If I try the whole pH range (starting at pH = 0), the initial system cannot be solved:

    Newton-Raphson did not converge after 999 iterations, maximum residual =    5.42e-15, Xi = 0.0000
    Largest residual(s):
                           Resid     Resid/Totmol   Cbasis
    ---------------------------------------------------------
     Na+                 3.338e-05    5.422e-15    7.396e+05
    ---------------------------------------------------------

    Reducing the pH range to 4-10 and deactivating charge balancing, the diagram can be calculated. But: The resulting diagrams of Act2 and Phase2 does not match.

    If I try to go higher, either GWB runs with full CPU workload and does not respond (Windows then kills the program if I try to close it) or produces an incorrect *.p2p file.

    Can you give me a hint how to correctly use Phase2?!

    Thank you in advance and best regards,

    Frank

    Phase2-Test.ac2

    Act2_output.txt

    Phase2-Test_error.ph2

    Phase2-Test.ph2

    p2plot_conf.p2c

×
×
  • Create New...