Réponse apportée
How can I tell Simulink to use the time steps of the input to produce exactly the same number of output steps as input?
In the "Data Import/Export" panel, Additional parameters, look for "Output options", select "Produce specified output only" and ...

environ 8 ans il y a | 0

| A accepté

Réponse apportée
How to incrementally save output data from long Simulink simulation?
You can specify the start and stop time of the simulation. The key point is to save the final state of the last simulation and u...

environ 8 ans il y a | 0

| A accepté

Réponse apportée
How to change table dimensions by ordering by column values?
Assume you put in those 15 numbers into a column vector: a=(1:15)'; b=reshape(a,5,3); t=array2table(b'); t.Propert...

environ 8 ans il y a | 1

| A accepté

Réponse apportée
create a matlab script file so that it loads a new configuration file and replace hte existing one in a simulink model
Save the configuration set from the sldemo_counters model to my_config_set.m. % Open the sldemo_counters model sldemo_co...

environ 8 ans il y a | 0

Réponse apportée
Set step time in Simulink
The setting of this parameter is dependent. It won't take effect until other settings are in place. You can check the solver typ...

environ 8 ans il y a | 1

| A accepté

Réponse apportée
How to attach the element into correct index
A=[A,B(3)] A(1,:)=B(1,:)

environ 8 ans il y a | 0

Réponse apportée
How to split a matrix
A=reshape(1:24,12,[]); B1=A(1:4,:) B2=A(5:8,:) B3=A(9:12,:) C=mat2cell(A,[4,4,4],2); C{1} C{:}

environ 8 ans il y a | 0

Réponse apportée
break out of if statement to else
No such capability in MATLAB. I am sure you can adjust your code flow to achieve your goal without jumping around the code, whic...

environ 8 ans il y a | 0

Réponse apportée
How to remove double quotes from a field?
The double quotes indicate the data is cell array of "string" class, not cell array of "char" class. They are not part of the da...

environ 8 ans il y a | 0

Réponse apportée
Tracing signals in script
To find out the source block that is connected to the Inport block in F14 f14; InportBlock='f14/Controller/alpha (rad)';...

environ 8 ans il y a | 0

Réponse apportée
How to find the first element in a vector of differing consecutive values?
Something like this? a=[636 637 638 24639 24640 48640 48641 48642 48643]; b=[0 a]; c=diff(b); index=c>1; out=a(...

environ 8 ans il y a | 3

| A accepté

Réponse apportée
How to copy a selected input-output pair of a MIMO bode plot into a new figure?
In the figure window, click menu "Edit" -> "Figure Properties ..." to activate the edit mode. Do the same for a new blank figur...

environ 8 ans il y a | 0

Réponse apportée
exponential transfer function in matlab
<https://www.mathworks.com/help/control/ug/time-delays-in-linear-systems.html Time Delays in Linear Systems>

environ 8 ans il y a | 0

| A accepté

Réponse apportée
How can i circle shift certain elements of two arrays simultaneously?
circshift(M,4) and circshift(N,4) where 4 is the same.

environ 8 ans il y a | 0

Réponse apportée
Error indexing usig logicals
This is really a floating point data precision issue. Run this to find out and deal with it based on whatever your use case. ...

environ 8 ans il y a | 0

Réponse apportée
How to arrange a Matrix in different shape?
A=magic(3); B=A(:,[3 2 1]) or B=A(:,[end:-1:1])

environ 8 ans il y a | 0

Réponse apportée
To find mean value of Y axis qty for specific time period?
t=0:0.1:10; y=sin(t); Index= (t>5) & (t<7); out=mean(y(Index))

environ 8 ans il y a | 0

| A accepté

Réponse apportée
Programmatically select a specific object when switching on plotedit
f=figure(1); p=plot(1:10); ax=findobj(f,'type','axes');

environ 8 ans il y a | 0

Réponse apportée
How can I calculate the delta T continously during simulation with simulink
It sounds like Tx is the integration of delta Temperature. Use an "Integrator" block. You may need to set up a linear Gain after...

environ 8 ans il y a | 0

Réponse apportée
How can I export all the enumerated data types from Data Dictionary to an m-file?
Even in R2018a, "The dictionary does not export enumerated data types (which are stored as Simulink.data.dictionary.EnumTypeDef...

environ 8 ans il y a | 0

Réponse apportée
Replace NaN with mean of previous values
Use the second code, replace size() with numel()

environ 8 ans il y a | 0

Réponse apportée
Syntax error in every function I wrote at Simulink Fcn block
I tried it. Initially, it had "syntax error". But once I assigned the following variables, the error disappeared. I used a Const...

environ 8 ans il y a | 0

| A accepté

Réponse apportée
looping over structure fields
for k=1:2:numel(fn) tmp = Structure.Aww.(fn{k}) tmp2= Structure.Aww.(fn{k+1}) end

environ 8 ans il y a | 0

| A accepté

Réponse apportée
is it possible to read special column of a text file?
just read the whole data and then you can do what ever you want a=importdata('FAR.txt',' ', 9); % the first 9 rows are igno...

environ 8 ans il y a | 0

Réponse apportée
how do i use different parts of a variable for the same code?
m0=[1 2 3 4; 10 20 30 40]; for iter=1:2 m0(iter,1) m0(iter,2) end

environ 8 ans il y a | 0

Réponse apportée
How to read header (text data of 100000 rows,18 columns) from data in excel into Matlab using different directory
Not sure what do you mean by "using different directory", but did you try? [Num, Txt, Raw]=xlsread('C:\MyDirectory\MyExcel....

environ 8 ans il y a | 0

| A accepté

Réponse apportée
How to stop a plot when values get to negative.
one way to do it, not sure if it is right for your use case though, z(z<0.5)=nan; surf(x,y,z)

environ 8 ans il y a | 0

Réponse apportée
Is it possible to add Area annotation programmatically?
An "Area" is an "Annotation", with empty "Name", "DropShadow" set as "On".

environ 8 ans il y a | 0

| A accepté

Réponse apportée
How to open a .txt file with header information
importdata(FILENAME, DELIM, NHEADERLINES) loads data from ASCII file FILENAME, reading numeric data starting from line NHEADERLI...

environ 8 ans il y a | 0

Réponse apportée
Programmatically changing the parameters of a LTI System Block in Simulink
The parameter names are "sys" and "IC". get_param('ES_Optimizer/LTI System','sys') get_param('ES_Optimizer/LTI System','...

environ 8 ans il y a | 0

| A accepté

Charger plus