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

Use PeriodicTable without instantiating #216

Open
pfebrer opened this issue Apr 27, 2020 · 3 comments
Open

Use PeriodicTable without instantiating #216

pfebrer opened this issue Apr 27, 2020 · 3 comments

Comments

@pfebrer
Copy link
Contributor

pfebrer commented Apr 27, 2020

Hi Nick, is there a reason why you need to instatiate the PeriodicTable class to get the information? Not a big deal, but seems strange :)

@tfrederiksen
Copy link
Contributor

I have been wondering about this too.

@zerothi
Copy link
Owner

zerothi commented Apr 27, 2020

I agree, this class needs an overhaul.

Actually I think the dispatch method could be useful here since users could register their own values on par with the default values!
Then something like

PeriodicTable.radius.vdw(...)

could be used. What do you think about such an interface?

@pfebrer
Copy link
Contributor Author

pfebrer commented Apr 27, 2020

Seems good to me! As long as you can still call the default with:

PeriodicTable.radius()

The only problem that I see is that maybe the documentation becomes more confusing. But maybe you know how to make it clear.

PS: Can a bond method be useful? I know it is very easy to get anyway by doing radii(["C", "H"]).sum(), but I don't know, it may be handy and it might make code more explicit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants