[SciPy-user] strange addition behavior

Chris Lee c.j.lee@tnw.utwente...
Thu Feb 14 09:24:32 CST 2008


Code was fine. Reading comprehension problem instead
Sorry all.
Cheers
Chris

Alan G Isaac wrote:
> On Thu, 14 Feb 2008, Chris Lee apparently wrote:
>   
>> print 'dividing up the X axis'
>> print 'current range is ', xCMin, xCMax
>> xSpace = 0.5*(xCMax - xCMin)
>> print 'the new span is ', xSpace
>> xNew = xSpace + xCMin
>> print 'the boundary value is ', xNew
>>     
>
>   
>> xCMin = -0.03
>> xCMax = 0.05
>> xSpace = 0.04
>> xNew = 0.07
>>     
>
>
> No way this can be true.
> Show me in the interpreter.
> For example:
>
>     >>> xCMin = -0.03
>     >>> xCMax = 0.05
>     >>> print 'dividing up the X axis'
>     dividing up the X axis
>     >>> print 'current range is ', xCMin, xCMax
>     current range is  -0.03 0.05
>     >>> xSpace = 0.5*(xCMax - xCMin)
>     >>> print 'the new span is ', xSpace
>     the new span is  0.04
>     >>> xNew = xSpace + xCMin
>     >>> print 'the boundary value is ', xNew
>     the boundary value is  0.01
>     >>>
>
> Looks like you have a sign error in your code.
>
> Cheers,
> Alan Isaac
>
>
>
>
> _______________________________________________
> SciPy-user mailing list
> SciPy-user@scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user
>   

-- 
**********************************************
*  Chris Lee                                 *
*  Laser physics and nonlinear optics group  *
*  MESA+ Institute                           *
*  University of Twente                      *
*  Phone: ++31 (0)53 489 3968                *
*  fax: ++31 (0) 53 489 1102                 *
**********************************************



More information about the SciPy-user mailing list