Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 7ebd25ac536d248d499a3ce2acda963a > files > 2260

Macaulay2-1.3.1-8.fc15.i686.rpm

-- -*- M2-comint -*- {* hash: -1539528818 *}

i1 : stderr << "-- hi there --" << endl
-- hi there --

o1 = stderr

o1 : File

i2 : << "-- ho there --" << endl
-- ho there --

o2 = stdio

o2 : File

i3 : fn = temporaryFileName()

o3 = /tmp/M2-22789-1

i4 : fn << "hi there" << endl << close

o4 = /tmp/M2-22789-1

o4 : File

i5 : get fn

o5 = hi there


i6 : R = QQ[x]

o6 = R

o6 : PolynomialRing

i7 : f = (x+1)^10

      10      9      8       7       6       5       4       3      2
o7 = x   + 10x  + 45x  + 120x  + 210x  + 252x  + 210x  + 120x  + 45x  + 10x +
     ------------------------------------------------------------------------
     1

o7 : R

i8 : << f
 10      9      8       7       6       5       4       3      2
x   + 10x  + 45x  + 120x  + 210x  + 252x  + 210x  + 120x  + 45x  + 10x + 1
o8 = stdio

o8 : File

i9 : fn << f << close

o9 = /tmp/M2-22789-1

o9 : File

i10 : get fn

o10 =  10      9      8       7       6       5       4       3      2
      x   + 10x  + 45x  + 120x  + 210x  + 252x  + 210x  + 120x  + 45x  + 10x
      + 1

i11 : fn << toExternalString f << close

o11 = /tmp/M2-22789-1

o11 : File

i12 : get fn

o12 = x^10+10*x^9+45*x^8+120*x^7+210*x^6+252*x^5+210*x^4+120*x^3+45*x^2+10*x+
      1

i13 : value get fn

       10      9      8       7       6       5       4       3      2
o13 = x   + 10x  + 45x  + 120x  + 210x  + 252x  + 210x  + 120x  + 45x  + 10x
      -----------------------------------------------------------------------
      + 1

o13 : R

i14 : removeFile fn

i15 :