ó
    oñ:iÞ  ã                   óP   • S SK Jr  S SKrS SKrS SKrS/r " S S\5      rS rS r	g)é    )ÚNumberNÚVectorc                   ó  ^ • \ rS rSrSrSrS U 4S jjrU 4S jrS rS r	S r
S	 r\rS
 rS rS r\rS rS rS rS r\S.S jrU 4S jrS rS r\rS rS rS rS rS r\ S 5       r!\!RD                  S 5       r!SS S\#4S jr$Sr%U =r&$ )!r   é
   zËA math-like vector.

Represents an n-dimensional numeric vector. ``Vector`` objects support
vector addition and subtraction, scalar multiplication and division,
negation, rounding, and comparison tests.
© c                 óŒ   >• USLa  [         R                  " S[        5        [        U5      [        :X  a  U$ [
        TU ]  X5      $ )NFz'the 'keep' argument has been deprecated)ÚwarningsÚwarnÚDeprecationWarningÚtyper   ÚsuperÚ__new__)ÚclsÚvaluesÚkeepÚ	__class__s      €ÚX/srv/projetos/modelo_ml_acdoc/venv/lib/python3.13/site-packages/fontTools/misc/vector.pyr   ÚVector.__new__   s?   ø€ Ø�uÒÜ�MŠMØ9Ü"ôô �‹<œ6Ó!àˆMÜ‰w‰˜sÓ+Ð+ó    c                 óT   >• U R                   R                   S[        TU ]  5        S3$ )NÚ(Ú))r   Ú__name__r   Ú__repr__)Úselfr   s    €r   r   ÚVector.__repr__   s*   ø€ Ø—.‘.×)Ñ)Ð*¨!¬E©GÑ,<Ó,>Ð+?¸qÐAÐAr   c                 ó$  ^^• [        T[        5      (       a?  [        U 5      [        T5      :X  d   eU R                  U4S j[	        U T5       5       5      $ [        T[
        5      (       a  U R                  UU4S jU  5       5      $ [        5       e)Nc              3   ó8   >#   • U  H  u  pT" X5      v •  M     g 7f©Nr   )Ú.0ÚaÚbÚops      €r   Ú	<genexpr>Ú#Vector._vectorOp.<locals>.<genexpr>%   s   øé € Ð!HÒ7G©t¨q¡" Q§( (Ò7Gùs   ƒc              3   ó6   >#   • U  H  nT" UT5      v •  M     g 7fr   r   ©r    Úvr#   Úothers     €€r   r$   r%   '   ó   øé € Ð!=º°1¡" Q¨§, ,ºùó   ƒ)Ú
isinstancer   Úlenr   Úzipr   ÚNotImplementedError©r   r)   r#   s    ``r   Ú	_vectorOpÚVector._vectorOp"   sm   ù€ Ü�eœV×$Ñ$Ü�t“9¤ E£
Ó*Ð*Ð*Ø—>‘>Ô!H´s¸4ÀÔ7GÓ!HÓHÐHÜ�eœV×$Ñ$Ø—>‘>Õ!=¹Ó!=Ó=Ð=Ü!Ó#Ð#r   c                 ó|   ^^• [        T[        5      (       a  U R                  UU4S jU  5       5      $ [        5       e)Nc              3   ó6   >#   • U  H  nT" UT5      v •  M     g 7fr   r   r'   s     €€r   r$   Ú#Vector._scalarOp.<locals>.<genexpr>,   r*   r+   )r,   r   r   r/   r0   s    ``r   Ú	_scalarOpÚVector._scalarOp*   s.   ù€ Ü�eœV×$Ñ$Ø—>‘>Õ!=¹Ó!=Ó=Ð=Ü!Ó#Ð#r   c                 ó:   ^• U R                  U4S jU  5       5      $ )Nc              3   ó4   >#   • U  H  nT" U5      v •  M     g 7fr   r   )r    r(   r#   s     €r   r$   Ú"Vector._unaryOp.<locals>.<genexpr>0   s   øé € Ð2ªT¨™b Ÿe˜eªTùs   ƒ©r   )r   r#   s    `r   Ú_unaryOpÚVector._unaryOp/   s   ø€ Ø�~‰~Ô2©TÓ2Ó2Ð2r   c                 óB   • U R                  U[        R                  5      $ r   )r1   ÚoperatorÚadd©r   r)   s     r   Ú__add__ÚVector.__add__2   ó   € Ø�~‰~˜e¤X§\¡\Ó2Ð2r   c                 óB   • U R                  U[        R                  5      $ r   )r1   r?   ÚsubrA   s     r   Ú__sub__ÚVector.__sub__7   rD   r   c                 ó.   • U R                  U[        5      $ r   )r1   Ú_operator_rsubrA   s     r   Ú__rsub__ÚVector.__rsub__:   s   € Ø�~‰~˜e¤^Ó4Ð4r   c                 óB   • U R                  U[        R                  5      $ r   )r6   r?   ÚmulrA   s     r   Ú__mul__ÚVector.__mul__=   rD   r   c                 óB   • U R                  U[        R                  5      $ r   )r6   r?   ÚtruedivrA   s     r   Ú__truediv__ÚVector.__truediv__B   s   € Ø�~‰~˜e¤X×%5Ñ%5Ó6Ð6r   c                 ó.   • U R                  U[        5      $ r   )r6   Ú_operator_rtruedivrA   s     r   Ú__rtruediv__ÚVector.__rtruediv__E   s   € Ø�~‰~˜eÔ%7Ó8Ð8r   c                 ó@   • U R                  [        R                  5      $ r   )r<   r?   Úpos©r   s    r   Ú__pos__ÚVector.__pos__H   ó   € Ø�}‰}œXŸ\™\Ó*Ð*r   c                 ó@   • U R                  [        R                  5      $ r   )r<   r?   Únegr[   s    r   Ú__neg__ÚVector.__neg__K   r^   r   )Úroundc                ó$   • U R                  U5      $ r   )r<   )r   rc   s     r   Ú	__round__ÚVector.__round__N   s   € Ø�}‰}˜UÓ#Ð#r   c                 ób   >• [        U[        5      (       a  [        U5      n[        TU ]  U5      $ r   )r,   ÚlistÚtupler   Ú__eq__)r   r)   r   s     €r   rj   ÚVector.__eq__Q   s(   ø€ Ü�eœT×"Ñ"ä˜%“LˆEÜ‰w‰~˜eÓ$Ð$r   c                 ó.   • U R                  U5      (       + $ r   )rj   rA   s     r   Ú__ne__ÚVector.__ne__W   s   € Ø—;‘;˜uÓ%Ô%Ð%r   c                 ó   • [        U 5      $ r   )Úanyr[   s    r   Ú__bool__ÚVector.__bool__Z   s   € Ü�4‹yÐr   c                 óN   • [         R                  " [        S U  5       5      5      $ )Nc              3   ó*   #   • U  H	  oU-  v •  M     g 7fr   r   )r    Úxs     r   r$   Ú!Vector.__abs__.<locals>.<genexpr>`   s   é € Ð1ªD q žUªDùs   ‚)ÚmathÚsqrtÚsumr[   s    r   Ú__abs__ÚVector.__abs___   s   € Ü�yŠyœÑ1©DÓ1Ó1Ó2Ð2r   c                 ó   • [        U 5      $ )z;Return the length of the vector. Equivalent to abs(vector).©Úabsr[   s    r   ÚlengthÚVector.lengthb   s   € ä�4‹yÐr   c                 ó   • U [        U 5      -  $ )z+Return the normalized vector of the vector.r}   r[   s    r   Ú
normalizedÚVector.normalizedf   s   € à”c˜$“iÑÐr   c                 ól   • [        U 5      [        U5      :X  d   e[        S [        X5       5       5      $ )zSPerforms vector dot product, returning the sum of
``a[0] * b[0], a[1] * b[1], ...``c              3   ó.   #   • U  H  u  pX-  v •  M     g 7fr   r   )r    r!   r"   s      r   r$   ÚVector.dot.<locals>.<genexpr>n   s   é € Ð6Ò%5™T˜Q�1–5Ò%5ùs   ‚)r-   ry   r.   rA   s     r   ÚdotÚ
Vector.dotj   s0   € ô �4‹yœC ›JÓ&Ð&Ð&ÜÑ6¤S¨Ô%5Ó6Ó6Ð6r   c                 óX   • [         R                  " S[        5        U R                  5       $ )NzAthe 'toInt' method has been deprecated, use round(vector) instead)r	   r
   r   re   r[   s    r   ÚtoIntÚVector.toIntr   s#   € Ü�ŠØOÜô	
ð �~‰~ÓÐr   c                 óN   • [         R                  " S[        5        [        U 5      $ )NzPthe 'values' attribute has been deprecated, use the vector object itself instead)r	   r
   r   rh   r[   s    r   r   ÚVector.valuesy   s"   € ä�Šð/äô	
ô
 �D‹zÐr   c                 ó   • [        S5      e)Nz?can't set attribute, the 'values' attribute has been deprecated)ÚAttributeError)r   r   s     r   r   r�   ‚   s   € äØMó
ð 	
r   r)   Úreturnc                 ót   ^• [        U 5      [        U5      :X  d   e[        U4S j[        X5       5       5      $ )z5Return True if the vector is close to another Vector.c              3   óV   >#   • U  H  u  p[         R                  " X40 TD6v •  M      g 7fr   )rw   Úisclose)r    r!   r"   Úkwargss      €r   r$   Ú!Vector.isclose.<locals>.<genexpr>‹   s#   øé € ÐMÒ<L±D°A”4—<’< Ñ/¨Ö/Ò<Lùs   ƒ&))r-   Úallr.   )r   r)   r”   s     `r   r“   ÚVector.iscloseˆ   s/   ø€ ä�4‹yœC ›JÓ&Ð&Ð&ÜÔM¼CÀÔ<LÓMÓMÐMr   )F)'r   Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Ú	__slots__r   r   r1   r6   r<   rB   Ú__radd__rG   rK   rO   Ú__rmul__rS   rW   r\   ra   rc   re   rj   rm   rq   Ú__nonzero__rz   r   r‚   r‡   rŠ   Úpropertyr   ÚsetterÚboolr“   Ú__static_attributes__Ú__classcell__r;   s   @r   r   r   
   sà   ø† ñð €I÷	,õBò$ò$ò
3ò3ð €Hò3ò5ò3ð €Hò7ò9ò+ò+ð "'õ $õ%ò&òð €Kò3òò ò7ò ð ñó ðð ‡]�]ñ
ó ð
ð
N˜Xð N°D÷ Nò Nr   c                 ó.   • [         R                  " X5      $ r   )r?   rF   ©r!   r"   s     r   rJ   rJ   Ž   s   € Ü�<Š<˜ÓÐr   c                 ó.   • [         R                  " X5      $ r   )r?   rR   r¦   s     r   rV   rV   ’   s   € Ü×Ò˜AÓ!Ð!r   )
Únumbersr   rw   r?   r	   Ú__all__ri   r   rJ   rV   r   r   r   Ú<module>rª      s5   ðÝ Û Û Û ð ˆ*€ôANˆUô ANòHó"r   