我可以在课堂上使用omnetpp.ini变量吗?

在我的项目中,我正在建立一个UE和ENb(5G)网络,并且拥有不同数量的UE,并遵循ENb门控

[Config SingleUE]
project3.numberOfUes = 1
project3.ENb.numberOfGates = 1

[Config MultiUE]
project3.numberOfUes = 10
project3.ENb.numberOfGates = 10

在我的课堂上,我想检查是否有任何用户设备发送了相同数量的消息,最后检查我的msgCounter是否等于我想要的numberOfGates,因此将所有保存在向量数组中的消息发送出去

if(msgCounter == numberOfGates)
        {
            for(uint i = 0; i < messages.size(); i++)
            {
               EV<<"sending RACH-Response";
               RAP *msg = generateMessage2();
               send(msg,"out",0);
               delete msg;
            }
        }

但是此numberOfGates与omnetpp.ini文件中的不同,所以我的问题是是否可以在类中设置变量的其他方法或其他方法?

zb415 回答:我可以在课堂上使用omnetpp.ini变量吗?

好吧,我找到了答案

   g(3)
~> (fn x => f(x + 2) * 2)(3)
~> f(3 + 2) * 2
~> f(5) * 2
~> (if (5 mod 2 = 0) then 5 - 10 else 5 + 10) * 2
~> (if (1 = 0) then 5 - 10 else 5 + 10) * 2
~> (5 + 10) * 2
~> 15 * 2
~> 30

我可以链接两个参数

本文链接:https://www.f2er.com/3030488.html

大家都在问