Re: [sympy] Re: Removing duplication of evaluation and refine logic

2021-03-31 Thread JS S
> Note that your benchmark is flawed since it creates an AssumptionsWrapper each time in the timing loop. If we only want to make a single call to is_positive then we could have a function that does that without creating a new Basic instance. Otherwise the AssumptionsWrapper is created so that

Re: [sympy] Proposition for the new relation system using predicate

2021-03-11 Thread JS S
Aaron, Oscar, please share your idea on this. My recent opinion is: 1. We need relational predicates (Q.eq) to make inference system work with relations. Eq(..., evaluate=False) cannot do this. 2. I will not replace Eq with Q.eq because doing that will break backwards compatibility. Instead,

Re: [sympy] Re: Preparing to release SymPy 1.7

2020-11-12 Thread JS S
That's nice. Thanks for your effort! 2020년 11월 9일 월요일 오후 8시 58분 49초 UTC+9에 Oscar님이 작성: > I'm almost ready with the release script. This is a busy time of the > year for me at work so it's difficult to find time to work on sympy > right now. > > Oscar > > On Mon, 9 Nov 2020 at 04:52, ­송지수 / 학생 /

Re: [sympy] is_indefinite returns nothing or error: 'simplify' flag is unsupported in roots()

2020-05-14 Thread JS
uffini_theorem>. Converting to a matrix M to matrix of floats M.n() works as a workaround since then the eigenvalues can be computed approximately by mpmath."? and giving a link to this conversation? On Thursday, May 14, 2020 at 2:47:41 PM UTC+2, JS wrote: > > Thank you. > T

Re: [sympy] is_indefinite returns nothing or error: 'simplify' flag is unsupported in roots()

2020-05-14 Thread JS
Thank you. This has worked for all matrices that I have tried. : - ) Even M.is_positive_definite and M.is_negative_definite works. On Thursday, May 14, 2020 at 1:54:52 PM UTC+2, Oscar wrote: > > Looking at it seems that the improvements were for `is_positive_definite`, >

[sympy] is_indefinite returns nothing or error: 'simplify' flag is unsupported in roots()

2020-05-14 Thread JS
Hello, I have run into a problem with various matrices. I have read Gotchas and Pitfalls and tried to search around, but I was unable to find anything relevant. For some matrices M, the *M.is_indefinite* simply *returns no output*. I have noticed that M.eigenvals() works for on these

Re: Re: [sympy] Suggestion on Derivative and Expr._diff_wrt

2020-01-04 Thread JS S
Your suggestion is true. However, using ``Derivative(f(x), x) * 1/Derivative(x+1, x)`` explicitly every time is not very systematic approach. If we know "Hey, df(x)/d(x+1) equals (df(x)/dx)/(d(x+1)/dx)!", then why don't we let SymPy know to automatically deal with this case with same approach?

[sympy] Re: Suggestion on Derivative and Expr._diff_wrt

2020-01-04 Thread JS S
I have tried, and although it was working well, `diff()` method was unaffected since `Expr.diff()` method is connected to `Derivative`. 2020년 1월 4일 토요일 오후 7시 8분 39초 UTC+9, Francesco Bonazzi 님의 말: > > It's suggest to subclass Derivative if this feature is needed. -- You received this message

Re: [sympy] Would it be breaking sympy's main design to introduce `sin + cos`?

2019-12-08 Thread JS S
objects. Then sin(x) would create an object that represents > calling the function sin with the argument x like Call(sin, x). Then > undefined functions can be more like symbols. > > On Sun, 8 Dec 2019 at 03:36, JS S > > wrote: > > > > Can you link me to

Re: [sympy] Would it be breaking sympy's main design to introduce `sin + cos`?

2019-12-07 Thread JS S
differentiate > functions directly without needing any reference to an unnecessary > symbol as in `D(sin) -> cos`. In the context of multivariable > functions and partial differentiation maybe that would be something > like `D[2](atan2)`... > > -- > Oscar > > On

[sympy] Would it be breaking sympy's main design to introduce `sin + cos`?

2019-12-06 Thread JS S
In the top docstring of core/function, such behavior is proposed. I also found it mentioned in https://github.com/sympy/sympy/issues/5105, which was open 10 years ago... I know that using `rcall` on `Lambda(x,sin(x))+Lambda(x,cos(x))` will do it, but it seems a bit verbose. I am currently

Re: [sympy] What is the difference between Basic and Expr?

2019-12-04 Thread JS S
, Francesco Bonazzi 님의 말: > > > > On Monday, 2 December 2019 05:25:54 UTC+1, JS S wrote: >> >> >> Likewise, there exists no class such as 'NDimArrayAdd' class, making >> NDimArray subclass of Basic only. >> > > Technically there is *CodegenArrayElementw

Re: [sympy] What is the difference between Basic and Expr?

2019-12-01 Thread JS S
c 2019 at 01:59, JS S > > wrote: > > > > But what confuses me is this: > > > > - ImmutableDenseMatrix is subclass of Expr > > - ImmutableSparseMatrix is subclass of Basic, but not Expr. > > - ImmutableDenseNDimArray is, unlike its Matrix counterpart, subcl

[sympy] What is the difference between Basic and Expr?

2019-12-01 Thread JS S
Sorry for duplicate question - my previous one didn't get any answer so I cannot but ask again. Now, I know that Basic object must be immutable, and Expr object must be able to be subject to arithmetic operation. (As far as I know, that is why some classes, e.g. FiniteSet, is instance of

Re: [sympy] Why are some classes not subclass of Basic?

2019-11-29 Thread JS S
y. I'm not sure about Vector but I think it is > similar. > > Aaron Meurer > > On Fri, Nov 29, 2019 at 12:23 AM JS S > > wrote: > > > > I'm just being curious. > > Some classes in sympy, such as Matrix in matrices package or Vector i

[sympy] Why are some classes not subclass of Basic?

2019-11-28 Thread JS S
I'm just being curious. Some classes in sympy, such as Matrix in matrices package or Vector in physics.vector package, are not subclass of Basic. Is this intentional? -- You received this message because you are subscribed to the Google Groups "sympy" group. To unsubscribe from this group and