Exemplo n.º 1
0
    internal void Calc_dynamics(int lr, AirPlane ap, Vector3D dv, double k_q, double k_S)
    {
        d_fv.SetVec(0.0D, 0.0D, 0.0D);
        d_tv.SetVec(0.0D, 0.0D, 0.0D);
        if (type == 0)
        {
            return;
        }

        baseWingBlock.Calc_dynamics(lr, null, ap, dv, k_q, k_S);
        d_cl  = baseWingBlock.cl;
        d_cdi = baseWingBlock.cdi;
        Vector3D fv_base = new Vector3D(baseWingBlock.fv);
        Vector3D tv_base = new Vector3D(baseWingBlock.tv);

        baseWingBlock.Calc_dynamics(lr, this, ap, dv, k_q, k_S);
        d_cl  = (baseWingBlock.cl - d_cl);
        d_cdi = (baseWingBlock.cdi - d_cdi);
        d_fv  = baseWingBlock.fv.Sub(fv_base);
        d_tv  = baseWingBlock.tv.Sub(tv_base);
    }
Exemplo n.º 2
0
 internal void Calc_dynamics(AirPlane ap, Vector3D[] dv, double[] k_q, double[] k_S)
 {
     fv.SetVec(0.0D, 0.0D, 0.0D);
     tv.SetVec(0.0D, 0.0D, 0.0D);
     for (int lr = 0; lr < n_lr; lr++)
     {
         for (int i = 0; i < n_wing_block; i++)
         {
             WingPlane wpi = wp[i, lr];
             if (wpi.flag != 0)
             {
                 wpi.Calc_dynamics(lr, null, ap, dv[lr], k_q[lr], k_S[lr]);
                 fv = fv.Add(wpi.fv);
                 tv = tv.Add(wpi.tv);
             }
         }
     }
 }