On Tuesday, January 16, 2018 at 3:23:16 AM UTC+1, saad khalid wrote:
>
> Hello everyone:
>
> So, I was just messing around with the assume command, and did:
>
> var('i')
> assume(abs(x) < 1)
> f(x) = sum(x^i, i, 0, oo )
>
> This is just 1/(1-x). I wanted to see what would happen when I tried using 
> x > 1, and it still evaluates properly
>

I cannot confirm that, I get:
sage: forget()
sage: assume(x-1>0)
sage: f(x) = sum(x^i, i, 0, oo )
...
ValueError: Sum is divergent.
 

> , even though the sum should be divergent for x > 1. How does this happen 
> behind the scenes exactly? Is Sage/Maxima substituting 1/(1-x) for my sum? 
> Further, I took the integral from 0 to 2:
>
> integrate(f(x),x,0,2)
>
> which returned -I*pi. 
>

I cannot confirm that either for f(x) = 1/(1-x) because I get
sage: integrate(1/(1-x),x,0,2)
...
ValueError: Integral is divergent.
regardless of assumptions.

My guess is you have done operations with f(x) in the meantime that change 
what you think you are doing.

Regards,

-- 
You received this message because you are subscribed to the Google Groups 
"sage-support" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-support+unsubscr...@googlegroups.com.
To post to this group, send email to sage-support@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-support.
For more options, visit https://groups.google.com/d/optout.

Reply via email to