Math-Zap
view release on metacpan or search on metacpan
lib/Math/Zap/Triangle2.pm view on Meta::CPAN
497498499500501502503504505506507508509510511512513514515516517# Remove duplicate points caused by splitting the vertices - inefficient and unreliable
my
%p
;
$p
{
"$_"
}=
$_
for
(
@p
);
values
(
%p
);
}
=head3 ring
Ring of points formed by overlaying triangle t and T
=cut
sub
ring($$)
{
my
(
$t
,
$T
) =
@_
;
check(
@_
)
if
debug;
# Triangles
my
@p
=
$t
->pointsInCommon(
$T
);
# scalar(@p) == 1 and warn "Only one point in common";
pod/triangle2.pod view on Meta::CPAN
579580581582583584585586587588589590591592593594595596597598599
$p
{
"$_"
}=
$_
for
(
@p
);
values
(
%p
);
}
=head3 ring
Ring of points formed by overlaying triangle t and T
sub ring($$)
{my ($t, $T) = @_;
check(@_) if debug; # Triangles
my @p = $t->pointsInCommon($T);
# scalar(@p) == 1 and warn "Only one point in common";
( run in 0.307 second using v1.01-cache-2.11-cpan-cba739cd03b )