
˽Xc           @` s  d  d l  m Z m Z m Z d  d l Z d  d l Z e j d  d k rZ d  d l m Z n d  d l m Z d  d l	 Z	 d  d l
 Z d  d l m Z m Z m Z d  d l m Z m Z m Z d  d l m Z m Z d  d l m Z m Z d	 Z e d) e j d d d d d d d d d d g
 d  d d d  d  d! d! d" d# d# g
 g  f  Z d$   Z d% e f d&     YZ d' e f d(     YZ d S(*   i    (   t   divisiont   print_functiont   absolute_importNi   (   t   StringIO(   t   TestCaset   assert_equalt   assert_array_almost_equal_nulp(   t
   coo_matrixt
   csc_matrixt   rand(   t   hb_readt   hb_write(   t   HBFilet   HBInfos%  No Title                                                                |No Key
             9             4             1             4
RUA                      100           100            10             0
(26I3)          (26I3)          (3E23.15)
1  2  2  2  2  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3
3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3  3
3  3  3  3  3  3  3  4  4  4  6  6  6  6  6  6  6  6  6  6  6  8  9  9  9  9
9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9  9 11
37 71 89 18 30 45 70 19 25 52
2.971243799687726e-01  3.662366682877375e-01  4.786962174699534e-01
6.490068647991184e-01  6.617490424831662e-02  8.870370343191623e-01
4.196478590163001e-01  5.649603072111251e-01  9.934423887087086e-01
6.912334991524289e-01
g?gC&9kp?g)u?gMf?g"?g}b?gPٓ?gL`'?g>G?gO=?i$   iF   iX   i   i   i,   iE   i   i   i3   i   i:   i=   iH   iI   ic   c         C` sX   t  |   }  t  |  } t |  j | j  t |  j | j  t |  j | j d  d  S(   Ni'  (   R   R   t   indptrt   indicesR   t   data(   t   rt   l(    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyt   assert_csc_almost_equal/   s
    t   TestHBReaderc           B` s   e  Z d    Z RS(   c         C` s#   t  t t   } t | t  d  S(   N(   R
   R   t   SIMPLER   t   SIMPLE_MATRIX(   t   selft   m(    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyt   test_simple8   s    (   t   __name__t
   __module__R   (    (    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyR   7   s   t   TestRBRoundtripc           B` s   e  Z d    Z RS(   c         C` s   t  d d d  j   } t j d d  \ } } z) t | | t j |   t |  } Wd  t j	 |  t j
 |  Xt | |  d  S(   Nid   i  g?t   suffixt   rb(   R	   t   tocsct   tempfilet   mkstempR   R   t	   from_dataR
   t   ost   closet   removeR   (   R   t   rmt   fdt   filenameR   (    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyR   >   s    (   R   R   R   (    (    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyR   =   s   (
   g?gC&9kp?g)u?gMf?g"?g}b?gPٓ?gL`'?g>G?gO=?(    t
   __future__R    R   R   R#   t   syst   version_infot   ioR   R    t   numpyt   npt   numpy.testingR   R   R   t   scipy.sparseR   R   R	   t   scipy.ioR
   R   t   scipy.io.harwell_boeingR   R   R   t   arrayR   R   R   R   (    (    (    sD   /tmp/pip-build-7oUkmx/scipy/scipy/io/harwell_boeing/tests/test_hb.pyt   <module>   s*     '0	