Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
PSET Circle!
#11
3 lines, using another algorithm:

[syntax="QBASIC"]FOR I! = -0.5 TO 199.5 STEP .5
IF I! = -0.5 THEN SCREEN 13 ELSE PSET (((INT(I!) = I!) * 2 + 1) * SQR(10000 - (INT(I!) - 100) ^2) + 160, INT(I!) * 0.75), 15
NEXT I![/syntax]

Doesn't draw the circle completely, in this case it needs some more code to optimize this block, but it draws the outlines which can be connected with line or by enhancing the above code.
Advantage of this x = SQR(r^2-y^2) algorithm is that it's faster and doesn't require large loops.

In these kind of challenges it's impossible to draw a full connected circle, because if you zoom in on the circles made with the COS/SIN algorithm you'll see the same as the algorithm above displays.
Reply


Messages In This Thread
PSET Circle! - by Rattrapmax6 - 03-16-2005, 08:45 AM
PSET Circle! - by Diroga - 03-16-2005, 11:36 AM
PSET Circle! - by Dr_Davenstein - 03-16-2005, 01:54 PM
PSET Circle! - by xteraco - 03-16-2005, 02:14 PM
PSET Circle! - by xteraco - 03-16-2005, 02:20 PM
PSET Circle! - by xteraco - 03-16-2005, 02:35 PM
PSET Circle! - by Sterling Christensen - 03-16-2005, 02:37 PM
PSET Circle! - by xteraco - 03-16-2005, 02:41 PM
Re: PSET Circle! - by KiZ - 03-16-2005, 09:13 PM
PSET Circle! - by Meg - 03-16-2005, 09:38 PM
PSET Circle! - by Neo - 03-16-2005, 09:55 PM
PSET Circle! - by Rattrapmax6 - 03-16-2005, 10:11 PM
PSET Circle! - by Meg - 03-17-2005, 12:47 AM
PSET Circle! - by Rattrapmax6 - 03-17-2005, 02:07 AM
PSET Circle! - by Mitth'raw'nuruodo - 03-17-2005, 02:54 AM
PSET Circle! - by Sterling Christensen - 03-17-2005, 03:00 AM
PSET Circle! - by Rattrapmax6 - 03-17-2005, 03:02 AM
PSET Circle! - by Mitth'raw'nuruodo - 03-17-2005, 03:04 AM
PSET Circle! - by Diroga - 03-17-2005, 12:33 PM
PSET Circle! - by Neo - 03-17-2005, 02:09 PM
PSET Circle! - by KiZ - 03-17-2005, 02:47 PM
PSET Circle! - by xteraco - 03-17-2005, 05:55 PM
PSET Circle! - by Neo - 03-17-2005, 10:22 PM
PSET Circle! - by Eurodance - 03-18-2005, 12:27 AM
Fu program - by Meg - 03-18-2005, 01:36 AM
PSET Circle! - by Rattrapmax6 - 03-18-2005, 02:27 AM
PSET Circle! - by Mitth'raw'nuruodo - 03-19-2005, 01:19 AM
PSET Circle! - by Dio - 03-19-2005, 01:49 AM
PSET Circle! - by Rattrapmax6 - 03-19-2005, 03:59 AM
PSET Circle! - by Mitth'raw'nuruodo - 03-25-2005, 09:27 AM
PSET Circle! - by Diroga - 03-25-2005, 09:55 AM
PSET Circle! - by Rattrapmax6 - 03-26-2005, 08:45 PM
PSET Circle! - by Mitth'raw'nuruodo - 03-26-2005, 09:04 PM
PSET Circle! - by Rattrapmax6 - 03-26-2005, 09:08 PM
PSET Circle! - by Mitth'raw'nuruodo - 03-26-2005, 09:26 PM
PSET Circle! - by Rattrapmax6 - 03-26-2005, 09:36 PM
PSET Circle! - by Mitth'raw'nuruodo - 03-26-2005, 09:39 PM
PSET Circle! - by Rattrapmax6 - 03-26-2005, 09:40 PM
PSET Circle! - by Mitth'raw'nuruodo - 03-26-2005, 09:43 PM
PSET Circle! - by Nathan1993 - 08-19-2005, 11:31 PM
PSET Circle! - by Anonymous - 08-19-2005, 11:55 PM
PSET Circle! - by Neo - 08-20-2005, 12:25 AM
PSET Circle! - by Rattrapmax6 - 08-20-2005, 12:52 AM
PSET Circle! - by Dio - 08-20-2005, 12:55 AM
PSET Circle! - by Rattrapmax6 - 08-20-2005, 02:44 AM
PSET Circle! - by Ralph - 08-29-2005, 10:02 PM
PSET Circle! - by dumbledore - 08-30-2005, 12:04 AM
PSET Circle! - by Dr_Davenstein - 08-30-2005, 02:43 AM
PSET Circle! - by Dio - 08-30-2005, 03:50 AM
PSET Circle! - by Rattrapmax6 - 08-30-2005, 03:52 AM
PSET Circle! - by Deleter - 08-30-2005, 03:58 AM
PSET Circle! - by Dr_Davenstein - 08-30-2005, 04:43 AM
PSET Circle! - by Rattrapmax6 - 08-30-2005, 04:52 AM
PSET Circle! - by dumbledore - 08-30-2005, 10:15 AM
PSET Circle! - by Rattrapmax6 - 08-30-2005, 07:29 PM
PSET Circle! - by dumbledore - 08-31-2005, 12:49 AM
PSET Circle! - by axipher - 12-13-2005, 07:45 AM
PSET Circle! - by Deleter - 12-13-2005, 09:21 AM
PSET Circle! - by Nemesis - 12-13-2005, 10:33 AM
PSET Circle! - by Xerol - 12-13-2005, 11:56 AM
Breshenham algorithm - by googly - 12-13-2005, 06:29 PM
PSET Circle! - by axipher - 12-13-2005, 08:16 PM
Re: Breshenham algorithm - by Dr_Davenstein - 12-14-2005, 02:41 AM
PSET Circle! - by axipher - 12-14-2005, 07:16 AM
PSET Circle! - by Dr_Davenstein - 12-14-2005, 07:22 AM
PSET Circle! - by axipher - 12-14-2005, 07:40 AM

Forum Jump:


Users browsing this thread: 1 Guest(s)