Drawing Braids: Difference between revisions

From Knot Atlas
Jump to navigationJump to search
No edit summary
 
No edit summary
Line 4: Line 4:


<!--$$?BraidPlot$$-->
<!--$$?BraidPlot$$-->
<!--The lines to END were generated by WikiSplice: do not edit; see manual.-->
{{Help1|n=2|s=BraidPlot}}
BraidPlot[br, opts] produces a plot of the braid br. Possible options are Mode, HTMLOpts and Images.
{{Help2}}
<!--END-->
<!--END-->


Line 9: Line 13:


<!--$$br = BR[5, {{1,3}, {-2,-4}, {1, 3}}];$$-->
<!--$$br = BR[5, {{1,3}, {-2,-4}, {1, 3}}];$$-->
<!--The lines to END were generated by WikiSplice: do not edit; see manual.-->
{{In1|n=3}}
br = BR[5, {{1,3}, {-2,-4}, {1, 3}}];
{{In2}}
<!--END-->
<!--END-->


<!--$$Show[BraidPlot[br]]$$-->
<!--$$Show[BraidPlot[br]]$$-->
<!--The lines to END were generated by WikiSplice: do not edit; see manual.-->
{{Graphics1|n=4}}
Show[BraidPlot[br]]
{{Graphics2|n=4|imagename=Drawing_Braids_Out_4.gif}}
<!--END-->
<!--END-->


Line 17: Line 29:


<!--$$Options[BraidPlot]$$-->
<!--$$Options[BraidPlot]$$-->
<!--The lines to END were generated by WikiSplice: do not edit; see manual.-->
{{InOut1|n=5}}
Options[BraidPlot]
{{InOut2|n=5}}<pre style="border: 0px; padding: 0em">{Mode -> Graphics, Images -> {0.gif, 1.gif, 2.gif, 3.gif, 4.gif}, HTMLOpts -> }</pre>
{{InOut3}}
<!--END-->
<!--END-->


Line 22: Line 39:


<!--$$BraidPlot[br, Mode -> "HTML"]$$-->
<!--$$BraidPlot[br, Mode -> "HTML"]$$-->
<!--The lines to END were generated by WikiSplice: do not edit; see manual.-->
{{InOut1|n=6}}
BraidPlot[br, Mode -> "HTML"]
{{InOut2|n=6}}<pre style="border: 0px; padding: 0em"><table cellspacing=0 cellpadding=0 border=0>
<tr><td><img src=1.gif><img src=0.gif><img src=1.gif></td></tr>
<tr><td><img src=2.gif><img src=3.gif><img src=2.gif></td></tr>
<tr><td><img src=1.gif><img src=4.gif><img src=1.gif></td></tr>
<tr><td><img src=2.gif><img src=3.gif><img src=2.gif></td></tr>
<tr><td><img src=0.gif><img src=4.gif><img src=0.gif></td></tr>
</table></pre>
{{InOut3}}
<!--END-->
<!--END-->



Revision as of 18:27, 24 August 2005


(For In[1] see Setup)

In[2]:= ?BraidPlot

BraidPlot[br, opts] produces a plot of the braid br. Possible options are Mode, HTMLOpts and Images.

Thus for example,

In[3]:=

br = BR[5, {{1,3}, {-2,-4}, {1, 3}}];

In[4]:=

Show[BraidPlot[br]]

Drawing Braids Out 4.gif
Out[4]= -Graphics-

BraidPlot takes several options:

In[5]:=

Options[BraidPlot]

Out[5]=
{Mode -> Graphics, Images -> {0.gif, 1.gif, 2.gif, 3.gif, 4.gif}, HTMLOpts -> }

The Mode option to BraidPlot defaults to "Graphics", which produces output as above. An alternative is setting Mode -> "HTML", which produces an HTML <table> that can be readily inserted into HTML documents:

In[6]:=

BraidPlot[br, Mode -> "HTML"]

Out[6]=
<table cellspacing=0 cellpadding=0 border=0>
<tr><td><img src=1.gif><img src=0.gif><img src=1.gif></td></tr>
<tr><td><img src=2.gif><img src=3.gif><img src=2.gif></td></tr>
<tr><td><img src=1.gif><img src=4.gif><img src=1.gif></td></tr>
<tr><td><img src=2.gif><img src=3.gif><img src=2.gif></td></tr>
<tr><td><img src=0.gif><img src=4.gif><img src=0.gif></td></tr>
</table>

The table produced contains an array of image inclusions that together draws the braid using 5 fundamental building blocks: a horizontal "unbraided" line (0.gif above), the upper and lower halves of an overcrossing (1.gif and 2.gif above) and the upper and lower halves of an underfcrossing (3.gif and 4.gif above).

Assuming 0.gif through 4.gif are BraidPart0, BraidPart1, BraidPart2, BraidPart3 and BraidPart4,