# This file was *autogenerated* from the file ./runSLZ-06.sage
from sage.all_cmdline import *   # import sage library
_sage_const_3 = Integer(3); _sage_const_2 = Integer(2); _sage_const_35 = Integer(35); _sage_const_8 = Integer(8); _sage_const_1023 = Integer(1023); _sage_const_1022 = Integer(1022); _sage_const_10 = Integer(10); _sage_const_53 = Integer(53)#! /opt/sage/sage
# @file runSLZ-05.sage
#from scipy.constants.codata import precision
def initialize_env():
    """
    Load all necessary modules.
    """
    compiledSpyxDir = "/home/storres/recherche/arithmetique/pobysoPythonSage/compiledSpyx"
    if compiledSpyxDir not in sys.path:
        sys.path.append(compiledSpyxDir)
    if not 'mpfi' in sage.misc.cython.standard_libs:
        sage.misc.cython.standard_libs.append('mpfi')
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sollya_lib.sage")
    #load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageMpfr.spyx")
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/pobyso.py")
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageSLZ.sage")
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageNumericalOperations.sage")
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageRationalOperations.sage")
    # Matrix operations are loaded by polynomial operations.
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sagePolynomialOperations.sage")
    load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageRunSLZ.sage")


print "Running SLZ..."
initialize_env()
from sageMpfr import *
from sageGMP  import *
#
x = var('x')
__tmp__=var("x"); func = symbolic_expression(exp(x)).function(x)
precision = _sage_const_53 
RRR = RealField(precision)
intervalCenter      = RRR(_sage_const_3 /_sage_const_2 )
icUlp               = intervalCenter.ulp()
intervalRadiusInUlp = _sage_const_2 **_sage_const_8 
intervalRadius      = RRR(_sage_const_2 **(-_sage_const_35 ))          
srs_run_SLZ_v06(inputFunction           = func, 
                inputLowerBound         = intervalCenter - intervalRadiusInUlp * icUlp, 
                inputUpperBound         = intervalCenter + intervalRadiusInUlp * icUlp, 
                alpha                   = _sage_const_2 , 
                degree                  = _sage_const_2 , 
                precision               = precision, 
                emin                    = -_sage_const_1022 , 
                emax                    = _sage_const_1023 , 
                targetHardnessToRound   = precision + _sage_const_10 , 
                debug                   = True)
#
