
    ЦiN                     N   S SK Jr  S SKJr  S SKJr  SSKJrJrJ	r	J
r
JrJr  SSKJr  SR                  5       r\R"                  " 5        V Vs/ s H  u  pU \;  d  M  X4PM     snn r\" \40 SS	S
SSSSSSSSSS.D6rSSSSSS.r\R#                  5        V Vs0 s H  u  pU SU-   _M     snn r\R#                  5        V Vs0 s H  u  pU SU-   _M     snn r " S S\\5      r\ H  r\" \S\ 3\
5        M     \ H  r\" \S\ 3\	5        M     0 SS _S!S!_S"S"_S#S$_S%S&_S'S(_S)S*_S+S+_S,S,_S-S-_S.S._S/S0_S1S2_S3S3_S4S5_S6S7_S8S9_S:S;S<S=S>S?S@SASB.ErSCSSD.r\R#                  5        V Vs0 s H  u  pU SEU-   _M     snn r\R#                  5        V Vs0 s H  u  pU SFU-   _M     snn r " SG SH\5      r \ H  r\" \ S\ 3\
5        M     \ H  r\" \ S\ 3\	5        M     \R#                  5        V Vs0 s H  u  pU SIU-   _M     snn r!\R#                  5        V Vs0 s H  u  pU SIU-   _M     snn r" " SJ SK\5      r#\! H  r\" \#S\ 3\
5        M     \" H  r\" \#S\ 3\	5        M     \R#                  5        V Vs0 s H  u  pU SLU-   _M     snn r$\R#                  5        V Vs0 s H  u  pU SLU-   _M     snn r% " SM SN\5      r&\$ H  r\" \&S\ 3\
5        M     \% H  r\" \&S\ 3\	5        M     gOs  snn f s  snn f s  snn f s  snn f s  snn f s  snn f s  snn f s  snn f s  snn f )P    )S)Lambda)Pow   )PythonCodePrinter_known_functions_math_print_known_const_print_known_func_unpack_integral_limitsArrayPrinter)CodePrinterz!erf erfc factorial gamma loggammaarccosarccosharcsinarcsinharctanarctan2arctanhexp2sign	logaddexp
logaddexp2isnan)acosacoshasinasinhatanatan2atanhr   r   r   r   r   epieuler_gammananinf)Exp1Pi
EulerGammaNaNInfinityznumpy.c                     ^  \ rS rSrSrSr\r\r	S,U 4S jjr
S rS rS rS rS	 rS
 rS rS rS rS rS rS rS rS rS rS rS rU 4S jrS rS rS rS-S jr S r!S r"S r#S r$S r%S  r&S! r'S" r(S# r)S$ r*U 4S% jr+S&r,S'r-S(r.S)r/S*r0\1Rd                  r3\1Rd                  r4\1Rd                  r5\1Rd                  r6S+r7U =r8$ ).NumPyPrinter#   zU
Numpy printer which handles vectorized piecewise functions,
logical operators, etc.
numpyc                    > SR                  U R                  5      U l        SR                  U R                  5      U l        0 [        R
                  EU R
                  EU l        [        TU ]  US9  g)z
`settings` is passed to CodePrinter.__init__()
`module` specifies the array module to use, currently 'NumPy', 'CuPy'
or 'JAX'.
zPython with {}z_{}codesettingsN)format_modulelanguageprintmethodr   _kfsuper__init__selfr1   	__class__s     S/var/www/html/ai-image-ml/venv/lib/python3.13/site-packages/sympy/printing/numpy.pyr8   NumPyPrinter.__init__-   s^     )//=$++DLL98'++8txx8(+    c                 \   ^  SnSR                  UR                  U 4S jU 5       5      5      $ )z+General sequence printer: converts to tuple, z({},)c              3   F   >#    U  H  nTR                  U5      v   M     g 7fN_print).0itemr:   s     r<   	<genexpr>*NumPyPrinter._print_seq.<locals>.<genexpr>@   s     ,O34T[[->->3   !)r2   join)r:   seq	delimiters   `  r<   
_print_seqNumPyPrinter._print_seq;   s(     	~~inn,O3,OOPPr>   c                 F    SU R                  [        R                  5      -   $ )N-)rD   r   r*   r:   exprs     r<   _print_NegativeInfinity$NumPyPrinter._print_NegativeInfinityB   s    T[[,,,r>   c                 X  ^  UR                  5       S   [        R                  LaR  UR                  5       S   UR                  5       S   /-   nSR                  SR	                  U 4S jU 5       5      5      $ SR                  SR	                  U 4S jUR
                   5       5      5      $ )zMatrix multiplication printerr   r   ({})z).dot(c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rE   ir:   s     r<   rG   -NumPyPrinter._print_MatMul.<locals>.<genexpr>I   s     .Qy!t{{1~~yrI   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   rZ   J   s     *M9a4;;q>>9rI   )as_coeff_matricesr   Oner2   rJ   args)r:   rR   	expr_lists   `  r<   _print_MatMulNumPyPrinter._print_MatMulE   s    !!#A&aee3..03d6L6L6Nq6Q4SSI==.Qy.Q!QRR}}X]]*M499*MMNNr>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  S   5      U R                  UR                  S   5      5      $ )zMatrix power printerz
{}({}, {})z.linalg.matrix_powerr   r   r2   _module_formatr3   rD   r^   rQ   s     r<   _print_MatPowNumPyPrinter._print_MatPowL   sU    ""4#6#6t||F\7\#]KK		!%t{{499Q<'@B 	Br>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  S   5      5      $ )zMatrix inverse printer{}({})z.linalg.invr   rc   rQ   s     r<   _print_InverseNumPyPrinter._print_InverseQ   s=    t224<<-3OPKK		!%' 	'r>   c                 *   UR                   u  p#UR                  S   S:w  a  UR                  nUR                  S   S:w  a  UR                  nU R                  U R                  S-   5      < SU R                  U5      < SU R                  U5      < S3$ )Nr   r   z.dot(r@   ))r^   shapeTrd   r3   rD   )r:   rR   arg1arg2s       r<   _print_DotProductNumPyPrinter._print_DotProductV   sz     YY
::a=A66D::a=A66D#224<<&3HI#{{40#{{402 	2r>   c                     U R                  U R                  S-   5      < SU R                  UR                  5      < SU R                  UR                  5      < S3$ )Nz.linalg.solverl   r@   rm   )rd   r3   rD   matrixvectorrQ   s     r<   _print_MatrixSolveNumPyPrinter._print_MatrixSolvec   sC    #224<</3QR#{{4;;7#{{4;;79 	9r>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  5      5      $ )Nrh   z.zerosr2   rd   r3   rD   rn   rQ   s     r<   _print_ZeroMatrixNumPyPrinter._print_ZeroMatrixh   s9    t224<<(3JKKK

#% 	%r>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  5      5      $ )Nrh   z.onesrz   rQ   s     r<   _print_OneMatrixNumPyPrinter._print_OneMatrixl   s9    t224<<'3IJKK

#% 	%r>   c                   ^  SSK JnJn  UR                  n[	        U[
        5      (       d  [        X#4U" X#5      5      nSR                  T R                  T R                  S-   5      SR                  U 4S jUR                  S    5       5      T R                  UR                  S   5      T R                  UR                  5      5      $ )Nr   )rY   jz{}(lambda {}: {}, {})z.fromfunctionr@   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rE   argr:   s     r<   rG   5NumPyPrinter._print_FunctionMatrix.<locals>.<genexpr>v   s     @-3dkk#&&-rI   r   )	sympy.abcrY   r   lamda
isinstancer   r2   rd   r3   rJ   r^   rD   rn   )r:   rR   rY   r   r   s   `    r<   _print_FunctionMatrix"NumPyPrinter._print_FunctionMatrixp   s    "

%((A65;/E&--d.A.A$,,Q`B`.aII@%**Q-@@KK

1&DJJ(?A 	Ar>   c                 $  ^ ^ T R                  T R                  S-   5      mSR                  UU 4S jUR                  S S  5       5      SR	                  T R                  UR                  S   5      S[        UR                  5      S-
  -  5      -   $ )N	.multiply c              3   f   >#    U  H&  nS R                  TTR                  U5      5      v   M(     g7fz{}({}, Nr2   rD   rE   r   funcr:   s     r<   rG   6NumPyPrinter._print_HadamardProduct.<locals>.<genexpr>{   1      '% !''dkk#.>??%   .1{}{}rm   r   rd   r3   rJ   r^   r2   rD   lenr:   rR   r   s   ` @r<   _print_HadamardProduct#NumPyPrinter._print_HadamardProducty   s}    ""4<<+#=>ww 'yy"~' ')/t{{499R=7Q3tyy>A%&*(( 	(r>   c                 $  ^ ^ T R                  T R                  S-   5      mSR                  UU 4S jUR                  S S  5       5      SR	                  T R                  UR                  S   5      S[        UR                  5      S-
  -  5      -   $ )Nz.kronr   c              3   f   >#    U  H&  nS R                  TTR                  U5      5      v   M(     g7fr   r   r   s     r<   rG   7NumPyPrinter._print_KroneckerProduct.<locals>.<genexpr>   r   r   r   r   rm   r   r   r   s   ` @r<   _print_KroneckerProduct$NumPyPrinter._print_KroneckerProduct   s}    ""4<<'#9:ww 'yy"~' ')/t{{499R=7Q3tyy>A%&*(( 	(r>   c                     SR                  U R                  U R                  S-   5      U R                  U R                  S-   5      U R                  UR                  S   5      5      $ )Nz
{}({}({}))z
.conjugatez
.transposer   rc   rQ   s     r<   _print_AdjointNumPyPrinter._print_Adjoint   sW    ""| ;<| ;<KK		!%' 	'r>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  5      5      nSR                  U R                  U R                  S-   5      U5      $ )Nrh   z.diagz{}({}, (-1, 1))z.reshape)r2   rd   r3   rD   r   )r:   rR   vects      r<   _print_DiagonalOfNumPyPrinter._print_DiagonalOf   sg    w 67KK!# !''z 9:DB 	Br>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  S   5      5      $ )Nrh   z	.diagflatr   rc   rQ   s     r<   _print_DiagMatrixNumPyPrinter._print_DiagMatrix   s=    t224<<+3MNKK		!%' 	'r>   c           
      >   SR                  U R                  U R                  S-   5      U R                  UR                  5      U R                  U R                  S-   5      U R                  UR
                  S   5      U R                  UR
                  S   5      5      $ )Nz{}({}, {}({}, {}))r   .eyer   r   )r2   rd   r3   rD   r   rn   rQ   s     r<   _print_DiagonalMatrix"NumPyPrinter._print_DiagonalMatrix   sz    #**4+>+>t||k?Y+ZKK!4#6#6t||f7L#MKK

