<?xml version="1.0" encoding="utf-8" ?> <!-- for emacs: -*- coding: utf-8 -*- --> <!-- Apache may like this line in the file .htaccess: AddCharset utf-8 .html --> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1 plus MathML 2.0 plus SVG 1.1//EN" "http://www.w3.org/2002/04/xhtml-math-svg/xhtml-math-svg-flat.dtd" > <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> <head><title>rotate(ZZ,VisibleList) -- rotate a list</title> <link rel="stylesheet" type="text/css" href="../../../../Macaulay2/Style/doc.css"/> </head> <body> <table class="buttons"> <tr> <td><div><a href="_round.html">next</a> | <a href="_root__U__R__I.html">previous</a> | <a href="_round.html">forward</a> | <a href="_root__U__R__I.html">backward</a> | up | <a href="index.html">top</a> | <a href="master.html">index</a> | <a href="toc.html">toc</a> | <a href="http://www.math.uiuc.edu/Macaulay2/">Macaulay2 web site</a></div> </td> </tr> </table> <hr/> <div><h1>rotate(ZZ,VisibleList) -- rotate a list</h1> <div class="single"><h2>Synopsis</h2> <ul><li><div class="list"><dl class="element"><dt class="heading">Usage: </dt><dd class="value"><div><tt>rotate(n,v)</tt></div> </dd></dl> </div> </li> <li><span>Function: <a href="_rotate_lp__Z__Z_cm__Visible__List_rp.html" title="rotate a list">rotate</a></span></li> <li><div class="single">Inputs:<ul><li><span><tt>n</tt>, <span>an <a href="___Z__Z.html">integer</a></span></span></li> <li><span><tt>v</tt>, <span>a <a href="___Visible__List.html">visible list</a></span></span></li> </ul> </div> </li> <li><div class="single">Outputs:<ul><li><span>the list obtained by rotating the list <tt>v</tt> leftward <tt>n</tt> places</span></li> </ul> </div> </li> </ul> </div> <div class="single"><h2>Description</h2> <div><table class="examples"><tr><td><pre>i1 : p = 0 .. 20 o1 = (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, ------------------------------------------------------------------------ 20) o1 : Sequence</pre> </td></tr> <tr><td><pre>i2 : rotate(3,p) o2 = (3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 0, 1, ------------------------------------------------------------------------ 2) o2 : Sequence</pre> </td></tr> <tr><td><pre>i3 : rotate(-3,p) o3 = (18, 19, 20, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, ------------------------------------------------------------------------ 17) o3 : Sequence</pre> </td></tr> </table> </div> </div> </div> </body> </html>