Although this table is a bit unrealistically complicated one, certainly it is a nightmare to write an HTML file of this table manually. Creating this kind of table with table.el package is relatively easy by using cell spanning commands and cell splitting commands because the operation is interactive and the result is WYSIWYG.

Now move the point in anywhere in the table and issue the command to generate HTML file.

Then select the buffer to insert the result. Also specify a caption or a title of the table.

Voila!

Finally, let's see how the resulted HTML source is rendered in this browser. It looks pretty good. For closer examination see the source of this page. The generated table HTML source is inserted verbatim in this page.

Table
0     1           2    
     
     
     
     
3          
           
           
4     5    
     
     
6           7     8    
     
     
9     10         
           
11          12   
     
     
13    14          15    16   
     
     
17         
18    19   
     
     
     
     
     
     
20          21   
     
     
22         
           
23   
     
     
24         
           
           
25   
     
     
26   
     
     
27   
     
     
28   
     
     
29    30    31