+
    i6+                        ^ RI Ht ^ RIHt ^ RIHtHt ^ RIHt ^ RI	H
t
 ^ RIHt ^ RIHt ^ RIHt ^ R	IHt ^ R
IHtHtHtHtHtHtHt ^ RIHtHtHt ^ RIH t  ^ RI!H"t"H#t# ^ RI$H%t%H&t&H't'H(t(H)t)H*t*H+t+ ^ RI,H-t- ^ RI.H/t/H0t0H1t1H2t2 ^ RI3H4t4H5t5H6t6 ^ RI7H8t8 ^ RI9H:t:H;t; ^ RI<H=t= ]=! R4      t>]>'       dK   ]>P~                  P                  ]>P~                  P                  . 4      P                  4      tC]CP                  tER tFR tGR tHR tIR tJR tKR tLR tMR tNR tOR  tPR! tQR" tRR# tSR$ tTR% tUR& tVR' tWR( tXR) tYR* tZR+ t[R, t\R- t]R. t^R/# )0    )Sum)Mod)Equality
Unequality)sqrt)	Piecewise)BlockMatrix)MatrixSymbol)Identity)lambdify)xijabcd)FunctionPowSymbol)MatrixSolve)	logaddexp
logaddexp2)log1pexpm1hypotlog10exp2log2Sqrt)Array)ArrayTensorProductArrayAddPermuteDimsArrayDiagonal)
JaxPrinter_jax_known_constants_jax_known_functions)convert_matrix_to_array)skipraises)import_modulejaxc                     \        4       p \        ^\        ^ 8  3R4      pV P                  V4      R8X  g   Q hV P                  R0 Rm/8X  g   Q hR# )z
NumPyPrinter needs to print Piecewise()'s choicelist as a list to avoid
breaking compatibility with numpy 1.8. This is not necessary in numpy 1.9+.
See gh-9747 and gh-9749 for details.
zKjax.numpy.select([jax.numpy.less(x, 0),True], [1,0], default=jax.numpy.nan)z	jax.numpyN)r   T>   nanlessselect)r&   r   r   doprintmodule_imports)printerps     [/var/www/html/photoedit/myenv/lib/python3.14/site-packages/sympy/printing/tests/test_jax.pytest_jax_piecewise_regressionr7   (   sZ     lG1a!e*i(A??1UV V V!!k3L%MMMM    c                      \        \        \        4      p \        4       P	                  V 4      R 8X  g   Q h\        \        \        4      p\        4       P	                  V4      R8X  g   Q hR# )zjax.numpy.logaddexp(a, b)zjax.numpy.logaddexp2(a, b)N)r   r   r   r&   r2   r   )laelae2s     r6   test_jax_logaddexpr<   5   sQ    
Aq/C<$(CCCCaD<%)EEEEr8   c                  &  a \         '       g   \        R 4       \        \        \        ,          \        \
        \        34      p \        \
        \        \        3V R4      p^ ^
r2\         P                  P                  R^^
4      o\         P                  P                  V! W#S4      \        V3R l\        W#^,           4       4       4      4      '       g   Q h\        \        \        ,          \        \
        \        34      p \        \
        \        \        3V R4      p^ ^
r2\         P                  P                  R^^
4      o\         P                  P                  V! W#S4      \        V3R l\        W#^,           4       4       4      4      '       g   Q hR# )JAX not installedr-   c              3   6   <"   T F  pSV,          x  K  	  R # 5iN .0i_x_s   & r6   	<genexpr>test_jax_sum.<locals>.<genexpr>E   s     0VDUbrDUs   c              3   4   <"   T F  qS,          x  K  	  R # 5ir@   rA   rB   s   & r6   rF   rG   L   s     0UCTRbCTs   N)r-   r*   r   r   r   r   r   r   numpylinspaceallclosesumrange)sfa_b_rE   s       @r6   test_jax_sumrS   <   s   3 !AFQ1IA!QAu%A			BB	'B99amS0VE"STfDU0V-VWWWWAEAq!9A!QAu%A			BB	'B99amS0U5RSVCT0U-UVVVVr8   c                    aaa \         '       g   \        R 4       \        \        \        ,           \
        ,          \
        \        \        3\        \        \        34      p \        \        \        \        \        \        3V R4      p^ ^
r2^^uoo\         P                  P                  R^^
4      o\         P                  P                  V! W#SSS4      \        VVV3R l\        W#^,           4       4       4      4      '       g   Q hR# )r>   r-   c              3   x   <"   T F/  p\        SS^,           4       F  pSV,           V,          x  K  	  K1  	  R# 5i)   N)rN   )rC   rD   j_c_d_rE   s   &  r6   rF   )test_jax_multiple_sums.<locals>.<genexpr>Z   s6     b4EbPUVXZ\_`Z`Pa"BGr>>Pa>4Es   7:NrI   )r-   r*   r   r   r   r   r   r   r   r   r   rJ   rK   rL   rM   rN   )rO   rP   rQ   rR   rX   rY   rE   s       @@@r6   test_jax_multiple_sumsr[   O   s    3 !QUaK!QQ1I.A!Q1a!U+AFB			BB	'B99aB3bE"1f4Ebbd d d dr8   c                     \         '       g   \        R 4       \        R^^4      p \        R^^4      p\        W,          4      p\	        W3VR4      p\         P
                  P                  ^^.^^..4      p\         P
                  P                  ^R.R^..4      pV! WE4      \         P
                  P                  WE4      8H  P                  4       '       g   Q hR# )r>   MNr-   NrI   )	r-   r*   r
   r)   r   rJ   arraymatmulall)r]   r^   cgrP   mambs         r6   test_jax_codegen_einsumrf   ]   s    3 !S!QAS!QA	 	'B!U#A	1a&1a&)	*B	1R&2q'*	+BbI))"11668888r8   c            
         \         '       g   \        R 4       \        R^^4      p \        R^^4      p\        R^^4      p\        R^^4      p\         P                  P	                  ^^.^^..4      p\         P                  P	                  ^R.R	^..4      p\         P                  P	                  ^^ .^^..4      p\         P                  P	                  ^R	.^^..4      p\        W4      p\        W3VR4      p	V	! WE4      \         P                  P                  V^ ^.V^^.4      8H  P                  4       '       g   Q h\        W4      p\        W3VR4      p	V	! WE4      WE,           8H  P                  4       '       g   Q h\        WV4      p\        WV3VR4      p	V	! WEV4      WE,           V,           8H  P                  4       '       g   Q h\        WW#4      p\        WW#3VR4      p	V	! WEWg4      WE,           V,           V,           8H  P                  4       '       g   Q h\        V ^^ .4      p\        V 3VR4      p	V	! V4      VP                  8H  P                  4       '       g   Q h\        \        W4      . R
