+
    ʇi7T                        ^ RI Ht ^ RIHt ^ RIHtHt ^ RIt^ RIH	t
 ^ RIHtHtHt ^ RIHtHt  ! R R4      t ! R	 R
4      t ! R R4      t]P*                  P-                  RR7      R 4       t]P*                  P-                  RR7      R 4       t]P*                  P3                  R*]! ]! ^^4      ]! ^^4      .]R7      R3]! ^^]! ^^4      .]R7      R3]! ]! R4      ]! R4      ^.]R7      R334      R 4       t]P*                  P3                  R*]! . R+O]R7      R3]! ^^^^..]R7      R334      R 4       t ! R R4      t]P*                  P3                  R,]
P<                  R3]
P>                  R3]
P@                  R3]
PB                  R 3]
PD                  R!3]
PF                  R"334      R# 4       t$ ! R$ R%4      t% ! R& R'4      t&R-t' ! R( R)4      t(R# ).    )Decimal)Fraction)infnanN)arangearrayprintoptions)assert_assert_equalc                     a  ] tR t^t o ]P
                  ! RRR7      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t
]P                  P                  R . R!OR	3. R"OR
3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       tR tRtV tR# )#TestStrUnicodeSuperSubscriptsclassTscopeautousec                2    \         P                  ! R 4       R# unicodeNpolyset_default_printstyleselfs   &y/Users/max/.openclaw/workspace/postharvest/merge_env/lib/python3.14/site-packages/numpy/polynomial/tests/test_printing.pyuse_unicode)TestStrUnicodeSuperSubscripts.use_unicode   s    ##I.       1.0 + 2.0·x + 3.0·x²u#   -1.0 + 0.0·x + 3.0·x² - 1.0·x³u   0.0 + 1.0·x + 2.0·x² + 3.0·x³ + 4.0·x⁴ + 5.0·x⁵ + 6.0·x⁶ + 7.0·x⁷ +
8.0·x⁸ + 9.0·x⁹ + 10.0·x¹⁰ + 11.0·x¹¹c                ^    \         P                  ! V4      p\        V4      p\        WB4       R # N)r   
Polynomialstrr   )r   inptgtpress   &&&  r   test_polynomial_str1TestStrUnicodeSuperSubscripts.test_polynomial_str   s#     OOC !fSr   !   1.0 + 2.0·T₁(x) + 3.0·T₂(x)u1   -1.0 + 0.0·T₁(x) + 3.0·T₂(x) - 1.0·T₃(x)u   0.0 + 1.0·T₁(x) + 2.0·T₂(x) + 3.0·T₃(x) + 4.0·T₄(x) + 5.0·T₅(x) +
6.0·T₆(x) + 7.0·T₇(x) + 8.0·T₈(x) + 9.0·T₉(x) + 10.0·T₁₀(x) + 11.0·T₁₁(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r"   r   	Chebyshevr   r   r#   r$   r&   s   &&& r   test_chebyshev_str0TestStrUnicodeSuperSubscripts.test_chebyshev_str    s     $..%&Sr   u!   1.0 + 2.0·P₁(x) + 3.0·P₂(x)u1   -1.0 + 0.0·P₁(x) + 3.0·P₂(x) - 1.0·P₃(x)u   0.0 + 1.0·P₁(x) + 2.0·P₂(x) + 3.0·P₃(x) + 4.0·P₄(x) + 5.0·P₅(x) +
6.0·P₆(x) + 7.0·P₇(x) + 8.0·P₈(x) + 9.0·P₉(x) + 10.0·P₁₀(x) + 11.0·P₁₁(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r"   r   Legendrer   r-   s   &&& r   test_legendre_str/TestStrUnicodeSuperSubscripts.test_legendre_str+        $--$%Sr   u!   1.0 + 2.0·H₁(x) + 3.0·H₂(x)u1   -1.0 + 0.0·H₁(x) + 3.0·H₂(x) - 1.0·H₃(x)u   0.0 + 1.0·H₁(x) + 2.0·H₂(x) + 3.0·H₃(x) + 4.0·H₄(x) + 5.0·H₅(x) +
6.0·H₆(x) + 7.0·H₇(x) + 8.0·H₈(x) + 9.0·H₉(x) + 10.0·H₁₀(x) + 11.0·H₁₁(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r"   r   Hermiter   r-   s   &&& r   test_hermite_str.TestStrUnicodeSuperSubscripts.test_hermite_str6   s     $,,s#$Sr   u#   1.0 + 2.0·He₁(x) + 3.0·He₂(x)u4   -1.0 + 0.0·He₁(x) + 3.0·He₂(x) - 1.0·He₃(x)u   0.0 + 1.0·He₁(x) + 2.0·He₂(x) + 3.0·He₃(x) + 4.0·He₄(x) + 5.0·He₅(x) +
6.0·He₆(x) + 7.0·He₇(x) + 8.0·He₈(x) + 9.0·He₉(x) + 10.0·He₁₀(x) +
11.0·He₁₁(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r"   r   HermiteEr   r-   s   &&& r   test_hermiteE_str/TestStrUnicodeSuperSubscripts.test_hermiteE_strA        $--$%Sr   u!   1.0 + 2.0·L₁(x) + 3.0·L₂(x)u1   -1.0 + 0.0·L₁(x) + 3.0·L₂(x) - 1.0·L₃(x)u   0.0 + 1.0·L₁(x) + 2.0·L₂(x) + 3.0·L₃(x) + 4.0·L₄(x) + 5.0·L₅(x) +
6.0·L₆(x) + 7.0·L₇(x) + 8.0·L₈(x) + 9.0·L₉(x) + 10.0·L₁₀(x) + 11.0·L₁₁(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r"   r   Laguerrer   r-   s   &&& r   test_laguerre_str/TestStrUnicodeSuperSubscripts.test_laguerre_strM   r5   r   c                    \        \        P                  ! ^ ^.4      4      pRp\        W4       \        \        P                  ! ^ ^.^^.R7      4      pRp\        W4       R# )r   u   0.0 + 1.0·xdomainu   0.0 + 1.0·(-3.0 + 2.0x)Nr"   r   r!   r   r   r&   r$   s   &  r   test_polynomial_str_domains9TestStrUnicodeSuperSubscripts.test_polynomial_str_domainsX   sP    $//1a&)*S$//1a&!Q89(Sr    Nr#   r$            r   rR   rT   )__name__
__module____qualname____firstlineno__pytestfixturer   markparametrizer   r'   r.   r3   r9   r>   rD   rK   __static_attributes____classdictcell____classdict__s   @r   r   r      s    ^^'40/ 1/ [[^	-.	>?	 $ 	&. 
 [[^	78	LM	 K 	M.  [[^	78	LM	 K 	M.  [[^	78	LM	 K 	M.  [[^	9:	OP	 * 	,.  [[^	78	LM	 K 	M.  r   r   c                     a  ] tR t^at o ]P
                  ! RRR7      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t
]P                  P                  R . R!OR	3. R"OR
3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       t]P                  P                  R . R!OR3. R"OR3]	! ^4      R334      R 4       tR tRtV tR# )#TestStrAsciir   Tr   c                2    \         P                  ! R 4       R# asciiNr   r   s   &r   	use_asciiTestStrAscii.use_asciic       ##G,r   1.0 + 2.0 x + 3.0 x**2z"-1.0 + 0.0 x + 3.0 x**2 - 1.0 x**3z}0.0 + 1.0 x + 2.0 x**2 + 3.0 x**3 + 4.0 x**4 + 5.0 x**5 + 6.0 x**6 +
7.0 x**7 + 8.0 x**8 + 9.0 x**9 + 10.0 x**10 + 11.0 x**11c                Z    \        \        P                  ! V4      4      p\        W24       R # r    rI   r-   s   &&& r   r'    TestStrAscii.test_polynomial_strg   s     $//#&'Sr   1.0 + 2.0 T_1(x) + 3.0 T_2(x)z+-1.0 + 0.0 T_1(x) + 3.0 T_2(x) - 1.0 T_3(x)z0.0 + 1.0 T_1(x) + 2.0 T_2(x) + 3.0 T_3(x) + 4.0 T_4(x) + 5.0 T_5(x) +
6.0 T_6(x) + 7.0 T_7(x) + 8.0 T_8(x) + 9.0 T_9(x) + 10.0 T_10(x) +
11.0 T_11(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r+   r-   s   &&& r   r.   TestStrAscii.test_chebyshev_strr   s     $..%&Sr   z1.0 + 2.0 P_1(x) + 3.0 P_2(x)z+-1.0 + 0.0 P_1(x) + 3.0 P_2(x) - 1.0 P_3(x)z0.0 + 1.0 P_1(x) + 2.0 P_2(x) + 3.0 P_3(x) + 4.0 P_4(x) + 5.0 P_5(x) +
6.0 P_6(x) + 7.0 P_7(x) + 8.0 P_8(x) + 9.0 P_9(x) + 10.0 P_10(x) +
11.0 P_11(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r1   r-   s   &&& r   r3   TestStrAscii.test_legendre_str~   r@   r   z1.0 + 2.0 H_1(x) + 3.0 H_2(x)z+-1.0 + 0.0 H_1(x) + 3.0 H_2(x) - 1.0 H_3(x)z0.0 + 1.0 H_1(x) + 2.0 H_2(x) + 3.0 H_3(x) + 4.0 H_4(x) + 5.0 H_5(x) +
6.0 H_6(x) + 7.0 H_7(x) + 8.0 H_8(x) + 9.0 H_9(x) + 10.0 H_10(x) +
11.0 H_11(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r7   r-   s   &&& r   r9   TestStrAscii.test_hermite_str   s     $,,s#$Sr   z1.0 + 2.0 He_1(x) + 3.0 He_2(x)z.-1.0 + 0.0 He_1(x) + 3.0 He_2(x) - 1.0 He_3(x)z0.0 + 1.0 He_1(x) + 2.0 He_2(x) + 3.0 He_3(x) + 4.0 He_4(x) +
5.0 He_5(x) + 6.0 He_6(x) + 7.0 He_7(x) + 8.0 He_8(x) + 9.0 He_9(x) +
10.0 He_10(x) + 11.0 He_11(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    r<   r-   s   &&& r   r>   TestStrAscii.test_hermiteE_str   r@   r   z1.0 + 2.0 L_1(x) + 3.0 L_2(x)z+-1.0 + 0.0 L_1(x) + 3.0 L_2(x) - 1.0 L_3(x)z0.0 + 1.0 L_1(x) + 2.0 L_2(x) + 3.0 L_3(x) + 4.0 L_4(x) + 5.0 L_5(x) +
6.0 L_6(x) + 7.0 L_7(x) + 8.0 L_8(x) + 9.0 L_9(x) + 10.0 L_10(x) +
11.0 L_11(x)c                Z    \        \        P                  ! V4      4      p\        W24       R # r    rB   r-   s   &&& r   rD   TestStrAscii.test_laguerre_str   r@   r   c                    \        \        P                  ! ^ ^.4      4      pRp\        W4       \        \        P                  ! ^ ^.^^.R7      4      pRp\        W4       R# )r   z0.0 + 1.0 xrG   z0.0 + 1.0 (-3.0 + 2.0x)NrI   rJ   s   &  r   rK   (TestStrAscii.test_polynomial_str_domains   sP    $//1a&)*S$//1a&!Q89'Sr   rM   NrN   rO   rS   )rU   rV   rW   rX   rY   rZ   rf   r[   r\   r   r'   r.   r3   r9   r>   rD   rK   r]   r^   r_   s   @r   rb   rb   a   s    ^^'40- 1- [[^	,-	=>	 ; 	=.  [[^	34	FG	 % 	'.  [[^	34	FG	 % 	'.  [[^	34	FG	 % 	'.  [[^	56	IJ	 6 	8.  [[^	34	FG	 % 	'.  r   rb   c                      a  ] tR t^t o ]P
                  ! RRR7      R 4       tR tR tR t	R t
]P                  P                  RR4      R	 4       tR
tV tR# )TestLinebreakingr   Tr   c                2    \         P                  ! R 4       R# rd   r   r   s   &r   rf   TestLinebreaking.use_ascii   rh   r   c                    \         P                  ! . RO4      p\        \        \	        V4      4      ^J4       \        \	        V4      R4       R# )Na zJ12345678.0 + 12345678.0 x + 12345678.0 x**2 + 12345678.0 x**3 + 123.0 x**4N)r~   r~   r~   r~   {   r   r!   r   lenr"   r   r%   s   & r   test_single_line_one_less*TestLinebreaking.test_single_line_one_less   s6    OOIJSQ["%SV+	r   c                    \         P                  ! . RO4      p\        \        \	        V4      4      ^K4       \        \	        V4      R4       R# )r~   zK12345678.0 + 12345678.0 x + 12345678.0 x**2 + 12345678.0 x**3 +
1234.0 x**4N)r~   r~   r~   r~   i  r   r   s   & r   test_num_chars_is_linewidth,TestLinebreaking.test_num_chars_is_linewidth   s6    OOJKSQ["%SV-	r   c                    \         P                  ! . RO4      p\        \        \	        V4      P                  R4      ^ ,          4      ^J4       \        \	        V4      R4       R# )r~   
zZ12345678.0 + 12345678.0 x + 12345678.0 x**2 + 12345678.0 x**3 + 1.0 x**4 +
12345678.0 x**5N)r~   r~   r~   r~   rP   r~   )r   r!   r   r   r"   splitr   s   & r   6test_first_linebreak_multiline_one_less_than_linewidthGTestLinebreaking.test_first_linebreak_multiline_one_less_than_linewidth   sI    OOE 	SQd+A./4SV<	r   c                `    \         P                  ! . RO4      p\        \        V4      R4       R# )r~   z[12345678.0 + 12345678.0 x + 12345678.0 x**2 + 12345678.12 x**3 +
1.0 x**4 + 12345678.0 x**5N)r~   r~   r~   g=
)gArP   r~   )r   r!   r   r"   r   s   & r   +test_first_linebreak_multiline_on_linewidth<TestLinebreaking.test_first_linebreak_multiline_on_linewidth   s(    OOH 	SV=	r   c                2   \         P                  ! . RO4      p\        VR7      ;_uu_ 4        \        \	        V4      V4       \	        V4      P                  R4       F  p\        \        V4      V8  4       K  	  RRR4       R#   + '       g   i     R# ; i)r   )	linewidthr   N)
r   
      i  i@  i  i'	 ip i@  i  )r   r!   r	   r   r"   r   r
   r   )r   lwr$   r%   lines   &&&  r   test_linewidth_printoption+TestLinebreaking.test_linewidth_printoption   sf     OOG
 B''Q%AT*D	B' + ('''s   ABB	rM   N)r   r$   ))K   z0.0 + 10.0 x + 200.0 x**2 + 3000.0 x**3 + 40000.0 x**4 + 500000.0 x**5 +
600000.0 x**6 + 70000.0 x**7 + 8000.0 x**8 + 900.0 x**9)-   z0.0 + 10.0 x + 200.0 x**2 + 3000.0 x**3 +
40000.0 x**4 + 500000.0 x**5 +
600000.0 x**6 + 70000.0 x**7 + 8000.0 x**8 +
900.0 x**9)   z0.0 + 10.0 x + 200.0 x**2 + 3000.0 x**3 + 40000.0 x**4 + 500000.0 x**5 + 600000.0 x**6 + 70000.0 x**7 + 8000.0 x**8 + 900.0 x**9)rU   rV   rW   rX   rY   rZ   rf   r   r   r   r   r[   r\   r   r]   r^   r_   s   @r   rz   rz      s`     ^^'40- 1-	 [[] 
- 
(
(r   rz   z(set_default_printstyle() is global state)reasonc                     \         P                  ! . R	O4      p \         P                  ! . R	O4      p\         P                  ! R4       \	        \        V 4      R4       \	        \        V4      R4       \         P                  ! R4       \	        \        V 4      R4       \	        \        V4      R4       \        P                  ! \        4      ;_uu_ 4        \         P                  ! R4       RRR4       R#   + '       g   i     R# ; i)
rP   re   ri   rl   r   r   r)   invalid_inputNrO   )	r   r!   r,   r   r   r"   rY   raises
ValueError)r%   cs     r   test_set_default_printoptionsr      s    	"Ay!A(Q12Q89	*Q23Q<=	z	"	"##O4 
#	"	"	"s   C44D	c                    . R	Op \         P                  ! V 4      p\         P                  ! \        V \        R7      4      p\         P                  ! R4       \        \        V4      R4       \        \        V4      R4       \         P                  ! R4       \        \        V4      R4       \        \        V4      R4       R# )
z%Test both numpy and built-in complex.dtyper   u*   1j + (1+1j)·x - (2-2j)·x² + (3+0j)·x³u+   1j + (1+1j)·x + (-2+2j)·x² + (3+0j)·x³re   z)1j + (1+1j) x - (2-2j) x**2 + (3+0j) x**3z*1j + (1+1j) x + (-2+2j) x**2 + (3+0j) x**3N)y              ?y      ?      ?y              @y      @        )r   r!   r   objectr   r   r"   )coefsp1p2s      r   test_complex_coefficientsr     s     .E		B	uF3	4B	*RFGRGH(REFRFGr   r   u   1/2 + 3/4·xu   1 + 2·x + 5/7·x²z1.00z2.2u   1.00 + 2.2·x + 3·x²c                     \         P                  ! V 4      p\         P                  ! R 4       \        \	        V4      V4       R# r   r   r!   r   r   r"   r   r$   r%   s   && r    test_numeric_object_coefficientsr     s.     	A	*Qr   u   1 + 2·x + f·x²u   1 + 2·x + [3, 4]·x²c                    \         P                  ! V 4      p\         P                  ! R4       \        \	        V4      V4       R# )zC
Test coef fallback for object arrays of non-numeric coefficients.
r   Nr   r   s   && r   #test_nonnumeric_object_coefficientsr   (  s.     	A	*Qr   c                   8   a  ] tR tRt o R tR tR tR tRtV t	R# )
TestFormati5  c                    \         P                  ! R 4       \         P                  ! . RO4      p\        \	        VR4      R4       R# )re   r   u"   1.0 + 2.0·x + 0.0·x² - 1.0·x³NrP   rQ   r   rT   r   r   r!   r   formatr   s   & r   test_format_unicodeTestFormat.test_format_unicode6  s0    ##G,OOM*VAy)+OPr   c                    \         P                  ! R 4       \         P                  ! . RO4      p\        \	        VR4      R4       R# )r   re   z!1.0 + 2.0 x + 0.0 x**2 - 1.0 x**3Nr   r   r   s   & r   test_format_asciiTestFormat.test_format_ascii;  s3    ##I.OOM*1g C	
r   c                    \         P                  ! R 4       \         P                  ! . RO4      p\        \	        V4      R4       \        V R4       R# )re   ri   NrO   r   r   s   & r   test_empty_formatstrTestFormat.test_empty_formatstrB  s:    ##G,OOI&VAY 89s56r   c                    \         P                  ! . RO4      p\        P                  ! \        4      ;_uu_ 4        \        VR4       RRR4       R#   + '       g   i     R# ; i)rP   z.2fNr   )r   r!   rY   r   r   r   r   s   & r   test_bad_formatstrTestFormat.test_bad_formatstrH  s8    OOM*]]:&&1e '&&&s   AA#	rM   N)
rU   rV   rW   rX   r   r   r   r   r]   r^   r_   s   @r   r   r   5  s     Q

7 r   r   u   1.0 + 2.0·z + 3.0·z²u!   1.0 + 2.0·T₁(z) + 3.0·T₂(z)u!   1.0 + 2.0·H₁(z) + 3.0·H₂(z)u#   1.0 + 2.0·He₁(z) + 3.0·He₂(z)u!   1.0 + 2.0·L₁(z) + 3.0·L₂(z)u!   1.0 + 2.0·P₁(z) + 3.0·P₂(z)c                 :    V ! . RORR7      p\        VR V4       R# )rP   zsymbolr   NrO   )r   )r   r$   r%   s   && r   test_symbolr   N  s     	Ys#AAg;%r   c                   D   a  ] tR tRt o R tR tR tR tR tR t	Rt
V tR	# )
TestRepri[  c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   zFPolynomial([0., 1.], domain=[-1.,  1.], window=[-1.,  1.], symbol='x')N)reprr   r!   r   rJ   s   &  r   test_polynomial_reprTestRepr.test_polynomial_repr\  s-    4??Aq6*+ 	 	Sr   c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   zEChebyshev([0., 1.], domain=[-1.,  1.], window=[-1.,  1.], symbol='x')N)r   r   r,   r   rJ   s   &  r   test_chebyshev_reprTestRepr.test_chebyshev_reprd  s-    4>>1a&)* 	 	Sr   c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   zDLegendre([0., 1.], domain=[-1.,  1.], window=[-1.,  1.], symbol='x')N)r   r   r2   r   rJ   s   &  r   test_legendre_reprTestRepr.test_legendre_reprl  -    4==!Q() 	 	Sr   c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   zCHermite([0., 1.], domain=[-1.,  1.], window=[-1.,  1.], symbol='x')N)r   r   r8   r   rJ   s   &  r   test_hermite_reprTestRepr.test_hermite_reprt  s-    4<<A'( 	 	Sr   c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   zDHermiteE([0., 1.], domain=[-1.,  1.], window=[-1.,  1.], symbol='x')N)r   r   r=   r   rJ   s   &  r   test_hermiteE_reprTestRepr.test_hermiteE_repr|  r   r   c                b    \        \        P                  ! ^ ^.4      4      pRp\        W4       R# )r   z@Laguerre([0., 1.], domain=[0., 1.], window=[0., 1.], symbol='x')N)r   r   rC   r   rJ   s   &  r   test_laguerre_reprTestRepr.test_laguerre_repr  r   r   rM   N)rU   rV   rW   rX   r   r   r   r   r   r   r]   r^   r_   s   @r   r   r   [  s(      r   r   c                   R   a  ] tR tRt o Rt]R 4       tR tR tR t	R t
R tR	tV tR
# )TestLatexRepri  z#Test the latex repr used by Jupyterc                J    RR lV n          V P                  4       V = #   T = i ; i)Fc                     \        V 4      # r    )r"   )xparenss   &&r   <lambda>(TestLatexRepr.as_latex.<locals>.<lambda>  s    Qr   )F)_repr_latex_scalar_repr_latex_)objs   &r   as_latexTestLatexRepr.as_latex  s+    
 "@	'##%&&s    "c                   \         P                  ! . RO4      p\        V P                  V4      R4       \         P                  ! . ROR	^ .R7      p\        V P                  V4      R4       \         P                  ! . ROR
R.R7      p\        V P                  V4      R4       \         P                  ! . ROR^ .R7      p\        V P                  V4      R4       R# )rP   z%$x \mapsto 1.0 + 2.0\,x + 3.0\,x^{2}$rG   zK$x \mapsto 1.0 + 2.0\,\left(1.0 + x\right) + 3.0\,\left(1.0 + x\right)^{2}$      ?zE$x \mapsto 1.0 + 2.0\,\left(2.0x\right) + 3.0\,\left(2.0x\right)^{2}$zQ$x \mapsto 1.0 + 2.0\,\left(1.0 + 2.0x\right) + 3.0\,\left(1.0 + 2.0x\right)^{2}$NrO         rT   r   r!   r   r   r   s   & r   test_simple_polynomial$TestLatexRepr.test_simple_polynomial  s    OOI&T]]1%4	6 OOIr1g6T]]1%Z	\ OOItSk:T]]1%T	V OOIr1g6T]]1%`	br   c                    \         P                  ! . RO4      p\        V P                  V4      R4       \         P                  ! . ROR^ .R7      p\        V P                  V4      R4       R# )rP   z?$x \mapsto 1.0\,{T}_{0}(x) + 2.0\,{T}_{1}(x) + 3.0\,{T}_{2}(x)$rG   zZ$x \mapsto 1.0\,{T}_{0}(1.0 + 2.0x) + 2.0\,{T}_{1}(1.0 + 2.0x) + 3.0\,{T}_{2}(1.0 + 2.0x)$NrO   rT   )r   r,   r   r   r   s   & r   test_basis_funcTestLatexRepr.test_basis_func  sT    NN9%T]]1%N	P NN9b!W5T]]1%i	kr   c                l    \         P                  ! . RO4      p\        V P                  V4      R4       R# )rP   zB$x \mapsto 1.0\,{He}_{0}(x) + 2.0\,{He}_{1}(x) + 3.0\,{He}_{2}(x)$NrO   )r   r=   r   r   r   s   & r   test_multichar_basis_func'TestLatexRepr.test_multichar_basis_func  s'    MM)$T]]1%Q	Sr   c                   \         P                  ! . R
ORR7      p\        V P                  V4      R4       \         P                  ! . R
OR^ .RR7      p\        V P                  V4      R4       \         P                  ! . R
ORR.RR7      p\        V P                  V4      R4       \         P                  ! . R
OR^ .RR7      p\        V P                  V4      R4       R	# )rP   r   r   z%$z \mapsto 1.0 + 2.0\,z + 3.0\,z^{2}$)rH   r   zK$z \mapsto 1.0 + 2.0\,\left(1.0 + z\right) + 3.0\,\left(1.0 + z\right)^{2}$r   zE$z \mapsto 1.0 + 2.0\,\left(2.0z\right) + 3.0\,\left(2.0z\right)^{2}$zQ$z \mapsto 1.0 + 2.0\,\left(1.0 + 2.0z\right) + 3.0\,\left(1.0 + 2.0z\right)^{2}$NrO   r   r   rT   r   r   s   & r   test_symbol_basicTestLatexRepr.test_symbol_basic  s    OOIc2T]]1%4	6 OOIr1gcBMM!-	
 OOItSk#FMM!*	
 OOIr1gcBMM!0	
r   c                    \        \        ^^4      \        ^4      .4      p\        P                  ! V4      p\	        V P                  V4      R4       R# )rP   z$x \mapsto 1/2 + 1\,x$N)r   r   r   r!   r   r   )r   r   r%   s   &  r   r   .TestLatexRepr.test_numeric_object_coefficients  s=    x1~x{34OOE"T]]1%'ABr   rM   N)rU   rV   rW   rX   __doc__staticmethodr   r   r   r   r   r   r]   r^   r_   s   @r   r   r     s>     -' 'b*kS
"
HC Cr   r   c                   v   a  ] tR tRt o Rt]P                  ! RRR7      R 4       tR tR t	R	 t
R
 tR tRtV tR# )TestPrintOptionsi  z
Test the output is properly configured via printoptions.
The exponential notation is enabled automatically when the values
are too small or too large.
r   Tr   c                2    \         P                  ! R 4       R# rd   r   r   s   &r   rf   TestPrintOptions.use_ascii  rh   r   c                    \         P                  ! . RO4      p\        \        V4      R4       \	        ^R7      ;_uu_ 4        \        \        V4      R4       RRR4       R#   + '       g   i     R# ; i)rP   zC0.5 + 0.14285714 x + 14285714.28571429 x**2 + (1.42857143e+08) x**3	precisionz40.5 + 0.143 x + 14285714.286 x**2 + (1.429e+08) x**3Nr   g$I$I?gI$Ir?kAgm۶mAr   r!   r   r"   r	   r   s   & r   test_strTestPrintOptions.test_str   sS    OOHISV 7 	8 A&&Q "6 7 '&&&s   A""A3	c                    \         P                  ! . RO4      p\        VP                  4       R4       \	        ^R7      ;_uu_ 4        \        VP                  4       R4       RRR4       R#   + '       g   i     R# ; i)rP   zp$x \mapsto \text{0.5} + \text{0.14285714}\,x + \text{14285714.28571429}\,x^{2} + \text{(1.42857143e+08)}\,x^{3}$r  za$x \mapsto \text{0.5} + \text{0.143}\,x + \text{14285714.286}\,x^{2} + \text{(1.429e+08)}\,x^{3}$Nr  )r   r!   r   r   r	   r   s   & r   
test_latexTestPrintOptions.test_latex	  s[    OOHIQ^^%/	0
 A&&)KL '&&&s   A,,A=	c                v   \         P                  ! R.4      p\        \        V4      R4       \	        RR7      ;_uu_ 4        \        \        V4      R4       RRR4       \	        R^R7      ;_uu_ 4        \        \        V4      R4       RRR4       R#   + '       g   i     LE; i  + '       g   i     R# ; i)	rP   z0.5fixed)	floatmodez
0.50000000N)r  r  z0.5000r   r  r   s   & r   
test_fixedTestPrintOptions.test_fixed  sx    OOUG$SVU#G,,Q. - Gq99Q* :9 -, :99s   B4B'B$	'B8	c                   \        \        4       F  w  r\        VR 7      ;_uu_ 4        \        P                  ! \        V^,          ^,           4       Uu. uF  pR^
V) ,          ,          NK  	  up4      p\        V4      P                  RR4      V8X  g   Q h RRR4       K  	  R# u upi   + '       g   i     K  ; i)r  gރB?r    N)	enumerateSWITCH_TO_EXPr	   r   r!   ranger"   replace)r   isr%   s   &   r   test_switch_to_exp#TestPrintOptions.test_switch_to_exp  s    m,DA**OO.3AFQJ.?%A.? &0"qb&%8%8.?%A B1v~~dC0A555 +* -%A +**s   ,B,B'/)B,'B,,B=c                P   \         P                  ! \        \        .4      p\	        V4      R 8X  g   Q hVP                  4       R8X  g   Q h\        RRR7      ;_uu_ 4        \	        V4      R8X  g   Q hVP                  4       R8X  g   Q h RRR4       R#   + '       g   i     R# ; i)znan + inf xz&$x \mapsto \text{nan} + \text{inf}\,x$NANINF)nanstrinfstrzNAN + INF xz&$x \mapsto \text{NAN} + \text{INF}\,x$N)r   r!   r   r   r"   r   r	   r   s   & r   test_non_finite TestPrintOptions.test_non_finite&  s    OOS#J'1v&&&~~#LLLLu55q6]***>>#9: : : 6555s   *BB%	rM   N)rU   rV   rW   rX   r   rY   rZ   rf   r  r	  r  r  r  r]   r^   r_   s   @r   r   r     sH      ^^'40- 1-7
L+6: :r   r   )r   r$   )rP   rQ   f)r   r$   )z"1.0 + (1.0e-01) x + (1.0e-02) x**2z"1.2 + (1.2e-01) x + (1.2e-02) x**2z11.23 + 0.12 x + (1.23e-02) x**2 + (1.23e-03) x**3z51.235 + 0.123 x + (1.235e-02) x**2 + (1.235e-03) x**3zG1.2346 + 0.1235 x + 0.0123 x**2 + (1.2346e-03) x**3 + (1.2346e-04) x**4zL1.23457 + 0.12346 x + 0.01235 x**2 + (1.23457e-03) x**3 + (1.23457e-04) x**4za1.234568 + 0.123457 x + 0.012346 x**2 + 0.001235 x**3 + (1.234568e-04) x**4 + (1.234568e-05) x**5zg1.2345679 + 0.1234568 x + 0.0123457 x**2 + 0.0012346 x**3 + (1.2345679e-04) x**4 + (1.2345679e-05) x**5))decimalr   	fractionsr   mathr   r   rY   numpy.polynomial
polynomialr   numpy._corer   r   r	   numpy.testingr
   r   r   rb   rz   r[   thread_unsafer   r   r\   r   r   r   r   r!   r,   r8   r=   rC   r2   r   r   r   r  r   rM   r   r   <module>r*     s*        3 3 /Q QfT Tl?( ?(D "LM
5 N
5 "LMH NH )
HQNHQN+6: Aq(1a.!0 GFOWU^Q/v> 
, 

 )
;f%':;
Aq1a&>(*BC, 	 2 	__/0	^^89	\\67	]]9:	]]78	]]78+ &&
/ /dXC XCv38: 8:r   