Menu

JMT2LINE

Help
2019-02-26
2022-02-20
  • Catia Trubiani

    Catia Trubiani - 2019-02-26

    Hi all,

    I am trying to convert a JMT model into LINE but I get the following error:

    LINE2SCRIPT(JMT2LINE('myModelJMT.jsimg'),'myModelLine.m')
    Dot indexing is not supported for variables of this type.
    Error in JMT2LINE (line 68)
    xsvc{i} = {xsection_i{i}(2).parameter.subParameter};

    Any suggestion for this?

    Kind regards, Catia

     
  • Giuliano Casale

    Giuliano Casale - 2019-03-04

    Hi.
    This problem is now fixed in the latest commit.
    Best wishes,
    Giuliano

     
  • Ines Gharbi

    Ines Gharbi - 2022-02-15

    Hi everyone,
    I have a similar problem with the conversion of my JMT model to LINE. I'm trying to concept a model similar to the "jackson network" (multiples sources, multiples sinks, multiple queueus, forks, and joins) using JMT. I received these errors:
    Operands to the logical and (&&) and or (||) operators must be convertible to logical scalar values.
    Error in Network/sanitize (line 125)
    if isempty(self.getIndexSourceStation) || i ~= self.getIndexSourceStation
    Error in Network/refreshStruct (line 7)
    sanitize(self);
    Error in NetworkSolver (line 34)
    self.model.refreshStruct(); % force model to refresh
    Error in SolverJMT (line 35)
    self@NetworkSolver(model, mfilename);

    Thank you for your help.

     
  • Giuliano Casale

    Giuliano Casale - 2022-02-15

    Thanks a lot for the bug report. Can you share the JMT model in this thread? Thanks

     
  • Ines Gharbi

    Ines Gharbi - 2022-02-15

    Hi,
    This is my model.
    I tried to replace || with | at line 125 as you mentioned it but it doesn't work.
    Thank you for your help.

     
  • Giuliano Casale

    Giuliano Casale - 2022-02-15

    Thanks, I've tried it but JMT2LINE works on my LINE and MATLAB R2021a. Which MATLAB are you using? Are you using the latest version of LINE?

    Giuliano

     
  • Ines Gharbi

    Ines Gharbi - 2022-02-15

    I'm using Matlab R 2021a and line-2.0.17
    This is the used script to generate the code:

    JMT2LINE('modelI3CI_1.jsimg')
    ans =
    Network with properties:

        classes: {4×1 cell}
          items: {}
       stations: {7×1 cell}
          nodes: {13×1 cell}
    connections: [13×13 double]
           name: 'modelI3CI_1'
    

    model=ans
    model =
    Network with properties:

        classes: {4×1 cell}
          items: {}
       stations: {7×1 cell}
          nodes: {13×1 cell}
    connections: [13×13 double]
           name: 'modelI3CI_1'
    

    LINE2SCRIPT(model)

    Otherwise, would you please share the source code that you generated.
    Thank you for your help

     

    Last edit: Ines Gharbi 2022-02-15
  • Giuliano Casale

    Giuliano Casale - 2022-02-15

    I understand now. You used multiple Sources, but LINE requires there's a single Source in the model for technical reasons. You need to use a single Source in JMT and place after it a router to split probabilistically the arrivals.

    Alternatively, you can use a single Source in JMT and assign the arriving jobs to different classes (possibly with identical arrival rates if they were the same class in the original model). You can also put a class switch after the Source in JMT.

    I will open a ticket to see if in future releases we can support multiple sources in LINE.

     
  • Ines Gharbi

    Ines Gharbi - 2022-02-16

    Hi all,
    Perhaps, I had to ask from the beginning if LINE accepts managing multi-sources because I tried to run all models in the folders gallery and examples, and I haven't found an example using multi-sources or multi-sinks.
    Thank you a lot for your help and quick response.
    LINE is a wonderful tool, easy to use. It will be great if it will provide managing multi-sources and multi-sinks in future releases.

     

    Last edit: Ines Gharbi 2022-02-16
  • Giuliano Casale

    Giuliano Casale - 2022-02-16

    Thank you very much for your interest and support and please do not hesitate to flag other bugs or feature requests. We'll sort out this issue of multi-sources within JMT2LINE but it will take some weeks.

     
  • Giuliano Casale

    Giuliano Casale - 2022-02-20

    Ines, I've checked your model in JMT and what you are doing with the multiple sources can be easily avoided: when you define the classes map them to the same Source node (use a single Source in the model) and then in the Routing section of that Source you configure the routing probabilities to Queue1, Queue2 and Queue3 for each class.

     
  • Ines Gharbi

    Ines Gharbi - 2022-02-20

    Thank you for your suggestion, I will try this method.

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.