O4      p\        W3VR4      p	V	! WE4      \         P                  P                  \         P                  P                  V^ ^.V^^.4      R
4      8H  P                  4       '       g   Q h\        \        W4      R4      p\        W3VR4      p	V	! WE4      \         P                  P                  \         P                  P                  V^ ^.V^^.4      ^^R7      8H  P                  4       '       g   Q hR# )r>   r]   r^   PQr-   )axis1axis2Nr_   rI   )rV         r   rV   rl   )r-   r*   r
   rJ   r`   r"   r   einsumrb   r#   r$   T	transposer%   diagonal)
r]   r^   rh   ri   rd   re   mcmdrc   rP   s
             r6   test_jax_codegen_extraru   l   s   3 !S!QAS!QAS!QAS!QA	1a&1a&)	*B	1R&2q'*	+B	1a&1a&)	*B	1R&1a&)	*B	A	!B!U#AbI))"q!fb1a&AAFFHHHH	!B!U#AbI##%%%%	!	B!B&AbbMRU2X%**,,,,	!	B!r5)Abbr",113333	QA	B!r5!AbERTTM    	'-|	<B!U#AbI,,SYY-=-=b1a&"qRSf-UWcddiikkkk	)!/	8B!U#AbI++CII,<,<R!QaQRV,T\]ef+ggllnnnnr8   c                  H   \         '       g   \        R 4       \        \        ^4      p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        \        ^4      p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        ^8  p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        ^8*  p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        ^8  p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        ^8  p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . R	O4      '       g   Q h\        ^8  \        ^8  ,          p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . RO4      '       g   Q h\        ^8  \        ^8  ,          p \	        \        3V R4      p\         P
                  P                  . RO4      p\         P
                  P                  V! V4      . R
O4      '       g   Q hR# )r>   r-   N)r   rV   rl   )FTF)TFT)TFF)TTF)FFT)FTT)TTT)	r-   r*   r   r   r   rJ   r`   array_equalr   )erP   rE   s      r6   test_jax_relationalry      s   3 !AA!q% A		#B99  2(<====1aA!q% A		#B99  2(;<<<<	
QA!q% A		#B99  2(<====	
aA!q% A		#B99  2(;<<<<	
QA!q% A		#B99  2(<====	
aA!q% A		#B99  2(;<<<< 
aAEA!q% A		#B99  2(<====	
aAEA!q% A		#B99  2(:;;;;r8   c                     \         '       g   \        R 4       \        \        \        4      p \        \        \        3V R4      p\         P                  P                  . RO4      p^p\         P                  P                  V! W#4      . RO4      '       g   Q h\         P                  P                  . RO4      p\         P                  P                  . RO4      p\         P                  P                  V! W#4      . RO4      '       g   Q h\         P                  P                  . RO4      p\         P                  P                  . RO4      p\         P                  P                  V! W#4      . RO4      '       g   Q hR# )r>   r-   N)r   rV   rl   rm   )r   rV   r   rV   )rl   rl   rl   rl   )rl   rm         )r   r   r   r   )	r-   r*   r   r   r   r   rJ   r`   rw   )rx   rP   rQ   rR   s       r6   test_jax_modr}      s    3 !Aq	A!QE"A		&B	
B99  2L9999		&B		&B99  2L9999		&B		&B99  2L9999r8   c                      \         '       g   \        R 4       \        ^RRR7      p \        . V R4      pV! 4       R8X  g   Q hR# )r>   F)evaluater-   g      ?NrI   )r-   r*   r   r   )exprrP   s     r6   test_jax_powr      s:    3 !q"u%DT5!A3#::r8   c                      \         '       g   \        R 4       \        \        3\	        \        4      R4      p \        V ! R4      R,
          R,
          4      R\        ,          8:  g   Q hR# )r>   r-   g|=g#B;N)r-   r*   r   r   r   absJAX_DEFAULT_EPSILONrP   s    r6   test_jax_expm1r      sK    3 !!uQx'Aqx%%'(E4G,GGGGr8   c                      \         '       g   \        R 4       \        \        3\	        \        4      R4      p \        V ! R4      R,
          4      R\        ,          8:  g   Q hR# )r>   r-   g>N}a+N)r-   r*   r   r   r   r   r   r   s    r6   test_jax_log1pr      sF    3 !!uQx'Aqx% E,?$????r8   c            	          \         '       g   \        R 4       \        \        \        \
        3\        \        \
        4      R4      ! ^^4      ^,
          4      \        8:  g   Q hR# r>   r-   N)r-   r*   r   r   r   r   r   r   rA   r8   r6   test_jax_hypotr      sC    3 !xAaU3Aq9A=>BUUUUr8   c                      \         '       g   \        R 4       \        \        \        3\        \        4      R4      ! ^d4      ^,
          4      \        8:  g   Q hR# r   )r-   r*   r   r   r   r   r   rA   r8   r6   test_jax_log10r      s=    3 !xeAh.s3a78<OOOOr8   c                      \         '       g   \        R 4       \        \        \        3\        \        4      R4      ! ^4      ^ ,
          4      \        8:  g   Q hR# r   )r-   r*   r   r   r   r   r   rA   r8   r6   test_jax_exp2r     s=    3 !xd1gu-a0256:MMMMr8   c                      \         '       g   \        R 4       \        \        \        3\        \        4      R4      ! R4      ^,
          4      \        8:  g   Q hR# )r>   r-      N)r-   r*   r   r   r   r   r   rA   r8   r6   test_jax_log2r     s=    3 !xd1gu-c2Q67;NNNNr8   c                      \         '       g   \        R 4       \        \        \        3\        \        4      R4      ! ^4      ^,
          4      \        8:  g   Q hR# r   )r-   r*   r   r   r   r    r   rA   r8   r6   test_jax_Sqrtr     =    3 !xd1gu-a01459LLLLr8   c                      \         '       g   \        R 4       \        \        \        3\        \        4      R4      ! ^4      ^,
          4      \        8:  g   Q hR# r   )r-   r*   r   r   r   r   r   rA   r8   r6   test_jax_sqrtr     r   r8   c                  L   \         '       g   \        R 4       \        R^^4      p \        R^^4      pV R,          V,          V,           p\        W4      V,           p\	        W3VR4      p\	        W3VR4      p\         P
                  P                  . RO. RO. RO.4      p\         P
                  P                  P                  V4      ^8X  g   Q h\         P
                  P                  . R	O4      p\         P
                  P                  V! Wg4      V! Wg4      4      '       g   Q hR# )
