## Where communities thrive

• Join over 1.5M+ people
• Join over 100K+ communities
• Free without limits
##### Activity
• 06:19
mcepl commented #23533
• 04:51
github-actions[bot] commented #23462
• 03:52
anutosh491 commented #23525
• 03:43
bertiewooster commented #23462
• 03:41
bertiewooster commented #23462
• 03:34
sympy-bot commented #23462
• 03:34
sympy-bot commented #23462
• 03:34
bertiewooster synchronize #23462
• 03:07
dysai1234 starred sympy/sympy
• 02:55
anutosh491 commented #23525
• 02:42
anutosh491 commented #23525
• 02:21
anutosh491 commented #23525
• 02:21
asmeurer commented #23462
• 02:20
anutosh491 commented #23525
• 00:55
bertiewooster commented #23462
• 00:55
bertiewooster commented #23462
• 00:54
bertiewooster commented #23462
• May 24 23:45
asmeurer commented #23462
• May 24 22:40
oscarbenjamin commented #23061
• May 24 21:35
equalis3r starred sympy/sympy
ThePauliPrinciple
@ThePauliPrinciple
Thanks a lot :)
ThePauliPrinciple
@ThePauliPrinciple
from sympy import IndexedBase,symbols,Idx,Derivative
X = IndexedBase('X')
D = IndexedBase('D')
i= symbols('i', cls=Idx)
Derivative(X[i]*X[i],D[i])
Is there some way to tell sympy that X is a function of D?
pillsy
@pillsy
Is there a way to match (not just replace) a pattern where the argument is fixed and the function is wild?
In Mathematica, I'd match a pattern like f_[x]
pillsy
@pillsy
Variations on this don't work:
sympify('f(x)').match(Function(Wild('g'))(Symbol('x')))
(Stripping the commutative assumption off of the Wild symbol doesn't do the trick....)
pillsy
@pillsy
OK, I can do something like this:
F_x = Wild('F', properties=[lambda e: e.args == (x,)])
Swagat S. Bhuyan
@SwagatSBhuyan
Hello, I'm Swagat from india. Looking forward to contributing to Python. If anyone would be kind enough to guide me in these initial stages of getting the hang of it and starting to contribute, that would be really great. Thanks!
Tirthankar Mazumder
@wermos
I too am looking to contribute to SymPy!
Sidharth Mundhra
@0sidharth
https://github.com/sympy/sympy/wiki/Introduction-to-contributing has some pointers to help get you started
Anutosh Bhat
@anutosh491
Hello ,I am trying to approach couple of issues involving Sum.doit() but I am not able to understand completely how doit works for a Sum/Integral ( sometimes the recursive call and other times the not so self-explanatory variables like 'rep','did' etc (yeah i know its not possible to write self-explanatory variables always) in the code throw me off and finding it a bit tough to relate as a whole .
any guidance by someone familiar with doit/concrete module regarding how does doit calculate a basic sum like an infinite geometric series would be great ! Thanks
ThePauliPrinciple
@ThePauliPrinciple
Just wanted to point out that I wrote some ideas/examples in https://github.com/sympy/sympy/discussions/22219 looking forward to any feedback
ThePauliPrinciple
@ThePauliPrinciple
Thanks for the reply @oscarbenjamin !
falematte
@falematte
I think that I found a bug on the evaluation of the limits of a function that I summarize in this pic. Any tips? I can also provide the code to reproduce it.
Of course L and r are symbols positive defined
falematte
@falematte
I have opened and Issue here, please contribute sympy/sympy#22220
The limit is different in the discontinuity points.
ThePauliPrinciple
@ThePauliPrinciple
I am looking to setup a workflow to work on a pull request. In particular, I am looking for some way to be able to edit the library and then immediately check manually/interactively if I obtained the intended result. For example, to have a conda environment which uses the fork as the source for sympy. Any ideas? I have read through the development workflow document, but I feel I'm missing the point on how to do this effectively.
anonbox.netuser
@anonbox.netuser:matrix.org
[m]
Hi, is sympy 1.9 officially released? I saw it is tagged on github, but the usual files for downloading are missing and pypi also only lists 1.9cr1 as latest version. The sympy.org website is also not helpful in this regard, showing the release of 1.7.1 as latest news.
Anutosh Bhat
@anutosh491
Hi guys , I was solving an issue regarding functions/limits and I came across something which might help . So do we have any method /function in sympy that checks whether some function/expression might encapsulate or bound another expression . Like is there any way I could check something like -1/x < cos(x)/x < 1/x or even one sided
ThanhVu (Vu) Nguyen
@nguyenthanhvuh
Hi, it seems that the .subs function is quite slow. When I have a long expression e (can contain nonlinear terms like x**2, y*x*z), calling e.subs(some_dict) takes quite sometime (a sec or so). In fact subs is often slower than solving for large equations. Am I using subs correctly?
빈백에 박제가 되어버린 로듐을 아시오?
hi guys i'm new with sympy, so can anyone help me with solving this problem?
I was trying it on my own, but i can't get a grip on how to solve this Error
import sympy as sp
from sympy import exp, oo

sp.init_printing()

x = sp.Symbol("x")
a, m, h = sp.symbols("a, m, h", positive = True)
A = sp.Symbol("A")

f = exp(-2 * a * m * x**2 / h)
int_f = sp.integrate(f, (x, 0, oo))

eq1 = 2 * (abs(A))**2 * (int_f) - 1

print(sp.solve(eq1, A))
ThePauliPrinciple
@ThePauliPrinciple
A = sp.Symbol("A",real=True) seems to give a solution (although I have not verified it is the correct solution)
빈백에 박제가 되어버린 로듐을 아시오?
I'll give it a try thanks!
wow it works thank u!!!!
Henry smith
Hello all. Henry here , I'm using sympy for the first time for one of my course project reports at my University. The course is based on series and summations overall and while trying to get familiar I realized that Sum((-1)**(x+1) + (-1)**(x+2) , (x, 1, oo)).is_convergent() is not returning the expected result and raises a TypeError saying Invalid NaN comparison , is this a meaningful error or Am I missing something useful ?Maybe I could raise an issue ?
anonbox.netuser
@anonbox.netuser:matrix.org
[m]
Try: sym.simplify(sym.Sum((-1)**(x+1)+(-1)**(x+2),(x,1,sym.oo)))
So basically try to simplify the expression, may yield some more insight also in other cases.
Anutosh Bhat
@anutosh491
@Henrysm41987301_twitter hey Thanks for pointing this out . No need to raise an issue ,there is a fix for similar errors in sympy/sympy#22200 which is currently being reviewed by @oscargus and others .Maybe after that is fixed you could use this expression!
Henry smith
Thanks for the suggestions
ThePauliPrinciple
@ThePauliPrinciple
tests finished: 9644 passed, 436 skipped, 355 expected to fail, 4 expected to fail but passed, in 2343.62 seconds <- this means there is nothing wrong correct?
ThePauliPrinciple
@ThePauliPrinciple
What is the logic in sympy for when to import at the top of a module or inside the code?
Kalevi Suominen
@jksuom
@ThePauliPrinciple Imports should preferably be at the top of a module but sometimes they lead to circular imports and then those must be put in a function or method in order to delay the import.
ThePauliPrinciple
@ThePauliPrinciple
That makes sense, thanks!
ThePauliPrinciple
@ThePauliPrinciple
Ah, I had no choice in the first place, I was doing a circular import anyways
Steven Lee
@stevenleeS0ht
What is the latest progress of migrating sympy-live from python 2 to python 3?
ThePauliPrinciple
@ThePauliPrinciple
I notice a lot of old issues and pull requests, is there any procedure for getting them closed? E.g. by replying with a comment showing that it is no longer an issue/something similar has already been merged into sympy?
ThePauliPrinciple
@ThePauliPrinciple
When we create an undefined function using Function(name), it is possible to add attributes to it using kwargs, e.g. F=Function('F', foo=bar), which will expose F.foo, as well as consider it a different function if foo is not the same. I'm looking for similar behaviour when subclassing Function, is there a way to do so?
ThePauliPrinciple
@ThePauliPrinciple
in particular I want foo to not be in F.args
Rohit Nagar
@nagar2817
Heyy!!! I am a newbie to the open-source, I need to Contribute to your project. How can I contribute to your organization?? Need help!!