- Join over
**1.5M+ people** - Join over
**100K+ communities** - Free
**without limits** - Create
**your own community**

- 03:53friyaz labeled #19476
- 03:50friyaz commented #19480
- 03:31friyaz labeled #19480
- 02:56sylee957 commented #19479
- 02:53sylee957 commented #19479
- 02:26sympy-bot commented #18814
- 02:26sympy-bot commented #18814
- 02:26
smichr on master

fix(solvers): solve_linear_syst… fix(solvers): solve_linear_syst… fix(solvers): solve_linear_syst… and 1 more (compare)

- 02:26smichr closed #18814
- 02:26smichr closed #2275
- 02:26smichr closed #18531
- 02:26smichr closed #6420
- 02:26smichr closed #4949
- 02:25smichr commented #18814
- 01:27sylee957 commented #19465
- 01:26sylee957 reopened #19465
- 01:24sylee957 synchronize #19466
- 01:08codecov[bot] commented #19466
- 01:08sympy-bot commented #19466

The second one is where the problems start

Hi. I would like to report that issue #15276 can be closed, since it seems that

`TensExpr.data`

is deprecated.
This is in reference to #19277, I need help as to how an unevaluated derivative can be returned for

`Abs`

class as it is suggested that this way it could be useful to substitute functions later when needed in calculations.
I was informed that implementing

`String`

class was discussed in the past, and eventually turned down. (https://groups.google.com/forum/#!topic/sympy/tNm1LDcEXA4) Does anyone remember why it was rejected? I really would like to know.
There's discussion somewhere on GitHub about whether thats actually a sane invariant for atoms

At any rate,

`Named.func`

could be a `@property`

implemented as `functools.partial(type(self), name=name)`

Or even as

`lambda: self`

I was concerned that we may want to give name to non-atomic objects, where `obj.func(*obj.args)`

must return original one. For me, the fact that `Symbol`

is broken here does not matter much since it is an atomic object so we won't need to travel the branch beneath it.

Making `func`

return `partial`

or `lambda`

can break many things. I have seen many codes in SymPy using `obj.func`

to return the class of `obj`

.

Thanks

I have made a PR which introduces a hook that supplants "postprocessor". Although oscarbenjamin is kindly reviewing this, it is core-related change and I would like to have as many feedbacks as possible.

If anyone is interested, please refer to https://groups.google.com/forum/#!topic/sympy/XNAgvD02_PA and #18769, and join the discussion. Thanks.

If anyone is interested, please refer to https://groups.google.com/forum/#!topic/sympy/XNAgvD02_PA and #18769, and join the discussion. Thanks.

It might be worth comparing to the design of

`__array_function__`

or `__array_ufunc__`

, which are other implementations of python multiple dispatch in the wild
Hey guys, Suryansh here. So I would like to get into OSS. I used to previously think that GSOC only promotes Web Dev OSS until I found an article and it had stated that I can do it in AI/ML as well. I was thrilled. I would love to be get your guidance. Please guide on how can i start with OSS and what all do i need to know. I know python and java and I know the basic ML algorithms. Yeah so thats it guys please let me know how can i proceed and what should be my next steps.

@jksuom Can you help me with #19277

`Abs(x**3).diff(x)`

gives `x**2*Derivative(Abs(x), x) + 2*x*Abs(x)`

which I think is wrong plus I can't think of how to return an unevluated derivative for `Abs`

.
said otherwise, how can i get the non constant symbols from a function as I'd like to compute the gradient of a function

There was an article in the sympy documentation in which ondrej explained how one can start understanding with large codebases. I am a beginner hence i need that document(or possibly any other) but currently I am finding it missing. Also I find the architecture link broken( I think it was here where the article which i state was located). It will be great if someone can help out.

4 replies

For eg:

`simplify`

is a big hammer, and you might need only a small function that `simplify`

calls
@isuruf : That makes sense. A lot of time is spent in basic.py:2012(_preorder_traversal), radsimp.py:23(collect), expr.py:124(

`__eq__`

), cache.py:91(wrapper), and compatibility.py:570(ordered). I'm just not sure how difficult it would be to cythonize any one of these (even if it'd be possible), or whether there'd be a perf gain (if it were possible)
It would help to see your code

I don't know if cythonizing would help or not

(used

`pip install symengine`

and `import symengine as ...`

)
In version 1.6, I'm running into an issue with *sympifying this equation works well using SymPy v1.5.1 but does not come through in v1.6 (conda installation)*. Error message:

`sympify`

. I want to `sympify`

a string with comparison `'u * (dae_t <= 0)'`

. The comparison is supposed to yield the truth value of it. `unsupported operand type(s) for *: 'Symbol' and 'LessThan'`

. Any suggestion?
You can use

`Piecewise((1, dae_t <= 0), (0, True))`

to convert from boolean to number. I don't know how to easily get that from your string without just rewriting it.
@isuruf : Sure! It's open source: https://github.com/zachetienne/nrpytutorial . My code is completely documented in Jupyter notebooks (table of contents here: https://nbviewer.jupyter.org/github/zachetienne/nrpytutorial/blob/master/NRPyPlus_Tutorial.ipynb), but you can run e.g.,

`python3 BaikalETK/BaikalETK_main_codegen_driver.py`

to generate something useful (note that it uses `multiprocessing`

to help speed up the process, but still takes ~minutes to complete). Note that this is the command that I used to profile `symengine`

(replacing calls to sympy.cse() with symengine.cse())
@isuruf Sure: here are 6 of the ~100 expressions that need to be processed: http://astro.phys.wvu.edu/zetienne/outRicci.txt

(through cse; note that these 6 are processed in a single cse call, so common subexpressions are found throughout the expressions. Also note that each expression is separated by a linebreak.)