setVerbosity(MinimalLog)

# Create the molecule
azane = moleculeFromSmiles('N')

# Set the calculator
basis_set = [
    BasisGGAPseudoDojo.Hydrogen_High,
    BasisGGAPseudoDojo.Nitrogen_High,
]
solvation_parameters = CosmoSolvationParameters()
calculator = LCAOCalculator(
    basis_set=basis_set,
    solvation_parameters=solvation_parameters
)
azane.setCalculator(calculator)

# Optimize the geometry
azane = OptimizeGeometry(
    configuration=azane,
    trajectory_filename=None
)

# Create the COSMO-RS object
solvation_energy = SolvationEnergy(
    configuration=azane
)
azane_cosmo_rs = CosmoRS(
    configuration=azane,
    solvation_energy=solvation_energy
)

# Load the database
database = CosmoRSSpeciesDatabase()

# Add the molecule to the database
database.importSpecies(
    'azane',
    azane_cosmo_rs,
    category='Inorganic bases',
    description='Added as example of COSMO-RS molecular database',
    boiling_point=239.81*Kelvin,
    melting_point=195.42*Kelvin,
    density=0.682*kiloGram/liter,
    antoine_a=4.86886*bar,
    antoine_b=1113.928*Kelvin,
    antoine_c=-10.409*Kelvin,
)

# Remove the species from the database
database.deleteSpecies('azane')
