Branch Coverage

blib/lib/Math/Yapp.pm
Criterion Covered Total %
branch 224 320 70.0


line true false branch
185 6 0 if defined $_[0]
203 1 0 defined $_[0] ? :
223 0 0 if (@_ != 0)
235 13 1 if (defined $_[0])
254 5 0 if (defined $_[0])
264 5 0 if (defined $_[0])
303 41 107 if ($coef_count > 1) { }
95 12 elsif ($coef_count == 1) { }
307 56 39 if (ref $_[0] eq 'ARRAY') { }
315 97 51 if ($aref != 0)
341 117 148 if (ref $class eq $class_name) { }
393 6 458 unless defined $self->{'coeff'}[$slc]
403 109 4 if $self->{'coeff'}[$slc] != 0
417 0 148 if defined $self->{'derivative'}[0]
418 0 148 if defined $self->{'integral'}[0]
424 0 148 unless defined $self->{'variable'}
448 0 93 defined $_[0] ? :
449 0 93 defined $_[0] ? :
459 51 42 if ($start_high) { }
474 93 618 if $lc > $self->{'degree'} or $lc < 0
479 82 536 if (ref $self->{'coeff'}[$lc] eq $class_cplx) { }
486 14 68 if ($lc == $lc_start) { }
12 56 elsif ($lc == 1) { }
8 48 elsif ($lc == 0) { }
495 82 0 if ($self->{'coeff'}[$lc] != $czero or $print_zero)
508 79 457 if ($lc == $lc_start) { }
81 376 elsif ($lc == 1) { }
43 333 elsif ($lc == 0) { }
518 511 25 if ($self->{'coeff'}[$lc] != 0 or $print_zero)
527 93 525 if $lc == 0
531 93 525 if ("$out_string" eq '') { }
534 500 25 if $term ne ''
575 0 40 defined $_[0] ? :
576 0 40 defined $_[0] ? :
577 8 32 if ref $cnum ne $class_cplx
614 0 2855 if $#_ > 0
619 222 2633 if (wantarray) { }
1817 816 elsif (defined wantarray) { }
635 252 1565 if abs $thing < $margin
640 240 1325 if (ref $thing eq $class_cplx) { }
643 5 235 if (abs $thing->Re < $margin)
647 37 203 if (abs $thing->Im < $margin)
660 222 594 if (ref $thing eq 'ARRAY') { }
687 0 29 if (ref $coef eq $class_cplx)
711 1 0 if ($self->{'degree'} == $compr->{'degree'}) { }
715 0 6 if $self->{'coeff'}[$dlc] != $compr->{'coeff'}[$dlc]
716 0 6 unless $comp_ok
745 2 2 if ($c_string =~ /^($sign_pat)/u)
747 2 0 $1 eq '-' ? :
761 2 2 $c_pair[1] eq '-' ? :
795 0 675 if ($term_id > $self->{'degree'} or $term_id < 0)
818 93 7 if (@_ == 0) { }
883 0 39 if $testmode
906 3 54 if ($pterms[$tlc] =~ /^[-\+]$/u)
908 0 3 if $tlc == $#pterms
912 0 3 if ($pterms[$tlc + 1] =~ /^[-\+]/u) { }
914 0 0 if ($pterms[$tlc] eq substr($pterms[$tlc + 1], 0, 1)) { }
935 49 5 if ($cur_term =~ /($coef_pat)/u) { }
941 15 34 if ($cur_coeff =~ /^($sign_pat)/u)
943 11 4 $1 eq '-' ? :
950 4 45 if ($cur_coeff =~ /$cplx_pat/u) { }
956 0 45 if $cur_coeff eq ''
972 15 39 if ($cur_term =~ /^($varia_pat)/u) { }
986 5 49 if ($cur_term =~ /($power_pat)/u) { }
988 5 0 if (defined $cur_varia) { }
998 10 39 defined $cur_varia ? :
1009 12 42 if $cur_degree > $self->{'degree'}
1014 0 15 if (defined $cur_varia and defined $self->{'variable'} and $self->{'variable'} ne $cur_varia)
1026 15 39 if defined $cur_varia
1032 39 15 if (defined $self->{'coeff'}[$cur_degree]) { }
1045 27 12 unless defined $self->{'variable'}
1065 21 2 if (ref $added eq $class_name) { }
2 0 elsif ($added =~ /^($coef_pat)$/u or ref $added eq $class_cplx) { }
1073 184 17 if (defined $builder[$alc]) { }
1076 17 184 if $alc > $self->{'degree'}
1089 2 0 if (defined $self->{'coeff'}[0]) { }
1135 1 8 if (ref $subtractor eq $class_name) { }
1149 8 0 defined $self->{'coeff'}[0] ? :
1173 7 2 if $swapped
1204 66 127 if (ref $multiplier eq "$class_cplx" or ref \$multiplier eq 'SCALAR') { }
127 0 elsif (ref $multiplier eq $class_name) { }
1210 358 57 if $self->{'coeff'}[$ylc] != 0
1224 724 621 unless defined $builder[$term_degree]
1292 1 8 if $swapped
1294 1 7 if $power != int $power
1366 0 9 if ($testmode)
1368 0 0 if (defined wantarray) { }
1370 0 0 if (wantarray) { }
1381 9 0 if (defined wantarray) { }
1410 3 0 defined wantarray ? :
1415 9 11 unless ref $ryapp->{'coeff'}[$clc] eq $class_cplx
1418 3 0 if defined wantarray
1454 10 119 if (wantarray) { }
1589 20 2 defined $_[0] ? :
1594 8 14 if (defined $self->{'derivative'}[$order])
1602 2 12 if (defined $self->{'derivative'}[1]) { }
1614 0 16 if $dlc >= $self->{'degree'}
1616 12 4 if ($dlc == 0) { }
1653 0 4 unless $#_ == 2 or $#_ == 0
1662 3 1 if $#_ == 1
1669 3 1 if (ref $self->{'integral'} ne $class_name) { }
1684 1 3 unless defined $l_limit
1738 0 25 if ($solu_end == 0)
1762 0 25 if ($degree == 1) { }
16 9 elsif ($degree == 2) { }
4 5 elsif ($degree == 3) { }
3 2 elsif ($degree == 4) { }
0 2 elsif (not $self->all_real) { }
1 1 elsif ($degree % 2 == 1) { }
1828 0 10 if abs $yp == 0
1831 9 1 if abs $xn - $xc < $margin
1834 0 1 if $testmode
1893 0 4 $norms[0] > $norms[1] ? :
1899 0 4 if $testmode
1925 0 16 if ($discr == 0) { }
5 11 elsif ($discr > 0) { }
1942 0 11 if $testmode
1973 0 4 if ($self->{'coeff'}[3] == 1) { }
1980 0 4 if $testmode
1983 4 0 if ($monic->{'coeff'}[2] != 0) { }
1987 0 4 if $testmode
2010 0 4 if $testmode
2030 1 10 if (ref $u_roots[$rlc] ne $class_cplx)
2061 0 4 if (ref $solutions[0] eq $class_cplx and $allreal) { }
2104 0 3 if ($self->{'coeff'}[4] == 1) { }
2111 0 3 if $testmode
2114 3 0 if ($monic->{'coeff'}[3] != 0) { }
2118 0 3 if $testmode
2174 3 0 if ref $rc_plug ne $class_cplx
2186 0 3 if ($testmode)
2217 0 3 if $testmode
2274 1 2 if ($left_try == 0) { }
2297 1 3 if $betw_eval == 0
2298 0 3 $left_eval >= 0 ? :
2299 3 0 $right_eval >= 0 ? :
2300 1 2 $betw_eval >= 0 ? :
2306 1 2 if ($left_sign != $betw_sign) { }
2321 1 0 $betw_eval == 0 ? :
2333 1 0 if abs $zzero >= $margin
2347 1 0 if ($quotient->{'degree'} > 0)
2391 1 0 if (ref $xn eq $class_cplx) { }
2403 1 0 if abs $zzero >= $margin
2420 0 0 if abs $zzero >= $margin
2431 1 0 if ($quotient->{'degree'} > 0)
2471 0 0 if (ref $xn eq $class_cplx) { }
2475 0 0 if (abs $conj_zero < $margin)
2486 0 0 if abs $zzero >= $margin
2495 0 0 if (abs $conj_zero < $margin)
2507 0 0 if abs $zzero >= $margin
2518 0 0 if ($quotient->{'degree'} > 0)
2558 0 2 unless $pcount >= 2
2570 0 3 unless $ycount == $xcount
2579 1 1 $derivs == 2 ? :
2714 13 72 if $mlc == $xlc
2748 2 0 ref $_[0] eq 'ARRAY' ? :
2794 2 0 if $testmode
2799 2 0 if $testmode
2804 2 0 if $testmode
2809 2 0 if $testmode
2830 0 0 if abs $innerprod <= $margin