| Products & Services | Solutions | Academia | Support | User Community | Company |
| Download Product Updates | | | Get Pricing | | | Trial Software |
| Documentation → Simulink |
| Contents | Index |
| Learn more about Simulink |
int_T ssSetOutputPortVectorDimension(SimStruct *S, int_T port, int_T w)
SimStruct representing an S-Function block.
Index of an output port.
Width of the vector or DYNAMICALLY_SIZED.
1 if successful; otherwise, 0.
Specifies that port emits a w-element vector signal. If the width is dynamically sized, the S-function must provide mdlSetOutputPortDimensionInfo and mdlSetDefaultPortDimensionInfo methods to enable the signal dimensions to be set correctly during signal propagation.
C, C++
The following example specifies that output port 0 emits an 8-element matrix signal.
ssSetOutputPortVectorDimension(S, 0, 8);
See the S-function matlabroot/toolbox/simulink/simdemos/simfeatures/src/sdotproduct.c used in sfcndemo_sdotproduct.mdl for a complete example that uses this function.
![]() | ssSetOutputPortSampleTime | ssSetOutputPortWidth | ![]() |

Learn more about Simulink through this collection of videos, articles, technical literature and the Getting Started with Simulink Guide.
| © 1984-2009- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |