Chemistry Wizard

From wiki.olisystems.com
Jump to: navigation, search

Contents

Overview

Click here for the OLI Chemistry Wizard 9.5 User Guide

OLI Chemistry Wizard is a Windows wizard-style application that leads you through the process of creating an OLI chemistry model file and associated model database file for use with any other OLI product or custom solution that incorporates OLI Engine. Chemistry Wizard includes both the aqueous and mixed solvent electrolyte (MSE) databanks.

This manual is intended to give you a quick introduction to the Chemistry Wizard and lead you through the process of creating your first set of chemistry model files.

  • A Quick Start
  • Welcome
  • Databank Selection
  • Component Selection
  • Redox, Assay and Pseudocomponent Selection
  • Phase Selection
  • Summary
  • Generating Model Files
  • Details
  • Location of Databanks
  • Redox Selection
  • Assays and Pseudocomponents

A Quick Start

To launch Chemistry Wizard, double-click on the OLI Chemistry Wizard icon on your desktop or, use your mouse to navigate to the Chemistry Wizard 9.1 menu entry in the Windows program menu:

Start -> Programs -> OLI Systems -> Chemistry Wizard 9.2

Use a single left mouse button click on the Chemistry Wizard 9.2 menu entry to start the application.

Welcome

Chemwiz1.png

Figure 1: Splash screen


Chemwiz2.png

Figure 2: Welcome screen

The welcome dialog prompts to you specify a base name and a folder to use for all generated files.

The working directory defaults to your temporary directory. Use the Browse button to change the working directory. Your new working directory will be saved as a preference and will be used whenever you start Chemistry Wizard. If you do change the working directory and would like to revert back to the default, simply click the Reset button.

Notice the Open Existing Model button. Whenever you use Chemistry Wizard to create a chemistry model a special file with a ‘.cwa’ extension is created. This file enables you to return to a case that you created with the Chemistry Wizard, view current settings, make revisions and regenerate chemistry model files.

After you supply a model name (no extension) the Next button will become active. Click Next to proceed.

Databank Selection

Chemistry Wizard includes a number of optional databanks. The Public databank is always selected and can’t be removed from the Selected databanks list.

You can add an optional databank by selecting (with a single left click) an entry in the Available list. As soon as an entry in the Available list is selected, the right arrow button will become active. When you click the right arrow button, the databank will be moved to the Selected list.

You can remove an optional databank by highlighting it in the Selected list and clicking the (now active) left arrow button.

When 2 or more optional databanks are added to the Selected list, they can be re-sorted using the up and down arrows. The databanks are searched top-down. So, the first entry in the Selected databanks will be searched first, the second entry is next, etc. The “Public” databank is always searched last.

For now, do not add any optional databanks and select Next.


Chemwiz3 1.png

Figure 3: Selected Databanks

Component Selection

This page shows the Selected Components for this case. By default, water is always included. More components can be selected by clicking the Add button in the top-right corner:


Chemwiz4.png


Figure 4: Component Addition


The “Add Component” dialog let’s you scroll or search for components in the OLI databanks by ID, Formula or Name. The column being searched has a plum colored arrow pointing up (ascending sort order) or down (descending sort order). To find and highlight NaCl, type NaCl in the Search by ID field. If you press ENTER or click the Add button, the highlighted component will be added to your list of selected components.

Do not close this dialog yet. Type HCL and press ENTER. Type NaOH and press ENTER. Now, close the dialog by clicking the Close button.

Your Selected Components page should now look like this:

Chemwiz4 1.png


Notice that you can sort selected components by ID, Formula or Name.

Click Next to proceed.

Redox, Assay and Pseudo component Selection

Chemwiz5.png

Figure 6: Redox window

This page dialog is used to allow inclusion of reduction/oxidation chemistry as well as assays and pseudo-components in your the chemistry model. For the purposes of this tutorial, we will ignore redox, assays and pseudo-components. If you would like to consider these components in your models, please refer to Redox Selection section for a detailed description of this page.

For now, click Next to proceed.

Phase Selection

Chemwiz6.png

Figure 7: Phases

This page shows the Phases that will be included in all equilibrium calculations. By default, the aqueous, vapor and all solid phases are considered. If your problem includes organic species, then you may wish to enable the Second Liquid phase.

You can exclude individual solid phases. This helps to limit the size of your chemistry model and improves equilibrium calculation performance. We suggest that you include all solids until you are sure that you can safely ignore one or more solids in the temperature, pressure and concentration region of interest.

The Insert Solid Info section allows you to specify the density and heat capacity of non-reactive components which are included in the model. Non-reactive components include ash, carbon, coal and coke.

Click Next to proceed.

Summary

Chemwiz7.png

Figure 8: Generating files

Finally, you will end up at the “Summary” page that shows you all of the selections that you have made.

If you click the “Generate Files Now”, then all chemistry model files will be generated without leaving the application. It’s possible to go back to previous pages, make changes and then regenerate model files.

If you click the “Finish” button, then the files will be generated and the application will be closed.

Click “Finish” to proceed.

Generating Model Files

If your model files are generated successfully, then the following dialog will appear:


Chemwiz8.png

Figure 9: Generated file location

This dialog tells you where the files were written. Click “OK” to close the application.

You should have these files in your Working Directory:


