{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "RDKit WARNING: [21:49:30] Enabling RDKit 2019.09.3 jupyter extensions\n" ] } ], "source": [ "from psikit import Psikit" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [], "source": [ "from orbkit import options\n", "from orbkit import main\n", "from orbkit import read, grid, extras, output, display" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [], "source": [ "pk = Psikit()" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "pk.read_from_smiles('c1ccncc1C#N')" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [], "source": [ "pk.rdkit_optimize()" ] }, { "cell_type": "code", "execution_count": 6, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Optimizer: Optimization complete!\n" ] }, { "data": { "text/plain": [ "-338.4355393893239" ] }, "execution_count": 6, "metadata": {}, "output_type": "execute_result" } ], "source": [ "pk.optimize()" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [], "source": [ "fchk_writer = pk.psi4.core.FCHKWriter(pk.wfn)\n", "fchk_writer.write('output.fchk')" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [], "source": [ "options.filename = \"output.fchk\"\n", "options.outputname = 'vis/mol'\n", "options.otype = ['vmd','mayavi']\n", "#options.otype = ['vmd']\n", "options.adjust_grid = [5,0.1]\n", "options.calc_mo = 'homo-1:lumo+2'" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "This is ORBKIT.\n", " Copyright (C) 2017 Gunter Hermann, Vincent Pohl, Lukas Eugen Marsoner Steinkasserer, Axel Schild, and Jean Christophe Tremblay\n", " This program comes with ABSOLUTELY NO WARRANTY.\n", " This is free software, and you are welcome to redistribute it\n", " under certain conditions. Type '-l' for details.\n", "\n", "Writing log to vis/mol.oklog\n", "\n", "Checking orbkit.options...\n", "\n", "Loading data from fchk type file output.fchk\n", "\n", "\n", "Setting up the grid...\n", "\tx[0] = -10.76 x[-1] = 10.64 Nx = 215 dx = 0.100\n", "\ty[0] = -8.66 y[-1] = 9.14 Ny = 179 dy = 0.100\n", "\tz[0] = -5.88 z[-1] = 5.92 Nz = 119 dz = 0.100\n", "\n", "\n", "Processing molecular orbital list...\n", "\tLine 1: homo-1:lumo+2\n", "\n", "\n", "The following orbitals will be considered...\n", "\tLine 1: [25 26 27 28]\n", "\n", "Converting the regular grid to a vector grid containing 4.58e+06 grid points...\n", "\n", "Starting the calculation of the molecular orbitals...\n", "The grid has been separated into 458 slices each having 1.00e+04 grid points.\n", "The calculation will be carried out using only one process.\n", "\n", "\tThe number of subprocesses can be changed with -p\n", "\n", "\n", "There are 140 contracted Cartesian AOs and 4 MOs to be calculated.\n", "\tFinished 10 % (47 slices in 1.747 s)\n", "\tFinished 20 % (46 slices in 1.861 s)\n", "\tFinished 30 % (46 slices in 1.684 s)\n", "\tFinished 40 % (46 slices in 1.717 s)\n", "\tFinished 50 % (45 slices in 1.647 s)\n", "\tFinished 60 % (46 slices in 1.681 s)\n", "\tFinished 70 % (46 slices in 1.704 s)\n", "\tFinished 80 % (46 slices in 1.708 s)\n", "\tFinished 90 % (46 slices in 1.697 s)\n", "Converting the output from a vector grid to a regular grid...\n", "\n", "Norm of the MOs:\n", "\t0.999994\tMO 26.1 (Occ = 2.00, E = -0.4081 E_h)\n", "\t0.999988\tMO 27.1 (Occ = 2.00, E = -0.3688 E_h)\n", "\t0.999978\tMO 28.1 (Occ = 0.00, E = +0.0775 E_h)\n", "\t0.999987\tMO 29.1 (Occ = 0.00, E = +0.1024 E_h)\n", "\n", "Saving to cube file...\n", "\tvis/mol_MO_0.cube\n", "\n", "Saving to cube file...\n", "\tvis/mol_MO_1.cube\n", "\n", "Saving to cube file...\n", "\tvis/mol_MO_2.cube\n", "\n", "Saving to cube file...\n", "\tvis/mol_MO_3.cube\n", "\n", "Creating VMD network file...\n", "\tvis/mol_MO.vmd\n", "\n", "Depicting the results with MayaVi...\n", "\t\n" ] } ], "source": [ "m = main.run_orbkit()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.7.6" } }, "nbformat": 4, "nbformat_minor": 4 }