<?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>toCC -- convert to high-precision complex number</title> <link rel="stylesheet" type="text/css" href="../../../../Macaulay2/Style/doc.css"/> </head> <body> <table class="buttons"> <tr> <td><div><a href="_to__Dual.html">next</a> | <a href="_to__Absolute__Path.html">previous</a> | <a href="_to__Dual.html">forward</a> | <a href="_to__Absolute__Path.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>toCC -- convert to high-precision complex number</h1> <div class="single"><h2>Description</h2> <div><div><h2>Synopsis</h2> <ul><li><div class="list"><dl class="element"><dt class="heading">Usage: </dt><dd class="value"><div><tt>toCC(prec,x,y)</tt><br/><tt>toCC(prec,x)</tt></div> </dd></dl> </div> </li> <li>Inputs:<ul><li><span><tt>prec</tt>, <span>an <a href="___Z__Z.html">integer</a></span>, the number of bits of precision desired</span></li> <li><span><tt>x</tt>, <span>an <a href="___Z__Z.html">integer</a></span>, <span>a <a href="___Q__Q.html">rational number</a></span>, or <span>a <a href="___R__R.html">real number</a></span></span></li> <li><span><tt>y</tt>, <span>an <a href="___Z__Z.html">integer</a></span>, <span>a <a href="___Q__Q.html">rational number</a></span>, or <span>a <a href="___R__R.html">real number</a></span></span></li> </ul> </li> <li>Outputs:<ul><li><span><span>a <a href="___C__C.html">complex number</a></span>, the complex number with real part <tt>x</tt> and complex part <tt>y</tt>. If <tt>y</tt> is omitted, the imaginary part is zero.</span></li> </ul> </li> </ul> <table class="examples"><tr><td><pre>i1 : toCC(200,7) o1 = 7 o1 : CC (of precision 200)</pre> </td></tr> <tr><td><pre>i2 : toCC(100,7,3.) o2 = 7+3*ii o2 : CC (of precision 100)</pre> </td></tr> </table> </div> <div><h2>Synopsis</h2> <ul><li><div class="list"><dl class="element"><dt class="heading">Usage: </dt><dd class="value"><div><tt>toCC(x,y)</tt><br/><tt>toCC x</tt></div> </dd></dl> </div> </li> <li>Inputs:<ul><li><span><tt>x</tt>, <span>a <a href="___R__R.html">real number</a></span></span></li> <li><span><tt>y</tt>, <span>a <a href="___R__R.html">real number</a></span></span></li> </ul> </li> <li>Outputs:<ul><li><span><span>a <a href="___C__C.html">complex number</a></span>, the complex number with real part <tt>x</tt> and complex part <tt>y</tt>. If <tt>y</tt> is omitted, the imaginary part is zero. The precision of the result is the minimum precision of the arguments.</span></li> </ul> </li> </ul> <table class="examples"><tr><td><pre>i3 : toCC(3.,4.) o3 = 3+4*ii o3 : CC (of precision 53)</pre> </td></tr> <tr><td><pre>i4 : toCC(3.p100,4.p200) o4 = 3+4*ii o4 : CC (of precision 100)</pre> </td></tr> </table> </div> </div> </div> <div class="waystouse"><h2>Ways to use <tt>toCC</tt> :</h2> <ul><li>toCC(CC)</li> <li>toCC(QQ)</li> <li>toCC(RR)</li> <li>toCC(RR,RR)</li> <li>toCC(ZZ)</li> <li>toCC(ZZ,CC)</li> <li>toCC(ZZ,QQ)</li> <li>toCC(ZZ,QQ,QQ)</li> <li>toCC(ZZ,QQ,RR)</li> <li>toCC(ZZ,QQ,ZZ)</li> <li>toCC(ZZ,RR)</li> <li>toCC(ZZ,RR,QQ)</li> <li>toCC(ZZ,RR,RR)</li> <li>toCC(ZZ,RR,ZZ)</li> <li>toCC(ZZ,ZZ)</li> <li>toCC(ZZ,ZZ,QQ)</li> <li>toCC(ZZ,ZZ,RR)</li> <li>toCC(ZZ,ZZ,ZZ)</li> </ul> </div> </div> </body> </html>