From 873a9f9bedbbfb07d475e271923a7b86464e515f Mon Sep 17 00:00:00 2001 From: pants Date: Wed, 7 Sep 2016 14:55:30 -0400 Subject: more major refactoring --- src/homo_voronoi_fracture.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'src/homo_voronoi_fracture.c') diff --git a/src/homo_voronoi_fracture.c b/src/homo_voronoi_fracture.c index 6171480..85a9c2b 100644 --- a/src/homo_voronoi_fracture.c +++ b/src/homo_voronoi_fracture.c @@ -211,9 +211,9 @@ int main(int argc, char *argv[]) { for (uint32_t i = 0; i < N; i++) { printf("\033[F\033[JFRACTURE: %0*d / %d\n", (uint8_t)log10(N) + 1, i + 1, N); - graph_t *network = ini_voronoi_network(L, boundary, use_dual, genfunc_hyperuniform, &c); + graph_t *network = ini_voro_graph(L, boundary, use_dual, genfunc_hyperuniform, &c); net_t *perm_instance = create_instance(network, inf, use_voltage_boundaries, true, &c); - double *fuse_thres = gen_fuse_thres(network->ne, network->edge_coords, beta, beta_scaling_flat); + double *fuse_thres = gen_fuse_thres(network->ne, network->ex, beta, beta_scaling_flat); net_t *instance = copy_instance(perm_instance, &c); data_t *breaking_data = fracture_network(instance, fuse_thres, &c, cutoff); free_instance(instance, &c); @@ -299,8 +299,8 @@ int main(int argc, char *argv[]) { if (save_network) { FILE *net_out = fopen("network.txt", "w"); for (uint_t j = 0; j < network->nv; j++) { - fprintf(net_out, "%f %f ", network->vert_coords[2 * j], - tmp_instance->graph->vert_coords[2 * j + 1]); + fprintf(net_out, "%f %f ", network->vx[2 * j], + tmp_instance->graph->vx[2 * j + 1]); } fprintf(net_out, "\n"); for (uint_t j = 0; j < tmp_instance->graph->ne; j++) { @@ -309,8 +309,8 @@ int main(int argc, char *argv[]) { } fprintf(net_out, "\n"); for (uint_t j = 0; j < tmp_instance->graph->dnv; j++) { - fprintf(net_out, "%f %f ", tmp_instance->graph->dual_vert_coords[2 * j], - tmp_instance->graph->dual_vert_coords[2 * j + 1]); + fprintf(net_out, "%f %f ", tmp_instance->graph->dvx[2 * j], + tmp_instance->graph->dvx[2 * j + 1]); } fprintf(net_out, "\n"); for (uint_t j = 0; j < tmp_instance->graph->ne; j++) { -- cgit v1.2.3-70-g09d2