+
    i                     X    ^ RI Ht ^ RIHt ^ RIHt ^ RItR tR tR t	R
R lt
R
R	 ltR# )    )Float)Dummy)lambdifyNc                    V f   R# \        V \        4      '       d   R# \        P                  ! V 4      '       * ;'       d    \        P                  ! V 4      '       * # )z)Check if a floating point number is validF)
isinstancecomplexmathisinfisnan)xs   &w/Users/tonyclaw/.openclaw/workspace/skills/math-calculator/venv/lib/python3.14/site-packages/sympy/plotting/textplot.pyis_validr      s>    y!Wzz!}22TZZ]!22    c                   . pWC,
          pWC,           ^,          p\        V4       F  p\        W,          4      '       d   W,          V,
          V,          p	\        V	4      '       g   VP                  R4       KT  \        W,          V^,          ,           V^,
          ,          V,          4      P	                  4       p
\        V
4      p
VP                  V
4       K  VP                  R4       K  	  V# )z{Rescale the given array `y` to fit into the integer values
between `0` and `H-1` for the values between ``mi`` and ``ma``.
N)ranger   appendr   roundint)yWHmimay_newnormoffsetr   
normalizedrescaleds   &&&&&      r   rescaler      s     E7Dg]F1XAD>>$-4/JJ''T" *,1"41!=a!?@FFHx=X&LL  Lr   c                     \        V4       Uu. uF&  q0W,
          V,          V^,
          ,          ,           NK(  	  up# u upi )   )r   )startstopnumr   s   &&& r   linspacer%   (   s4    :?*E*QT\Q&#a%000*EEEs   ,=c              #  	  "   V P                   p\        V4      ^8  d   \        RP                  V4      4      hV'       d   VP	                  4       M	\        4       p\        V.V 4      p\        V\        4      '       d   VP                  ^ 8X  d   VP                  p\        V\        4      '       d   VP                  ^ 8X  d   VP                  p\        V4      p\        V4      p\        WV4      p. pV F  p	 VP                  V! V	4      4       K  	  \!        \#        \$        V4      4      p
V
'       d@   \'        V
4      p\)        V
4      pW8X  d#   V'       d   \+        ^ ^V,          .4      w  rMR^rMR^rW,
          p\,        P.                  ! \,        P0                  ! V4      4      ^,
          pVR,          p\3        W4      p\3        W4      p\5        WWLV4      p\        WV4      p^p\7        V^,
          RR4       EF  pR.V,          p\7        V4       F  pVV,          V8X  g   K  V^ 8X  g   VV^,
          ,          V^,
          8X  d2   VV^,
          8X  g   VV^,           ,          V^,           8X  d   RVV&   Kg  V^ 8X  g   VV^,
          ,          V^,           8X  d2   VV^,
          8X  g   VV^,           ,          V^,
          8X  d   RVV&   K  RVV&   K  	  V^ 8X  d   \7        V4       F  pRVV&   K
  	  V^ V^,          V^,
          39   d$   RVV,          ,          P9                  V4      RV pM	RV,          pR	P;                  V4      pVV^,          8X  d   VP=                  RR
4      pVR,           V,           x  EK  	  RV^,           ,          pVRV^ ,          ,          P?                  V^,          4      ,          pV^,          ^8X  d5   VRWc^,          ,          ,          P?                  V^,          4      ,          pM:VRWc^,          ,          ,          P?                  V^,          ^,
          4      ,          pVRVR,          ,          ,          pVx  R#   \        \        \        3 d    TP                  R4        EK  i ; i5i)z#Generator for the lines of the plotz4The expression must have a single variable. (Got {})N /\._z%g -z |) free_symbolslen
ValueErrorformatpopr   r   r   r   imagrealfloatr%   r   	TypeErrorZeroDivisionErrorlistfilterr   maxminsortedr	   floorlog10r   r   r   rjustjoinreplaceljust)exprabr   r   freer   fr   valy_validr   r   y_range	precisiony_binsmarginhsiprefixbottoms   &&&&&                 r   textplot_strrT   ,   s    D
4y1}BVD\ 	 
A!dA!W66Q;A!W66Q;AaAaA 	qA
A	HHQsV  6(A&'G\\8AbD	*BQBQBgG

4::g./!3IOI	r	B	r	BaR Aba F F1q5"b!EAIqAtqyFaAh!a%/a1q5jAa!eHPQTUPUDUAaD1f!a%AE 1QU
aAhRSVWRWFWAaDAaD  61X!  AqD!a%  VAY&--f5gv>FZFGGAJ19		#s#Atma/ "4 FQJF
tad{!!!Q$''F1uz4!qD'>((A..4!qD'>((Aa00
dQrUlF
Lw I'89 	HHTNN	s?   >R	B6R	8QAR	CR	)H1R	'RR	RR	c                D    \        WW#V4       F  p\        V4       K  	  R# )aC  
Print a crude ASCII art plot of the SymPy expression 'expr' (which
should contain a single symbol, e.g. x or something else) over the
interval [a, b].

Examples
========

>>> from sympy import Symbol, sin
>>> from sympy.plotting import textplot
>>> t = Symbol('t')
>>> textplot(sin(t)*t, 0, 15)
 14 |                                                  ...
    |                                                     .
    |                                                 .
    |                                                      .
    |                                                .
    |                            ...
    |                           /   .               .
    |                          /
    |                         /      .
    |                        .        .            .
1.5 |----.......--------------------------------------------
    |....       \           .          .
    |            \         /                      .
    |             ..      /             .
    |               \    /                       .
    |                ....
    |                                    .
    |                                     .     .
    |
    |                                      .   .
-11 |_______________________________________________________
     0                          7.5                        15
N)rT   print)rD   rE   rF   r   r   lines   &&&&& r   textplotrX      s    H TaA.d /r   )7      )sympy.core.numbersr   sympy.core.symbolr   sympy.utilities.lambdifyr   r	   r   r   r%   rT   rX    r   r   <module>r_      s-    $ # - 3.FTn%r   