| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /* Automatically generated code, do not edit */ | ||
| 2 | /* Generated from source file: det4d.pck */ | ||
| 3 | |||
| 4 | 4386 | inline int det_4d_filter( const double* p0, const double* p1, const double* p2, const double* p3) { | |
| 5 | double m12; | ||
| 6 | 4386 | m12 = ((p1[0] * p0[1]) - (p0[0] * p1[1])); | |
| 7 | double m13; | ||
| 8 | 4386 | m13 = ((p2[0] * p0[1]) - (p0[0] * p2[1])); | |
| 9 | double m14; | ||
| 10 | 4386 | m14 = ((p3[0] * p0[1]) - (p0[0] * p3[1])); | |
| 11 | double m23; | ||
| 12 | 4386 | m23 = ((p2[0] * p1[1]) - (p1[0] * p2[1])); | |
| 13 | double m24; | ||
| 14 | 4386 | m24 = ((p3[0] * p1[1]) - (p1[0] * p3[1])); | |
| 15 | double m34; | ||
| 16 | 4386 | m34 = ((p3[0] * p2[1]) - (p2[0] * p3[1])); | |
| 17 | double m123; | ||
| 18 | 4386 | m123 = (((m23 * p0[2]) - (m13 * p1[2])) + (m12 * p2[2])); | |
| 19 | double m124; | ||
| 20 | 4386 | m124 = (((m24 * p0[2]) - (m14 * p1[2])) + (m12 * p3[2])); | |
| 21 | double m134; | ||
| 22 | 4386 | m134 = (((m34 * p0[2]) - (m14 * p2[2])) + (m13 * p3[2])); | |
| 23 | double m234; | ||
| 24 | 4386 | m234 = (((m34 * p1[2]) - (m24 * p2[2])) + (m23 * p3[2])); | |
| 25 | double Delta; | ||
| 26 | 4386 | Delta = ((((m234 * p0[3]) - (m134 * p1[3])) + (m124 * p2[3])) - (m123 * p3[3])); | |
| 27 | int int_tmp_result; | ||
| 28 | double eps; | ||
| 29 | 4386 | double max1 = fabs(p0[0]); | |
| 30 |
2/2✓ Branch 0 taken 1728 times.
✓ Branch 1 taken 2658 times.
|
4386 | if( (max1 < fabs(p1[0])) ) |
| 31 | { | ||
| 32 | 1728 | max1 = fabs(p1[0]); | |
| 33 | } | ||
| 34 |
2/2✓ Branch 0 taken 1044 times.
✓ Branch 1 taken 3342 times.
|
4386 | if( (max1 < fabs(p2[0])) ) |
| 35 | { | ||
| 36 | 1044 | max1 = fabs(p2[0]); | |
| 37 | } | ||
| 38 |
2/2✓ Branch 0 taken 1452 times.
✓ Branch 1 taken 2934 times.
|
4386 | if( (max1 < fabs(p3[0])) ) |
| 39 | { | ||
| 40 | 1452 | max1 = fabs(p3[0]); | |
| 41 | } | ||
| 42 | 4386 | double max2 = fabs(p0[1]); | |
| 43 |
2/2✓ Branch 0 taken 1584 times.
✓ Branch 1 taken 2802 times.
|
4386 | if( (max2 < fabs(p1[1])) ) |
| 44 | { | ||
| 45 | 1584 | max2 = fabs(p1[1]); | |
| 46 | } | ||
| 47 |
2/2✓ Branch 0 taken 972 times.
✓ Branch 1 taken 3414 times.
|
4386 | if( (max2 < fabs(p2[1])) ) |
| 48 | { | ||
| 49 | 972 | max2 = fabs(p2[1]); | |
| 50 | } | ||
| 51 |
2/2✓ Branch 0 taken 938 times.
✓ Branch 1 taken 3448 times.
|
4386 | if( (max2 < fabs(p3[1])) ) |
| 52 | { | ||
| 53 | 938 | max2 = fabs(p3[1]); | |
| 54 | } | ||
| 55 | 4386 | double max3 = fabs(p0[2]); | |
| 56 |
2/2✓ Branch 0 taken 2034 times.
✓ Branch 1 taken 2352 times.
|
4386 | if( (max3 < fabs(p1[2])) ) |
| 57 | { | ||
| 58 | 2034 | max3 = fabs(p1[2]); | |
| 59 | } | ||
| 60 |
2/2✓ Branch 0 taken 1314 times.
✓ Branch 1 taken 3072 times.
|
4386 | if( (max3 < fabs(p2[2])) ) |
| 61 | { | ||
| 62 | 1314 | max3 = fabs(p2[2]); | |
| 63 | } | ||
| 64 |
2/2✓ Branch 0 taken 1358 times.
✓ Branch 1 taken 3028 times.
|
4386 | if( (max3 < fabs(p3[2])) ) |
| 65 | { | ||
| 66 | 1358 | max3 = fabs(p3[2]); | |
| 67 | } | ||
| 68 | 4386 | double max4 = fabs(p0[3]); | |
| 69 |
2/2✓ Branch 0 taken 2106 times.
✓ Branch 1 taken 2280 times.
|
4386 | if( (max4 < fabs(p1[3])) ) |
| 70 | { | ||
| 71 | 2106 | max4 = fabs(p1[3]); | |
| 72 | } | ||
| 73 |
2/2✓ Branch 0 taken 1488 times.
✓ Branch 1 taken 2898 times.
|
4386 | if( (max4 < fabs(p2[3])) ) |
| 74 | { | ||
| 75 | 1488 | max4 = fabs(p2[3]); | |
| 76 | } | ||
| 77 |
2/2✓ Branch 0 taken 1743 times.
✓ Branch 1 taken 2643 times.
|
4386 | if( (max4 < fabs(p3[3])) ) |
| 78 | { | ||
| 79 | 1743 | max4 = fabs(p3[3]); | |
| 80 | } | ||
| 81 | double lower_bound_1; | ||
| 82 | double upper_bound_1; | ||
| 83 | 4386 | lower_bound_1 = max1; | |
| 84 | 4386 | upper_bound_1 = max1; | |
| 85 |
2/2✓ Branch 0 taken 1534 times.
✓ Branch 1 taken 2852 times.
|
4386 | if( (max2 < lower_bound_1) ) |
| 86 | { | ||
| 87 | 1534 | lower_bound_1 = max2; | |
| 88 | } | ||
| 89 | else | ||
| 90 | { | ||
| 91 |
1/2✓ Branch 0 taken 2852 times.
✗ Branch 1 not taken.
|
2852 | if( (max2 > upper_bound_1) ) |
| 92 | { | ||
| 93 | 2852 | upper_bound_1 = max2; | |
| 94 | } | ||
| 95 | } | ||
| 96 |
2/2✓ Branch 0 taken 1768 times.
✓ Branch 1 taken 2618 times.
|
4386 | if( (max3 < lower_bound_1) ) |
| 97 | { | ||
| 98 | 1768 | lower_bound_1 = max3; | |
| 99 | } | ||
| 100 | else | ||
| 101 | { | ||
| 102 |
2/2✓ Branch 0 taken 1010 times.
✓ Branch 1 taken 1608 times.
|
2618 | if( (max3 > upper_bound_1) ) |
| 103 | { | ||
| 104 | 1010 | upper_bound_1 = max3; | |
| 105 | } | ||
| 106 | } | ||
| 107 |
2/2✓ Branch 0 taken 989 times.
✓ Branch 1 taken 3397 times.
|
4386 | if( (max4 < lower_bound_1) ) |
| 108 | { | ||
| 109 | 989 | lower_bound_1 = max4; | |
| 110 | } | ||
| 111 | else | ||
| 112 | { | ||
| 113 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 3397 times.
|
3397 | if( (max4 > upper_bound_1) ) |
| 114 | { | ||
| 115 | ✗ | upper_bound_1 = max4; | |
| 116 | } | ||
| 117 | } | ||
| 118 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 4386 times.
|
4386 | if( (lower_bound_1 < 3.20402459074399025456e-74) ) |
| 119 | { | ||
| 120 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 121 | } | ||
| 122 | else | ||
| 123 | { | ||
| 124 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 4386 times.
|
4386 | if( (upper_bound_1 > 1.44740111546645196071e+76) ) |
| 125 | { | ||
| 126 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 127 | } | ||
| 128 | 4386 | eps = (2.11135406605316806158e-14 * (((max1 * max2) * max3) * max4)); | |
| 129 |
2/2✓ Branch 0 taken 113 times.
✓ Branch 1 taken 4273 times.
|
4386 | if( (Delta > eps) ) |
| 130 | { | ||
| 131 | 113 | int_tmp_result = 1; | |
| 132 | } | ||
| 133 | else | ||
| 134 | { | ||
| 135 |
1/2✓ Branch 0 taken 4273 times.
✗ Branch 1 not taken.
|
4273 | if( (Delta < -eps) ) |
| 136 | { | ||
| 137 | 4273 | int_tmp_result = -1; | |
| 138 | } | ||
| 139 | else | ||
| 140 | { | ||
| 141 | ✗ | return FPG_UNCERTAIN_VALUE; | |
| 142 | } | ||
| 143 | } | ||
| 144 | } | ||
| 145 | 4386 | return int_tmp_result; | |
| 146 | } | ||
| 147 |