sage: import scipy as sc
sage: map(floor,sc.arange(0.0,1.2,0.1))
[0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1]
On 1 Kwi, 21:17, ObsessiveMathsFreak
wrote:
> Thanks for that, but I've run into another issue. I don't know whether
> this is related to the sequence syntax or not
>
> sage: for n in [0.0,0.1,..
On 4/1/11 2:17 PM, ObsessiveMathsFreak wrote:
Thanks for that, but I've run into another issue. I don't know whether
this is related to the sequence syntax or not
sage: for n in [0.0,0.1,..,1.1]:
sage: print n, floor(n)
0.000 0
0.100 0
0.200 0
0.30
Thanks for that, but I've run into another issue. I don't know whether
this is related to the sequence syntax or not
sage: for n in [0.0,0.1,..,1.1]:
sage: print n, floor(n)
0.000 0
0.100 0
0.200 0
0.300 0
0.400 0
0.500 0
On Fri, Apr 1, 2011 at 8:08 PM, ObsessiveMathsFreak
wrote:
>> sage: [0,0.2,..,1]
>> [0.000, 0.200, 0.400,
>> 0.600, 0.800, 1.00]
>
> May sage installation appears to be having trouble with this syntax
>
> OK Here
> sage: [0.0,
> sage: [0,0.2,..,1]
> [0.000, 0.200, 0.400,
> 0.600, 0.800, 1.00]
May sage installation appears to be having trouble with this syntax
OK Here
sage: [0.0,0.2,..,0.9]
[0.000, 0.200, 0.400,
0
On 3/28/11 6:28 AM, ObsessiveMathsFreak wrote:
This is a simple question, but I can't find anything in the
documentation about it.
I would like to declare a simple arithmetic sequence in sage. I use
this a lot for discrete plots, etc. In octave, syntax such as
[0:0.1:1] returns the sequence
0.0
On Mon, Mar 28, 2011 at 1:57 PM, ObsessiveMathsFreak
wrote:
> Thank you. That is more or less what I was looking for.
>
> However, is there any shorthand way of getting srange to include the
> final endpoint? While
> srange(0,1.0,0.1,include_endpoint=True)
> works, it is somewhat more verbose than
Thank you. That is more or less what I was looking for.
However, is there any shorthand way of getting srange to include the
final endpoint? While
srange(0,1.0,0.1,include_endpoint=True)
works, it is somewhat more verbose than I am used to.
On Mar 28, 12:45 pm, David Joyner wrote:
> On Mon, Mar