ÿØÿà JFIF      ÿÛ „ 	 ( %!1!%)+//.383,7(-.+



-%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ               ÿÄ J  	     ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ              ÿÄ *        !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú
"SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5
ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍÑ¶¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e
ríV
..............................................................................................................................................................................
.............................................................................                                                  
                                                                                                                                                                                     ÿØÿà JFIF      ÿÛ „ 	 ( %!1!%)+//.383,7(-.+



-%%-////---/-.+/--+------/------/--0+--/-/-----.-----ÿÀ  ¥2" ÿÄ               ÿÄ J  	     ! 1AQ"aq2‘#BR‚¡ÁÑ3br’¢±Âð$CSƒ²á4c“%DsÓñÿÄ              ÿÄ *        !1AQa‘"2q3±ð#b¡ÿÚ   ? ¼QxJQaÍuò¸Zö Úü8,ÐÚú
"SSn<rçù–´âE—^ªBÖ9À\†¸ÔÁT­ÃÛ5
ëd´³Í#Ý;Þ38œî ¶H£M:wÎ3…³…âpÔF&‚FK¸9„â4àGEõªfÿ ‘ñ(ßw­pŽF|È¥ù®häðÍÑ¶¹‘[ÒinÙW¶ùñY˜Q{›K"išÒ[Ú8žë\F¹@-?v"ÔU”,ìöžkÿ {I‡£šÍ?e
ríV
..............................................................................................................................................................................
.............................................................................                                                  
                                                                                                                                                                                     
Afc           @   sm   d  Z  d d l Td d l m Z m Z d e f d     YZ d   Z e d k ri e   Z	 e	 GHe
   n  d S(	   s&        turtle-example-suite:

        tdemo_fractalCurves.py

This program draws two fractal-curve-designs:
(1) A hilbert curve (in a box)
(2) A combination of Koch-curves.

The CurvesTurtle class and the fractal-curve-
methods are taken from the PythonCard example
scripts for turtle-graphics.
i(   t   *(   t   sleept   clockt   CurvesTurtlec           B   s#   e  Z d    Z d   Z d   Z RS(   c         C   s   | d k r d  S|  j  | d  |  j | | d |  |  j |  |  j | d  |  j | | d |  |  j |  |  j | | d |  |  j | d  |  j |  |  j | | d |  |  j  | d  d  S(   Ni    iZ   i   (   t   leftt   hilbertt   forwardt   right(   t   selft   sizet   levelt   parity(    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyR      s    c         C   s   d d  l  } d | | j | j |  } |  j   |  j |  |  j   |  j d d | d |  x8 t |  D]* } |  j | | |  |  j d |  qu W|  j	 d d | d |  |  j   |  j
 |  |  j   d  S(   Nii   i   iZ   ih  (   t   matht   sint   pit   put   fdt   pdt   rtt   ranget   fractalt   ltt   bk(   R   t   nt   radt   levt   dirR   t   edget   i(    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyt
   fractalgon/   s    


c         C   s   | d k  r |  j  |  d  S|  j | d | d |  |  j d |  |  j | d | d |  |  j d |  |  j | d | d |  |  j d |  |  j | d | d |  d  S(   Ni   i   i<   ix   (   R   R   R   R   (   R   t   distt   depthR   (    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyR   B   s    (   t   __name__t
   __module__R   R   R   (    (    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyR      s   		c          C   sr  t    }  |  j   |  j d  |  j   |  j d d  |  j   d } |  j d | d |  |  j   t   } |  j	 d  |  j
 t  |  j |  |  j | d d  |  j |  x: t d  D], } |  j d  |  j | d	 | d
  q W|  j   x. t d
  D]  } |  j |  |  j d  qW|  j   x: t d  D], } |  j | d | d
  |  j d  qKW|  j
 t  t   } d | | } t d  |  j   |  j d  |  j   |  j d d  t   } |  j d d  |  j
 t  |  j d d d d  |  j
 t  |  j d  |  j d d d d  |  j
 t  t   } | d | | 7} | S(   Ni    i   i   iit   redi   iZ   i@   i   i   iB   s   Hilbert: %.2fsec. t   blackt   bluei   i   is   Koch: %.2fsec.(   R   t   resett   speedt   htt   tracerR   t   setposR   R   t	   fillcolort   fillt   TrueR   R   R   R   R   t   FalseR   t   colorR   (   t   ftR	   t   taR   t   tbt   res(    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyt   mainN   sZ    	



	

	


		t   __main__N(   t   __doc__t   turtlet   timeR   R   t   PenR   R3   R    t   msgt   mainloop(    (    (    s7   /usr/lib64/python2.7/Demo/turtle/tdemo_fractalcurves.pyt   <module>   s   
=	8	