public void initial()
        {
            m_user1 = MockTDSimUser.CreatTDSimUser_CSDL();
            m_user2 = MockTDSimUser.CreatTDSimUser_CSUL();
            m_user3 = MockTDSimUser.CreatTDSimUser_PSDL();
            m_user4 = MockTDSimUser.CreatTDSimUser_PSUL();
            m_user5 = MockTDSimUser.CreatTDSimUser_PSDL();
            m_UnAccessedUsers = new List<TDSimUser>();

            m_Cell1 = MockTDSimCell.CreatTDSimCell();
            m_Cell1.CarrType = CarrierTypeOfTD.R4;
            m_Cells=new List<TDSimCell>();
            m_Cells.Add(m_Cell1);
            m_Tran = new TDSimTran(m_Cells);

            initialUser(m_user1, m_Cell1, m_Tran);
            initialUser(m_user2, m_Cell1, m_Tran);
            initialUser(m_user3, m_Cell1, m_Tran);
            initialUser(m_user4, m_Cell1, m_Tran);

            m_Carrier1 = new TDSCDMACarrier();
            m_Transceiver = new Transceiver();
            
            m_R4_CellAssign = new R4_CellAssign();
        }
Exemple #2
0
       //构造TDCarrier
       public static IACell CreatTDCarrier()
       {
           IACell cell = new TDSCDMACarrier();
           Transceiver trans = new Transceiver();
           Site site = new Site();

           site.X = 100;
           site.Y = 100;
           site.Equipment = new BtsEquipment();
           site.Equipment.NoiseFigure = 2;

           trans.Name = "Trans1";
           trans.Parent = site;
           trans.Cells.Add(cell);

           cell.Name = "TDCell1";
           cell.Parent = trans;
           cell.FreqBand = new FrequencyBand();
           cell.FreqBand.DLFrequency = 2010f;
           cell.FreqBand.ULFrequency = 2010f;

           AntConfig antConfig = new AntConfig();
           antConfig.OutdoorAntenna = new Huawei.UNet.Antenna.Entity.AntennaEntity();
           cell.Parent.AntConfiguration.Add(antConfig);
           cell.Parent.AntConfiguration[0].IsMainAnt = true;
           cell.Parent.AntConfiguration[0].DlTotalLoss = 3;
           cell.Parent.AntConfiguration[0].OutdoorAntenna.Gain = 18;
           cell.ID = 2;

           PropModelConfig propModelConfig = new PropModelConfig();
           propModelConfig.CalcRadius = 4000;
           propModelConfig.CalcResolution = 50;
           trans.Cells[0].PropModels.Add(propModelConfig);
           return cell;
       }
Exemple #3
0
        private double CalcAjecentCellInterf(TDSCDMACarrier tdInterfCell, TDSCDMACarrier bestCell, float linkLoss)
        {
            CoPredicGroup coPredicGroup = new CoPredicGroup();
            double txPower = UnitTrans.dBmTomw(tdInterfCell.PCCPCHPower) + (UnitTrans.dBmTomw(tdInterfCell.SCCPCHPower) + UnitTrans.dBmTomw(tdInterfCell.PICHPower)) * coPredicGroup.CoCovUIParam.OtherCommonCHFactor;
            double interf = 0;
            FrequencyRelationType type = GetFrequencyRelation(bestCell, tdInterfCell, bestCell.ChannelIndex, tdInterfCell.ChannelIndex);
            if (type == FrequencyRelationType.SameFrequency)
            {
                interf = UnitTrans.dBmTomw(UnitTrans.mwTodBm(txPower) - linkLoss) * (1 - bestCell.OrthCoef);
            }
            else if (type == FrequencyRelationType.FirstNeighbour)
            {
                double ACIR1 = (double)m_IInterf.findACIR(tdInterfCell.FreqBand.DLFrequency, tdInterfCell.FreqBand.BandWidth);
                if (!double.IsNaN(ACIR1))
                {
                    interf = UnitTrans.dBmTomw(UnitTrans.mwTodBm(txPower) - linkLoss - ACIR1);
                }
            }
            else if (type == FrequencyRelationType.SecondNeighbour)
            {
                double ACIR2 = (double)m_IInterf.findACIR2(tdInterfCell.FreqBand.DLFrequency, tdInterfCell.FreqBand.BandWidth);
                if (!double.IsNaN(ACIR2))
                {
                    interf = UnitTrans.dBmTomw(UnitTrans.mwTodBm(txPower) - linkLoss - ACIR2);
                }
            }
            return interf;

        }
 /// <summary>
 /// 构造函数
 /// </summary>
 /// <param name="CI">当前链路的CIR</param>
 /// <param name="bestCell">当前点的最佳服务小区</param>
 /// <param name="tdHSDPABearList">承载列表</param>
 /// <param name="tdTerminal">终端类型</param>
 public TDDwLinkThroughPutCalculator(double CI, IACell bestCell, 
     List<TDHSDPABearer> tdHSDPABearList, TDTerminal tdTerminal)
 {
     m_ServiceCI = CI;
     m_TdHSDPABearList = tdHSDPABearList;
     m_TdCell = bestCell as TDSCDMACarrier;
     m_TdTerminal = tdTerminal;
 }
