13.07.2015 Views

xlop-doc.pdf. - Mirror

xlop-doc.pdf. - Mirror

xlop-doc.pdf. - Mirror

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

source\opcopy{0.7}{a}\opcopy{­8}{n}%\oppower{a}{n}{r}%\opdecimalwidth{r}{dr}$\opprint{a}^{\opprint{n}}$ has \opprint{dr}figures after dot.0.7 −8 has 72 figures after dot.In fact, when exponent is negative, first <strong>xlop</strong> calulates inverse of the numberand after that, it calculates the power with opposite of the exponent. In thisexample, if we had left −17 rather than −8, then there will be a capacityoverflow capacity of TEX.Three macros allow a control about precision. They allow to approximatea number giving the rank of the approximation. There are \opfloor,\opceil, and \opround. They need three parameters which are (in order):start number, rank of approximation, variable name to store the result.Rank is an integer value giving number of digits after decimal separatorwhich must be present. If this rank is negative, approximation will be donebefore the decimal separator. If rank is positive and indicates more digitsthan decimal part has, then zeros will be added. If rank is negative and indicatesmore digits than integer part has, then approximation will be lockedin order to give the first digit of the number at least.Here is a summary table which allow to understand how these macroswork.\op...{3838.3838}{n}{r}n floor ceil round6 3838.383800 3838.383800 3838.3838004 3838.3838 3838.3838 3838.38383 3838.383 3838.384 3838.3840 3838 3839 3838−1 3830 3840 3840−2 3800 3900 3800−6 3000 4000 4000\op...{­3838.3838}{n}{r}n floor ceil round6 −3838.383800 −3838.383800 −3838.3838004 −3838.3838 −3838.3838 −3838.38383 −3838.384 −3838.383 −3838.3840 −3839 −3838 −3838−1 −3840 −3830 −3840−2 −3900 −3800 −3800−6 −4000 −3000 −400029

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!