SymPy vector error

79 views
Skip to first unread message

berk berk

unread,
Mar 29, 2022, 6:48:37 PM3/29/22
to sympy
Hey guys, when i add interesting vector import my code, i display that error : TypeError: unsupported operand type(s) for +=: 'NoneType' and 'NoneType'

from sympy.vector import CoordSys3D, curl, divergence, gradient
from sympy.vector import *

Chris Smith

unread,
Mar 30, 2022, 12:31:47 AM3/30/22
to sympy
These two imports do not cause me a problem in the current development version.

/c

berk berk

unread,
Mar 30, 2022, 10:01:31 AM3/30/22
to sympy
Sorry I couldn't explain. The SymPy(vectors) does work great at me as well. I meant on mobile phone. on mobile  SymPy  ver==1.1.1 
I can't update latest ver(1.10.1) yet. When I update SymPy 1.1.1 to 1.10.1 I display some '.rej' file with errors on my log.
30 Mart 2022 Çarşamba tarihinde saat 07:31:47 UTC+3 itibarıyla smi...@gmail.com şunları yazdı:

Alan Bromborsky

unread,
Mar 30, 2022, 10:27:27 AM3/30/22
to sy...@googlegroups.com

If you are interested in manipulating vectors the following package built using sympy might be of interest -

https://galgebra.readthedocs.io/en/latest/

especially the way that the different products and derivatives are implemented (the gradient of a scalar function f is simply grad*f and the divergence of a vector function F is grad|F).  It will run in Juypter notebook.  You define the type of coordinate system you want by inputting a metrics tensor (rectangular, cylindrical, and spherical are in the examples).

--
You received this message because you are subscribed to the Google Groups "sympy" group.
To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/60c48518-eb63-40eb-a5c0-a6eb13d5826an%40googlegroups.com.
Message has been deleted

berk berk

unread,
Mar 30, 2022, 11:33:19 AM3/30/22
to sympy
Yes I saw it. But I need sympy.vector in SymPy for usage mobile phone.

30 Mart 2022 Çarşamba tarihinde saat 17:27:27 UTC+3 itibarıyla brombo şunları yazdı:

Peter Stahlecker

unread,
Mar 30, 2022, 1:29:52 PM3/30/22
to sy...@googlegroups.com
For what it is worth:
I use the free app Carnets Plus on my iPad ( and my iPhone ) and it works very well on my iPad!
I assume it should work on an iPhone, too - but I never really used it on my iPhone.

--
Best regards,

Peter Stahlecker

berk berk

unread,
Mar 30, 2022, 3:09:44 PM3/30/22
to sympy
My problem is sympy.vector in SymPy 1.1.1 I guess. My package use SymPy 1.1.1 if I upgrade to SymPy 1.10.1(latest) occour a few errors during compile. 
30 Mart 2022 Çarşamba tarihinde saat 20:29:52 UTC+3 itibarıyla peter.st...@gmail.com şunları yazdı:

Aaron Meurer

unread,
Mar 30, 2022, 3:44:15 PM3/30/22
to sy...@googlegroups.com
If you are getting errors just from imports, it is most likely that
the issue has to do with your installation. I would try removing SymPy
and reinstalling it. For instance, perhaps when upgrading somehow
files from the old version have been left around and are messing with
the new version.

Aaron Meurer
> --
> You received this message because you are subscribed to the Google Groups "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/6b8c447a-f0b3-4e18-88c6-c46a83d3429an%40googlegroups.com.

berk berk

unread,
Mar 30, 2022, 5:16:55 PM3/30/22
to sympy
I tried it... Actually while i following with usb debugging i see some errors these just from "from sympy.vector import ...."
My compiling using base library SymPy 1.1.1 in it. When I out off to  "from sympy.vector import ...." from my main code everything is well.
Yes again some structures doesn't work, example: evaluate=True,  plot3d(_one variable graph). But these unimportance to me.
As a natural I thought this problem cause by old SymPy version. Therefore I updating SymPy 1.1.1 to 1.10.1 or another 1.9... I display that error during compile:


STDOUT:
patching file sympy/utilities/timeutils.py
Hunk #1 FAILED at 8.
1 out of 1 hunk FAILED -- saving rejects to file sympy/utilities/timeutils.py.rej

30 Mart 2022 Çarşamba tarihinde saat 22:44:15 UTC+3 itibarıyla asme...@gmail.com şunları yazdı:

Aaron Meurer

unread,
Mar 30, 2022, 5:24:05 PM3/30/22
to sy...@googlegroups.com
On Wed, Mar 30, 2022 at 3:16 PM berk berk <cing...@gmail.com> wrote:
>
> I tried it... Actually while i following with usb debugging i see some errors these just from "from sympy.vector import ...."
> My compiling using base library SymPy 1.1.1 in it. When I out off to "from sympy.vector import ...." from my main code everything is well.
> Yes again some structures doesn't work, example: evaluate=True, plot3d(_one variable graph). But these unimportance to me.
> As a natural I thought this problem cause by old SymPy version. Therefore I updating SymPy 1.1.1 to 1.10.1 or another 1.9... I display that error during compile:
>
>
> STDOUT:
> patching file sympy/utilities/timeutils.py
> Hunk #1 FAILED at 8.
> 1 out of 1 hunk FAILED -- saving rejects to file sympy/utilities/timeutils.py.rej

It's not clear what you mean by "compile" (SymPy is pure Python and
does not need to be compiled), or what program you are using that
produces the above output (it looks like it is coming from 'patch' or
'git' maybe?).

Without more context, it's impossible to know what is going wrong.
None of the errors you have shown look like they are coming from SymPy
itself, but rather from a broken installation of it. I would repeat my
advice from before that usually your best bet when this sort of thing
happens is to just delete the environment and recreate it from
scratch.

Aaron Meurer

>
> 30 Mart 2022 Çarşamba tarihinde saat 22:44:15 UTC+3 itibarıyla asme...@gmail.com şunları yazdı:
>>
>> If you are getting errors just from imports, it is most likely that
>> the issue has to do with your installation. I would try removing SymPy
>> and reinstalling it. For instance, perhaps when upgrading somehow
>> files from the old version have been left around and are messing with
>> the new version.
>>
>> Aaron Meurer
>>
>> On Tue, Mar 29, 2022 at 4:48 PM berk berk <cing...@gmail.com> wrote:
>> >
>> > Hey guys, when i add interesting vector import my code, i display that error : TypeError: unsupported operand type(s) for +=: 'NoneType' and 'NoneType'
>> >
>> > from sympy.vector import CoordSys3D, curl, divergence, gradient
>> > from sympy.vector import *
>> >
>> > --
>> > You received this message because you are subscribed to the Google Groups "sympy" group.
>> > To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
>> > To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/6b8c447a-f0b3-4e18-88c6-c46a83d3429an%40googlegroups.com.
>
> --
> You received this message because you are subscribed to the Google Groups "sympy" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to sympy+un...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/sympy/d37f9dcd-6405-4307-8e1c-959b599fcb2an%40googlegroups.com.
Message has been deleted

berk berk

unread,
Mar 31, 2022, 10:49:41 AM3/31/22
to sympy
Yes I found. Problem is by Compiler. it is pinning SymPy 1.1.1 and while I upgrade to up version  it s giving some patching errors. Unfortunately this problem need editing to according to new SymPy version in patch.

31 Mart 2022 Perşembe tarihinde saat 00:24:05 UTC+3 itibarıyla asme...@gmail.com şunları yazdı:
Reply all
Reply to author
Forward
0 new messages