Respondida
Detect if user has a valid MatLab license
There are so many ways to specify the license file, I think you need to follow this order specified in "MATLAB License Search Pa...

alrededor de 3 años hace | 1

Respondida
creating matrix using output elements
B=[1:1:576]'; mean(reshape(B,24,[]))

alrededor de 3 años hace | 0

| aceptada

Respondida
Is it possible to access/use sldd data within a stateflow without using a mask?
Once the SLDD is specified for the model, its data can be used by the whole model. What is the issue? In Stateflow, add a param...

alrededor de 3 años hace | 0

| aceptada

Respondida
Disable some or all the optimization for simulink simulation
I would suggest using blocks from Simulink Dashboard, e.g. Slider

alrededor de 3 años hace | 0

Respondida
How do I print a legend using a character array and integer array?
a="current"; b={'archive'}; c='current'; sprintf('%s',a) sprintf('%s',b{1}) sprintf('%s',c)

alrededor de 3 años hace | 0

Respondida
How to interact with model configuration parameters using script
vdp; get_param('vdp','ParameterOverflowMsg'); set_param('vdp','ParameterOverflowMsg','warning') web(fullfile(docroot, 'simu...

alrededor de 3 años hace | 0

| aceptada

Respondida
Not a 'Simulink.Signal' object
Select a signal line in your model, right click, select Properties, type in a name "SignalA", and check the check-box "Signal na...

alrededor de 3 años hace | 0

Respondida
Getting error on opening Signal Builder block
Might be due to a corruptted file. If it is not critical to lose this particular block, then drag a new SignalBuilder block to a...

alrededor de 3 años hace | 0

Respondida
How to assign initial values to closed loops in simulink
There are many blocks inside model A, B and C. Some of the blocks (e.g. an Integrator) have dialog parameter for initial value. ...

alrededor de 3 años hace | 0

| aceptada

Respondida
a serialized simulation in Simulink
This should be a relatively easy task. I think the best way is to implement it in the "StopFcn" callback of the model. Open th...

alrededor de 3 años hace | 0

Respondida
Why can this expression be logically evaluated but not used in an if-statements?
"somehow it didn't throw an error in any of the cases (1, any number or no number)." The coding problem still exists. The err...

alrededor de 3 años hace | 0

Respondida
Variation between data during simulation and that stored for use in second simulation
@Paul, I am determined to persuade you on this. Luckily, I was able to make an example quickly. See attached model in R2022b. ...

alrededor de 3 años hace | 0

Respondida
Failed to evaluate mask initialization commands.
This is the first three lines of code in the initialization function of that "Image from File" block. The variable "ImageValue...

alrededor de 3 años hace | 0

Respondida
How to set the 'Model name' in Model Reference via MATLAB command?
get_param(Block,'ModelName') get_param(Block,'ModelFile')

alrededor de 3 años hace | 0

| aceptada

Respondida
How to implement a look up table in simulink which can accept variable SIZE data as inputs
You must be using the "Lookup Table Dynanic" block for this. Accordig to its doc, it does not support 'variable-size signals". S...

alrededor de 3 años hace | 2

Respondida
Custom Library Blocks get reset to default value every time the model is closed.
This is caused by improper mask or improper usage of a custom library block. The proper way is to specify the Constant block va...

alrededor de 3 años hace | 0

Respondida
Variation between data during simulation and that stored for use in second simulation
I think I understand your question. I will use this diagram from https://en.wikipedia.org/wiki/Control_theory to explain. You...

alrededor de 3 años hace | 0

Respondida
How to simulate a Simulink model through a .m file, that is executed by a GUI
It is a source workspace issue. Based on your code, Kennfeldabhaengigkeit.m is a script. "When I execute the m.file by itself"...

alrededor de 3 años hace | 0

Respondida
Create an assembly matrix with ones placed from values in elemental matrix FEM
%% element = [1 2 4; 1 4 3]; N_Row=numel(element); N_Col=max(element(:)); Row_index=(1:N_Row)'; Col_index=element'; Col_in...

alrededor de 3 años hace | 0

Respondida
Using Simulink block parameters in a Matlab function
If this value is something you type in at the dialog of the Simulink block, then Specify it as 'MyValue' at the dialog, then I...

alrededor de 3 años hace | 0

Respondida
Algebraic Loop Caused by MATLAB Function Block. How to Resolve Without Time Delay?
If you suspect your MATLAB Function block or your MEX function caused the algebraic loop, consider setting this "Direct Feedthro...

alrededor de 3 años hace | 1

| aceptada

Respondida
Readtable (file not getting detected in the directory)
It is not robust to change the file name or create new files in the script and expect to access it right away in the script. in...

alrededor de 3 años hace | 0

Respondida
Matrix index summation with repeated index
%% A = [1;2;3;4]; A_add = [1;2;3]; i = [1;2;1]; A=A+accumarray(i,A_add,size(A))

alrededor de 3 años hace | 2

| aceptada

Respondida
Save matrices (present within a cell) into a single matrix
C={rand(2,3), rand(4,3),rand(5,3)}; D=cell2mat(C')

alrededor de 3 años hace | 0

| aceptada

Respondida
Switch case structure, I needed to show all units in this excercise
use if-elseif, When you have logical comparison in the case statement, it results in true or false (1 or 0 in value). The resu...

alrededor de 3 años hace | 0

Respondida
Error in using variable from MATLAB workspace to Simulink?
The error message has explained the problem. Maybe you are not familar with the usage. Double click the "From Workspace" block, ...

alrededor de 3 años hace | 0

Respondida
Why simulink uses -1 for inherting sampletime for blocks ?
It is just a good way to distinguish from all the other cases. See this full description of sample time Specify Sample Time

alrededor de 3 años hace | 0

Respondida
How to pad zero in string using sprintf
a={'1010' '111' '010' '10' '10111'}; b=char(a) b(b==' ')='0'

alrededor de 3 años hace | 1

Respondida
Multiple Simulink models in one system
You can construct Simulink model and physical system model seamlessly in Simuink. See This example There is PS to Simulink and ...

alrededor de 3 años hace | 0

| aceptada

Respondida
Simulink Signals Data Types
The best approach is to Create Duplicate Inport Blocks. https://www.mathworks.com/help/simulink/slref/inport.html To do it by...

alrededor de 3 años hace | 1

| aceptada

Cargar más