Download e-book for kindle: METAFONT the program by Donald E. Knuth

By Donald E. Knuth

The is the fourth quantity in a five-volume sequence on desktops and Typesetting, all authored by way of Donald E. Knuth.

Show description

Read or Download METAFONT the program PDF

Best desktop publishing books

Timothy Sean Sykes's 3D AutoCAD 2004/2005: One Step at a Time PDF

This thorough textual content will train you the way to take advantage of AutoCAD's startup wizards to open a brand new drawing, realize many of the elements of the AutoCAD consumer interface, use colour, use linetypes, create dimensions, and lots more and plenty extra.

Download e-book for iPad: Teach Yourself VISUALLY HTML and CSS by Mike Wooldridge

Are you a visible learner? Do you wish directions that aid you do anything - and bypass the long-winded reasons? if this is the case, then this e-book is for you. Open it up and you will find transparent, step by step display pictures that make it easier to take on greater than one hundred seventy five projects related to HTML and CSS. each one task-based unfold covers a unmarried procedure, bound to assist you wake up and operating with HTML and CSS very quickly.

Download e-book for kindle: SONAR 4 Power! by Scott R. Garrigus

Dig deep down into the recent beneficial properties of SONAR four and how one can triumph over each via step by step examples and routines which are designed to make your composing and recording periods run extra easily. From in the beginning customizing SONAR four to making and generating a encompass sound combine, prepare to discover all that SONAR four has to supply!

Download e-book for kindle: Schaum’s Outline of Computer Graphics by Zhigang Xiang

Rankings of examples and difficulties let scholars to hone their abilities. transparent motives of primary initiatives facilitate scholars’ figuring out of significant suggestions. New! Chapters on shading types, shadow, and texture―including the Phong illumination model―explain the newest strategies and instruments for reaching photorealism in special effects.

Additional resources for METAFONT the program

Sample text

The function get avail returns a pointer to a new one-word node whose link field is null. However, METAFONT will halt if there is no more room left. function get avail : pointer ; { single-word node allocation } var p: pointer ; { the new node being got } begin p ← avail ; { get top location in the avail stack } if p = null then avail ← link (avail ) { and pop it off } else if mem end < mem max then { or go into virgin territory } begin incr (mem end ); p ← mem end ; end else begin decr (hi mem min ); p ← hi mem min ; if hi mem min ≤ lo mem max then begin runaway ; { if memory is exhausted, display possible runaway text } overflow ("main memory size", mem max + 1 − mem min ); { quit; all one-word nodes are busy } end; end; link (p) ← null ; { provide an oft-desired initialization of the new node } stat incr (dyn used ); tats { maintain statistics } get avail ← p; end; 164.

Handle non-positive logarithm 134 ≡ begin print err ("Logarithm of "); print scaled (x); print (" has been replaced by 0"); help2 ("Since I don´t take logs of non−positive numbers,") ("I´m zeroing this one. "); error ; m log ← 0; end This code is used in section 132. §135 METAFONT PART 8: ALGEBRAIC AND TRANSCENDENTAL FUNCTIONS 51 135. Conversely, the exponential routine calculates exp(x/28 ), when x is scaled . The result is an integer approximation to 216 exp(x/224 ), when x is regarded as an integer.

Dk−1 ), where 0 ≤ k ≤ 17. The digit di is given in dig [i], and the calculation produces a correctly rounded result. function round decimals (k : small number ): scaled ; { converts a decimal fraction } var a: integer ; { the accumulator } begin a ← 0; while k > 0 do begin decr (k); a ← (a + dig [k] ∗ two ) div 10; end; round decimals ← half (a + 1); end; §103 METAFONT PART 7: ARITHMETIC WITH SCALED NUMBERS 39 103. Conversely, here is a procedure analogous to print int . If the output of this procedure is subsequently read by METAFONT and converted by the round decimals routine above, it turns out that the original value will be reproduced exactly.

Download PDF sample

Rated 4.12 of 5 – based on 34 votes