277 unsigned long n_lower = this->Nx * Ny1;
278 unsigned long n_upper = this->Nx * Ny2;
280 Lower_layer_element_pt.reserve(
n_lower);
283 Lower_layer_element_pt.push_back(this->finite_element_pt(
e));
286 Upper_layer_element_pt.reserve(
n_upper);
289 Upper_layer_element_pt.push_back(this->finite_element_pt(
e));
293 Interface_lower_boundary_element_pt.resize(this->Nx);
294 Interface_upper_boundary_element_pt.resize(this->Nx);
298 for (
unsigned e = 0;
e < this->Nx;
e++)
300 Interface_lower_boundary_element_pt[
e] =
303 Interface_upper_boundary_element_pt[
e] =
325 if (boundary_coordinate_exists(3))
331 this->set_boundary_coordinate_exists(4);
332 this->set_boundary_coordinate_exists(5);
336 nod_pt->remove_from_boundary(3);
343 this->add_boundary_node(4,
nod_pt);
345 if (this->boundary_coordinate_exists(4))
353 this->add_boundary_node(5,
nod_pt);
355 if (this->boundary_coordinate_exists(5))
363 this->Boundary_node_pt[3].clear();
374 if (this->boundary_coordinate_exists(2))
378 this->set_boundary_coordinate_exists(3);
382 nod_pt->remove_from_boundary(2);
384 this->add_boundary_node(3,
nod_pt);
385 if (this->boundary_coordinate_exists(3))
392 this->Boundary_node_pt[2].clear();
410 if (this->boundary_coordinate_exists(1))
414 this->set_boundary_coordinate_exists(2);
423 this->add_boundary_node(2,
nod_pt);
425 if (this->boundary_coordinate_exists(2))
438 this->remove_boundary_node(1, *
it);
446 unsigned n_p =
dynamic_cast<ELEMENT*
>(finite_element_pt(0))->
nnode_1d();
451 this->set_boundary_coordinate_exists(6);
454 for (
unsigned e = 0;
e < this->Nx;
e++)
467 this->convert_to_boundary_node(
nod_pt);
468 this->add_boundary_node(6,
nod_pt);
477 Spine_pt.reserve((
n_p - 1) * this->Nx);
481 Spine_pt.reserve((
n_p - 1) * this->Nx + 1);
501 nod_pt->spine_mesh_pt() =
this;
503 nod_pt->node_update_fct_id() = 0;
507 for (
unsigned long i = 0;
i < Ny1;
i++)
517 nod_pt->fraction() = (
nod_pt->x(1) - this->Ymin) / (H1);
519 nod_pt->spine_mesh_pt() =
this;
521 nod_pt->node_update_fct_id() = 0;
526 for (
unsigned long i = 0;
i < Ny2;
i++)
537 nod_pt->fraction() = (
nod_pt->x(1) - (this->Ymin + H1)) / (H2);
539 nod_pt->spine_mesh_pt() =
this;
541 nod_pt->node_update_fct_id() = 1;
549 for (
unsigned long j = 0;
j < this->Nx;
j++)
556 if ((this->Xperiodic) && (
j == this->Nx - 1))
n_pmax =
n_p - 1;
572 nod_pt->spine_mesh_pt() =
this;
574 nod_pt->node_update_fct_id() = 0;
578 for (
unsigned long i = 0;
i < Ny1;
i++)
585 element_node_pt(
i * this->Nx +
j,
l1 *
n_p +
l2);
591 nod_pt->spine_mesh_pt() =
this;
593 nod_pt->node_update_fct_id() = 0;
598 for (
unsigned long i = 0;
i < Ny2;
i++)
605 element_node_pt((Ny1 +
i) * this->Nx +
j,
l1 *
n_p +
l2);
610 nod_pt->fraction() = (
nod_pt->x(1) - (this->Ymin + H1)) / H2;
612 nod_pt->spine_mesh_pt() =
this;
614 nod_pt->node_update_fct_id() = 1;
633 nod_pt->fraction() = element_node_pt(0, 0)->fraction();
635 nod_pt->spine_mesh_pt() = element_node_pt(0, 0)->spine_mesh_pt();
637 nod_pt->node_update_fct_id() =
638 element_node_pt(0, 0)->node_update_fct_id();
641 for (
unsigned i = 0;
i < (Ny1 + Ny2);
i++)
654 element_node_pt(
i * this->Nx,
l1 *
n_p)->fraction();
656 nod_pt->node_update_fct_id() =
657 element_node_pt(
i * this->Nx,
l1 *
n_p)->node_update_fct_id();
660 element_node_pt(
i * this->Nx,
l1 *
n_p)->spine_mesh_pt();
689 this->setup_boundary_element_info();