KTUGFaq

KTUG FAQ

·Î±×ÀÎ:
ºñ¹Ð¹øÈ£:
°¡ÀÔ
You are unscrupulously dishonest, false, and deceitful.
lpcover.jpg

À§ ÄÚµå´Â KnuthÀÇ Àú¼­ Literate Programming ÀÇ Ç¥Áö¿¡ ³ª¿ÍÀÖ´Â ÄÚµåÀÔ´Ï´Ù.

¸ñÂ÷

1 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö À̶õ?
1.1 ±â¿ø ¹× ¼Ò°³
1.2 KnuthÀÇ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö °­ÀÇ
1.3 KnuthÀÇ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö¿¡ ´ëÇÑ ¾ÖÁ¤
1.4 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö °ü·Ã ±Û
1.5 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö °ü·Ã »çÀÌÆ®
2 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö ½Ã½ºÅÛ
2.1 LaTeXÀ» ÀÌ¿ëÇÑ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö
2.1.1 noweb À» ÀÌ¿ëÇÏ´Â ¹æ¹ý
2.1.2 CWEB À» ÀÌ¿ëÇÏ´Â ¹æ¹ý
2.1.3 ±âŸ ÀÚ·á
2.2 PlainTeXÀ» ÀÌ¿ëÇÑ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö

1 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö À̶õ?

¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö(literate programming)Àº ÇÁ·Î±×·¡¹Ö ¹æ¹ý·ÐÀÇ ÇÑ °¡Áö·Î, ÇÁ·Î±×·¡¹ÖÀ» ÇÒ ¶§ ÄÄÇ»ÅÍ·Î ÄÄÆÄÀÏ °¡´ÉÇÑ Äڵ带 ¸¸µå´Â °Íº¸´Ù »ç¶÷ÀÌ ÀÌÇØÇϱ⠽¬¿î Äڵ带 ¸¸µå´Â °Í¿¡ ÁßÁ¡À» µÎ´Â ¹æ¹ýÀÌ´Ù. Áï, »ç¶÷ÀÌ º¸°í ÀÌÇØÇÒ ¼ö ÀÖµµ·Ï ¹®¼­¸¦ ¸¸µéµíÀÌ ÇÁ·Î±×·¡¹ÖÀ» ÇÏ´Â °ÍÀÌ ¸ñÀûÀÌ´Ù. '¸¶Ä¡ ¹®ÇÐÀÛÇ°À» Àд °Íó·³ ÇÁ·Î±×·¡¹ÖÀ» ÀÐÀ» ¼ö ÀÖµµ·Ï ¸¸µå´Â °Í'ÀÌ ¸ñÇ¥À̹ǷΠ'¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö'À̶ó´Â À̸§À» Áö¾ú´Ù. (Ãâó: [http]¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö-À§Å°¹é°ú)

1.1 ±â¿ø ¹× ¼Ò°³

¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀº ¿ì¸®¿¡°Ô TeXÀÇ ÀúÀÚ·Î ¾Ë·ÁÁø Knuth°¡ ¸¸µé¾î³½ ÇÁ·Î±×·¡¹ÖÀÇ »õ·Î¿î Æз¯´ÙÀÓÀÔ´Ï´Ù. Knuth°¡ ÀÌ¿¡ ´ëÇÑ °³³äÀ» ±¸Ã¼È­Çϱ⠽ÃÀÛÇÑ °ÍÀÌ 1980³â´ë ÃʹÝÀ̴ϱî 2006³â ÇöÀç·Î½á´Â '»õ·Î¿î'À̶õ ´Ü¾î°¡ Á» ¹«»öÇØ Áý´Ï´Ù. ÇÏÁö¸¸ ÇöÀç±îÁöµµ ±×¸® ³Î¸® ÀÌ¿ëµÇ°í ÀÖÁö´Â ¾ÊÀ¸µí ½Í½À´Ï´Ù.

Àü»êÇп¡´Â Àü»êÇÐÀÇ ³ëº§»óÀ̶ó ºÒ¸®´Â Æ©¸µ»ó([http]A. M. Turing Award) ÀÌ ÀÖ½À´Ï´Ù. 1974³â Æ©¸µ»ó ¼ö»óÀÚ´Â ¾Ë°í¸®ÁòÀÇ ºÐ¼®°ú ÇÁ·Î±×·¡¹Ö ¾ð¾îÀÇ µðÀÚÀÎ ±×¸®°í, The art of computer programming À̶ó´Â Àú¼­·Î ±× ºÐ¾ß¿¡ ¸¹Àº °øÇåÀ» ÇÑ Knuth ¿´½À´Ï´Ù.