Chemwiz9.png


All of these files are ASCII files that can be inspected using an editor like Notepad.

In Windows Explorer, if you double-click on the “Test.cws” file then you will start the Chemistry Wizard with the case already loaded.

Location of Databanks

The Chemistry Wizard program has a preference that allows you to control where it searches for OLI databanks. By default, this preference is the directory where the “OLI Chemistry Wizard installation program copied the OLI databanks.

If you would like to use databanks installed by another OLI product, then you can change the databank directory using a dialog accessed from the Databank selection page:


Chemwiz10.png

Figure 10: Databank Preferences


Notice the “Databank Preferences” button. Click on it to access the “Databank Preferences” dialog:


Update the “Directory Path” to point to the directory where your other OLI system databanks are located.


Using Private (User) Databanks

You may have a private database provided to you (or created by you). To use these databanks you have two options. First you can install the private databank in the working folder for your chemistry model or you can install it in the OLI databank folder. We will describe both options.

See Private Databases in ESP for installing the databanks.


Using a local working folder

In this example we are using the private databank Portland and we are assuming you have installed this in your local folder. Here is what the folder may look like:

2017-05-02 13-27-34.png

The path to the folder is shown in the address bar (we are using our technical support folders for our Agent AQSim)

Now start the OLI Chemistry Wizard and create a file in that same folder:

2017-05-02 13-29-51.png

click the Browse button

2017-05-02 13-30-43.png

Enter the path to your local folder. I find it easier to copy and paste the information from the address bar in File Explorer.

Click the OK button.

Create a name for a chemistry model and then click Next

2017-05-02 13-40-36.png

This example uses a model in the MSE Thermodynamic Framework so we need to select that radio button.(#1)

This will display all the MSE databanks available,including the private one in our folder. You can see (#2) that the Portland databank is visible. Click the databank and then the right-arrow (#3) to use the databank.

2017-05-02 13-41-21.png

The databank is now selected. You can now generate the chemistry model as in the previous examples above.

2017-05-02 13-44-15.png


Using the OLI System folder

The OLI databank system folder varies depending on the version of the software. If you used the above instruction for installing the software in the system folder (see Private Databases in ESP) then the steps for using the database are the same as for the databanks provided by OLI.

Starting with a new folder you can see we have not installed the databanks locally.

2017-05-02 13-47-53.png

Start the OLI Chemistry Wizard and switch to your working folder. Create a model name and then select the MSE Thermodynamic Framework.

2017-05-02 13-50-32.png

You can see our private databank Portland is visible. This is because it is located in the databank system folder for this version. Generating the model is the same as in the above examples.

Redox Selection

If you would like to consider reduction/oxidation chemistry in your simulation model, then you will need to enable the “Enable Redox Chemistry”check-box:


The “Included Subsystems” list will update with all of the redox subsystems that are associated with the species that you have selected so far. Click on those subsystems that you would like to consider:


In this example, we will consider some oxidation states for chlorine. This will dramatically increase the number of components involved in your simulation and will have an impact on calculation times.

Chemwiz12.png

Figure 12: Chlorine Subsystem

If you are going to include redox chemistry then make sure that you only pick those subsystems that are of most interest. The more redox subsystems you select, the more components you will have and your calculations will take more time.

Assays and Pseudocomponents

Chemistry Wizard version 9 adds support for assays and pseudocomponents. These can be added by clicking on the Add button in the dialog. To add an assay, select Assay from the popup menu.


Selecting the Assay option will bring up the Assay Entry dialog.


Chemwiz13.png

Figure 13: Adding Assays and Pseudo Components

This dialog allows you to define the assay by specifying the distillation data along with other physical parameters including average bulk density and the number of cuts. The Distillation Data grid allows you to enter ordered pairs of distillation volume and temperature values. Rows can be inserted or deleted by right-clicking on the row header in the grid.

Chemwiz14.png

Once all data has been entered, you can click on the Calculate button to view the list of components and their physical properties generated by Chemistry Wizard.


Chemwiz15.png

Click OK to save the assay definition and exit from the dialog.

Similarly, pseudo components can be added by selecting the Pseudo component option after clicking on the Add button. Chemistry Wizard displays a Pseudo component Entry dialog that can be used to enter the parameters that define the Pseudo Component such as normal boiling point, specific gravity and molecular weight.

Chemwiz16.png

Click on the Calculate button to view the generated properties of the pseudo component. Click OK to save the Pseudo Component definition and exit from the dialog.


Sending Diagnostic Information to OLI

On occasion you will need to send diagnostic information to OLI Systems. Unlike other OLI software, the mechanism for the Chemistry Wizard is different. Below is the standard OLI Chemistry Wizard dialog.

2017-10-20 11-08-29.jpg

Locate and click the small "Beaker" in the upper left-hand corner.


2017-10-20 11-09-57.jpg

This will display a small menu. Click the About menu item.

2017-10-20 11-11-24.jpg

Click the Contact Support button

2017-10-20 11-12-11.jpg

Please fill out the information requested

2017-10-20 11-13-47.jpg

This will send diagnostic information to OLI systems. You can either use your mail system directly (using the Submit Online button) or copy the information to the clipboard or a file to send later.

To see what is sent to OLI during this process see the article Information collected with the Contact Support button