How to set a sample time in a Discrete Transfer Fcn??

I'm following the training of Simulink fundamentals, and I'm stucked trying to set the sample time on the parameters. Is not showing me that option to set it. I attached an image for you to view. Please I need some help with this is the only task that is left to end the course. Thanks in advance.

4 comentarios

Hi I have this same problem even in the offline version. I cannot set the time and I cannot progress in the course. I need urgent help please.
Fernando
Fernando el 3 de Oct. de 2023
Editada: Fernando el 3 de Oct. de 2023
Hey!! I was looking on several websites for help. And finally got something to help here.
Here is what I've done.
Step 1. Make a mask of the discrete transfer function.
Step 2. Promote sample time to show on your parameters.
Step 3. Save changes and then edit parameters of the discrete time function.
If you need any help ping me a message on vonszcelesv@gmail.com
BTW: there´s another issue like this on a lesson later on time. For that I haven´t found any help. And that is the 1% that now I need to get the certificate of completion
Henrique
Henrique el 6 de Oct. de 2023
Yes, I had the same problem.
Matlab gives some explanation at "https://nl.mathworks.com/help/simulink/ug/sampletimehiding.html".
The workaround by promoting the parameter worked for me. You can read more about promoting the parameter at "https://nl.mathworks.com/help/simulink/ug/parameter-promotion.html"
Thanks @Fernando

Iniciar sesión para comentar.

 Respuesta aceptada

Oren Savir
Oren Savir el 29 de Oct. de 2023

12 votos

I also got stuck with this problem.
but here is the solution:
Click the block (discrete transfer function)
Go to Model Explorer
change to default from the dropdown menu
Add SampleTime to objects visible:
Then click at bottom on paremter value and change -1 to Ts.
Exit Model Explorer
Clicking the block now includes the Sample Time option.

5 comentarios

Could @MathWorks Support Team please update the training material?
Simulink fundamentals
Modeling Discrete Dynamic Systems
Modeling Discrete Transfer Functions and State-Space Representations
Task 2
There is a easier way to solve this, go to model data editor, scroll down to find the discrete transfer function, then click on the the third column from the right which is sample time, change it from -1 to Ts
Thanks, I had to do it a bit different. After changing "column view" to default, I clicked "show details" at the right, and scrolled down to find SampleTime, then double-clicked to make it edtiable and changed it to Ts for discrete transfer funct.
Paula
Paula el 7 de Ag. de 2024
Agree with Zhaolun's approach, esier, open model data editor can edit all sample times for all the blocks.
It worked as ZD said.

Iniciar sesión para comentar.

Más respuestas (4)

Subhrajeet
Subhrajeet el 28 de Feb. de 2024
Step1 : Go to Model Explorer and change the Column view to Default.
Step2: Search SampleTime under the search section and double click on the SampleTime, and then the SampleTime will come under "Display column names" section.
Step3: Then see the buttom of the page, The columns will appear [Name, BlockType, SampleTime].
Step4: Then double click on Discrete Filter -> Sample Time to what ever you want.
(See the attached pdf for the Complete Solution)
Michael
Michael el 3 de Oct. de 2023
Per default the sample time of this block is (-1). This means the sample time is inherited from the signal at the input of the block. It is documented at the end of the help page of "Discrete Transfer Fcn" in the chapter "Version History"
Hassaan
Hassaan el 9 de Feb. de 2024
Editada: Hassaan el 9 de Feb. de 2024
@MathWorks Support Team I am having the same issue and stuck on this part. None of the solutions worked for me.
Could @MathWorks Support Team please update the training material?
Simulink fundamentals
Modeling Discrete Dynamic Systems
Modeling Discrete Transfer Functions and State-Space Representations
Task 2

1 comentario

Paula
Paula el 7 de Ag. de 2024
sorry to hear this, please open Model Data Editor Under 'Modeling' Tab. you will see the window above. on the far right, there is a column of sample time. you can edit all sample times for all the blocks here. once you put in Ts_filt for block 'Discrete Filter', then go back to the block again, you will see the updated Sample Time shows up. and click on the 'why' which explains in detail why by default , this sample time was hiddlen. Hope this helps.

Iniciar sesión para comentar.

Kitsirin
Kitsirin el 31 de Jul. de 2024
Does the following block have the correct parameter settings?
Discrete Filter:
Numerator: num_filt
Denominator: den_filt
InitialStates: 0
SampleTime: Ts_filt

Categorías

Más información sobre Simulink en Centro de ayuda y File Exchange.

Productos

Versión

R2023b

Preguntada:

el 28 de Sept. de 2023

Comentada:

el 26 de Ag. de 2024

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by