Difference between revisions of "Sierpinski Assignment"
Jump to navigation
Jump to search
Line 22: | Line 22: | ||
(spacer-rect (image-width img) (image-height img)))</nowiki> | (spacer-rect (image-width img) (image-height img)))</nowiki> | ||
=Sierpiński= | =Sierpiński= | ||
+ | {{RacketToImplement|sierpinski|sierpinski-triangle<br>sierpinski-carpet|sierpinski_and_cantor}} | ||
==Triangle== | ==Triangle== | ||
[https://en.wikipedia.org/wiki/Sierpi%C5%84ski_triangle Sierpiński Triangle] | [https://en.wikipedia.org/wiki/Sierpi%C5%84ski_triangle Sierpiński Triangle] |
Revision as of 01:21, 16 March 2020
Contents
Code To Investigate
Racket Image Library
Racket Image Library Documentation
placement
shapes
Spacer
; fully transparent rectangle (define (spacer-rect w h) (rectangle w h "outline" (color 0 0 0 0))) ; fully transparent image the size of img (define (spacer-image img) (spacer-rect (image-width img) (image-height img)))
Sierpiński
file: | src/main/racket/sierpinski_and_cantor/sierpinski.rkt | |
functions: | sierpinski-triangle sierpinski-carpet |
Triangle
(define (sierpinski-triangle side-length n) (raise 'not-yet-implemented #t))
n=0 | n=1 | n=2 | n=3 | n=4 |
Carpet
(define (sierpinski-carpet side-length n) (raise 'not-yet-implemented #t))
n=0 | n=1 | n=2 | n=3 | n=4 |
Cantor
Stool
(define (cantor-stool width height n) (raise 'not-yet-implemented #t))
n=0 | n=1 | n=2 | n=3 | n=4 |