Why am I not able to define input types of Entry-Point Function in MATLAB Coder 3.3 (R2017a)?

1 view (last 30 days)
My code has many inputs but the following message was shown in the Define Input Types step in the MATLAB Coder APP. I can define input types with the same code in R2013b.
1. >> coder
2. Add Stiff_Matrix_Gen
3. Click Next
In the Define Input Types step,
-------------------------------------
Function Stiff_Matrix_Gen does not have any input arguments. No input type definitions are required.
-------------------------------------

Accepted Answer

MathWorks Support Team
MathWorks Support Team on 6 Nov 2017
There is a bug in MATLAB Coder 3.3 (R2017a) in separated beginning lines of function code. This bug is fixed in R2017b. To work around this issue, combine beginning lines to contain input element in the first line.
For example,
In your code, it needs to be changed the three lines of function beginning.
Original:
-------------------------------------
function [Displacement_Results, Stress_Results, Restraint_Results, GlobalForce_Results] = ...
Stiff_Matrix_Gen ...
(CII_Element,CII_RIGID, ...
-------------------------------------
Modified:
-------------------------------------
function [Displacement_Results, Stress_Results, Restraint_Results, GlobalForce_Results] = Stiff_Matrix_Gen(CII_Element,CII_RIGID, ...
-------------------------------------

More Answers (0)

Categories

Find more on MATLAB Coder in Help Center and File Exchange

Tags

No tags entered yet.

Products


Release

R2013b

Community Treasure Hunt

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

Start Hunting!