X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ian/git?a=blobdiff_plain;f=minimise.h;h=9ce07c429318949d5f9ca74d42c011ad2937a2a3;hb=9e8860ae32184285e451568d39df79baf7f44aff;hp=28bef2c9e7eb9f296bfaa4dfd11b236cafc71b31;hpb=58a4b8719e43b27e6ae5493c9bfe32741d71c235;p=moebius2.git diff --git a/minimise.h b/minimise.h index 28bef2c..9ce07c4 100644 --- a/minimise.h +++ b/minimise.h @@ -10,21 +10,34 @@ double compute_energy(const struct Vertices *vs); void energy_init(void); -double graph_layout_cost(const Vertices v); +double graph_layout_cost(const Vertices v, int section); void graph_layout_prepare(); -void compute_vertex_areas(const Vertices vertices); -void compute_edge_lengths(const Vertices vertices); -extern double vertex_areas[N], vertex_mean_edge_lengths[N], edge_lengths[N][V6]; +void compute_vertex_areas(const Vertices vertices, int section); +void compute_edge_lengths(const Vertices vertices, int section); +void compute_rim_twist_angles(const Vertices vertices, int section); -double line_bending_cost(const Vertices vertices); -double noncircular_rim_cost(const Vertices vertices); -double edge_length_variation_cost(const Vertices vertices); -double rim_proximity_cost(const Vertices vertices); +//extern double vertex_areas[N], edge_lengths[N][V6]; +extern double vertex_mean_edge_lengths[N]; + +extern const double edge_angle_cost_circcircrat; + +double vertex_displacement_cost(const Vertices vertices, int section); +double vertex_edgewise_displ_cost(const Vertices vertices, int section); +double line_bending_cost(const Vertices vertices, int section); +double noncircular_rim_cost(const Vertices vertices, int section); +double edge_length_variation_cost(const Vertices vertices, int section); +double prop_edge_length_variation_cost(const Vertices vertices, int section); +double rim_proximity_cost(const Vertices vertices, int section); +double rim_twist_cost(const Vertices vertices, int section); +double edge_angle_cost(const Vertices vertices, int section); +double small_triangles_cost(const Vertices vertices, int section); +double nonequilateral_triangles_cost(const Vertices vertices, int section); extern const char *input_file, *best_file; extern char *best_file_tmp; extern long long evaluations; +extern double stop_epsilon; enum printing_instance { pr_cost, pr_size, pr__max }; int printing_check(enum printing_instance, int indent);