
Thanks for the help.
What about atkinson dithering? is it any good? some say that it's better (although not as popular) than FloydSteinberg.





I don't know what you are encoding, but standard jpeg compression gives good quality at 1 bit per pixel. You should be able to find a photo editor or similar to play around with the compression ratios for testing.
Peter
"Until the invention of the computer, the machine gun was the device that enabled humans to make the most mistakes in the smallest amount of time."





Ive allways liked playing around wih SetPixel and GetPixel, this time ive created a quite nice and simple pattern drawer, only using the SetPixel, GetPixel and some very simple math ( pow(), cos() sin() tan() modulo, * / +  ).
It fills up the screen with varius drawing methods using a formula.
Here[^] (2.49MB) is an example of my latest pattern.
I wonder, can this be considerd as a simple algorithm?
//Johannes





Probably.
From Wikipedia: an algorithm is a finite list of welldefined instructions for accomplishing some task that, given an initial state, will terminate in a defined endstate.
Seems to match.
Is it simple ?
Johpoke wrote: some very simple math
You claim it is, so it is.
But then sooner or later some one may come up with something simpler
that produces the same result...





Actually I see only an Image...
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.





Luc Pattyn wrote: But then sooner or later some one may come up with something simpler
that produces the same result...
I meant that i dont use any advanced functions for mathematics.
the drawing code itself is kinda insane and the whole project would probably land in coding horrors if i where to release it
//Johannes






If I recall correctly, Trig is high school level mathematics which does not make it advanced by today's standards.





...usually basic arithmetic on integers produces also real number results...
(or your basic arithmetic operators are just + and  }?)
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.






The Grand Negus wrote: Such is life
Maybe such is your life, not mine (maybe I live in a parallel universe... )
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.






Maybe you can move all your widgets to a parallel discussion board ?






The Grand Negus wrote: 3.14159
It seems you already took a couple of steps inside the parallel universe...
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.





The Grand Negus wrote: The actual universe is discrete
The current dominating perception of the universe is. It wasn't for centuries, maybe will be not the future one.
The Grand Negus wrote: (1) there's no end to numbers like those
Of course it's a feature, not a problem
The Grand Negus wrote: (2) there's nothing exactly like them in this universe
Actually there's no mathematical model that exactly resembles even a little piece of this universe.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.





The Grand Negus wrote: Exactly how, in your universe, do you pack nine widgets into four boxes, where each box is only big enough for two? And how does 9/4=2.25 help you do that more than 9/4=2r1?
How would you pour 9 liters of water into 4 containers ensuring each container has an equal quantity? I would pour 2.25 (9/4) liters into each glass. 9/4=2r1 is not as useful as 9/4=2.25 in this example. I’m afraid I’m not ready to give up my rational (or even real) numbers.
Steve





If you were determined to use only integers you could, in theory, use the number of water molecules as a measure of volume. At one level this system is ultimately simple: unfortunately it is also impractical to the point of near impossibility. You say that you would use a smaller unit of measurement: so in this example each glass would contain 2250 milliliters. Is this really much simpler or more intuitive than 2.25 liters?
Steve





The Grand Negus wrote: Nine divided by four is two with one left over.
So it seems you also believe in rational numbers. Pity real life isn't always so simple. Presenting a simple example does not negate the existence of more complex ones or the more advanced tools which may be required to deal with them.
Steve





Actually he believe in a discrete universe.
If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
 Alfonso the Wise, 13th Century King of Castile.





Most people, including people who consider basic trigonomic function like sine and cosine advanced, could readily understand them if they were explained properly.
Steve






This appears to me to be a simple modification of the nqueens problem. Placing n queens on a board such that no queen can capture any other queen. I would persue this line of thought with a google search on the nqueens problem.





Hi,
I beg to differ. On an n*n board (with n>2) you can place n queens, the only problem
is finding one of the many solutions. In the problem at hand, you dont know beforehand
how many "queens" you can put; you loose some squares to the walls, and in return
the walls typically offer the possibility to put more than n.
BTW the maximum seems to be n*n/2 (putting a wall on all the squares of one color).





I agree with you totally on the number of queens that could be placed on this board due to wall constraints, this is why I suggested a modified version of n queens. The wall constraints could easily be taken into account and still allow for the same "Basic" n queens algorithm to function correctly.