Exemple #5
0
 public void GetFrequencytest()
 {
     IACell cell = new TDSCDMACarrier();
     cell.FreqBand.DLFrequency = 2e9f;
     cell.ChannelIndex = 5;
     cell.FreqBand.StartChIndex = 1;
     cell.FreqBand.BandWidth = 1.6e6f;
     float actual = TDPredictionCommonCalc.GetFrequency(cell);
     float expected = 2.0072e9f;
     Assert.AreEqual(expected, actual);
 }
Exemple #6
0
 private double CalcInnerSystemInterf(int index, TDSCDMACarrier tdInterfCell, TDSCDMACarrier bestCell, float dlLinkLoss)
 {
     double interf = 0;
     foreach (TDSCDMACarrier tdCell in tdInterfCell.Parent.Cells)
     {
         if (!object.ReferenceEquals(tdCell, bestCell))
         {
             interf += CalcAjecentCellInterf(tdCell, bestCell, dlLinkLoss);
         }
     }
     return interf;
 }
Exemple #7
0
 public double CalcInterf(int index, IACell interfCell, TDSCDMACarrier bestCell, float dlLinkLoss)
 {
     double interf = 0;
     TDSCDMACarrier tdInterfCell = interfCell as TDSCDMACarrier;
     if (tdInterfCell != null)
     {
         interf = CalcInnerSystemInterf(index, tdInterfCell, bestCell,dlLinkLoss);
     }
     else
     {
         interf = CalcOtherSystemInterf(index, interfCell, bestCell,dlLinkLoss);
     }
     return interf;
 }
Exemple #8
0
 /// <summary>
 /// 获得小区到小区的干扰
 /// </summary>
 /// <param name="index"></param>
 /// <param name="cell"></param>
 /// <param name="bestCell"></param>
 /// <param name="currentCell"></param>
 /// <param name="intefRxPower"></param>
 private void GetCellToCellInterf(int index, TDSCDMACarrier currentCell, TDSCDMACarrier bestCell, float intefRxPower)
 {
     Signal usefulSignal = TDIntefCalc.InitSingle(bestCell);//有用信号
     Signal source = TDIntefCalc.InitSingle(currentCell);//干扰信号
     source.RxPower = intefRxPower;
     if (currentCell is TDSCDMACarrier)
     {
         TDSCDMACarrier tdCell = currentCell as TDSCDMACarrier;
         source.OrthCoef = tdCell.OrthCoef;
     }
     InterfParameter param = new InterfParameter();
     param.InterfTable = m_InterfTable;
     IInterfCalc m_IInterf = new InterfCalculate(param);
     m_totalCellInterf = TDIntefCalc.GetInf(usefulSignal, source, m_IInterf, m_totalCellInterf);
 }
Exemple #9
0
 public static List<ISimCellBase> InitialTDInterfCell()
 {
     List<ISimCellBase> TDInterfCellList = new List<ISimCellBase>();
     IACell aCell = new TDSCDMACarrier();
     TDSimCell TDInterfCell = new TDSimCell(aCell);
     TDInterfCell.Cell.FreqBand.BandWidth = 3f;
     TDInterfCell.DlFrequency = 2000f;
     TDInterfCell.DlPower = 33;
     List<ISimUser> simUserList = new List<ISimUser>();
     ISimUser user1 = new MockTDSimUser();
     ISimUser user2 = new MockTDSimUser();
     simUserList.Add(user1);
     simUserList.Add(user2);
     TDInterfCell.ULSimUsers = simUserList;
     TDInterfCellList.Add(TDInterfCell);
     return TDInterfCellList;
 }
