Using Emacs' outline-mode for writing a paper outline/draft and presentation slides (2005/6/8)

[Japanese]

1. Add these lines to your ~/.emacs.
  ;; outline
  (add-hook 'outline-mode-hook
          '(lambda ()
             (setq outline-regexp "\\(\\*\\|-\\|  -\\|    -\\)")
             (setq outline-level
                   '(lambda ()
                      (cond ((looking-at "\\*") 1)
                            ((looking-at "-") 2)
                            ((looking-at "  -") 3)
                            ((looking-at "    -") 4)
                            (t 1000))))))
  (setq outline-font-lock-keywords
    '(;;
      ;; Highlight headings according to the level.
      (eval . (list (concat "^" outline-regexp ".+")
                  0 '(or (cdr (assq (outline-font-lock-level)
                                    '((1 . font-lock-function-name-face)
                                      (2 . font-lock-variable-name-face)
                                      (3 . font-lock-doc-face)
                                      (4 . font-lock-comment-face)
                                      (5 . font-lock-comment-face)
                                      (6 . font-lock-type-face)
                                      (7 . font-lock-type-face)
                                      (8 . font-lock-string-face))))
                         font-lock-warning-face)
                  nil t))))

Note that this definition overrides outline-mode definition of Emacs.

2. Write a paper outline/draft or presentation slides as follows.
  * Top Level Item
  
  - Second level item
    - Third level item
      - Fourth level item

Emacs automatically highlits each level with a different face.

An example of my presentation slides, which was presented at SPIE's International Symposium on the Convergence of Information Technologies and Communications (ITCom 2004), is shown below.

  -*- Outline -*-
  
  * Title
  
  - On Packet Marking Function of Active Queue Management Mechanism: Should It Be Linear, Concave, or Convex?
  - Hiroyuki Ohsaki and Masayuki Murata
  - Graduate School of Information Science and Technology, Osaka University, Japan
  - oosaki[atmark]ist.osaka-u.ac.jp
  
  * Contents
  
  - Introduction
    - RED (Random Early Detection)
    - Objectives
  - Analysis
  - Numerical Examples
  - Conclusion
  
  * Background
  
  - AQM (Active Queue Management) mechanisms
    - Studied by many researchers
    - Supports the congestion control mechanism of TCP
  
  - RED (Random Early Detection)
    - A representative AQM mechanism
    - Randomly discards an arriving packet
      - Keeps the average queue length small
      - Achieves high throughput
    - Its operation algorithm is quite simple
  
  * RED Known Problems
  
  - Parameter sensitivity
    - Effectiveness is dependent on four control parameters
    - Average queue length is dependent on traffic load
      - i.e., the number of active TCP connections
  
  - Parameter tuning difficulty
    - The optimal control parameters is affected by traffic load
  
  - More understanding on RED is necessary
  
  * RED Packet Marking Probability
  
  - RED randomly discards an arriving packet with a probability proportional to its average queue length
  
  * Question on RED Packet Marking Probability
  
  - Analytically known facts
    - TCP throughput is inversely proportional to p^(1/2)
      - p: the packet loss probability in the network
    - For M/M/1 queueing system, the average queue length is (rho/(1-rho))
      - rho: utilization factor
    - So, should the packet marking probability not be changed linearly?
  
  - Question
    - For achieving good steady state and transient state performances...
    - Whether the packet marking probability should be proportional to the average queue length or not? 
  
  * Objectives
  
  - Investigate effect of packet marking function on RED's performance
    - Steady state performance
    - Transient state performance
  
  - Show how the packet marking function should be determined
    - Utilize analytic results of TCP and RED steady state analysis
  
  - Consider three classes of packet marking functions
    - Linear, concave, and convex
    - Show which packet marking functions is the best...
      - in terms of good transient state performance and robustness
  
  * Analysis Overview
  
  - 1. Replace the packet marking function with a generic one
  
  - 2. Combining two analytic models
    - Stochastic model of TCP window size
    - Deterministic model of RED queue length
  
  - 3. Analyze toward what value the average queue length converges...
    - for a given average queue length
  
  * 1. Replace Packet Marking Function and Define Queue Occupancy
  
  - The packet marking function is replaced by
    - (2)
  
  - Introduce ``queue occupancy''
  
  * 2. Combining Two Analytic Models
  
  - Expected value of TCP window size: w(p)
    - (3)
    - (4)
    - b: the number of packets required for returning an ACK packet
    - p: the packet loss probability in the network
  
  - Queue length of RED in steady state: qavg
    - (5)
    - N: the number of TCP connections
    - w: TCP window size
    - B: maximum transmission capacity of RED router
    - tau: two-way propagation delay of TCP connection
  
  * 3. Analyze Average Queue Length Convergence Point
  
  - Average queue length convergence point: qavg
    - (8)
  - Queue occupancy in steady state: x^*
    - (9)
  
  * Effect of Packet Marking Function
  
  - Fig. 2
  
  * Optimal Packet Marking Function
  
  - Packet marking function should be chosen such that Eq. (9) becomes a linear function 
    - (10)
  
  - By solving the above equation, we have
    - (11)
  
  - To optimize the steady state and transient state performances...
    - f(x) must be changed according to N
    - N: the number of active TCP connections
  
  - However, Eq. (11) is impractical...
    - since RED router has no capability to know the number of active TCP connections
  
  * Three Function Classes: Linear, Concave, Convex
  
  - Linear
    - Eq (11)
  
  - Concave
    - Eq (12)
  
  - Convex
    - Eq. (13)
  
  * RED Queue Occupancy (Linear Case)
  
  - Fig. 3
  
  * RED Queue Occupancy (Concave Case)
  
  - Fig. 4
  
  * RED Queue Occupancy (Convex Case)
  
  - Fig. 5
  
  * Conclusion
  
  - Analyze effect of packet marking function on RED's performance
    - Steady state performance
    - Transient state performance
  
  - Show how the packet marking function should be determined
    - Utilize analytic results of TCP and RED steady state analysis
    - Derive the optimal packet marking function
  
  - Consider three classes of packet marking functions
    - Linear, concave, and convex
    - Show RED with concave function works best...
      - in terms of good transient state performance and robustness

