示例#1
0
        /// <summary>
        /// WFG1 t3 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <returns></returns>
        public float[] T3(float[] z)
        {
            float[] result = new float[z.Length];

            for (int i = 0; i < z.Length; i++)
            {
                result[i] = Transformations.B_poly(z[i], (float)0.02);
            }

            return(result);
        }
示例#2
0
        /// <summary>
        /// WFG5 t1 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T1(float[] z, int k)
        {
            float[] result = new float[z.Length];

            for (int i = 0; i < z.Length; i++)
            {
                result[i] = Transformations.S_decept(z[i], (float)0.35, (float)0.001, (float)0.05);
            }

            return(result);
        }
        /// <summary>
        /// WFG4 t1 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T1(float[] z, int k)
        {
            float[] result = new float[z.Length];

            for (int i = 0; i < z.Length; i++)
            {
                result[i] = Transformations.S_multi(z[i], 30, 10, (float)0.35);
            }

            return(result);
        }
示例#4
0
        /// <summary>
        /// WFG2 t1 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T1(float[] z, int k)
        {
            float[] result = new float[z.Length];

            Array.Copy(z, 0, result, 0, k);

            for (int i = k; i < z.Length; i++)
            {
                result[i] = Transformations.S_linear(z[i], (float)0.35);
            }

            return(result);
        }
示例#5
0
        /// <summary>
        /// WFG1 t2 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T2(float[] z, int k)
        {
            float[] result = new float[z.Length];

            Array.Copy(z, 0, result, 0, k);

            for (int i = k; i < z.Length; i++)
            {
                result[i] = Transformations.B_flat(z[i], (float)0.8, (float)0.75, (float)0.85);
            }

            return(result);
        }
示例#6
0
        /// <summary>
        ///  WFG3 t2 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T2(float[] z, int k)
        {
            float[] result = new float[z.Length];

            Array.Copy(z, 0, result, 0, k);

            int l = z.Length - k;

            for (int i = k + 1; i <= k + l / 2; i++)
            {
                int     head = k + 2 * (i - k) - 1;
                int     tail = k + 2 * (i - k);
                float[] subZ = SubVector(z, head - 1, tail - 1);

                result[i - 1] = Transformations.R_nonsep(subZ, 2);
            }
            return(result);
        }
        /// <summary>
        /// WFG9 t3 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <param name="M"></param>
        /// <returns></returns>
        public float[] T3(float[] z, int k, int M)
        {
            float[] result = new float[M];

            for (int i = 1; i <= M - 1; i++)
            {
                int     head = (i - 1) * k / (M - 1) + 1;
                int     tail = i * k / (M - 1);
                float[] subZ = SubVector(z, head - 1, tail - 1);
                result[i - 1] = Transformations.R_nonsep(subZ, k / (M - 1));
            }

            int h = k + 1;
            int t = z.Length;
            int l = z.Length - k;

            float[] sZ = SubVector(z, h - 1, t - 1);
            result[M - 1] = Transformations.R_nonsep(sZ, l);

            return(result);
        }
        /// <summary>
        /// WFG9 t1 transformation
        /// </summary>
        /// <param name="z"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public float[] T1(float[] z, int k)
        {
            float[] result = new float[z.Length];
            float[] w      = new float[z.Length];

            for (int i = 0; i < w.Length; i++)
            {
                w[i] = (float)1.0;
            }

            for (int i = 0; i < z.Length - 1; i++)
            {
                int     head = i + 1;
                int     tail = z.Length - 1;
                float[] subZ = SubVector(z, head, tail);
                float[] subW = SubVector(w, head, tail);
                float   aux  = Transformations.R_sum(subZ, subW);
                result[i] = Transformations.B_param(z[i], aux, (float)0.98 / (float)49.98, (float)0.02, (float)50);
            }

            result[z.Length - 1] = z[z.Length - 1];
            return(result);
        }