1&DJJqM(BD 	Dr>   c                   ^ ^^^ SSK JmJm  UU U4S jmSR                  SR	                  U 4S jUR
                   5       5      5      nSR                  SR	                  U4S jUR
                   5       5      5      nSR                  T R                  T R                  S	-   5      X2T R                  [        R                  5      5      $ )
zPiecewise function printerr   )ITEsimplify_logicc                    > U R                  T5      (       a  TR                  T" U 5      5      $ TR                  U 5      $ )z#Problem having an ITE in the cond. )hasrD   )condr   r:   r   s    r<   
print_cond1NumPyPrinter._print_Piecewise.<locals>.print_cond   s3    xx}}{{>$#788{{4((r>   z[{}],c              3   Z   >#    U  H   nTR                  UR                  5      v   M"     g 7frB   )rD   rR   r   s     r<   rG   0NumPyPrinter._print_Piecewise.<locals>.<genexpr>   s!     &R	t{{388'<'<	s   (+c              3   H   >#    U  H  nT" UR                   5      v   M     g 7frB   )r   )rE   r   r   s     r<   rG   r      s     &Qyz#((';';ys   "z{}({}, {}, default={})z.select)sympy.logic.boolalgr   r   r2   rJ   r^   rd   r3   rD   r   r)   )r:   rR   exprscondsr   r   r   s   `   @@@r<   _print_PiecewiseNumPyPrinter._print_Piecewise   s    ;	) chh&R		&RRSchh&Qtyy&QQR
 (..y 895KK  	 r>   c                 6  > SSSSSSS.nUR                   U;   aq  U R                  UR                  5      nU R                  UR                  5      nSR	                  U R                  U R                  S	-   X!R                      -   5      X4S
9$ [        TU ]!  U5      $ )z.Relational printer for Equality and Unequalityequal	not_equalless
less_equalgreatergreater_equal)z==z!=<z<=>z>=z{op}({lhs}, {rhs}).)oplhsrhs)	rel_oprD   r   r   r2   rd   r3   r7   _print_Relational)r:   rR   r   r   r   r;   s        r<   r   NumPyPrinter._print_Relational   s     !
 ;;"++dhh'C++dhh'C'..$2E2EdllUXFXY[\g\gYhFh2i36 / A Aw(..r>   c                    ^  SR                  T R                  T R                  S-   5      SR                  U 4S jUR                   5       5      5      $ )Logical And printer{}.reduce(({}))z.logical_andr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   *NumPyPrinter._print_And.<locals>.<genexpr>   s0       eH  ~Gxyeiepepqreses  ~GrI   r2   rd   r3   rJ   r^   rQ   s   ` r<   
