-
-
Couldn't load subscription status.
- Fork 49k
Hopkinsons law #6524
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
Hopkinsons law #6524
Conversation
Fix docstring (#6461)
This comment was marked as off-topic.
This comment was marked as off-topic.
electronics/hopkinson's_law.py
Outdated
| raise ValueError("One and only one argument must be 0") | ||
| if reluctance < 0: | ||
| raise ValueError("Reluctance cannot be negative") | ||
| if magnetomotive_force == 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| if magnetomotive_force == 0: | |
| if magnetomotive_force == 0: |
electronics/hopkinson's_law.py
Outdated
| @@ -0,0 +1,39 @@ | |||
| #https://en.wikipedia.org/wiki/Magnetic_circuit#Hopkinson's_law | |||
| from __future__ import annotations | |||
| def hopkinsons_law(magnetomotive_force:float, current:float, reluctance:float) -> dict[str, float]: | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| def hopkinsons_law(magnetomotive_force:float, current:float, reluctance:float) -> dict[str, float]: | |
| def hopkinsons_law(magnetomotive_force:float, current:float, reluctance:float) -> dict[str, float]: |
electronics/hopkinson's_law.py
Outdated
|
|
||
| if __name__ == "__main__": | ||
| import doctest | ||
| doctest.testmod() No newline at end of file |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| doctest.testmod() | |
| doctest.testmod() | |
Describe your change:
Checklist:
Fixes: #{$ISSUE_NO}.