# How to prevent the aliasing effect in simulation?

**URL:** <https://scilab.discourse.group/t/how-to-prevent-the-aliasing-effect-in-simulation/968>\
**Category:** Xcos\
**Created:** [June 11, 2025, 12:45pm UTC](https://scilab.discourse.group/t/how-to-prevent-the-aliasing-effect-in-simulation/968 "2025-06-11T12:45:23Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Student](https://avatars.discourse-cdn.com/v4/letter/s/ecc23a/32.png) [@Student](https://scilab.discourse.group/u/Student)\
**Post date:** [June 11, 2025, 12:45pm UTC](https://scilab.discourse.group/t/how-to-prevent-the-aliasing-effect-in-simulation/968/1 "2025-06-11T12:45:23Z")

</div>

I have a dynamic model of a power electronics converter in the Xcos. I have been using the TOWS\_c blocks for recording of the state variables.

My problem is that these blocks need sampling time input which has to be small enough to be able to record the switching noise and on the other hand big enough not to cause buffers overflow.

I have attempted to set the buffers based on the simulation paramters as t\_final/t\_sampling. Unfortunately also with this approach the buffers are somehow corrupted because I can see only short time interval before the t\_final. This occurs in a situation when the t\_sampling is suitable for the system dynamics (tens of microseconds). In case I increase the t\_sampling I can see whole time interval (hundreds of milliseconds) but it’s corrupted due to the aliasing effect.

Is there any recommended approach for this situation?

---

<div class="post-metadata">

**Author:** ![mottelet](https://yyz2.discourse-cdn.com/free1/user_avatar/scilab.discourse.group/mottelet/32/13_2.png) [@mottelet](https://scilab.discourse.group/u/mottelet)\
**Post date:** [June 11, 2025, 1:00pm UTC](https://scilab.discourse.group/t/how-to-prevent-the-aliasing-effect-in-simulation/968/2 "2025-06-11T13:00:53Z")

</div>

Hello,

I presume that you mean subsampling instead of aliasing, right ? There is no “corruption” of output data. Anyway, you should be able to see the whole output by taking a sufficiently large buffer length (this length can be way larger than needed).

S.
