1
$\begingroup$

By restricting

 $MinPrecision = $MaxPrecision = $MaxExtraPrecision = 17

and adding extra precision to any real number

$PreRead = (# /. 
     s_String /; 
       StringMatchQ[s, NumberString] && 
        Precision@ToExpression@s == MachinePrecision :> 
      s <> "`17." &);

as long as i have a real number i get the correct results

enter image description here

My question is that are there any side effects by restricting MinPrecision, MaxPrecision, and MaxExtraPrecision to the desired precision?

$\endgroup$
  • $\begingroup$ What's the goal here? $\endgroup$ – user6014 Sep 11 at 18:59
  • $\begingroup$ @user6014 to put a minimal effort to always have a consistent precision regardless of how many functions you have (instead of SetPrecision for every function). This solves many problems associated with WorkingPrecision errors. $\endgroup$ – user49047 Sep 12 at 9:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.