Ë
    ÄOígÑ  ã                  óL   — d dl mZ d dlmZ d dlZd dlmZ  G d„ d«      Zdd„Z	y)	é    )Úannotations)ÚIterableN)ÚVec3c                  ó    — e Zd ZdZdd„Zdd„Zy)ÚCSplinea[  
    In numerical analysis, a cubic Hermite spline or cubic Hermite interpolator
    is a spline where each piece is a third-degree polynomial specified in
    Hermite form, that is, by its values and first derivatives at the end points
    of the corresponding domain interval.

    Source: https://en.wikipedia.org/wiki/Cubic_Hermite_spline
    c                ó<   — || _         || _        || _        || _        y )N©Úp0Úp1Úm0Úm1)Úselfr
   r   r   r   s        úW/var/www/html/public_html/myphp/venv/lib/python3.12/site-packages/ezdxf/math/cspline.pyÚ__init__zCSpline.__init__   s   € ØˆŒØˆŒØˆŒØˆó    c                óè   — ||z  }||z  }|dz  |dz  z
  dz   }| dz  |dz  z   }||dz  z
  |z   }||z
  }| j                   |z  | j                  |z  z   | j                  |z  z   | j                  |z  z   S )Ng       @g      @ç      ð?r	   )r   ÚtÚt2Út3Úh00Úh10Úh01Úh11s           r   ÚpointzCSpline.point   s   € Ø‰UˆØ!‰VˆØ3‰h˜˜c™Ñ! CÑ'ˆØˆcC‰i˜"˜s™(Ñ"ˆØ2˜‘8‰m˜aÑˆØ2‰gˆØw‰w˜‰}˜tŸw™w¨™}Ñ,¨t¯w©w¸©}Ñ<¸t¿w¹wÈ¹}ÑLÐLr   N)r
   r   r   r   r   r   r   r   )r   ÚfloatÚreturnr   )Ú__name__Ú
__module__Ú__qualname__Ú__doc__r   r   © r   r   r   r   
   s   „ ñóôMr   r   c              #  óx   K  — | D ]1  }t        j                  dd|«      D ]  }|j                  |«      –— Œ Œ3 y ­w)Ng        r   )ÚnpÚlinspacer   )ÚcsplinesÚcountÚcspliner   s       r   Úapproximater)   %   s@   è ø€ Øò #ˆÜ—‘˜S # uÓ-ò 	#ˆAØ—-‘- Ó"Ó"ñ	#ñ#ùs   ‚8:)r&   zIterable[CSpline]r   zIterable[Vec3])
Ú
__future__r   Útypingr   Únumpyr$   Ú
ezdxf.mathr   r   r)   r"   r   r   ú<module>r.      s$   ðõ #Ý Û å ÷Mñ Mô6#r   