See the "Outline Mode" section of GNU Emacs manual page for details of the outline-mode, or run M-x describe-mode or M-x describe-bindings for usage summary.

  Commands:
  C-c C-n   outline-next-visible-heading      move by visible headings
  C-c C-p   outline-previous-visible-heading
  C-c C-f   outline-forward-same-level        similar but skip subheadings
  C-c C-b   outline-backward-same-level
  C-c C-u   outline-up-heading              move from subheading to heading
  
  C-c C-t       make all text invisible (not headings).
  C-c C-a       make everything in buffer visible.
  
  The remaining commands are used when point is on a heading line.
  They apply to some of the body or subheadings of that heading.
  C-c C-d   hide-subtree        make body and subheadings invisible.
  C-c C-s   show-subtree        make body and subheadings visible.
  C-c TAB   show-children       make direct subheadings visible.
                 No effect on body, or subheadings 2 or more levels down.
                 With arg N, affects subheadings N levels down.
  C-c C-c          make immediately following body invisible.
  C-c C-e          make it visible.
  C-c C-l          make body under heading and under its subheadings invisible.
                     The subheadings remain visible.
  C-c C-k  make all subheadings at all levels visible.
4. Convert the outline file to LaTeX format, if you need.

Use a simple Perl script for outline-to-LaTeX conversion.

  http://www.lsnl.jp/~ohsaki/software/perl/outline2tex

For converting to a presentation slide, use -s option.

5. Convert the outline file to HTML format or PPT (Microsoft PowerPoint) format, if you need.

Use a simple Perl script for outline-to-HTML conversion.

  http://www.lsnl.jp/~ohsaki/software/perl/outline2html

For converting to a PPT file, take the following steps:

1. Open the HTML-converted file with Microsoft Word.
2.In Microsoft Word, use File -> Send... -> Microsoft PowerPoint.

Hiroyuki Ohsaki (ohsaki[atmark]lsnl.jp)