Exemple #10
0
 public void CopyForm(TDSCDMACarrier cell)
 {
     base.CopyFrom(cell);
     this.IsMaster = cell.IsMaster;
     this.UlJDFactor = cell.UlJDFactor;
     this.MaxDLCodeCHPower = cell.MaxDLCodeCHPower;
     this.MinDLCodeCHPower = cell.MinDLCodeCHPower;
     this.PCCPCHPower = cell.PCCPCHPower;
     this.PCCPCHCode = cell.PCCPCHCode;
     this.PCCPCHTS = cell.PCCPCHTS;
     this.SCCPCHPower = cell.SCCPCHPower;
     this.SCCPCHCode = cell.SCCPCHCode;
     this.SCCPCHTS = cell.SCCPCHTS;
     this.FPACHPower = cell.FPACHPower;
     this.FPACHCode = cell.FPACHCode;
     this.FPACHTS = cell.FPACHTS;
     this.PICHPower = cell.PICHPower;
     this.PICHCode = cell.PICHCode;
     this.PICHTS = cell.PICHTS;
     this.PRACHIntPower = cell.PRACHIntPower;
     this.PRACHCode = cell.PRACHCode;
     this.PRACHTS = cell.PRACHTS;
     this.OrthCoef = cell.OrthCoef;
     this.MaxUserPerTS = cell.MaxUserPerTS;
     this.CarrierType = cell.CarrierType;
     this.ThermalNoiseDensity = cell.ThermalNoiseDensity;
     this.ULMaxNoiseRise = cell.ULMaxNoiseRise;
     this.MinCECount = cell.MinCECount;
     this.Sched = cell.Sched;
     this.HSDPALoad = cell.HSDPALoad;
     this.ScchPower = cell.ScchPower;
     this.NumSCCH = cell.NumSCCH;
     this.HSDPAUserNum = cell.HSDPAUserNum;
     this.HSDPAPower = cell.HSDPAPower;
     this.HSDPACode = cell.HSDPACode;
     this.DwPCHPower = cell.DwPCHPower;
     this.IsDynamic = cell.IsDynamic;
     this.RatioforR4 = cell.RatioforR4;
     this.DlMaxPowerLoad = cell.DlMaxPowerLoad;
     this.HSUPAMaxUser = cell.HSUPAMaxUser;
     this.HSUPAMaxUE = cell.HSUPAMaxUE;
     this.HSUPATSCode = cell.HSUPATSCode;
     this.SmartAntID = cell.SmartAntID;
     this.SwitchPoint = cell.SwitchPoint;
     this.NoiseFigure = cell.NoiseFigure;
 }
Exemple #11
0
        public void Inital()
        {
            #region 初始化小区
            bestCell = new TDSCDMACarrier();
            bestCell.FreqBand=new FrequencyBand();
            bestCell.FreqBand.BandWidth = 1.6f;
            bestCell.FreqBand.DLFrequency = 2010.0f;
            bestCell.FreqBand.StartChIndex = 0;
            bestCell.ChannelIndex = 0;

            intefCell = new TDSCDMACarrier();
            intefCell.FreqBand = new FrequencyBand();
            intefCell.FreqBand.BandWidth = 1.6f;
            intefCell.FreqBand.DLFrequency = 2010.0f;
            intefCell.FreqBand.StartChIndex = 0;
            intefCell.ChannelIndex = 0;
            ((TDSCDMACarrier)intefCell).OrthCoef = 0.5f;

            intefCell1 = new UMTSCell();
            intefCell1.FreqBand = new FrequencyBand();
            intefCell1.FreqBand.BandWidth = 1.6f;
            intefCell1.FreqBand.DLFrequency = 2010.0f;
            intefCell1.FreqBand.StartChIndex = 0;
            intefCell1.ChannelIndex = 0;

            intefCell2 = new GSMTRX();
            intefCell2.FreqBand = new FrequencyBand();
            intefCell1.FreqBand.BandWidth = 2.4f;
            intefCell1.FreqBand.DLFrequency = 1800.0f;
            intefCell1.FreqBand.StartChIndex = 0;
            intefCell1.ChannelIndex = 0;

            #endregion

            LinkLossAssist.Init();
            pg = MockGroupAndCell.MockTDPredicGroup();
            matrix = new TrueFalseMatrix(4, 4, 0.0, 200, 50, true);
            cell = MockCell.CreateCell(cell);
            cell1 = MockCell.CreateCell(cell1);

        }
