Black Eternal

…how abstract thy harvest rose doth fall, consigned to the flames of woe in sweet modesty…

Category Archives: Programming

Generic Image Library: Save Raw Image Data to File

GIL (Generic Image Library) is “a C++ generic library which allows for writing generic imaging algorithms with performance comparable to hand-writing for a particular image type” and it’s now part of the Boost Libraries. Today I wanted to implement a save_to_image function for a project I was working on this week, and I thought about [...]

Project Euler Problems 39 and 75

If p is the perimeter of a right angle triangle, {a, b, c}, which value, for p ≤ 1000, has the most solutions? The solution to this problem is using the following formulas for the iterative generation of new Pythagorean triples: where: This can be done easily using recursion:

Follow

Get every new post delivered to your Inbox.