Is it possible to assign the size of an input port to variables instead of fixed constants?

2 visualizaciones (últimos 30 días)
I am using an input port in a Simulink model that will be compiled and I need to set the starting size of the input port in order to compile the model without errors.
An array of size (i x j) is used as the input to the model, where i = rows and j = columns. i and j change values each time the compiled model is called but the values are known prior to the model being called.
Is it possible to define the size of the input port as (i x j) and assign values to these variables each time the model is called? My idea at the moment is to use two additional inputs to define the size of the rows and columns but I don't know how (or if) these can be used to size the orignal input port.

Respuesta aceptada

Mark McBroom
Mark McBroom el 27 de Oct. de 2023

Más respuestas (0)

Categorías

Más información sobre Event Functions en Help Center y File Exchange.

Productos


Versión

R2022a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by