Exemple #12
0
 private FrequencyRelationType GetFrequencyRelation(TDSCDMACarrier bestCell, TDSCDMACarrier tdInterfCell, int sourceChannelIndex, int targetChannelIndex)
 {
     bool isSameFrequency = JudgeFrequency(bestCell, tdInterfCell, sourceChannelIndex, targetChannelIndex, FrequencyRelationType.SameFrequency);
     if (isSameFrequency)
     {
         return FrequencyRelationType.SameFrequency;
     }
     bool isFirstNeighbourFreq = JudgeFrequency(bestCell, tdInterfCell, sourceChannelIndex, targetChannelIndex, FrequencyRelationType.FirstNeighbour);
     if (isFirstNeighbourFreq)
     {
         return FrequencyRelationType.FirstNeighbour;
     }
     bool isSecondNeighbourFreq = JudgeFrequency(bestCell, tdInterfCell, sourceChannelIndex, targetChannelIndex, FrequencyRelationType.SecondNeighbour);
     if (isSecondNeighbourFreq)
     {
         return FrequencyRelationType.SecondNeighbour;
     }
     else
     {
         return FrequencyRelationType.Non;
     }
 }
Exemple #13
0
 private void CalcInterf(int index, IACell interfCell, TDSCDMACarrier bestCell)
 {
     TDSCDMACarrier tdInterfCell = interfCell as TDSCDMACarrier;
     if (tdInterfCell != null)
     {
         CalcInnerSystemInterf(index, tdInterfCell, bestCell);
     }
     else
     {
         CalcOtherSystemInterf(index, interfCell, bestCell);
     }
 }
Exemple #14
0
 /// <summary>
 /// 判断该小区是否需要计算
 /// </summary>
 /// <param name="cell"></param>
 /// <returns></returns>
 protected override bool IsNeedCalc(IACell cell)
 {
     m_tdCell = cell as TDSCDMACarrier;
     return (m_tdCell != null && m_tdCell.IsMaster) ;
 }
Exemple #15
0
 private double CalcGSMInterfWithHopping(IACell interfCell, TDSCDMACarrier bestCell, float linkLoss)
 {
     double interf = 0;
     GSMTRX gsminterfCell = interfCell as GSMTRX;
     List<int> soureMal = m_HoppingMALDic[gsminterfCell.ID];
     foreach (int channelIndex in soureMal)
     {
         interf += CalcOneCellInterf(gsminterfCell, bestCell, channelIndex, linkLoss);
     }
     return (interf / soureMal.Count);
 }
Exemple #16
0
 private double CalcGSMInterfWithoutHopping(IACell interfCell, TDSCDMACarrier bestCell, float linkLoss)
 {
     double interf = 0;
     interf = CalcOneCellInterf(interfCell, bestCell, interfCell.ChannelIndex, linkLoss);
     return interf;
 }
Exemple #17
0
 private double CalcInterfFormGSM(IACell interfCell, TDSCDMACarrier bestCell, float linkLoss)
 {
     double interf = 0;
     GSMTRX gsmInterfCell = interfCell as GSMTRX;
     if (gsmInterfCell.HopMode == HoppingMode.NonHopping)
     {
         interf = CalcGSMInterfWithoutHopping(interfCell, bestCell, linkLoss);
     }
     else
     {
         interf = CalcGSMInterfWithHopping(interfCell, bestCell, linkLoss);
     }
     return interf;
 }