_print_AndNumPyPrinter._print_And   sc    
 !''(;(;DLL><Y(Z\_\d\d  eH  ~B  ~G  ~G  eH  ]H  I  	Ir>   c                    ^  SR                  T R                  T R                  S-   5      SR                  U 4S jUR                   5       5      5      $ )Logical Or printerr   z.logical_orr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   )NumPyPrinter._print_Or.<locals>.<genexpr>   s0       dG  }Fwxdhdodopqdrdr  }FrI   r   rQ   s   ` r<   	_print_OrNumPyPrinter._print_Or   sc    
 !''(;(;DLL=<X(Y[^[c[c  dG  }A  }F  }F  dG  \G  H  	Hr>   c                    ^  SR                  T R                  T R                  S-   5      SR                  U 4S jUR                   5       5      5      $ )zLogical Not printerrh   z.logical_notr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   *NumPyPrinter._print_Not.<locals>.<genexpr>   s$     [~t}op\`\g\ghi\j\jt}rI   r   rQ   s   ` r<   
_print_NotNumPyPrinter._print_Not   sC    
 t224<<.3PQSVS[S[[~txt}t}[~S~r>   c                    UR                   R                  (       aH  UR                   R                  (       a-  [        UR                  UR                   R                  5       SS9nU R                  XU R                  S-   S9$ )NF)evaluatez.sqrt)rationalsqrt)exp
is_integeris_negativer   baseevalf_hprint_Powr3   )r:   rR   r   s      r<   
_print_PowNumPyPrinter._print_Pow   sW    88488#7#7tyy$((.."2UCDdllW>TUUr>   c                    ^  SR                  T R                  T R                  S-   5      T R                  T R                  5      SR                  U 4S jUR                   5       5      5      $ )N{}({}.asarray([{}]), axis=0)z.aminr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   *NumPyPrinter._print_Min.<locals>.<genexpr>   L       Nq  gp  bc  OS  OZ  OZ  [\  O]  O]  gprI   r   rQ   s   ` r<   
_print_MinNumPyPrinter._print_Min       -44T5H5HX_I_5`bfbubuvz  wC  wC  cD  FI  FN  FN  Nq  gk  gp  gp  Nq  Fq  r  	rr>   c                    ^  SR                  T R                  T R                  S-   5      T R                  T R                  5      SR                  U 4S jUR                   5       5      5      $ )Nr   z.amaxr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   *NumPyPrinter._print_Max.<locals>.<genexpr>   r   rI   r   rQ   s   ` r<   
_print_MaxNumPyPrinter._print_Max   r   r>   c                     U R                  U R                  S-   5      < SU R                  UR                  S   5      < S3$ )Nz.anglerl   r   rm   rd   r3   rD   r^   rQ   s     r<   
_print_argNumPyPrinter._print_arg   s7    ..t||h/FGUYU^U^_`UaIbccr>   c                     U R                  U R                  S-   5      < SU R                  UR                  S   5      < S3$ )Nz.imagrl   r   rm   r   rQ   s     r<   	_print_imNumPyPrinter._print_im   7    ..t||g/EFTXT]T]^_T`Habbr>   c                    ^  T R                  T R                  S-   5      < SSR                  U 4S jUR                   5       5      < S3$ )Nz.modrl   r@   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   r   s     r<   rG   *NumPyPrinter._print_Mod.<locals>.<genexpr>   s     3#T[[rI   rm   )rd   r3   rJ   r^   rQ   s   ` r<   
_print_ModNumPyPrinter._print_Mod   s<    ..t||f/DEtyy33H5 6 	6r>   c                     U R                  U R                  S-   5      < SU R                  UR                  S   5      < S3$ )Nz.realrl   r   rm   r   rQ   s     r<   	_print_reNumPyPrinter._print_re   r  r>   c                     U R                  U R                  S-   5      < SU R                  UR                  S   [        R
                  -  5      < S3$ )Nz.sincrl   r   rm   )rd   r3   rD   r^   r   r'   rQ   s     r<   _print_sincNumPyPrinter._print_sinc   sC    ..t||g/EFTXT]T]^_T`abaeaeTeHfggr>   c                     U R                   R                  UR                  R                  S 5      nUc  U R	                  U R
                  S-   5      nU< SU R                  UR                  5       5      < S3$ )Nz.arrayrl   rm   )known_functionsgetr;   __name__rd   r3   rD   tolistr   s      r<   _print_MatrixBaseNumPyPrinter._print_MatrixBase   s\    ##''(?(?F<&&t||h'>?DT[[]!;<<r>   c                     UR                   n[        S U 5       5      (       aB  U R                  U R                  S-   5      < SU R	                  UR                   S   5      < S3$ [        S5      e)Nc              3   8   #    U  H  oR                   v   M     g 7frB   )
