Révision 227 pobysoPythonSage/src/sageSLZ/runSLZ-06.sage.py
runSLZ-06.sage.py (revision 227) | ||
---|---|---|
1 | 1 |
# This file was *autogenerated* from the file ./runSLZ-06.sage |
2 | 2 |
from sage.all_cmdline import * # import sage library |
3 |
_sage_const_3 = Integer(3); _sage_const_2 = Integer(2); _sage_const_45 = Integer(45); _sage_const_113 = Integer(113); _sage_const_49 = Integer(49); _sage_const_8 = Integer(8); _sage_const_16383 = Integer(16383); _sage_const_16382 = Integer(16382); _sage_const_18 = Integer(18); _sage_const_35 = Integer(35); _sage_const_6 = Integer(6)#! /opt/sage/sage
|
|
3 |
_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
|
|
4 | 4 |
# @file runSLZ-05.sage |
5 | 5 |
#from scipy.constants.codata import precision |
6 | 6 |
def initialize_env(): |
7 | 7 |
""" |
8 | 8 |
Load all necessary modules. |
9 | 9 |
""" |
10 |
compiledSpyxDir = "/home/storres/recherche/arithmetique/pobysoPythonSage/compiledSpyx" |
|
11 |
if compiledSpyxDir not in sys.path: |
|
12 |
sys.path.append(compiledSpyxDir) |
|
10 | 13 |
if not 'mpfi' in sage.misc.cython.standard_libs: |
11 | 14 |
sage.misc.cython.standard_libs.append('mpfi') |
12 | 15 |
load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sollya_lib.sage") |
13 |
load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageMpfr.spyx") |
|
16 |
#load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageMpfr.spyx")
|
|
14 | 17 |
load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/pobyso.py") |
15 | 18 |
load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageSLZ.sage") |
16 | 19 |
load("/home/storres/recherche/arithmetique/pobysoPythonSage/src/sageSLZ/sageNumericalOperations.sage") |
... | ... | |
22 | 25 |
|
23 | 26 |
print "Running SLZ..." |
24 | 27 |
initialize_env() |
28 |
from sageMpfr import * |
|
29 |
from sageGMP import * |
|
30 |
# |
|
25 | 31 |
x = var('x') |
26 | 32 |
__tmp__=var("x"); func = symbolic_expression(exp(x)).function(x) |
27 |
precision = _sage_const_113
|
|
33 |
precision = _sage_const_53
|
|
28 | 34 |
RRR = RealField(precision) |
29 |
intervalCenter = RRR(_sage_const_3 /_sage_const_8 )
|
|
35 |
intervalCenter = RRR(_sage_const_3 /_sage_const_2 )
|
|
30 | 36 |
icUlp = intervalCenter.ulp() |
31 |
intervalRadiusInUlp = _sage_const_2 **_sage_const_49 + _sage_const_2 **_sage_const_45
|
|
37 |
intervalRadiusInUlp = _sage_const_2 **_sage_const_8
|
|
32 | 38 |
intervalRadius = RRR(_sage_const_2 **(-_sage_const_35 )) |
33 |
srs_run_SLZ_v05(inputFunction=func,
|
|
34 |
inputLowerBound = intervalCenter - intervalRadius, |
|
35 |
inputUpperBound = intervalCenter + intervalRadius, |
|
36 |
alpha = _sage_const_6 ,
|
|
37 |
degree = _sage_const_18 ,
|
|
39 |
srs_run_SLZ_v06(inputFunction = func,
|
|
40 |
inputLowerBound = intervalCenter - intervalRadiusInUlp * icUlp,
|
|
41 |
inputUpperBound = intervalCenter + intervalRadiusInUlp * icUlp,
|
|
42 |
alpha = _sage_const_2 ,
|
|
43 |
degree = _sage_const_2 ,
|
|
38 | 44 |
precision = precision, |
39 |
emin = -_sage_const_16382 ,
|
|
40 |
emax = _sage_const_16383 ,
|
|
41 |
targetHardnessToRound = precision * _sage_const_6 ,
|
|
45 |
emin = -_sage_const_1022 ,
|
|
46 |
emax = _sage_const_1023 ,
|
|
47 |
targetHardnessToRound = precision + _sage_const_10 ,
|
|
42 | 48 |
debug = True) |
43 | 49 |
# |
Formats disponibles : Unified diff