<html>
  <head>

    <meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    How to passing linspace array to mgrid in numpy.?<br>
    i Tried&nbsp; following code:<br>
    <meta name="qrichtext" content="1">
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;
      -qt-user-state:0;">import numpy as np</p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;
      -qt-user-state:0;">t = np.linspace(0, 10, 21)</p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;
      -qt-user-state:0;">x = np.linspace(-0.2, 2.2 , 25)</p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;
      -qt-user-state:0;">A,B = np.mgrid[t, x]</p>
    <p style=" margin-top:0px; margin-bottom:0px; margin-left:0px;
      margin-right:0px; -qt-block-indent:0; text-indent:0px;
      -qt-user-state:0;">print A,3*'\n' , B</p>
    <p style="-qt-paragraph-type:empty; margin-top:0px;
      margin-bottom:0px; margin-left:0px; margin-right:0px;
      -qt-block-indent:0; text-indent:0px;"><br>
      but i Get error result:<br>
      Traceback (most recent call last):<br>
      File "D:\python\project\fisika sistem kompleks\quiver_test.py",
      line 13, in &lt;module&gt;<br>
      A,B = np.mgrid[t, x]<br>
      File "C:\Python27\lib\site-packages\numpy\lib\index_tricks.py",
      line 149, in __getitem__<br>
      step = key[k].step<br>
      AttributeError: 'numpy.ndarray' object has no attribute 'step'<br>
    </p>
    <meta http-equiv="Content-Type" content="text/html;
      charset=ISO-8859-1">
    <style type="text/css">
p, li { white-space: pre-wrap; }
</style><br>
  </body>
</html>