°ü·Ê(?)·Î½á ±× ÇØ Æ©¸µ»óÀ» ¹ÞÀº »ç¶÷Àº ACM Turing Award Lecture¶ó´Â À̸§À¸·Î °­ÀǸ¦ ÇÏ°Ô µÇ¾î Àִµ¥, 1974³â ±× °­ÀÇÀÇ Á¦¸ñÀº Computer Programming as an Art(»õ·Î¿î ÷ºÎ "knuth-turingaward.pdf)¿´½À´Ï´Ù"ÆÄÀÏ ¾÷·Îµå. Knuth´Â ¿©±â¼­ ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¹ÖÀ» ´Ü¼øÇÑ ±â¼úÀÌ ¾Æ´Ñ À½¾Ç, ¹Ì¼ú, ¹®Çаú °°Àº Á¾·ùÀÇ ÇϳªÀÇ ¿¹¼ú È°µ¿À̶ó°í °­Á¶ÇÏ°í ÀÖ½À´Ï´Ù. ±×¸®°í °á·ÐºÎ¿¡´Â ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¸Ó ÀÚ½ÅÀÌ ¿¹¼ú°¡¶ó´Â ÀνÄÀ» °¡Áö°í ÇÁ·Î±×·¡¹Ö ÀÛ¾÷¿¡ ÀÓÇϸé, ÇÁ·Î±×·¡¹ÖÀÌ ´õ¿í Áñ°Ì°í, ±× °á°ú ¶ÇÇÑ ´õ¿í ÁÁÀ» °ÍÀ̶ó°í ¸»ÇÕ´Ï´Ù.

To summarize: We have seen that computer programming is an art, because it applies accumulated knowledge to the world, because it requires skill and ingenuity, and especially because it produces objects of beauty. A programmer who subconsciously views himself as an artist will enjoy what he does and will do it better. Therefore we can be glad that people who lecture at computer conferences speak about the state of the Art.

¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀº ÀÌ·¸°Ô ½ÃÀÛÇß³ªº¾´Ï´Ù. ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¹ÖÀ» ¿¹¼ú·Î º¸´Â ´ë°¡·Î ºÎÅÍ ¸»ÀÔ´Ï´Ù. À§ÀÇ °­ÀǸ¦ ½ÃÀÛÀ¸·Î ´«¿¡ º¸ÀÌ´Â º»°ÝÀûÀÎ ¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀÇ ½ÃÀÛ ¶ÇÇÑ KnuthÀÇ ³í¹® Literate Programming (@knuthweb.pdf (257.24 KB) ) ¿¡¼­ ½ÃÀÛÇÕ´Ï´Ù. ÀÌ ³í¹®¿¡¼­ Knuth´Â ´õÀÌ»ó ÄÄÇ»Å͸¦ À§ÇØ ÇÁ·Î±×·¡¹ÖÀ» ÇÏ´Â ½Ã´ë´Â Áö³µ´Ù°í ¸»ÇÕ´Ï´Ù. »ç¶÷À» À§ÇÑ ÇÁ·Î±×·¡¹ÖÀ» ÇÏÀÚ°í ÇÕ´Ï´Ù. ¹°·Ð ÇÁ·Î±×·¡¹ÖÀ̶ó´Â °ÍÀÌ ÄÄÇ»ÅÍ¿¡ ÀÏÀ» ½ÃÅ°±â À§ÇÑ ¸í·ÉµéÀÇ ÁýÇÕÀÌÁö¸¸, ÀÌ°Í¿¡ ¿¬¿¬ÇÏ¿© ³Ê¹« ÄÄÇ»ÅÍ¿¡¸¸ ÃÊÁ¡À» ¸ÂÃßÁö ¸»°í, »ç¶÷µé¿¡°Ô ´«À» µ¹¸®ÀÚ´Â °ÍÀÌÁö¿ä. ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¹ÖÀÇ ¸£³×»ó½º ½Ã´ë°¡ ¿Â °ÍÀÌÁö¿ä.

ÀÌ ³í¹®¿¡¼­ ¿ª½Ã ÀÏ°üµÇ°Ô ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¹ÖÀ» ¹®ÇÐ ÀÛÇ°(works of literature) À¸·Î °£ÁÖÇÏ°í, Àç¹ÌÀÖ´Â ¸»ÀÎ Literate Programming À̶õ ¸»À»¸¸µé¾î ³Â½À´Ï´Ù. Knuth´Â ¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀ» ´Ü¼øÇÑ ¸»Àå³­¿¡ ±×Ä¡´Â °ÍÀ» ½È¾îÇؼ­ WEBÀ̶ó´Â ½Ã½ºÅÛÀ» ¸¸µé¾î ³Â½À´Ï´Ù. TeXÀÌ WEB ½Ã½ºÅÛÀ¸·Î ¸¸µé¾îÁ³´Ù´Â °ÍÀº Àß ¾Ë·ÁÁø »ç½ÇÀÌÁö¿ä.

I believe that the time is ripe for significantly better documentation of programs, and that we can best achieve this by considering programs to be works of literature. Hence, my title: Literate Programming. Let us change our traditional attitude to the construction of programs: Instead of imagining that our main task is to instruct a computer what to do, let us concentrate rather on explaining to human beings what we want a computer to do.

  • WEB À¸·Î ÀÛ¼ºµÈ TeX ¼Ò½º: [http]tex.web
    ÄÄÇ»ÅÍ ÇÁ·Î±×·¡¹ÖÀ» º»°ÝÀûÀ¸·Î ÀÍÈ÷°íÀÚ ÇÏ´Â »ç¶÷µéÀº ¹Ýµå½Ã ÀоîºÁ¾ß ÇÑ´Ù°í ÇÕ´Ï´Ù. TeX¿¡ Àͼ÷ÇØÁö¸é Çѹø µµÀüÇØ º¸°íÀÚ ÇÕ´Ï´Ù.
  • °ü½ÉÀÖ´Â ºÐÀ» À§ÇÏ¿©: pdf ÆÄÀÏÀ» ¸¸µé¾î³»´Â °úÁ¤À» ´ÙÀ½°ú °°½À´Ï´Ù. À§ÀÇ tex.webÀ» ´Ù¿î¹ÞÀ¸½Ã°í,
    % weave tex.web      <-- tex.web ÆÄÀÏ¿¡¼­ tex.tex ÆÄÀÏÀ» ¾ò½À´Ï´Ù.
    % tex tex.tex        <-- texÀÌ ¼¼¹øÀ̳ª ¾²¿´³×¿ä. 
    % dvipdfmx tex.dvi
    
    À§Ã³·³ ÇÏ¿© ¸¸µé¾î Áø Ã¥ÀÌ ¹Ù·Î KnuthÀÇ Àú¼­ Computers & Typesetting ½Ã¸®ÁîÀÇ Volume BÀÎ TeX: The Program ÀÔ´Ï´Ù.

  • Âü°í: À©µµ¿ìÁî¿¡¼­ MiKTeXÀ» ÀÌ¿ëÇϽô ºÐÀº KTUGContrib:3247 (by µµÀºÀ̾ƺü) À» Âü°í ÇÏ¸é µË´Ï´Ù.

  • 1.2 KnuthÀÇ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö °­ÀÇ

    Knuth´Â 1987³â 10~12¿ù¿¡ ½ºÅÄÆ÷µå´ëÇп¡¼­ Mathematical WritingÀ̶õ Á¦¸ñÀ¸·Î °­ÀǸ¦ ÇÏ¿´½À´Ï´Ù. ±× Áß ÀϺΰ¡ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö¿¡ °üÇÑ ³»¿ëÀÔ´Ï´Ù. ¿µ¾î°¡ ª¾Æ¼­ ´Ù ¾Ë¾ÆµèÁö´Â ¸øÇϴµ¥, ÇÑ°¡Áö ´ÙÇàÀÎ Á¡Àº °­ÀÇ Á¦¸ñ°ú µ¿ÀÏÇÑ Mathematical Writing À̶õ Ã¥ÀÌ Àִµ¥, ±× Ã¥Àº ÀÌ °­ÀǸ¦ ¼ö°­ÇÑ Çлýµé°ú Knuth°¡ ¸¸µç Ã¥À¸·Î "°­ÀÇ ³ëÆ®"ÀûÀÎ ¼º°ÝÀÌ Â£½À´Ï´Ù. ÀÌ¿¡ ±× Ã¥¿¡¼­ ÇØ´ç °­ÀÇ ºÎºÐÀ» ¿Ã¸³´Ï´Ù. µ¿¿µ»ó ½Ãû¿¡ ¸¹Àº µµ¿òÀÌ µÇ¸®¶ó º¾´Ï´Ù.

    1.3 KnuthÀÇ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö¿¡ ´ëÇÑ ¾ÖÁ¤

    [http]TUGboat Volume 26 (2005), No.3¿¡ [http]Interview with Donald E. Knuth¶ó´Â Á¦¸ñÀ¸·Î KnuthÀÇ ÀÎÅÍºä ±â»ç°¡ ½Ç·È½À´Ï´Ù. ÀÌ ±â»ç¿¡¼­ TeXÀ» ¸¸µé±â À§Çؼ­ ¾î¶² ÅøÀ» »ç¿ëÇߴ°¡¶ó´Â Áú¹®¿¡´ëÇÑ ±×ÀÇ ´ë´ä¿¡¼­ KnuthÀÇ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö¿¡ ´ëÇÑ »ç¶ûÀ» ¿³º¼ ¼ö ÀÖ´Â ºÎºÐÀÌ Àֱ⿡ ¿Å°Ü º¾´Ï´Ù.

    "The tools I used were home grown and became known as Literate Programming. I am enormously biased about Literate Programming, which is surely the greatest thing since sliced bread. I continue to use it to write programs almost every day, and it helps me get efficient, robust, maintainable code much more successfully than any other way I know. Of course, I realize that other people might find other approaches more to their liking; but wow, I love the tools I¡¯ve got now. I couldn¡¯t have written difficult programs like the MMIX meta-simulator at all if I hadn¡¯t had Literate Programming; the task would have been too difficult."

    1.4 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö °ü·Ã ±Û

    • @fine_art_programming.pdf (54.54 KB) : [http]Free Software Magazine Issue 6¿¡ ½Ç¸° ±Û·Î½á, Free software¿Í ¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀÇ ¹Ì·¡¿¡ ´ëÇÑ ±ÛÀÔ´Ï´Ù. Àо ¸¸ÇÕ´Ï´Ù. (Âü°í·Î ÀúÀÚ Matt BartonÀº St. Cloud State University in MinnesotaÀÇ ¿µ¹®ÇÐ ±³¼ö¶ó°í ÇÕ´Ï´Ù.)

    2 ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö ½Ã½ºÅÛ

    ¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀº ÇÁ·Î±×·¥ ¼Ò½º¿Í ±×¿¡ ´ëÇÑ ¹®¼­È­ ÀÛ¾÷À» µ¿½Ã¿¡ ÇÏ´Â °ÍÀÌ´Ù. µû¶ó¼­ ¹®ÇÐÀû ÇÁ·Î±×·¥ÀÇ ¼Ò½º´Â Å©°Ô ÇÁ·Î±×·¡¹Ö ºÎºÐ°ú ¹®¼­È­ ºÎºÐÀ¸·Î ³ª´µ¾îÁø´Ù. ÇÁ·Î±×·¡¹Ö ºÎºÐÀº ÇÁ·Î±×·¡¹Ö ¾ð¾î¿¡ µû¶ó ´Ù¸£Áö¸¸, ¹®¼­È­ ºÎºÐÀº ±âº»ÀûÀ¸·Î LaTeX ȤÀº plain TeXÀ» ÀÌ¿ëÇÑ´Ù. µû¶ó¼­ ¹®¼­È­ ºÎºÐ¿¡ ¾î¶² TeXÀ» »ç¿ëÇÏ´À³Ä¿¡ µû¶ó ³ª´· ¼ö ÀÖ°Ú´Ù.

    2.1 LaTeXÀ» ÀÌ¿ëÇÑ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö

    WEB/CWEB Àº ±âº»ÀûÀ¸·Î TeX À» »ç¿ëÇϵµ·Ï ¼³°èµÇ¾î ÀÖÁö¸¸ ¿©·¯°¡Áö ¹æ¹ýÀ» ÀÌ¿ëÇؼ­ LaTeX ¿¡¼­ »ç¿ëÇÒ ¼ö ÀÖ´Ù. Å©°Ô ´ÙÀ½ÀÇ µÎ°¡Áö ¹æ¹ýÀÌ ÀÖ´Ù.
    • nowebÀ» ÀÌ¿ëÇÏ´Â ¹æ¹ý
    • CWEBÀ» ÀÌ¿ëÇÏ´Â ¹æ¹ý

    2.1.1 noweb À» ÀÌ¿ëÇÏ´Â ¹æ¹ý

    noweb Àº LaTeX À» ÀÌ¿ëÇÒ ¼ö ÀÖµµ·Ï, ¶Ç ¿©·¯°¡Áö ÇÁ·Î±×·¡¹Ö ¾ð¾î¸¦ »ç¿ëÇÒ ¼ö ÀÖµµ·Ï º¯°æÇÑ, WEB ÀÌ´Ù. ½ÇÁ¦·Î LaTeX À» »ç¿ëÇϱâ À§Çؼ­´Â noweb À» »ç¿ëÇÏ´Â °ÍÀÌ Á¤´äÀ̶ó°í º¼ ¼ö ÀÖ´Ù.
    • ÀåÁ¡ : ½ºÅ¸ÀÏ ÆÄÀϸ¸À» Á¦°øÇÔÀ¸·Î¼­ ±âÁ¸ÀÇ Å¬·¡½ºµé°ú È¥¿ëÇÏ¿© »ç¿ëÇÏ´Â °ÍÀÌ °¡´ÉÇÏ´Ù. ¿©·¯°¡Áö ÇÁ·Î±×·¡¹Ö ¾ð¾î¸¦ Á¦°øÇÑ´Ù.
    • ´ÜÁ¡ : nawk µî ´Ù¸¥ À¯Æ¿¸®Æ¼¸¦ »ç¿ëÇÏ¿© ¼Ò½º¸¦ ÄÄÆÄÀÏ ÇÏ°Ô µÇ¹Ç·Î Á÷°üÀûÀÌÁö ¾ÊÀº ¼³Ä¡°úÁ¤ÀÌ ÇÊ¿äÇÏ´Ù. ±âÁ¸ÀÇ CWEB ¾ð¾î¿Í´Â Á¶±Ý ´Ù¸£´Ù.

    2.1.2 CWEB À» ÀÌ¿ëÇÏ´Â ¹æ¹ý

    CWEBÀº LaTeXÀ» ÀÌ¿ëÇÑ ¹æ¹ýµµ ÀÖÁö¸¸, LaTeXÀ» ÀÌ¿ëÇÏ·Á¸é, nowebÀ» ±ÇÀåÇÑ´Ù.

    CWEBÀ¸·Î ÀÛ¼ºµÈ w ÆÄÀÏÀ» ±â¹ÝÀ¸·Î ÇÑ´Ù. cweb.cls ¶ó°í Çϴ Ŭ·¡½º ÆÄÀÏÀÌ ÀÖÀ¸¹Ç·Î À̸¦ ÀÌ¿ëÇÏ°Ô µÈ´Ù.
    • ÀåÁ¡ : ±âÁ¸ÀÇ w ÆÄÀϵéÀ» ¸î°¡Áö º¯°æÇÔÀ¸·Î¼­ LaTeX »ó¿¡¼­ »ç¿ëÀÌ °¡´ÉÇÏ´Ù.
    • ´ÜÁ¡ : Ŭ·¡½º ÆÄÀϸ¸À» Á¦°øÇÔÀ¸·Î¼­ º»°ÝÀûÀÎ È®ÀåÀÌ °ÅÀÇ ºÒ°¡´É ÇÏ´Ù. ¿¹¸¦ µé¾î¼­ ¸Þ¸ð¾Æ¿Í °°ÀÌ »ç¿ëÇϱâ À§Çؼ­´Â Ŭ·¡½º ÆÄÀÏÀÎ cweb.cls ¸¦ .sty ÆÄÀÏ·Î º¯°æÇØ¾ß Çϴµ¥, ÀÌ ³ë·ÂÀº °ÅÀÇ ¹«ÀÇ¹Ì ÇÏ´Ù°í »ý°¢ÀÌ µÈ´Ù.

    2.1.3 ±âŸ ÀÚ·á

    LaTeX¿¡¼­ CWEB ÇÁ·Î±×·¡¹ÖÀ» À§ÇÑ ¹æ¹ýÀÌ ¼³¸íµÇ¾î ÀÖ´Ù.

    2.2 PlainTeXÀ» ÀÌ¿ëÇÑ ¹®ÇÐÀû ÇÁ·Î±×·¡¹Ö

    • CWEB
    • CTWILL: ÁַΠåÀ» ¸¸µå´Â °æ¿ì¿¡ ÀÌ¿ëµÈ´Ù.
    • [http]Rambutan: ÇÁ·Î±×·¡¹Ö ¾ð¾î·Î Java¸¦ »ç¿ëÇÑ´Ù´Â °Í¸¸ »©¸é CWEB°ú ¸ðµç °ÍÀÌ µ¿ÀÏÇÏ´Ù.
      • javaweave(CWEBÀÇ cweave¿¡ ÇØ´ç) Ãâ·Â Æ÷¸äÀÌ CWEB°ú ¶È°°´Ù.
      • ÇÏÁö¸¸ Çѱ۰ú ºÏ¸¶Å©°¡ ¾ÈµÈ´Ù.
      • Java ÇÁ·Î±×·¡¹ÖÀ» ÀÌ¿ëÇÏ¿© ¹®ÇÐÀû ÇÁ·Î±×·¡¹ÖÀ» ÇÒ ¶§´Â nowebÀ» ÃßõÇÑ´Ù.

    ^
    Valid XHTML 1.0! Valid CSS! powered by MoniWiki
    last modified 2006-07-17 12:03:48
    Processing time 0.0578 sec