r>   r]   r   r-   NrI   )rV   rl   rm   )rm   rl   r|   )r|         )rm   r{   r|   )
r-   r*   r
   r   r   rJ   r`   linalgmatrix_rankrL   )r]   r   r   matsolve_exprrP   
f_matsolvem0x0s           r6   test_jax_matsolver     s    3 !S!QAS!QAr7Q;?D%)M!u%A1&-7J	)Y	:	;B99''+q000		#B99j0!B)<<<<r8   c                  $   \         '       g   \        R 4       \        R^
^4      p \        R^
^4      p\        R^
^4      p\        R^
^4      p\        W.W#..4      pVP                  R8X  g   Q h\        4       pVP                  V4      R8X  g   Q hR# )r>   a_1a_2a_3a_4z)jax.numpy.block([[a_1, a_2], [a_3, a_4]])N)   r   )r-   r*   r
   r	   shaper&   r2   )r   r   r   r   Ar4   s         r6   
test_16857r   .  s    3 !
ub!
$C
ub!
$C
ub!
$C
ub!
$CcZ#,-A77glG??1!LLLLr8   c                    aa \         '       g   \        R 4       \        R^^4      p \        W \	        ^4      ,           R4      p\         P
                  P                  ^^.^^..4      p\         P
                  P                  ^^.^^..4      pV! V4      V8H  P                  4       '       g   Q h^ RIH	p V! RRR7      o\        RSS4      o\        \        VV3R l4       R# )	r>   r]   r-   )symbolsnT)integerc                  >   < \        S S \        S4      ,           R 4      # )r-   )r   r   )r^   r   s   r6   <lambda>"test_issue_17006.<locals>.<lambda>L  s    AOU(Kr8   N)r-   r*   r
   r   r   rJ   r`   rb   sympy.core.symbolr   r+   NotImplementedError)r]   rP   rd   mrr   r^   r   s        @@r6   test_issue_17006r   =  s    3 !S!QAOU+A	1a&1a&)	*B	1a&1a&)	*BbERK)T"AS!QA
 KLr8   c                      \        4       P                  \        R4      4      R8X  g   Q h\        4       P                  \        R4      4      R8X  g   Q hR# )rV   z!jax.numpy.array([[1, 2], [3, 5]])zjax.numpy.array([1, 2])Nrn   )rn   )rm   r|   )r&   r2   r!   rA   r8   r6   test_jax_arrayr   O  sD    <&6 78<____<f.2KKKKr8   c                      \         R ,          R8X  g   Q h\         R,          R8X  g   Q h\        R,          R8X  g   Q h\        R,          R8X  g   Q hR# )	NaNzjax.numpy.nan