is_Integer)rE   dims     r<   rG   /NumPyPrinter._print_Identity.<locals>.<genexpr>   s     /#~~s   r   rl   r   rm   zFSymbolic matrix dimensions are not yet supported for identity matrices)rn   allrd   r3   rD   NotImplementedError)r:   rR   rn   s      r<   _print_IdentityNumPyPrinter._print_Identity   s]    

////#224<<&3HI4;;W[WaWabcWdKeff%&noor>   c                     SR                  U R                  U R                  S-   5      U R                  UR                  S   R                  5       5      5      $ )Nrh   z.blockr   )r2   rd   r3   rD   r^   r  rQ   s     r<   _print_BlockMatrixNumPyPrinter._print_BlockMatrix   sH    t224<<(3JK!%TYYq\-@-@-B!CE 	Er>   c                 &  > [        UR                  5      S:X  a1  U R                  S-   U R                  UR                  S   5      -   S-   $ [        UR                  5      S:X  a  U R                  UR                  5       5      $ [        TU ]  X5      $ )Nr   z.array(r   rm      )r   rn   r3   rD   r^   tomatrixr7   _print_not_supported)r:   rR   r;   s     r<   _print_NDimArrayNumPyPrinter._print_NDimArray   sr    tzz?a<<)+dkk$))A,.GG#MMtzz?a;;t}}//w+D77r>   addeinsum	transposeoneszeros)r6   r4   r5   rB   )F)9r  
__module____qualname____firstlineno____doc__r3   _numpy_known_functionsr6   _numpy_known_constants_kcr8   rM   rS   r`   re   ri   rr   rw   r{   r~   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r  r  r  r  r  r  r!  r'  _add_einsum
_transpose_ones_zerosr   r&  _print_lowergamma_print_uppergamma_print_fresnelc_print_fresnels__static_attributes____classcell__r;   s   @r<   r,   r,   #   s   
 G
 C
 C,Q-OB
'
29
%%A(('B'D
 &/"IH@Vrrdc6ch=pE8 DGJEF#88#88!66O!66Or>   r,   _print_Eiexpierferfcbesseljjvbesselyyvbesseliivbesselkkvcosm1powm1	factorialgammaloggammagammalndigammapsi	polygammaRisingFactorialpochjacobieval_jacobi
gegenbauereval_gegenbauereval_chebyteval_chebyueval_legendreeval_hermiteeval_laguerreeval_genlaguerrebetalambertw)
chebyshevt
chebyshevulegendrehermitelaguerreassoc_laguerrerc  LambertWgolden_ratio)GoldenRatior'   zscipy.special.zscipy.constants.c                      ^  \ rS rSr0 \R
                  E\Er0 \R                  E\ErSU 4S jjr	S r
\
rS rS rS rS rS rS	 rS
 rS rS rS rS rS rS rS rS rS rSrU =r$ )SciPyPrinteri=  c                 .   > [         TU ]  US9  SU l        g )Nr0   zPython with SciPy and NumPy)r7   r8   r4   r9   s     r<   r8   SciPyPrinter.__init__B  s    (+5r>   c                    / / / pCnUR                  5       R                  5        H;  u  u  pVnUR                  U5        UR                  U5        UR                  U5        M=     SR                  U R	                  S5      XBX1R
                  S9$ )Nz+{name}(({data}, ({i}, {j})), shape={shape})zscipy.sparse.coo_matrix)namedatarY   r   rn   )todokitemsappendr2   rd   rn   )r:   rR   rY   r   rt  rcvs           r<   _print_SparseRepMatrix#SciPyPrinter._print_SparseRepMatrixF  s    Rd++-IFQAHHQKHHQKKKN .
 =CC$$%>?azz D 
 	
r>   c           	          SR                  U R                  S5      U R                  UR                  S   5      U R                  UR                  S   5      U R                  UR                  S   5      5      $ )Nz{0}({2}, {1}, {3})zscipy.special.lpmvr   r   r$  r2   rd   rD   r^   rQ   s     r<   _print_assoc_legendre"SciPyPrinter._print_assoc_legendreU  s`    #** 45KK		!%KK		!%KK		!%	' 	'r>   c           	          SR                  U R                  S5      U R                  S5      U R                  UR                  S   5      U R                  UR                  S   5      5      $ )N{0}({2})*{1}({2}, {3})scipy.special.gammazscipy.special.gammaincr   r   r~  rQ   s     r<   r:  SciPyPrinter._print_lowergamma\  s[    '.. 56 89KK		!%KK		!%	' 	'r>   c           	          SR                  U R                  S5      U R                  S5      U R                  UR                  S   5      U R                  UR                  S   5      5      $ )Nr  r  zscipy.special.gammainccr   r   r~  rQ   s     r<   r;  SciPyPrinter._print_uppergammac  s[    '.. 56 9:KK		!%KK		!%	' 	'r>   c                    U R                  S5      nU R                  S5      nUR                   Vs/ s H  o@R                  U5      PM     nnSU SUS    SUS    SUS    SU SUS    SUS    SUS	    S
U SUS    SUS    S3$ s  snf )Nscipy.special.betainczscipy.special.betarl   r   r@   r      z) - r$  z))             * rm   )rd   r^   rD   )r:   rR   betaincrc  r   r^   s         r<   _print_betaincSciPyPrinter._print_betaincj  s    %%&=>""#78,0II6ISC I67)1T!WIRQy47)4y$q'RTUYZ[U\T]]_`def`g_h ifAd1gYba	, 	, 7s   B	c           
      *   SR                  U R                  S5      U R                  UR                  S   5      U R                  UR                  S   5      U R                  UR                  S   5      U R                  UR                  S   5      5      $ )Nz'{0}({1}, {2}, {4}) - {0}({1}, {2}, {3})r  r   r   r$  r  r~  rQ   s     r<   _print_betainc_regularized'SciPyPrinter._print_betainc_regularizedq  st    8?? 78KK		!%KK		!%KK		!%KK		!%' 	'r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )N	{}({})[0]scipy.special.fresnelr   r~  rQ   s     r<   r=  SciPyPrinter._print_fresnelsy  8    !!##$;<DIIaL)+ 	+r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )N	{}({})[1]r  r   r~  rQ   s     r<   r<  SciPyPrinter._print_fresnelc~  r  r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nr  scipy.special.airyr   r~  rQ   s     r<   _print_airyaiSciPyPrinter._print_airyai  8    !!##$89DIIaL)+ 	+r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nr  r  r   r~  rQ   s     r<   _print_airyaiprimeSciPyPrinter._print_airyaiprime  r  r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nz	{}({})[2]r  r   r~  rQ   s     r<   _print_airybiSciPyPrinter._print_airybi  r  r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nz	{}({})[3]r  r   r~  rQ   s     r<   _print_airybiprimeSciPyPrinter._print_airybiprime  r  r>   c                 R    U R                  UR                  " UR                  6 5      $ rB   rD   _eval_rewrite_as_zetar^   rQ   s     r<   _print_bernoulliSciPyPrinter._print_bernoulli  s     {{455tyyABBr>   c                 R    U R                  UR                  " UR                  6 5      $ rB   r  rQ   s     r<   _print_harmonicSciPyPrinter._print_harmonic  s     {{455tyyABBr>   c           	        ^  [        U5      u  p#[        U5      S:X  a7  T R                  S5      nS[        [	        T R
                  US   5      5      -  nO;T R                  S5      nSR                  SR                  U 4S jU 5       5      5      nS	R                  USR                  [	        T R
                  U5      5      T R                  UR                  S   5      U5      $ )
