Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better consistency between ORCA and Gaussian inputs #8

Open
swheele2 opened this issue Feb 24, 2023 · 10 comments
Open

Better consistency between ORCA and Gaussian inputs #8

swheele2 opened this issue Feb 24, 2023 · 10 comments
Labels
enhancement New feature or request

Comments

@swheele2
Copy link
Member

For ORCA inputs using "Gaussian's B3LYP", automatically include "NoCosx" keyword to more closely match Gaussian results (ORCA uses RIJCOSX by default).
Similarly, add option to do "ORCA's 6-31G*" that requests Gaussian use 6-31G(d) with 5d/7f rather than the default 6d/10f, and similar for other Pople-style basis sets.

@ajs99778
Copy link
Contributor

The B3LYP one should be straightforward. The Method.get_orca() will basically just have to be changed to return a dictionary like what we do with xtb, and Theory.get_orca_X() will need to be changed accordingly.

For the basis set, maybe it would be better/more general to just make an option for pure vs Cartesian (possibly for individual shells). Of course, we would throw an error if you request Cartesian for ORCA and things like that.

@ajs99778
Copy link
Contributor

the method half of this is done

@swheele2
Copy link
Member Author

Thanks Tony.

@ajs99778 ajs99778 added the enhancement New feature or request label Mar 10, 2023
@ajs99778
Copy link
Contributor

I've added angular_momentum_type to BasisSet. It should be either "pure" or "cartesian" to invoke the relevant keywords. The default is to not specify anything. There is no option for this on the makeInput cls at the moment.

I don't think it's worth doing pure/cartesian by angular momentum type, which I suggested. Q-Chem and Gaussian allow it, but it seems pretty niche to want something like pure G shells but Cartesian everywhere D, F, and H. At that point, the users might want to learn how to set those things themselves.

@swheele2
Copy link
Member Author

swheele2 commented Mar 13, 2023 via email

@joegair
Copy link

joegair commented Mar 30, 2023

I see the updates to the basis.py to specify the angular momentum type, but it is not working as I expected. I'm not I'm not seeing 5D 7F in the route card when I use the following code. (I'm also not seeing the warning when I try to use "cartesian" in ORCA.

fun = Method("m062x")
basis_set = BasisSet(Basis("6-311+G**"), angular_momentum_type="pure")
int_grid = IntegrationGrid("UltraFine")
disp = EmpiricalDispersion(None)
solvent = ImplicitSolvent("SMD", "water")
charge = -2
multiplicity = 1
processors=16
memory=16

jobs = SinglePointJob()

m062x_6311plusgdp = Theory(
    method=fun, 
    basis=basis_set, 
    grid=int_grid, 
    empirical_dispersion=None, 
    job_type=jobs,
    charge=charge,
    multiplicity=multiplicity,
    processors=processors,
    memory=memory,
    solvent=solvent
)

geom.write(
    outfile=f"{name}.com", 
    theory=m062x_6311plusgdp,
    )

The resulting route card is #n m062x/6-311+G** SP Integral=(grid=UltraFine) scrf=(SMD,solvent=water)

@ajs99778
Copy link
Contributor

This is a bug. When you create a Theory, it will create a copy of the BasisSet. When that happens, the angular_momentum_type reverts to the default (do not specify). Currently, you need to do

theory = Theory(
    stuff
)

theory.basis.angular_momentum_type = "cartesian"

To get the warning after this bug is patched, you will to include return_warnings=True ingeom.write

@ajs99778
Copy link
Contributor

this should be fixed now

@joegair
Copy link

joegair commented Mar 31, 2023

Thank you! Everything is working as expected now.

@joegair
Copy link

joegair commented Mar 31, 2023

For what it is worth, I would prefer to have warnings on as the default. The warnings are a really nice feature and I didn't realize they were available based on the documentation alone.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants