package o; import com.google.android.gms.maps.model.BitmapDescriptorFactory; /* JADX INFO: Access modifiers changed from: package-private */ /* loaded from: classes.dex */ public final class FEM { final float a; final float b; final float c; final float d; final float e; private final float g; private final float h; private final float i; final float j; private FEM(float f, float f2, float f3, float f4, float f5, float f6, float f7, float f8, float f9) { this.b = f; this.e = f2; this.d = f3; this.h = f4; this.g = f5; this.i = f6; this.j = f7; this.a = f8; this.c = f9; } /* JADX INFO: Access modifiers changed from: package-private */ public static FEM a(int i, Eal eal) { float[] e = C16404nyu.e(i); float[][] fArr = C16404nyu.b; float f = e[0]; float[] fArr2 = fArr[0]; float f2 = fArr2[0]; float f3 = e[1]; float f4 = fArr2[1]; float f5 = e[2]; float f6 = fArr2[2]; float[] fArr3 = fArr[1]; float f7 = fArr3[0]; float f8 = fArr3[1]; float f9 = fArr3[2]; float[] fArr4 = fArr[2]; float f10 = fArr4[0]; float f11 = fArr4[1]; float f12 = fArr4[2]; float f13 = eal.f[0] * ((f2 * f) + (f4 * f3) + (f6 * f5)); float f14 = eal.f[1] * ((f7 * f) + (f8 * f3) + (f9 * f5)); float f15 = eal.f[2] * ((f * f10) + (f3 * f11) + (f5 * f12)); float pow = (float) Math.pow((eal.e * Math.abs(f13)) / 100.0d, 0.42d); float pow2 = (float) Math.pow((eal.e * Math.abs(f14)) / 100.0d, 0.42d); float pow3 = (float) Math.pow((eal.e * Math.abs(f15)) / 100.0d, 0.42d); float signum = ((Math.signum(f13) * 400.0f) * pow) / (pow + 27.13f); float signum2 = ((Math.signum(f14) * 400.0f) * pow2) / (pow2 + 27.13f); float signum3 = ((Math.signum(f15) * 400.0f) * pow3) / (pow3 + 27.13f); double d = signum3; float f16 = ((float) (((signum * 11.0d) + (signum2 * (-12.0d))) + d)) / 11.0f; float f17 = ((float) ((signum + signum2) - (d * 2.0d))) / 9.0f; float f18 = signum2 * 20.0f; float f19 = (((signum * 20.0f) + f18) + (21.0f * signum3)) / 20.0f; float f20 = (((signum * 40.0f) + f18) + signum3) / 20.0f; float atan2 = (((float) Math.atan2(f17, f16)) * 180.0f) / 3.1415927f; if (atan2 < BitmapDescriptorFactory.HUE_RED) { atan2 += 360.0f; } else if (atan2 >= 360.0f) { atan2 -= 360.0f; } float f21 = atan2; float f22 = (3.1415927f * f21) / 180.0f; float pow4 = ((float) Math.pow((f20 * eal.g) / eal.c, eal.a * eal.f8149o)) * 100.0f; float f23 = 4.0f / eal.a; float sqrt = (float) Math.sqrt(pow4 / 100.0f); float f24 = eal.c; float f25 = eal.d; float pow5 = ((float) Math.pow(1.64d - Math.pow(0.29d, eal.i), 0.73d)) * ((float) Math.pow((((((((float) (Math.cos((((((double) f21) < 20.14d ? 360.0f + f21 : f21) * 3.141592653589793d) / 180.0d) + 2.0d) + 3.8d)) * 0.25f) * 3846.1538f) * eal.j) * eal.h) * ((float) Math.sqrt((f16 * f16) + (f17 * f17)))) / (f19 + 0.305f), 0.9d)) * ((float) Math.sqrt(pow4 / 100.0d)); float f26 = pow5 * eal.d; float sqrt2 = (float) Math.sqrt((r4 * eal.a) / (eal.c + 4.0f)); float f27 = (1.7f * pow4) / ((0.007f * pow4) + 1.0f); float log = ((float) Math.log((0.0228f * f26) + 1.0f)) * 43.85965f; double d2 = f22; return new FEM(f21, pow5, pow4, f25 * f23 * sqrt * (f24 + 4.0f), f26, sqrt2 * 50.0f, f27, log * ((float) Math.cos(d2)), log * ((float) Math.sin(d2))); } /* JADX INFO: Access modifiers changed from: package-private */ public static FEM c(float f, float f2, float f3, Eal eal) { float f4 = 4.0f / eal.a; float sqrt = (float) Math.sqrt(f / 100.0d); float f5 = eal.c; float f6 = eal.d; float f7 = eal.d * f2; float sqrt2 = (float) Math.sqrt(((f2 / ((float) Math.sqrt(r4))) * eal.a) / (eal.c + 4.0f)); float f8 = (1.7f * f) / ((0.007f * f) + 1.0f); float log = ((float) Math.log((f7 * 0.0228d) + 1.0d)) * 43.85965f; double d = (3.1415927f * f3) / 180.0f; return new FEM(f3, f2, f, f4 * sqrt * (f5 + 4.0f) * f6, f7, sqrt2 * 50.0f, f8, log * ((float) Math.cos(d)), ((float) Math.sin(d)) * log); } /* JADX INFO: Access modifiers changed from: package-private */ public final int c(Eal eal) { float f; float f2 = this.e; if (f2 != 0.0d) { float f3 = this.d; if (f3 != 0.0d) { f = f2 / ((float) Math.sqrt(f3 / 100.0d)); float pow = (float) Math.pow(f / Math.pow(1.64d - Math.pow(0.29d, eal.i), 0.73d), 1.1111111111111112d); double d = (this.b * 3.1415927f) / 180.0f; float cos = (float) (Math.cos(2.0d + d) + 3.8d); float f4 = eal.c; float pow2 = (float) Math.pow(this.d / 100.0d, (1.0d / eal.a) / eal.f8149o); float f5 = eal.j; float f6 = eal.h; float f7 = (f4 * pow2) / eal.g; float sin = (float) Math.sin(d); float cos2 = (float) Math.cos(d); float f8 = (((0.305f + f7) * 23.0f) * pow) / (((((((cos * 0.25f) * 3846.1538f) * f5) * f6) * 23.0f) + ((11.0f * pow) * cos2)) + ((pow * 108.0f) * sin)); float f9 = cos2 * f8; float f10 = f8 * sin; float f11 = f7 * 460.0f; float f12 = (((451.0f * f9) + f11) + (288.0f * f10)) / 1403.0f; float f13 = ((f11 - (891.0f * f9)) - (261.0f * f10)) / 1403.0f; float f14 = ((f11 - (f9 * 220.0f)) - (f10 * 6300.0f)) / 1403.0f; float max = (float) Math.max(0.0d, (Math.abs(f12) * 27.13d) / (400.0d - Math.abs(f12))); float signum = Math.signum(f12); float f15 = 100.0f / eal.e; float pow3 = (float) Math.pow(max, 2.380952380952381d); float max2 = (float) Math.max(0.0d, (Math.abs(f13) * 27.13d) / (400.0d - Math.abs(f13))); float signum2 = Math.signum(f13); float f16 = 100.0f / eal.e; float pow4 = (float) Math.pow(max2, 2.380952380952381d); float max3 = (float) Math.max(0.0d, (Math.abs(f14) * 27.13d) / (400.0d - Math.abs(f14))); float signum3 = Math.signum(f14); float f17 = 100.0f / eal.e; float pow5 = (float) Math.pow(max3, 2.380952380952381d); float f18 = ((signum * f15) * pow3) / eal.f[0]; float f19 = ((signum2 * f16) * pow4) / eal.f[1]; float f20 = ((signum3 * f17) * pow5) / eal.f[2]; float[][] fArr = C16404nyu.a; float[] fArr2 = fArr[0]; float f21 = fArr2[0]; float f22 = fArr2[1]; float f23 = fArr2[2]; float[] fArr3 = fArr[1]; float f24 = fArr3[0]; float f25 = fArr3[1]; float f26 = fArr3[2]; float[] fArr4 = fArr[2]; return Rez.d((f21 * f18) + (f22 * f19) + (f23 * f20), (f24 * f18) + (f25 * f19) + (f26 * f20), (f18 * fArr4[0]) + (f19 * fArr4[1]) + (f20 * fArr4[2])); } } f = BitmapDescriptorFactory.HUE_RED; float pow6 = (float) Math.pow(f / Math.pow(1.64d - Math.pow(0.29d, eal.i), 0.73d), 1.1111111111111112d); double d2 = (this.b * 3.1415927f) / 180.0f; float cos3 = (float) (Math.cos(2.0d + d2) + 3.8d); float f42 = eal.c; float pow22 = (float) Math.pow(this.d / 100.0d, (1.0d / eal.a) / eal.f8149o); float f52 = eal.j; float f62 = eal.h; float f72 = (f42 * pow22) / eal.g; float sin2 = (float) Math.sin(d2); float cos22 = (float) Math.cos(d2); float f82 = (((0.305f + f72) * 23.0f) * pow6) / (((((((cos3 * 0.25f) * 3846.1538f) * f52) * f62) * 23.0f) + ((11.0f * pow6) * cos22)) + ((pow6 * 108.0f) * sin2)); float f92 = cos22 * f82; float f102 = f82 * sin2; float f112 = f72 * 460.0f; float f122 = (((451.0f * f92) + f112) + (288.0f * f102)) / 1403.0f; float f132 = ((f112 - (891.0f * f92)) - (261.0f * f102)) / 1403.0f; float f142 = ((f112 - (f92 * 220.0f)) - (f102 * 6300.0f)) / 1403.0f; float max4 = (float) Math.max(0.0d, (Math.abs(f122) * 27.13d) / (400.0d - Math.abs(f122))); float signum4 = Math.signum(f122); float f152 = 100.0f / eal.e; float pow32 = (float) Math.pow(max4, 2.380952380952381d); float max22 = (float) Math.max(0.0d, (Math.abs(f132) * 27.13d) / (400.0d - Math.abs(f132))); float signum22 = Math.signum(f132); float f162 = 100.0f / eal.e; float pow42 = (float) Math.pow(max22, 2.380952380952381d); float max32 = (float) Math.max(0.0d, (Math.abs(f142) * 27.13d) / (400.0d - Math.abs(f142))); float signum32 = Math.signum(f142); float f172 = 100.0f / eal.e; float pow52 = (float) Math.pow(max32, 2.380952380952381d); float f182 = ((signum4 * f152) * pow32) / eal.f[0]; float f192 = ((signum22 * f162) * pow42) / eal.f[1]; float f202 = ((signum32 * f172) * pow52) / eal.f[2]; float[][] fArr5 = C16404nyu.a; float[] fArr22 = fArr5[0]; float f212 = fArr22[0]; float f222 = fArr22[1]; float f232 = fArr22[2]; float[] fArr32 = fArr5[1]; float f242 = fArr32[0]; float f252 = fArr32[1]; float f262 = fArr32[2]; float[] fArr42 = fArr5[2]; return Rez.d((f212 * f182) + (f222 * f192) + (f232 * f202), (f242 * f182) + (f252 * f192) + (f262 * f202), (f182 * fArr42[0]) + (f192 * fArr42[1]) + (f202 * fArr42[2])); } }