Nr   zscipy.integrate.quadz%s, %sr   zscipy.integrate.nquadrV   r@   c              3   h   >#    U  H'  nS [        [        TR                  U5      5      -  v   M)     g7f)z(%s, %s)N)tuplemaprD   )rE   lr:   s     r<   rG   /SciPyPrinter._print_Integral.<locals>.<genexpr>  s*      0IAGA
U3t{{A#677s   /2z{}(lambda {}: {}, {})[0])	r   r   rd   r  r  rD   r2   rJ   r^   )r:   r!   integration_varslimits
module_str	limit_strs   `     r<   _print_IntegralSciPyPrinter._print_Integral  s    #:1#= v;!,,-CDJ 5T[[&))D#EEI,,-DEJdii 0IAG0I 'I JI *00		#dkk+;<=AFF1I&	 	r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nr  scipy.special.sicir   r~  rQ   s     r<   	_print_SiSciPyPrinter._print_Si  r  r>   c                 |    SR                  U R                  S5      U R                  UR                  S   5      5      $ )Nr  r  r   r~  rQ   s     r<   	_print_CiSciPyPrinter._print_Ci  r  r>   )r4   rB   )r  r.  r/  r0  r,   r6   _scipy_known_functionsr4  _scipy_known_constantsr8   r{  _print_ImmutableSparseMatrixr  r:  r;  r  r  r=  r<  r  r  r  r  r  r  r  r  r  r>  r?  r@  s   @r<   ro  ro  =  s    
8\
8!7
8C
8\
8!7
8C6

 $: ''','+
+
+
+
+
+
CC$+
+ +r>   ro  zcupy.c                   <   ^  \ rS rSrSrSr\r\r	SU 4S jjr
SrU =r$ )CuPyPrinteri  zT
CuPy printer which handles vectorized piecewise functions,
logical operators, etc.
cupyc                     > [         TU ]  US9  g )Nr0   )r7   r8   r9   s     r<   r8   CuPyPrinter.__init__  s    (+r>    rB   )r  r.  r/  r0  r1  r3   _cupy_known_functionsr6   _cupy_known_constantsr4  r8   r>  r?  r@  s   @r<   r  r    s#    
 G
C
C, ,r>   r  z
jax.numpy.c                   H   ^  \ rS rSrSrSr\r\r	SU 4S jjr
S rS rSrU =r$ )	
JaxPrinteri  zS
JAX printer which handles vectorized piecewise functions,
logical operators, etc.
z	jax.numpyc                 .   > [         TU ]  US9  SU l        g )Nr0   _jaxcode)r7   r8   r5   r9   s     r<   r8   JaxPrinter.__init__  s    (+%r>   c                    ^  SR                  T R                  T R                  S-   5      T R                  T R                  5      SR                  U 4S jUR                   5       5      5      $ )r   r   z.allr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   (JaxPrinter._print_And.<locals>.<genexpr>       7YT[[^^YrI   r   rQ   s   ` r<   r   JaxPrinter._print_And  U    -44v 56-HH7TYY77
 	
r>   c                    ^  SR                  T R                  T R                  S-   5      T R                  T R                  5      SR                  U 4S jUR                   5       5      5      $ )r   r   z.anyr   c              3   F   >#    U  H  nTR                  U5      v   M     g 7frB   rC   rX   s     r<   rG   'JaxPrinter._print_Or.<locals>.<genexpr>  r  rI   r   rQ   s   ` r<   r   JaxPrinter._print_Or  r  r>   )r5   rB   )r  r.  r/  r0  r1  r3   _jax_known_functionsr6   _jax_known_constantsr4  r8   r   r   r>  r?  r@  s   @r<   r  r    s-     G
C
C&


 
r>   r  N)'
sympy.corer   sympy.core.functionr   sympy.core.powerr   pycoder   r   r	   r
   r   r   codeprinterr   split_not_in_numpyrv  	_in_numpydict_known_functions_numpy_known_constants_numpyr2  r3  r,   r   setattrconst_known_functions_scipy_special _known_constants_scipy_constantsr  r  ro  r  r  r  r  r  r  )krz  s   00r<   <module>r     sz    &   K  K $ 499; 5 ; ; =X =-AWVaV =X	i ,   
  7M6R6R6TU6Tda!X\/6TU 6L6R6R6TU6Tda!X\/6TU n7<!2 n7` #DLGD6*,=> # $ELGE7+-?@ $"&"	5" F" t	"
 t" t" t" W" W" " W" 	" u" " v"  m!"" ##"$  (3" : "
$   @^?c?c?ef?etq!.22?ef AaAgAgAijAi!0144Aij {+< {+z #DLGD6*,=> # $ELGE7+-?@ $ 6L5Q5Q5ST5STQWq[5ST 5K5Q5Q5ST5STQWq[5ST ,, , "DK74&)+<= " #EK75'*,>? # 9O8T8T8VW8V<!++8VW 8N8T8T8VW8V<!++8VW 
 
> !DJ'$(*;< ! "EJ'%)+=> "i Y. VUr gjL UT, XWs<   K1K1K7K=(LL	1LL:L#L!