# The &kmolcalc; Handbook

Francesco
Bresciani

    fbresciani@users.sourceforge.net

2000-2002
Francesco Bresciani
&FDLNotice;
10/01/2003
0.5.01

This handbook documents &kmolcalc; version 0.5.1

&kmolcalc; is a molecular weight calculator distributed with &kemistry;

KDE
kemistry
KMolCalc
Calculator

## Introduction

&kmolcalc; is a molecular weight calculator. It is based on KMol, a molecular weight calculator for &kde; 1.x written by Tomislav Gountchev.

&kmolcalc; is a &kemistry; application. &kemistry; is a collection of chemical applications for &kde;.

### &kmolcalc; features

Here is a brief list of &kmolcalc; features:

- &kmolcalc; computes molecular weight and elemental composition

- User defined groups and elements can be added. A powerful editor is provided to let the user define new groups and/or elements

- &kmolcalc; can read a molecule from a lot of chemical file types (including XYZ, PDB, SMILES, ...) and compute its molecular weight and elemental composition

- A command line mode is available (only molecular weight is computed in command line mode)

## Using &kmolcalc;

### Command line mode

The command line mode is useful if you want to compute molecular weights quickly. Using the command line mode you can compute two or more molecular weights at once. For example:

    &percnt;kmolcalc C7H5 CO2

The output is

    C7H5-----> 89.1167 g/mol
    CO2-----> 44.0098 g/mol

A more compact output can be obtained with the `-raw` option:

    &percnt;kmolcalc -raw C7H5 CO2
    89.1167
    44.0098

### Computing molecular weight and elemental composition with &kmolcalc;

#### Computing molecular weight and elemental composition from a chemical formula

To compute molecular weight and elemental composition form a chemical formula simply enter the formula in the Formula line edit and press the Compute button. &kmolcalc; will parse the formula you entered and if no errors are found the result will be showed in the output window.

#### Computing molecular weight and elemental composition from a file

Starting from &kmolcalc; 0.3 you can compute molecular weight and elemental composition of a molecule saved in a file.

Computing molecular weight and elemental composition from a file is simple: simply click on the Load file and compute... button and select the file using the file selection dialog which appears.

After selecting the file, &kmolcalc; will try to open it. If no errors are found the results will be displayed in the output window.

### Using the elements and groups editor

Using the elements and groups editor an user can

- Add an element

- Add a group

- Modify elements or groups properties

- Remove an user defined element or group

#### Adding a new element

To add a new element click the New element button. You must set the element name , symbol (which must begin with an uppercase letter), and weight. Once finished click the Apply Changes.

#### Adding a new group

To add a new group click the New Group button. You must set the group name, symbol (which must begin with an uppercase letter), and formula. Once finished click the Apply Changes.

#### Modifying an existing group or element

To modify an existing group or element double click on the symbol in the listbox. The group(element) properties will be showed and you can modify them. Once finished click the Apply Changes.

#### Removing an existing group or element

To remove an existing group or element click on symbol in the listbox to select it, then click on the Remove button.

## Command Reference

### &kmolcalc; Main Window

The following image shows the &kmolcalc; main window

Formula

  This line edit is used to enter a chemical formula

Compute

  Click this button to compute molecular weight and elemental composition

Clear

  Clicking this button the output window and the Formula line edit will be cleared

Editor...

  Click this button to open the elements and groups editor

Load file and compute...

  Click this button to compute molecular weight and elemental composition from a file.

Help

  This will display the standard &kde; help menu.

Close

  Clicking this button will exit &kmolcalc;

### &kmolcalc; Editor

The following image shows the &kmolcalc; editor window

Name

  This line edit is used to set or modify the element/group name

Symbol

  This line edit is used to set or modify the element/group symbol

Mass

  This line edit is used to set the atomic weight (enabled when editing an element)

Formula

  This line edit is used to set the group formula (enabled only when editing a group)

Apply changes

  Clicking this button all changes will be applied

New Atom

  Clicking this button a new element will be added (all group-specific GUI elements will we disabled). You must edit all properties and click the Apply Changes button in order to save your changes.

New Group

  Clicking this button a new group will be added (all element-specific GUI elements will we disabled). You must edit all properties and click the Apply Changes in order to save your changes.

Remove

  Clicking this button the element or group currently selected in the listbox will be removed. Only user defined atoms or group can be removed (those marked with an asterisk (*))

Help

  This button invokes the &kde; help system

Close

  Closes the editor window

## Credits and License

&kmolcalc;

Program copyright 2000-2002 Francesco Bresciani fbresciani@users.sourceforge.net

Contributors:

Documentation copyright 2002 Francesco Bresciani fbresciani@users.sourceforge.net

&underFDL;

&underGPL;

## Installation

### How to obtain &kmolcalc;

&kmolcalc; is part of &kemistry;, a collection of chemistry application for &kde;. See the &kemistry; Homepage or the &kemistry; project page on SourceForge for information on obtaining &kemistry;.

### Requirements

In order to succesfully compile &kmolcalc; you need &kde; 3.0

All required libraries can be found on ftp://ftp.kde.org/pub/kde/

### Compilation and Installation

In order to compile and install &kmolcalc; extract the &kemistry; package and type the following commands in the base directory of the &kemistry; distribution:

    %./configure
    %make
    %make install

See the &kemistry; Homepage for further informations on compiling and installing &kemistry;.

Since &kemistry; uses autoconf and automake you should have no trouble compiling it.

&documentation.index;