Re: [sage-devel] Re: Why SR('expression') fail on some but not others?

2023-05-05 Thread sumaiya qureshi
Hey All! Please let me know I am included within the accepted organization or not? According to Karachi, Pakistan timezone last night was my GSoC'23 result. Please guide me through the procedure how to check my GSoC'23 result. Name :- Sumaiya Qureshi (Karachi, Pakistan) I opted for

Re: [sage-devel] Re: Why SR('expression') fail on some but not others?

2023-04-26 Thread William Stein
I put a few remarks related to this in a notebook: https://cocalc.com/wstein/support/SR-and-strings Basically, converting to from strings via str hardly works anywhere in Sage and that is by design, following the lead of Magma instead of Pari. Instead Pickle is the thing that mostly works for

[sage-devel] Re: Why SR('expression') fail on some but not others?

2023-04-26 Thread John H Palmieri
While sage_eval('sin(x)') does not work, sage_eval('sin(x)', {'x': x}) does work. sage_eval needs to know the context (which variables have been defined, etc.) in which to evaluate. I am not an expert, but sage_eval('sin(x)', locals=locals()) might work pretty reliably, without

[sage-devel] Re: Why SR('expression') fail on some but not others?

2023-04-26 Thread 'Nasser M. Abbasi' via sage-devel
I can't use SR(sage_eval(' expression')) Now all my integral are failing. Here is an example >sage │ SageMath version 9.8, Release Date: 2023-02-11 │ │ Using Python 3.11.1. Type "help()" for help. │ sage: var('x') x sage: SR(sage_eval('sin(x)'))

[sage-devel] Re: Why SR('expression') fail on some but not others?

2023-04-26 Thread Nils Bruin
I think the problem is that the SR exression parses does not know about python's "(a,b)" tuple notation. If you replace the round brackets with square brackets, it does seem to work; at least for the example you give: sage: SR('hypergeometric([3/2,], [5/2, 3], -1/4*3^2)')