Exemple #18
0
 private bool JudgeFrequency(TDSCDMACarrier bestCell, TDSCDMACarrier tdInterfCell, int sourceChannelIndex, int targetChannelIndex, FrequencyRelationType type)
 {
     float sourceBandWith = bestCell.FreqBand.BandWidth;
     float targetBandWith = tdInterfCell.FreqBand.BandWidth;
     float sourceDLFrequency = bestCell.FreqBand.DLFrequency;
     float targetDLFrequency = tdInterfCell.FreqBand.DLFrequency;
     int multiple = Convert.ToInt32(type);
     bool isSameBandWith = (sourceBandWith == targetBandWith);
     bool isIntegetExcursion = (Math.Abs((sourceDLFrequency + sourceBandWith * sourceChannelIndex) - (targetDLFrequency + targetBandWith * targetChannelIndex)) == sourceBandWith * multiple);
     return isSameBandWith && isIntegetExcursion;
 }
Exemple #19
0
 private void addNewTdscdmaCarrier(string carrierName, ReceptionEquipment reception)
 {
     TDSCDMACarrier cell = new TDSCDMACarrier();
     this.SetIACellProperty(carrierName, reception, cell);
     this.AddIACellToCarriers(cell);
 }
Exemple #20
0
 //TODO
 private double CalcAcir(IACell interfCell, TDSCDMACarrier bestCell, double deltaFreq)
 {
     double acir = double.NaN;
     Signal usefulSignal = new Signal();
     usefulSignal.FreqBand = bestCell.FreqBand.BandWidth;
     usefulSignal.Frequency = TDPredictionCommonCalc.GetFrequency((IACell)bestCell);
     usefulSignal.NetType = NetWorkType.TDSCDMA;
     Signal source = new Signal();
     source.FreqBand = interfCell.FreqBand.BandWidth;
     if (interfCell.NetType == NetWorkType.GSM)
     {
         source.Frequency = interfCell.FreqBand.DLFrequency + interfCell.FreqBand.BandWidth * (interfCell.ChannelIndex - bestCell.FreqBand.StartChIndex);
     }
     else
     {
         source.Frequency = TDPredictionCommonCalc.GetFrequency(interfCell);
     }
     acir = m_IInterf.findACIR(source, usefulSignal);
     return UnitTrans.todB(acir);
 }
Exemple #21
0
 private double CalcInterfByFreqRelation(IACell interfCell, TDSCDMACarrier bestCell, FrequencyRelationType type, double interfFreqBandWith, double bestCellFreqBandWith, double deltaFreq, double rxpower)
 {
     double interf = 0;
     double freqBandRatio = 0;
     double acir = 0;
     if (type == FrequencyRelationType.OutOfInterfFreq)
     {
         acir = CalcAcir(interfCell, bestCell, deltaFreq);
         if (!double.IsNaN(acir))
         {
             interf = UnitTrans.dBto(rxpower - acir);
         }
     }
     else if (type == FrequencyRelationType.InnerOfInterfFreq)
     {
         freqBandRatio = UnitTrans.todB(interfFreqBandWith / bestCellFreqBandWith);
         interf = UnitTrans.dBto(rxpower - freqBandRatio);
     }
     else if (type == FrequencyRelationType.InnerOfBestFreq)
     {
         interf = UnitTrans.dBto(rxpower);
     }
     return interf;
 }
Exemple #22
0
 private double CalcOneCellInterf(IACell interfCell, TDSCDMACarrier bestCell, int interfChannelIndex, double linkLoss)
 {
     double interf = 0;
     double interfFreqBandWith = interfCell.FreqBand.BandWidth;
     double bestCellFreqBandWith = bestCell.FreqBand.BandWidth;
     double deltaFreq = CalcFrequencyExcursion(interfCell, bestCell, interfChannelIndex);
     double rxpower = 0;
     if (interfCell.NetType == NetWorkType.GSM)
     {
         rxpower = ((GSMTRX)interfCell).TRXPower - linkLoss;
     }
     else if (interfCell.NetType == NetWorkType.UMTS)
     {
         rxpower = ((UMTSCell)interfCell).TotalPower - linkLoss;
     }
     else if (interfCell.NetType == NetWorkType.LTE)
     {
         rxpower = ((LTECell)interfCell).DlActualTxPower - linkLoss;
     }
     FrequencyRelationType type = JudgeFreqBandRelationship(interfCell, bestCell, interfChannelIndex);
     interf = CalcInterfByFreqRelation(interfCell, bestCell, type, interfFreqBandWith, bestCellFreqBandWith, deltaFreq, rxpower);
     return interf;
 }
