06-1350/Syzygies in Asymptote in Brief: Difference between revisions
From Drorbn
Jump to navigationJump to search
(For Handout.) |
No edit summary |
||
(7 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
===Installation=== |
===Installation=== |
||
See [[Syzygies in Asymptote]] for more detailed information. |
See [[06-1350/Syzygies in Asymptote]] for more detailed information. |
||
First install [http://asymptote.sourceforge.net Asymptote]. Once installed, download [http://www.math.utoronto.ca/~andy/syzygy.asy syzygy.asy]. |
First install [http://asymptote.sourceforge.net Asymptote]. Once installed, download [http://www.math.utoronto.ca/~andy/syzygy.asy syzygy.asy]. |
||
===Braids=== |
===Braids=== |
||
{|align=center |
|||
⚫ | |||
|- |
|||
⚫ | |||
import syzygy; // Accesses the syzygy module. |
import syzygy; // Accesses the syzygy module. |
||
Braid b; // Start a new braid. |
Braid b; // Start a new braid. |
||
Line 17: | Line 19: | ||
b.draw(); // Draw the resulting braid. |
b.draw(); // Draw the resulting braid. |
||
</pre> |
</pre> |
||
|width="40pt"| |
|||
[[Image:06-1350-mybraid.png |
|[[Image:06-1350-mybraid.png]] |
||
|} |
|||
===Relations=== |
===Relations=== |
||
{|align=center |
|||
⚫ | |||
|- |
|||
⚫ | |||
import syzygy; // Access the syzygy module. |
import syzygy; // Access the syzygy module. |
||
Braid l; // Define the left hand side of the relation. |
Braid l; // Define the left hand side of the relation. |
||
Line 29: | Line 34: | ||
Relation r3; // Define a relation. |
Relation r3; // Define a relation. |
||
r3.lsym="\rho_3"; // Give the relation a name |
r3.lsym="\rho_3"; // Give the relation a formula name. |
||
r3.codename="rho3"; // Give the relation a name to be used by Mathematica. |
r3.codename="rho3"; // Give the relation a name to be used by Mathematica. |
||
r3.lhs=l; r3.rhs=r; |
r3.lhs=l; r3.rhs=r; |
||
r3.draw(); |
r3.draw(); |
||
</pre> |
</pre> |
||
|width="40pt"| |
|||
[[Image:06-1350-R3-asy.png |
|[[Image:06-1350-R3-asy.png]] |
||
|} |
|||
<code>r3.toFormula()</code> produces the formula: |
<code>r3.toFormula()</code> produces the formula: |
||
⚫ | |||
⚫ | |||
(1230)^\star B^+ (1213)^\star B^+ (1023)^\star B^+ = |
(1230)^\star B^+ (1213)^\star B^+ (1023)^\star B^+ = |
||
(1123)^\star B^+ (1203)^\star B^+ (1231)^\star B^+ |
(1123)^\star B^+ (1203)^\star B^+ (1231)^\star B^+ |
||
</math> |
</math></center> |
||
<code>r3.toLinear()</code> produces the formula in linear form: |
<code>r3.toLinear()</code> produces the formula in linear form: |
||
{|align=center |
|||
<math> |
|||
|- |
|||
⚫ | |||
|<math>\rho_3(x_1,x_2,x_3,x_4) = </math> |
|||
</math> |
|||
|<math>b^+(x_1,x_2,x_3) + b^+(x_1+x_3,x_2,x_4) + b^+(x_1,x_3,x_4)</math> |
|||
|- |
|||
| |
|||
⚫ | |||
|} |
|||
and <code>r3.toCode()</code> produces a version usable in Mathematica: |
and <code>r3.toCode()</code> produces a version usable in Mathematica: |
||
Line 58: | Line 68: | ||
===Syzygies=== |
===Syzygies=== |
||
⚫ | |||
{|align=center |
|||
|- |
|||
⚫ | |||
import syzygy; |
import syzygy; |
||
Line 87: | Line 100: | ||
pb.draw(); |
pb.draw(); |
||
</pre> |
</pre> |
||
|width="60pt"| |
|||
[[Image:06-1350- |
|[[Image:06-1350-bpsmall.png]] |
||
|} |
|||
Again, like relations, we can use <code>pb.toLinear()</code> |
Again, like relations, we can use <code>pb.toLinear()</code> |
Latest revision as of 21:54, 4 December 2006
Installation
See 06-1350/Syzygies in Asymptote for more detailed information.
First install Asymptote. Once installed, download syzygy.asy.
Braids
Relations
r3.toFormula()
produces the formula:
r3.toLinear()
produces the formula in linear form:
and r3.toCode()
produces a version usable in Mathematica:
rho3[x1_, x2_, x3_, x4_] :> bp[x1, x2, x3] + bp[x1 + x3, x2, x4] + bp[x1, x3, x4] - bp[x1 + x2, x3, x4] - bp[x1, x2, x4] - bp[x1 + x4, x2, x3]
Syzygies
Again, like relations, we can use pb.toLinear()
and pb.toCode()
PhiAroundB[x1_, x2_, x3_, x4_, x5_] :> rho3[x1, x2, x3, x5] + rho4a[x1 + x5, x2, x3, x4] + rho4b[x1 + x2, x3, x4, x5] - rho3[x1, x2, x3 + x4, x5] - rho4a[x1, x2, x3, x4] - rho4b[x1, x3, x4, x5] + rho3[x1 + x3, x2, x4, x5]
to produce formulas.