Things Are Coming Along

The current update is basically focused at what's been done, and what's left to do. I've mostly finished off line, ray, segment, points, ellipses and circles. Most of what's left to do is in ellipse (intersection primarily). Now all that is left to do is Polygon (general, regular, and triangles as a specific case). Note that I have a pretty extensive set of test cases in place for what I have done. I have been doing these test cases incrementally because it's easiest this way. Once everything is done though, I will start working on a much more complex set of test cases to truly test the module.

After these things are done I'll take a step back, look at what is done and see how to improve the overall interface. Once that is done I will look into optimizations of existing code. Finally, to finish off I will look into some more advanced geometry applications. One thing I'm waiting on is simplification to be done in SymPy (which I believe is ratsimp's eventual purpose). This is because a lot of comparisons are happening which compare some expression to zero, and even though some things should be zero they are not coming out that way because proper simplification of expressions is not happening. Right now I'm just expanding things and hoping they come out to zero (which in most cases they do).

Now, for some decisions that have been made:
  • Line/Ray/Segment inherit from LinearEntity. This allowed me to write less code while still having everything meaningful. At first I was going to have Ray/Segment inherit from Line but this doesn't make sense.
  • In terms of everything, many functions depend on others so that optimizing will generally take place in less places. For example, for Line I have random_point and arbitrary_point functions. Instead of rewriting code I make random_point get an arbitrary point and then make substitutions
I'm hoping to update design.png soon to reflect what I have done. Work starts tomorrow but I'm hoping to have most of the basic functionality finished by the end of this weekend.

Brownie Points

It seems I always do my best work late at night; I just finished off the Point class, all except for one method which depends on the Line class. I also have a test method created for the Point's methods. Tomorrow I'm hoping to [at least] get the Line class finished, along with its children (Ray and Segment). Monday I hope to finish the Ellipse and Circle classes. I'm hoping that things will move quickly and smoothly so that I can begin working on the different polygon classes also. Once I get all the simple functionality done I can start working on more complex things.

Tuesday marks the start of my research work, which for the first couple of weeks will simply be my supervisor teaching me some different complexity theories and how to work with them. Should be interesting, but I'm anxious to start getting into an actual research topic. I'm hoping that everything will run smoothly (i.e., that I understand things instead of struggling with them) so that my supervisor and I can get into a problem as soon as possible! I've been reading Computers and Intractability by Garey and Johnson to get up to speed on everything!

Design Is Started

Just a quick update. I've got a pretty good start on the UML diagram for the foundation of the geometry module. You can get to it by following the My SymPy Workings link to the right or go to it directly by clicking here. This is just an initial, very basic diagram for the moment, and some things aren't really descried in the diagram. For example, Some things I have as methods but they might really be attributes fetched by an overloaded __getattr__ operator (eg, area for Polygons and Ellipses).

Any feedback on the current diagram, or suggestions for additions, would be great. Now, it's time for bed!