Ask Your Question

Revision history [back]

Assume your_script.sage starts with R=RealField(100); RealNumber=R. If you run:

 sage: %attach your_script.sage

then the Sage preparsing of the file is done before the execution of the file, hence the RealNumber which is used is the default one, that is with 53 bits of precision. See https://doc.sagemath.org/html/en/reference/repl/sage/repl/preparse.html about preparsing.

Instead, if your run:

 sage: %load your_script.sage

The preparsing is done during the execution, hence the RealNumber which is used is the one defined at the beginning of the script, that is with 100 bits of precision.