# Error upon running unmodified TorqueVect.mdl - Formula Carmaker

**URL:** <https://forums.ipg-automotive.com/t/error-upon-running-unmodified-torquevect-mdl-formula-carmaker/1214>\
**Category:** CM4SL\
**Tags:** student, carmaker\
**Created:** [25 November 2024 18:03 UTC](https://forums.ipg-automotive.com/t/error-upon-running-unmodified-torquevect-mdl-formula-carmaker/1214 "2024-11-25T18:03:50Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![egywc1](https://forums.ipg-automotive.com/letter_avatar_proxy/v4/letter/e/779978/32.png) [@egywc1](https://forums.ipg-automotive.com/u/egywc1)\
**Post date:** [25 November 2024 18:03 UTC](https://forums.ipg-automotive.com/t/error-upon-running-unmodified-torquevect-mdl-formula-carmaker/1214/1 "2024-11-25T18:03:50Z")

</div>

I’ve been looking into integrating our Torque Vectoring model into IPG to run some lap time simulations, and I initially decided I would try to use the OpenXWD format and Simulink.

Upon further reading, it seems like I could instead keep the powertrain model in IPG and instead just modify the PTControl unit as described in the Formula CarMaker tutorial (5.5.1). However, upon opening and running the example/tutorial model “FSE\_TorqueVectoring” using the Simulink model ‘TorqueVect.mdl’ (which I have not modified) I am getting two errors which prevent it from running.

Location of the error code:

 ![image](https://forums.ipg-automotive.com/uploads/default/original/1X/523295e41c4ae21115dd2cb91652e3ce142a38ef.png)

I think I understand that ‘CreateBus PTC\_Cfg Battery’ is receiving only 6 inputs, and inside, the demux is expecting 8 (I tried to upload a screenshot of this, but I am only allowed one as a new account!).

I’m not sure how to fix this, as I don’t think I’m able to modify the green S-Function Block “cm\_ptcontrol\_in”. There is even a 6 on the output line of the function block so it seems that was expected from the function.

Have I misstepped somewhere? Does this work for anyone else with the Formula Carmaker package? Any ideas would be appreciated, thank you.