Exemple #23
0
 private void CalcInnerSystemInterf(int index, TDSCDMACarrier tdInterfCell, TDSCDMACarrier bestCell)
 {
     double interf = 0;
     double dlInterf = 0;
     double pdschInterf = 0;
     float[] linkLoss = TDIntefCalc.GetLinkLossWithMainSAGain(index, m_TFMatrix, tdInterfCell, m_tdPredicGroup);
     double tempDLDCHInterf = UnitTrans.dBmTomw(m_DLDCHInterfMatrix[index]);
     double tempHSPDSCHInterf = UnitTrans.dBmTomw(m_HSPDSCHInterfMatrix[index]);
     foreach (TDSCDMACarrier tdCell in tdInterfCell.Parent.Cells)
     {
         if (!object.ReferenceEquals(tdCell, bestCell))
         {
             interf += CalcAdjecentCellInterf(tdCell, bestCell, linkLoss[1]);
         }
     }
     if (bestCell.CarrierType == CarrierTypeOfTD.R4)
     {
         dlInterf = interf * (1 - m_TDTerminal.MudFactor);
     }
     else if (bestCell.CarrierType == CarrierTypeOfTD.HSPA)
     {
         pdschInterf = interf * (1 - m_TDTerminal.MudFactor);
     }
     m_DLDCHInterfMatrix[index] = UnitTrans.mwTodBm(tempDLDCHInterf + dlInterf);
     m_HSPDSCHInterfMatrix[index] = UnitTrans.mwTodBm(tempHSPDSCHInterf + pdschInterf);
 }
Exemple #24
0
 private void CalcOtherSystemInterf(int index, IACell interfCell, TDSCDMACarrier bestCell)
 {
     float[] linkLoss = m_linkLossCalc.GetLinkLoss(index, m_TFMatrix, interfCell);
     double interf = 0;
     if (interfCell.NetType == NetWorkType.GSM)
     {
         interf = CalcInterfFormGSM(interfCell, bestCell, linkLoss[1]);
     }
     else if (interfCell.NetType == NetWorkType.UMTS)
     {
         interf = CalcInterfFormUMTS(interfCell, bestCell, linkLoss[1]);
     }
     else if (interfCell.NetType == NetWorkType.LTE)
     {
         interf = CalcInterfFormLTE(interfCell, bestCell, linkLoss[1]);
     }
     double tempOtherSystemInterf = UnitTrans.dBmTomw(m_OtherSystemInterfMatrix[index]);
     m_OtherSystemInterfMatrix[index] = UnitTrans.mwTodBm(tempOtherSystemInterf + interf);
 }
Exemple #25
0
 private double GetTxPower(TDSCDMACarrier cell)
 {
     double txPower = double.MinValue;
     if (cell.CarrierType == CarrierTypeOfTD.HSPA && m_tdPredicGroup.tdUIParam.CurrentTimeSlot != 6)
     {
         txPower = cell.HSDPAPower;
     }
     else if (cell.CarrierType == CarrierTypeOfTD.HSPA && m_tdPredicGroup.tdUIParam.CurrentTimeSlot == 6)
     {
         txPower = cell.MaxPower;
     }
     else if (cell.CarrierType == CarrierTypeOfTD.R4)
     {
         txPower = cell.MaxPower + UnitTrans.todB(cell.DlMaxPowerLoad);
     }
     return txPower;
 }
Exemple #26
0
 private FrequencyRelationType JudgeFreqBandRelationship(IACell interfCell, TDSCDMACarrier bestCell, int interfChannelIndex)
 {
     double TDSCDMABandWith = 1.28f;
     double bestStartFreq = bestCell.FreqBand.DLFrequency + bestCell.FreqBand.BandWidth * (bestCell.ChannelIndex + 0.5) - TDSCDMABandWith * 0.5;
     double bestEndFreq = bestStartFreq + TDSCDMABandWith;
     double interfStartFreq = 0;
     double interfEndFreq = 0;
     if (interfCell.NetType == NetWorkType.GSM)
     {
         interfStartFreq = interfCell.FreqBand.DLFrequency + interfCell.FreqBand.BandWidth * (interfChannelIndex - 0.5);
         interfEndFreq = interfStartFreq + interfCell.FreqBand.BandWidth;
     }
     else
     {
         interfStartFreq = interfCell.FreqBand.DLFrequency + interfCell.FreqBand.BandWidth * interfChannelIndex;
         interfEndFreq = interfStartFreq + interfCell.FreqBand.BandWidth;
     }
     if (bestStartFreq >= interfStartFreq && bestEndFreq <= interfEndFreq)
     {
         return FrequencyRelationType.InnerOfInterfFreq;
     }
     else if (interfStartFreq >= bestStartFreq && interfEndFreq <= bestEndFreq)
     {
         return FrequencyRelationType.InnerOfBestFreq;
     }
     else if (bestEndFreq <= interfStartFreq || bestStartFreq >= interfEndFreq)
     {
         return FrequencyRelationType.OutOfInterfFreq;
     }
     else
     {
         return FrequencyRelationType.Non;
     }
 }
