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

Addition of Laplacian operation #12382

Closed
wants to merge 4 commits into from
Closed

Conversation

mohit3011
Copy link
Contributor

Fixes #12381

@jksuom
Copy link
Member

jksuom commented Mar 21, 2017

This appears related to #12261.

@mohit3011
Copy link
Contributor Author

mohit3011 commented Mar 21, 2017

@jksuom , then would you consider merging the changes made by me?

@asmeurer
Copy link
Member

I agree this looks a lot like the other PR. I would likely prefer the other one as it is older, but also I prefer the changes slightly (it calls the function laplacian instead of laplace, also "Laplacian" is a different concept from "Laplace transform").

@mohit3011
Copy link
Contributor Author

@jksuom , @asmeurer , thanks for reviewing it. I think I will close this PR.

@mohit3011 mohit3011 closed this Mar 22, 2017
@mohit3011 mohit3011 deleted the Laplacian branch March 22, 2017 04:35
@mohit3011
Copy link
Contributor Author

I just wanted to know, why there is an error coming in doc tests. Also, I ran the code quality tests on my terminal then they were running fine but here in Travis test, these are giving error.
Please explain. Thanks.

@jksuom
Copy link
Member

jksuom commented Mar 22, 2017

bin/doctest was failing because laplace was not imported in its doctstring examples (https://travis-ci.org/sympy/sympy/jobs/213513081).

@mohit3011
Copy link
Contributor Author

So , does that mean that every time I include some examples (like here , I included Examples of Laplace in vector/functions.py) I have to include the function name of functions in docstrings too ?

@jksuom
Copy link
Member

jksuom commented Mar 22, 2017

When doctest is running the examples in docstrings, such as this one, for example,

    >>> from sympy.vector import CoordSysCartesian, divergence
    >>> R = CoordSysCartesian('R')
    >>> v1 = R.x**2*R.y**2*R.z**2
    >>> laplace(v1, R)
    2*R.x**2*R.y**2 + 2*R.x**2*R.z**2 + 2*R.y**2*R.z**2
    >>> v2 = 2*R.y**2*R.z
    >>> laplace(v2, R)

it simply copies each >>> line verbatim and feeds it to the Python interpreter. It does not automatically import the function. Therefore everything has to be given in the same way as when running the examples manually.

@mohit3011
Copy link
Contributor Author

Ok , Thanks @jksuom

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

Successfully merging this pull request may close these issues.

None yet

3 participants