En cours

Easy java project

Write an applet that develops a Sierpinski triangle and the GUI interface to it. The Sierpinski triangle generation algorithm is given in Savitch’s book (3rd edition) on pp 1061-2. That text is reproduced here.

Write a program that draws a Sierpinski gasket. A Sierpinski gasket or triangle is a type of fractal. It is an example of how an orderly structure can be created as a result of random, chaotic behavior.

The creation of a Sierpinski gasket is fairly simple. There are three points that form the corners of a triangle. In the figure below, they are labeled as A, B, and C.

B (Sorry for the quality of the scheme)

/\

/ \

/ \

/ \

/ \

/ \

A /______________\C

To draw the Sierpinski gasket follow the algorithm:

1. Randomly pick one of the three corners. Call this the current point. (Alternatively, you could also randomly select any point inside the triangle).

2. Randomly pick one of the three corners. Call this the target point.

3. Calculate the midpoint between the current point and the target point.

4. Draw a single pixel at the midpoint.

5. Set the current point to the midpoint.

6. Go back to step 2 and repeat many times (e.g., 50,000 iterations).

It would seem like you should get a random mess of dots since the algorithm randomly picks a target corner each time. Instead, if this process is repeated many times, you will get a very orderly picture with a repeating structure: <picture from Savitch is not reproduced here. Look at [url removed, login to view]

To draw a single pixel at coordinate (x, y) use the drawline method where the start and endpoints are both (x, y).

To generate a random number x, where 0 < x < 1, use x = [url removed, login to view]();. For example, multiplying by 3 and converting to an integer results in an integer that is from 0 to 2.

Compétences : Java

Voir plus : easy java project, savitch sierpinski, java sierpinski gasket randomly pick corners, random java sierpinski, java sierpinski randomly pick target, simple algorithm example, set algorithm, random no generation in c, program algorithm example, java to applet, how to write a simple algorithm, get math org, get a wikipedia, example of project, example of an algorithm, example of algorithm, c look algorithm, book pixel, applet.start, applet start, applet http, an example of an algorithm, algorithm set, algorithm creation, how to write an e-book

Concernant l'employeur :
( 3 commentaires ) Volos, Greece

N° du projet : #1623067

Décerné à :

throwngo

We're the right professionals and can deliver this job accordingly to your specs.

30 € EUR en 2 jours
(1 Commentaire)
1.2

25 freelance ont fait une offre moyenne de 55 € pour ce travail

dobreiiita

Hi, I am JAVA expert and can surely do this job. Thank You

30 € EUR en 1 jour
(179 Commentaires)
6.4
it2051229

Hi, kindly check your inbox for my inquiries. Thanks.

30 € EUR en 0 jours
(174 Commentaires)
6.1
procoder898

Hi, I am expert at Java and can surely satisfy you. Please check your inbox,

45 € EUR en 0 jours
(80 Commentaires)
6.1
diepbp

I am confident to handle your project. Please check your inbox for details, thank you.

45 € EUR en 1 jour
(77 Commentaires)
6.0
samitXI

Please check your inbox. Thanks

65 € EUR en 2 jours
(67 Commentaires)
5.9
buzzcoder

Easy project to me, kindly check your pm for more detail, thanks.

60 € EUR en 1 jour
(45 Commentaires)
5.5
kevinxiaozi

Dear sir, I am strong in java programming especially in algorithm implementation. I am proficient in Geometry algorithm including Polygon Cutting, Triangulation, Convex Hull algorithms and Stock Cutting problem. Plus

35 € EUR en 1 jour
(25 Commentaires)
5.3
csanuragjain

hi i can do this contact if interested

40 € EUR en 3 jours
(22 Commentaires)
5.1
coolbuddy19

Hi I am confident to handle this

100 € EUR en 2 jours
(15 Commentaires)
3.7
kikoqiu

Please check PMB.

30 € EUR en 0 jours
(3 Commentaires)
3.6
AmberSerpent

I have 4 years Java experience. I can write the prgram for you.

50 € EUR en 1 jour
(2 Commentaires)
3.4
coderz01

Hello. I can help you.

45 € EUR en 2 jours
(4 Commentaires)
3.1
tge

Hello, I can handle this project.

30 € EUR en 1 jour
(1 Commentaire)
2.4
vernonsullivan

Sierpinski triangle is cool stuff, would love to give it a try.

30 € EUR en 0 jours
(2 Commentaires)
1.9
codingJon

Sierpinski triangles are really neat, and I would love to do this project. I have experience working in Java and creating java applets.

45 € EUR en 2 jours
(0 Commentaires)
0.0
zeljkoar

Hi, I graduated computer science and I have this code already finished. If you are interested please award my bid and I will provide you code tonight. Thanks, Zeljko

30 € EUR en 0 jours
(0 Commentaires)
0.0
bssankaran

Hi Sir I did this for you and will give it to you instantly for the lowest price. Please check the screen shots in your mail. I studied your requirement carefully and read more about it before doing it.

30 € EUR en 0 jours
(0 Commentaires)
0.0
AndrewFromRussia

Hi, I've already made the applet for you. In fact it was a very simple task. I'd not hesitate to make it for symbolic one euro. Cheers!

30 € EUR en 0 jours
(0 Commentaires)
0.0
cpsinghal

I have 15 month IT experience. I have many applet project.

30 € EUR en 1 jour
(0 Commentaires)
0.0
oatf

I am java programmer 6 years ago during this period i did it something similar program that draw a triangles with a mathematical algorithm. I understand that you need for this project.

60 € EUR en 2 jours
(0 Commentaires)
0.0