- Double-check the number of parameters: Verify that the number of parameters defined in the S-function matches the number of parameters in the dialog of the 'Compressor' block. Make sure there is no discrepancy in the count.
- Check for parameter inconsistencies: Examine the parameter names and ensure they are consistent. Even a small difference in spelling or capitalization can cause a mismatch.
- Review the S-function code: Look at the code of the 'Compressor_TMATS' S-function and check if there are any sections or lines where the number of parameters is explicitly specified or calculated. Make sure these sections are correct and consistent.
- Debugging with print statements: Insert print statements or use MATLAB's debug mode to track the values of parameters during the simulation. This can help identify where the discrepancy occurs and provide more insight into the issue.
Troubleshooting T-MATS
13 views (last 30 days)
Show older comments
I am trying to run T-MATS (For a JT9D) and I keep getting this error:
Error using JT9D_setup_everything_Dyn (line 89) For S-function 'Compressor_TMATS', the number of defined parameters, 32, does not match the number of parameters on the dialog of 'JT9D_Model_Dyn_withPID/While Iterator Plant/Plant model/Fan/Compressor', 31. These two values must be identical.
I have cross-checked and the parameters are both 31, but I don't know why it keeps throwing this error. Any help?
0 Comments
Accepted Answer
Dhruv
on 16 May 2023
To troubleshoot the issue of mismatch between the number of defined parameters in the S-function 'Compressor_TMATS' and the number of parameters on the dialog of the 'JT9D_Model_Dyn_withPID/ Compressor' block, try the following steps:
By following these above steps, you should be able to identify the cause of the parameter mismatch error and resolve the issue.
0 Comments
More Answers (0)
See Also
Categories
Find more on Prepare Model Inputs and Outputs 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!