a
    {dw                     @   s   d dl mZmZmZ d dl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mZmZmZmZ d dl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 Z dd Z!dd Z"dS )    )IRationaloo)S)Symbol)explog)sqrt)singularitiesis_increasingis_strictly_increasingis_decreasingis_strictly_decreasingis_monotonic)Interval	FiniteSet)raises)xyc                      s  t d t d  tjks J t  d d   d   tddksLJ td d d   ttt ksrJ t  d d   tddtdt  d dtdt  d ksJ tdtd dt t  d  ttt tdt  t tdt  ksJ t ddd td d d   tjks4J ttd   tj	td	ksXJ ttd   t
ddtjks~J tt d d  t
ddtdksJ tt fd
d d S )Nr            T)realr   c                      s   t  t   S )N)r
   r    r   r   p/var/www/html/stable-diffusion-webui/venv/lib/python3.9/site-packages/sympy/calculus/tests/test_singularities.py<lambda>"       z$test_singularities.<locals>.<lambda>)r   r
   r   ZEmptySetr   r   r	   r   r   Realsr   r   r   NotImplementedErrorr   r   r   r   test_singularities   s     ,&* $
"$&,r"   c                  C   s&  t ddd} ttd dtd   dt  tjs4J ttd  tt dsPJ ttd  tdtrjJ tdtd  dtd   d	t  d
 tddrJ ttd t tdttsJ ttd  |  tdttsJ tdsJ tdtd  dtd   d	t  d
 tdddu s"J dS )z1Test whether is_increasing returns correct value.aT)negativer   r      r      H      r   r   FN)r   r   r   r   r    r   r   r   )r#   r   r   r   test_is_increasing%   s    (4 r)   c                   C   s
  t dtd  dtd   dt  d tt ds8J t dtd  dtd   dt  d tdtsnJ t dtd  dtd   dt  d tddrJ t td  tdtrJ td	rJ t dtd  dtd   dt  d tddd
u sJ dS )z:Test whether is_strictly_increasing returns correct value.r%   r   r&   r   r'   r(   r   r   r   FN)r   r   r   Ropenr   Lopenopenr   r   r   r   r   test_is_strictly_increasing4   s    .,,r-   c                  C   s   t ddd} tdtd dt   ttddds8J tdtd dt   tdds^J tdtd dt   tdtsJ tdtd dt   tt tddrJ ttd  tt drJ ttd  |  tt dtrJ d	S )
z1Test whether is_decreasing returns correct value.bT)Zpositiver   r   r         ?r   N)	r   r   r   r   r,   r   r+   r   r*   )r.   r   r   r   test_is_decreasingB   s    ,&&.r0   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rTJ t td  tt drpJ t dr|J t dtd dt   ttdddsJ t dtd dt   tddsJ dS )z:Test whether is_strictly_decreasing returns correct value.r   r   r   r   r/   N)r   r   r   r+   r   r*   r   r,   r   r   r   r   test_is_strictly_decreasingN   s    &$,r1   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sRJ t dtd dt   tdtsxJ t td dtd   dt  tjsJ t td  tjrJ t td t	 d tddtsJ t
tdd  dS )	z0Test whether is_monotonic returns correct value.r   r   r   r/   r%   c                   S   s   t td t d S )Nr   r   )r   r   r   r   r   r   r   r   a   r   z#test_is_monotonic.<locals>.<lambda>N)r   r   r   r,   r   r+   r   r   r    r   r   r!   r   r   r   r   test_is_monotonicY   s    ,&&("r2   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_23401d   s     r4   N)#Zsympy.core.numbersr   r   r   Zsympy.core.singletonr   Zsympy.core.symbolr   Z&sympy.functions.elementary.exponentialr   r   Z(sympy.functions.elementary.miscellaneousr	   Zsympy.calculus.singularitiesr
   r   r   r   r   r   Z
sympy.setsr   r   Zsympy.testing.pytestr   Z	sympy.abcr   r   r"   r)   r-   r0   r1   r2   r4   r   r   r   r   <module>   s    