Help


Home    Previous   Contents   Next


3. How to add a new Molecule or an Atom

      3.1 How to create *.csv file with cross-sections
      3.2 Conversion of a file with cross-sections to a MySQL table
      3.3 Changing settings of Web-EEDF
You will maybe come to a point, when you will want to calculate EEDF for a molecule, which I did not included in this version of Web-EEDF. You can wait for a new version, where I will maybe add a few more species, or you can do it yourself. The whole procedure of adding a new species consist from three steps:

  1. creation of a *.csv file with set of cross-sections
  2. conversion of this file to a MySQL table
  3. changing settings of Web-EEDF

3.1 How to create *.csv file with cross-sections

If you open a file 'co2.csv' (directory '/cross-sections') in a text editor, you'd see, that it has a special form. There are values separated by comma (therefore I have used extension csv). If you open it in a spreadsheet editor (e. g. OpenOffice.org Calc or Microsoft Excel), it will look like a table, where each line of this file will be displayed in a new row and commas will separate them into columns.

So, it is not difficult to write such a file, you can even write it an a 'Notepad' (Windows) or in 'vi' (linux). But you must follow criteria discribed in this subsection. However, it is much better to do it in any spreadsheet editor and finally to save it as a *.csv file.

First row - here are names of future columns of the MySQL table, they must have following order and values (with explanation in brackets):
energia (energia means energy in Slovak, units are [eV])
qm (cross-sections for momentum transfer collisions, units are [1016 cm-2])
...
qx (cross-sections for all other processes, like excitations, electron attachment, ... except ionization)
...
qi (cross-sections for electron impact ionization, units are [1016 cm-2])
qt (sum of all previous cross-sections)
You must use names 'energia', 'qm', 'qi' and 'qt'. You must also keep their position. But you can choose names of all the other processes, I use names like 'qr' for rotational excitation, 'qvn' for n-th vibrational excitation, qa for electron attachment...
But because this file will be converted to MySLQ table, better use short names with no special characters.

If you are not sure which cross-sections to use for which molecule, I reccommend you to read following paper [Sak02]. If you want to know more about cross-sections I use for nitrogen, water, carbon dioxide and oxygen, read chapter Theoretical Background.

Second row - this row contains values of energy loss of electron after each collision of a given kind. So, if you have there for example a process named qv1, which represents vibrational excitation by electron impact from vibrational level 0 to level 1 and difference of energy of these two levels is 0.35 eV, the value in this second row, below qv1 must be 0.35.
But, there are columnes (processes), where it is not possible to define such a number, because electron always loses different amount of energy, or it has no sense to define this energy (for example for columns 'energia' and 'qt'). There, you must write either -1 or 1000. Number 1000 is dedicated for electron assotiation processes, where electron loses all his energy. And value -1 must be written in columns 'energia', 'qm' and 'qt'. You may claim, that during ionization impact, the amount of energy the test electron loses is also always different. But here, he allways loses at least the amount of energy equal to the ionization treshold energy and the surplus of the energy he had before the collision id randomly shared between this test electron and newly created electron. So, together, these two rows must look like this:

energia, qm, qv1, qv2, qe1, qa, qe2, qi, qt
-1, -1, 0.29, 0.38, 3.25, 1000, 6.58, 12.69, -1

Other rows - there are values of cross-sections for given energies in the rest of this document. The energy starts at 0 eV and the last value is 100 eV. But the problem is, that values of cross-sections for different processes are usually defined for different energies. So, a table you would get will look something like this:

energiaqmqv1...qiqt
-1-10.38...12.69-1
0620 ...  
0.2410 ...  
0.38 0.0...  
0.4280 ...  
0.5 0.5894...  
0.6801.1508...  
...  ...  
4.05.80.0567...  
4.38 0.0000...  
5.06.3 ...  
...  ...  
12.02.7 ...  
12.69  ...0.0000 
13.02.56 ...0.2568 
15.02.46 ...0.7589 
...  ...  
100.00.98 ...2.9652 

So, in the next step, it is necessary, to fill in empty fields. I use linera interpolation for this purpose. After this operation, this table will look like this:

energiaqmqv1...qiqt
-1-10.38...12.69-1
06200.0...0.0 
0.24100.0...0.0 
0.382910.0...0.0 
0.42800.0015...0.0 
0.51800.5894...0.0 
0.6801.1508...0.0 
............... 
4.05.80.0567...0.0 
4.385.97750.0000...0.0 
5.06.30.0...0.0 
............... 
12.02.70.0...0.0 
12.692.610.0...0.0000 
13.02.560.0...0.2568 
15.02.460.0...0.7589 
............... 
100.00.980.0...2.9652 

Now, you have to calculate qt as a sum of all previous cross-sections and save it as a *.csv file. Let's call it 'ch4.csv' in this tutorial. Finally, if you check it in a text editor (or viewer) it should look like this:

energia, qm, qv1, qv2, qe1, qa, qe2, qi, qt
-1, -1, 0.29, 0.38, 3.25, 1000, 6.58, 12.69, -1
0.0,620,0.0,0.0,0.0,0.0,0.0,0.0,620
0.2,410,0.0,0.0,0.0,0.0,0.0,0.0,410
0.38,291,0.0,0.0,0.0,0.0,0.0,0.0,291
0.4,280,0.0015,0.0,0.0,0.0,0.0,0.0,280.0015
...
13.0,2.56,0.0,0.0,0.0,0.0,0.4231,0.2568,3.2399
...
100,0.98,0.0,0.0,0.0,0.0,0.0,2.9652,3.9452

top

3.2 Conversion of a file with cross-sections to a MySQL table

So, first of all, you must save your file 'ch4.csv' to the directory '/cross-sections' in your Web-EEDF. Now, open Web-EEDf in your web-browser and click on the link 'Data Conversions'. Go to the bottom of the form, choose job type 'create new table storing cross-sections', choose file storing cross-sections ant input there the name of MySQL table you want to create (for example 'ch4'). Befor you submit it, it sholud look like this:

Conversions1

If your input file 'ch4.csv' satisfy criteria mentioned in previous subsection and there is no other error, you have now created table 'ch4' with cross-sections. But if you want to add it to the input form for data necessary for the calcualtion of EEDF, you must also change your settings.

top

3.3 Changing settings of Web-EEDF

After you have succesfully created new table with cross-sections in your MySQL database, you must must add information about this new table and new molecule (or atom) to the file 'settings'. You can do it manually, or you can use script 'Preferences'. You must change three parameters. First, increase the 'number of included molecules'. Then, add the name of created MySQL table to the parameter, which represents a list of all included molecules. Finally, you must also add mass of this molecule to the last parameter, storing masses of all included molecules. For explanation, see chapter 2.4 How to change settings of Web-EEDF or following figure:

Conversions1

top


Home    Previous   Contents   Next