[source code included]
PoC – Proof of Concept
On this initiative, I opted to use the same tools and technologies I usually do in similar opportunities. I implemented a Windows (WinForms) application – .NET framework, version 4.5; and C# – as a prototype and proof instrument of my ideas, and also as a validation means for my hypotheses and assumptions.
Given the nature and characteristics of such initiative (PoC), I placed all code on a single file, although I strived to accurately observe and obey OOP’s concepts and principles; such as abstraction, unique responsibility principle etc.
Eventually, my efforts resulted into a structure that can be logically represented as follows:
Figure 1. Data flow throughout the solution’s logical layers
At the end of the day, the application’s face ended up like this:
Figure 2. TryAngels Project v.: 0.0.0.1 (R&D) – Main screen
I hope I have managed to meet the requirement that rules a friendly, intuitive, attractive and easy to use interface [marketing appeal].
Through this screen, the user has access to all the functional requirements. As in relation to the non-functional requirements (besides the just mentioned usability), the issues related to velocity and memory are inversely proportional, in this case.
The more the amount of objects increases, the more processing time they require; and the less the overall performance is. We need then to find a way to minimize the quantity of created, managed objects, in order to optimize performance and memory use, simultaneously.
Is it even possible? I believe so.
How? KISS: keep it simple, smarty!
On Figure 6, for instance, it was created neither 118 nor 28 objects to represent 7-side triangle. But only one. Through the manipulations of the properties (position, in this case) of a single one-side triangle, we can represent triangles with huge amount of measurement units of side; while warranting both storage space and processing speed.
It is necessary an absurdly huge number (18,446,744,073,709,551,615; to be precise) for we to reach processing limits.
Note that we can also easily set other properties – such as color, direction, etc.; with the same efficiency, accuracy and computational resources’ optimization.
In order to verify our algorithm’s processing speed, we created a bunch of performance tests (as the next figure shows):
Figure 3. TryAngels Project v.: 0.0.0.1 (R&D) – Performance Tests Screen
Although primitives, these tests can provide – through the simulation of various use cases and scenarios – an expressive number of valuable insights. It is known, for example, that parallel processing is only recommended for huge amounts of processing and/or data. In other cases, sequential processing tends to perform better.
Finally, we provided the source code, in order for it to be analyzed, as shown below:
Figure 4. TryAngels Project v.: 0.0.0.1 (R&D) – Source Code Screen
Although it is not a real representative of an evolutionary prototype, given it lacks many of such approach fundaments; the present implementation is far from being a disposable prototype, since it both contemplate various and important concepts and principles, as it adopts and exemplify many good practices and design patterns – even if as an elementary form; after all, it is a PoC.
I like to think my PoCs as “pre-evolutionary prototypes”. In order to present this solution as an actually evolutionary prototype, a series of other concepts, principles and practices should be seriously considered and effectively implemented. Among them, I would mention:
We also recommend (as usual) the adoption – since the very beginning – of a service oriented architecture (preferably under Thomas Erl’s guidance), as well as to consider the concepts and requirements of distributed and cloud [hybrid, preferably] computing.
After all, the natural tendency of every good idea, project or initiative is to grow and flourish. It is crucial, then, that we strive to grow from a solid (secure and trustful) beginning, in order to be better prepared to the challenges that future will certainly bring.