"Insufficient number of outputs from right hand side of equal sign to satisfy assignment." in Simulink
Show older comments
I got the error above in Simulink and that is the part of the model that causes it.

The interpolation factor of the DUC is 100. The slx-file is attached
Thanks :)
11 Comments
Daniel
on 4 Aug 2023
It will be a lot easier to answer the question if the model is attached, rather than a screenshot. That will allow people with expertise to investigate relevant block parameters and such.
Jan Van den Heuvel
on 4 Aug 2023
Jon
on 4 Aug 2023
Looks like you will also need to attach rtty_pinneberg_147_3kHz.wav
Jan Van den Heuvel
on 4 Aug 2023
Jon
on 4 Aug 2023
I can now replicate the problem, but unfortunately I realized am not familiar enough with the details of the blocks you are using to be able to guide you as how to resolve the issue. Now that you have a simple example to replicate the problem, hopefully someone can offer a solution.
Jan Van den Heuvel
on 4 Aug 2023
Daniel
on 4 Aug 2023
I'm not seeing an issue when I run it on my system (MATLAB R2023a Update 4 for Windows, all toolboxes installed). I tried updating the model and running it, and it's set to simulate using code generation.
@ Daniel I am also on MATLAB R2023a Update 4 for Windows, but I can only run the OP's code in Interpreted mode.
Can't seem to cut and paste the error message, but here is what it says:
An error occurred in the block upconverter/Digital Up-Converter' during compile.
Caused by:
- Insufficient number of outputs from right hand side of equal sign to satisfy assignment.
Component Simulink|Category:Block Error
Here is my Ver output
>> ver
-----------------------------------------------------------------------------------------------------
MATLAB Version: 9.14.0.2306882 (R2023a) Update 4
MATLAB License Number: 22059
Operating System: Microsoft Windows 10 Enterprise Version 10.0 (Build 19045)
Java Version: Java 1.8.0_202-b08 with Oracle Corporation Java HotSpot(TM) 64-Bit Server VM mixed mode
-----------------------------------------------------------------------------------------------------
MATLAB Version 9.14 (R2023a)
Simulink Version 10.7 (R2023a)
Control System Toolbox Version 10.13 (R2023a)
DSP System Toolbox Version 9.16 (R2023a)
Database Toolbox Version 11.0 (R2023a)
MATLAB Compiler Version 8.6 (R2023a)
MATLAB Compiler SDK Version 7.2 (R2023a)
Model Predictive Control Toolbox Version 8.1 (R2023a)
Optimization Toolbox Version 9.5 (R2023a)
Requirements Toolbox Version 2.2 (R2023a)
Robust Control Toolbox Version 6.11.3 (R2023a)
Signal Processing Toolbox Version 9.2 (R2023a)
Simulink Check Version 6.2 (R2023a)
Simulink Control Design Version 7.0 (R2023a)
Simulink Coverage Version 5.6 (R2023a)
Spreadsheet Link Version 3.4.9 (R2023a)
Stateflow Version 10.8 (R2023a)
Statistics and Machine Learning Toolbox Version 12.5 (R2023a)
System Identification Toolbox Version 10.1 (R2023a)
Daniel
on 4 Aug 2023
Strange. Identical MATLAB, different results. I wonder if we're using different compilers perhaps.
I'm also on Windows 11. Hopefully that's not causing the difference.
My compilers are mingw64-g++ and mingw64. I can find that through the following commands:
comps = mex.getCompilerConfigurations
comps.ShortName
I wonder what compilers you and OP are running.
Jan Van den Heuvel
on 5 Aug 2023
Daniel
on 7 Aug 2023
That output just means you have no compilers installed. 0x1 is an empty matrix, basically. (No rows, 1 column, technically. No elements regardless.) So it makes sense that generated code wouldn't work; that interpreted execution wouldn't work is a little stranger. What toolboxes do you have installed? (Paste the output of ver)
Alternatively, at this point a support ticket might be best, especially if interpreted execution isn't working either. It looks like what you're trying to do should work, given that it does work for Jon and me, so it might easily be a configuration issue rather than an issue with the model itself.
Answers (1)
Jon
on 4 Aug 2023
0 votes
I found that if I changed the "Simulate using" parameter on the DUC from Code Generation to Interpreted execution, the model ran without errors. So, maybe there is a bug with the Code Generation, or somehow it is just fussier, and there is still an issue, it just doesn't surface with the Interpreted execution.
Categories
Find more on Signal Generation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!