public void getSen(double[,] v1, double[,] v2, Sensitividades v3)
 {
     sensitividad = new double[v1.GetLength(0), v1.GetLength(1)];
     functionD    = new double[v1.GetLength(0), v1.GetLength(0)];
     for (int i = 0; i < functionD.GetLength(0); i++)
     {
         for (int j = 0; j < functionD.GetLength(1); j++)
         {
             if (i == j)
             {
                 functionD[i, j] = (1 - v1[i, 0]);
             }
         }
     }
     sensitividad = multMatrix(multMatrix(functionD, trans(v2)), v3.getThisSen());
 }
 public EntrenaRedNeuronal(int noCapasOc, int[] noNeuronas, int[] function, double[,] capaIn, double[,] vTarget, double alfa)
 {
     this.noNeuronas = noNeuronas;
     this.alfa       = alfa;
     vIn             = capaIn;
     this.capaIn     = new Capa(noNeuronas[0], capaIn);
     this.noCapasOc  = noCapasOc;
     this.capasOc    = new Capa[noCapasOc];
     //this.capaIn.setError(0.0);
     this.function = function;
     this.capaIn.setFunction(function[0]);
     this.capaIn.setVIn(capaIn);
     for (int i = 0; i < noCapasOc; i++)
     {
         this.capasOc[i] = new Capa(function[i + 1]);
     }
     setVTarget(vTarget);
     sen = new Sensitividades[noCapasOc + 2];
     for (int i = 0; i < noCapasOc + 2; i++)
     {
         sen[i] = new Sensitividades();
     }
 }