BoxAnneal Class Reference
[boxproblem]

N square boxes in a big square. More...

Inheritance diagram for BoxAnneal:

BasicAnneal

List of all members.

Public Member Functions

 BoxAnneal (const char *params="")
bool stop ()
int check_for_overlap ()
void wiggle ()
void best_found ()
float energy ()

Public Attributes

int no_of_nodes
int N
vector< Boxnodes
vector< Boxbest_nodes


Detailed Description

N square boxes in a big square.

This annealing class tries to put N square boxes in the smallest square containing them.


Constructor & Destructor Documentation

BoxAnneal::BoxAnneal ( const char *  params = ""  )  [inline]

params - like BasicAnneal. Addionally N - Number of Boxes

References Box::ang, Box::c, and BasicAnneal::std_init().


Member Function Documentation

bool BoxAnneal::stop (  )  [inline, virtual]

Reimplemented stop criterion.

Reimplemented from BasicAnneal.

int BoxAnneal::check_for_overlap (  )  [inline]

Check wheter our boxes overlap.

Referenced by wiggle().

void BoxAnneal::wiggle (  )  [inline, virtual]

Move and rotate a single box.

Reimplemented from BasicAnneal.

References check_for_overlap().

void BoxAnneal::best_found (  )  [inline, virtual]

This gets called each time anneal finds a new best energy.

Reimplemented from BasicAnneal.

References BasicAnneal::best_found().

float BoxAnneal::energy (  )  [inline, virtual]

Compute square surrounding the current boxes and use the edge size as energy.

Reimplemented from BasicAnneal.

References Vec2::x, and Vec2::y.


The documentation for this class was generated from the following file:

Generated on Mon Feb 8 17:22:36 2010 for libbiarc by  doxygen 1.5.6