EulerGammazjax.numpy.euler_gammaacoszjax.numpy.arccoslogzjax.numpy.logN)r'   r(   rA   r8   r6   test_jax_known_funcs_constsr   T  sP    &/999-1HHHH'+====&/999r8   c                  j    \        4       p \        V R 4      '       g   Q h\        V R4      '       g   Q hR# )_print_acos
_print_logN)r&   hasattr)prntrs    r6   test_jax_print_methodsr   \  s/    LE5-((((5,''''r8   c                  h    \        4       p \        V R 4      '       g   Q hV P                  R8X  g   Q hR# )printmethod_jaxcodeN)r&   r   r   )r4   s    r6   test_jax_printmethodr   b  s0    lG7M*****,,,r8   c                       ! R  R\         4      p \        4       pVP                  V ! \        R4      4      4      R8X  g   Q hR# )c                   &   a  ] tR tRt o R tRtV tR# )+test_jax_custom_print_method.<locals>.expm1ij  c                    V P                   w  pR VP                  V4       R2pVP                  VP                  R,           V,           4      # )zexpm1().)args_print_module_format_module)selfr4   r   functions   &&  r6   r   4test_jax_custom_print_method.<locals>.expm1._jaxcodel  sD    BAq 12!4H))'//C*?(*JKKr8   rA   N)__name__
__module____qualname____firstlineno__r   __static_attributes____classdictcell__)__classdict__s   @r6   r   r   j  s     	L 	Lr8   r   r   zjax.numpy.expm1(x)N)r   r&   r2   r   )r   r4   s     r6   test_jax_custom_print_methodr   h  s:    L L lG??5-.2FFFFr8   N)_sympy.concrete.summationsr   sympy.core.modr   sympy.core.relationalr   r   (sympy.functions.elementary.miscellaneousr   $sympy.functions.elementary.piecewiser   &sympy.matrices.expressions.blockmatrixr	   "sympy.matrices.expressions.matexprr
   "sympy.matrices.expressions.specialr   sympy.utilities.lambdifyr   	sympy.abcr   r   r   r   r   r   r   
sympy.corer   r   r   sympy.codegen.matrix_nodesr   sympy.codegen.numpy_nodesr   r   sympy.codegen.cfunctionsr   r   r   r   r   r   r    sympy.tensor.arrayr!   0sympy.tensor.array.expressions.array_expressionsr"   r#   r$   r%   sympy.printing.numpyr&   r'   r(   3sympy.tensor.array.expressions.from_matrix_to_arrayr)   sympy.testing.pytestr*   r+   sympy.externalr,   r-   rJ   finfor`   dtypedeafult_float_infoepsr   r7   r<   rS   r[   rf   ru   ry   r}   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   rA   r8   r6   <module>r      s+   )  8 9 : > ; 7 - ) ) ) , , 2 ; Q Q Q $  W W W - ( E)<)B)BC,00
NFW&d9'oT1<f:(H@V
PNOMM=*MM$L
:(-
Gr8   