Code generation does not support cell arrays in structure fields
Ältere Kommentare anzeigen
Dear All , I am getting 'Code generation does not support cell arrays in structure fields' error while trying to generate code for a matlab function. I am passing a cell array to odeset functions which in turn is a sparcity matrix.
reult_wp = odeset( 'reltol', 1e-04 , 'JPattern' {wb_1, wb_2})
wb_1 and wb_2 are sparcity matrix and size is 150x150 for both.
Please help me to resolve this issue.
Regards, Sanjeev
3 Kommentare
sanjeev kumar
am 31 Okt. 2018
sanjeev kumar
am 21 Nov. 2018
Adam Danz
am 21 Nov. 2018
Using fake (nonsense) data, I don't have any problems.
A = [ 0 0 0 5
0 2 0 0
1 3 0 0
0 0 4 0];
B = A';
reult_wp = odeset( 'reltol', 1e-04 , 'JPattern', {A, B})
First check that wb_1 and wb_2 are indeed matrices. If that's confirmed, copy and paste the entire error message into the comments section and the line of code generating the error (which I assume is the only line you shared).
Antworten (0)
Kategorien
Mehr zu MATLAB Coder finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!