Exemple #27
0
 /// <summary>
 /// 构建小区列表
 /// </summary>
 private void InitCellList()
 {
     for (int i = 0; i < 3; i++)
     {
         IACell cell = new TDSCDMACarrier();
         cell.FreqBand = new FrequencyBand();
         cell.FreqBand.BandWidth = 1.6f;
         cell.FreqBand.DLFrequency = 2010.0f;
         cell.FreqBand.StartChIndex = 0;
         cell.ChannelIndex = 0;
         
        
         m_CellList.Add(cell);
     }
     double[] x = new double[3] { 50, 100, 150 };
     double[] y = new double[3] { 50, 100, 50 };
     MockCellList.CreateCellList(m_CellList, x, y);
 }
Exemple #28
0
 private double CalcFrequencyExcursion(IACell interfCell, TDSCDMACarrier bestCell, int interfChannelIndex)
 {
     double interfFreqBandWith = interfCell.FreqBand.BandWidth;
     double bestFreqBandWith = bestCell.FreqBand.BandWidth;
     double interfDLCenterFreq = 0;
     if (interfCell.NetType == NetWorkType.GSM)
     {
         interfDLCenterFreq = interfCell.FreqBand.DLFrequency + interfFreqBandWith * interfChannelIndex;
     }
     else
     {
         interfDLCenterFreq = interfCell.FreqBand.DLFrequency + interfFreqBandWith * (interfChannelIndex + 0.5);
     }
     double bestDLCenterFreq = bestCell.FreqBand.DLFrequency + bestFreqBandWith * (bestCell.ChannelIndex + 0.5);
     return Math.Abs(interfDLCenterFreq - bestDLCenterFreq);
 }
Exemple #29
0
 private double CalcInterfFormUMTS(IACell interfCell, TDSCDMACarrier bestCell, float linkLoss)
 {
     double interf = 0;
     interf = CalcOneCellInterf(interfCell, bestCell, interfCell.ChannelIndex, linkLoss);
     return interf;
 }
Exemple #30
0
 private double CalcAdjecentCellInterf(TDSCDMACarrier tdInterfCell, TDSCDMACarrier bestCell, float linkLoss)
 {
     double txPower = GetTxPower(tdInterfCell);
     double interf = 0;
     double interfSC = 0;
     double interfAC = 0;
     double interfAC2 = 0;
     FrequencyRelationType type = GetFrequencyRelation(bestCell, tdInterfCell, bestCell.ChannelIndex, tdInterfCell.ChannelIndex);
     if (type == FrequencyRelationType.SameFrequency)
     {
         interfSC = UnitTrans.dBmTomw(txPower - linkLoss);
     }
     else if (type == FrequencyRelationType.FirstNeighbour)
     {
         double ACIR1 = (double)m_IInterf.findACIR(tdInterfCell.FreqBand.DLFrequency, tdInterfCell.FreqBand.BandWidth);
         if (!double.IsNaN(ACIR1))
         {
             interfAC = UnitTrans.dBmTomw(txPower - linkLoss - ACIR1);
         }
     }
     else if (type == FrequencyRelationType.SecondNeighbour)
     {
         double ACIR2 = (double)m_IInterf.findACIR2(tdInterfCell.FreqBand.DLFrequency, tdInterfCell.FreqBand.BandWidth);
         if (!double.IsNaN(ACIR2))
         {
             interfAC2 = UnitTrans.dBmTomw(txPower - linkLoss - ACIR2);
         }
     }
     interf = interfSC + interfAC + interfAC2;
     return interf;
 }