o
    oh                     @   s  d dl mZmZmZmZ d dlmZ d dlmZm	Z	 d dl
mZ d dlmZmZ d dlmZmZ d dlmZmZmZmZmZmZ d dlmZ d d	lmZmZmZmZm Z m!Z! d d
l"m#Z#m$Z$m%Z%m&Z& d dl'm(Z( d dl)m*Z*m+Z+ dd Z,dd Z-dd Z.dd Z/dd Z0dd Z1dd Z2dS )    )IRationalpioo)S)SymbolDummy)Lambda)explog)seccsc)cothsechatanhasechacothacsch)sqrt)singularitiesis_increasingis_strictly_increasingis_decreasingis_strictly_decreasingis_monotonic)Interval	FiniteSetUnionImageSet)raises)xyc               
      sv  t d t d  tjksJ t  d d   d   tddks&J td d d   ttt ks9J t  d d   tddtdt  d dtdt  d ks\J tdtd dt t  d  ttt tdt  t tdt  ksJ td} tt	  
ttt| d|  t t tt d  tjtt| d|  t t dt t d  tjsJ tt  
ttt| d|  t t tt  tjtt| d|  t t tjsJ tt  tddksJ tt  tddksJ tt  tdksJ tt  tdks#J t dd	d
 td d d   tjks:J ttd   tjtdksLJ ttd   tddtjks_J tt d d  tddtdksuJ tt fdd tt  tddt ttd dt d dt d ksJ tt  tddt tdtdt dt ksJ d S )Nr             nr   T)realc                      s   t  t   S )N)r   r    r    r)   {/var/www/html/construction_image-detection-poc/venv/lib/python3.10/site-packages/sympy/calculus/tests/test_singularities.py<lambda>1   s    z$test_singularities.<locals>.<lambda>   )r   r   r   EmptySetr   r   r   r!   r   r   dummy_eqr   r   r	   r   Integersr   r   r   r   r   r
   Realsr   r   r   NotImplementedErrorr   r   )_nr)   r*   r+   test_singularities   sF   ,&* $(,
$
"$&,r4   c                  C   s$  t ddd} ttd dtd   dt  tjsJ ttd  tt ds(J ttd  tdtr5J tdtd  dtd   d	t  d
 tddrOJ ttd t tdtts^J ttd  |  tdttsnJ tdstJ tdtd  dtd   d	t  d
 tdddu sJ dS )z1Test whether is_increasing returns correct value.aT)negativer#   r"      r      H      r$   r&   FN)r   r   r    r   r1   r   r   r!   )r5   r)   r)   r+   test_is_increasing8   s   (4 <r;   c                   C   s  t dtd  dtd   dt  d tt dsJ t dtd  dtd   dt  d tdts7J t dtd  dtd   dt  d tddrRJ t td  tdtr_J td	reJ t dtd  dtd   dt  d tddd
u sJ dS )z:Test whether is_strictly_increasing returns correct value.r7   r#   r8   r"   r9   r:   r$   r   r&   FN)r   r    r   Ropenr   Lopenopenr   r)   r)   r)   r+   test_is_strictly_increasingG   s   .,,>r?   c                  C   s   t ddd} tdtd dt   ttdddsJ tdtd dt   tdds/J tdtd dt   tdtsBJ tdtd dt   tt tddrYJ ttd  tt drgJ ttd  |  tt dtrxJ d	S )
z1Test whether is_decreasing returns correct value.bT)positiver&   r"   r#         ?r   N)	r   r   r    r   r>   r   r=   r   r<   )r@   r)   r)   r+   test_is_decreasingU   s   ,&&.&rC   c                   C   s   t dtd dt   tdtsJ t dtd dt   tt tddr*J t td  tt dr8J t dr>J t dtd dt   ttdddsTJ t dtd dt   tddsgJ dS )z:Test whether is_strictly_decreasing returns correct value.r&   r"   r#   r   rB   N)r   r    r   r=   r   r<   r   r>   r)   r)   r)   r+   test_is_strictly_decreasinga   s   &$,*rD   c                   C   s   t dtd dt   ttdddsJ t dtd dt   tdds)J t dtd dt   tdts<J t td dtd   dt  tjsPJ t td  tjr[J t td t	 d tddtslJ t
tdd  dS )	z0Test whether is_monotonic returns correct value.r&   r"   r#   rB   r7   c                   S   s   t td t d S )Nr"   r&   )r   r    r!   r)   r)   r)   r+   r,   t   s    z#test_is_monotonic.<locals>.<lambda>N)r   r    r   r>   r   r=   r   r   r1   r!   r   r2   r)   r)   r)   r+   test_is_monotonicl   s   ,&&("rE   c                  C   sB   t d} | d d| d  d|   d  }t|tdd| sJ d S )Nr    r&   gMbPr"   g?)r   r   r   )r    exprr)   r)   r+   test_issue_23401w   s    rG   N)3sympy.core.numbersr   r   r   r   sympy.core.singletonr   sympy.core.symbolr   r   sympy.core.functionr	   &sympy.functions.elementary.exponentialr
   r   (sympy.functions.elementary.trigonometricr   r   %sympy.functions.elementary.hyperbolicr   r   r   r   r   r   (sympy.functions.elementary.miscellaneousr   sympy.calculus.singularitiesr   r   r   r   r   r   
sympy.setsr   r   r   r   sympy.testing.pytestr   	sympy.abcr    r!   r4   r;   r?   rC   rD   rE   rG   r)   r)   r)   r+   <module>   s&      !