Beantwortet
Possible to export signal names from Simulink mux output to matlab workspace?
I would recommend that you replace all those "Mux" blocks with "Bus Creator" blocks. Then, follow this example: open_system(...

mehr als 7 Jahre vor | 2

| akzeptiert

Beantwortet
How I can Change the input and output data type of matlab function block? I want to change it to Matrix. Plz help me I am using matlab 2016a.
Press Ctrl+H at your model to open the Model Explorer, on the left, find and select the MATLAB Function block, on the right, you...

mehr als 7 Jahre vor | 0

Beantwortet
Simulink Settings for Blocks
One way I can think of (or actually I am doing it in this way) is that you modify the built-in Simulink library to reflect these...

mehr als 7 Jahre vor | 0

Beantwortet
Using Regex to get strings with whitespace within them.
white space in regular expression is \s

mehr als 7 Jahre vor | 0

Beantwortet
Creating text file with columns of data
In this case, you can use fprintf(fileID,'%f %f\n',data')

mehr als 7 Jahre vor | 1

Beantwortet
How do i plot data from a structure? and extract data from a structure?
[SpeedA.distanceA_km, SpeedA.SpeedA_kmph]

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
How can I read Simulink comments (annotations) from the Matlab command window?
What do you really mean by "read"? vdp; a=find_system('vdp','FindAll','On','type','annotation'); b=get(a,'Name') celldisp(...

mehr als 7 Jahre vor | 1

Beantwortet
How To Use Workspace Parameters in Simulink
You already did! In the most common case, you define a variable "k" in base workspace (you refer as editor workspace), specify t...

mehr als 7 Jahre vor | 1

Beantwortet
Obtaining signal units post compilation
CompiledPortUnits But according to R2018b document, Simulink passes units through the following blocks that do not change dat...

mehr als 7 Jahre vor | 1

| akzeptiert

Beantwortet
Plotting customized figures using Simulink
Open the model, click menu File, Model Properties, Model Properties Click the Callbacks tab, Select "StopFcn*" on the left, you...

mehr als 7 Jahre vor | 0

| akzeptiert

Beantwortet
How to set fixed values to Simulink parameters instead of variable?
Not following your point. If you want the gain to be a, put in a. If you want the gain to be 2, put in 2. You can add 'a' to th...

mehr als 7 Jahre vor | 1

| akzeptiert

Beantwortet
AUTOSAR support package free of charge?
Yes. Install AUTOSAR support package

mehr als 7 Jahre vor | 1

| akzeptiert

Beantwortet
How to get a csv file excluding first row and last column to run through if statement?
Let's fix the biggest issue first. Should be numrows = size(data,1); thisrow = data(rownum,:);

mehr als 7 Jahre vor | 0

Beantwortet
Reading data from excel
I would suggest reading the whole Excel sheet and then process the data in MATLAB according to your logic. xlsread() is more tim...

mehr als 7 Jahre vor | 0

Beantwortet
getting the mean EXCEPT zero entries
M=zeros(5); M(randi(25,10,1))=1:10; M(M==0)=nan; mean(M,'omitnan')

fast 8 Jahre vor | 1

Beantwortet
How to round a large array to the nearest factor of 0.0064
x-rem(x,0.0064) It is the floor() effect. If you want "round" effect, you might need a few lines more. This example assume...

fast 8 Jahre vor | 0

Beantwortet
How to build a graph from two graphs at certain intervals
From the diagram, it seems that it can be achieved by using a Switch block. Compare y1 with zero using a Relational Operator blo...

fast 8 Jahre vor | 0

Beantwortet
bdroot causes problems in MATLAB 2017b
Something may have changed from R2015b to R2017b but I would say that your usage of bdroot() for this purpose is not robust. "Si...

fast 8 Jahre vor | 0

| akzeptiert

Beantwortet
Simulink buffer: How do I fix the error "All sample times must be discrete. No continuous or constant sample times are allowed."
Try feeding the Buffer block with a Constant block. Changing the sample time of the Constant block from "inf" to 0.1 (for exampl...

fast 8 Jahre vor | 1

| akzeptiert

Beantwortet
How to access Data dictionary data in matlab function block simulink
Add a "data" to the MATLAB Function block and specify its scope as "Parameter" (rather than input or output). Have "data" define...

fast 8 Jahre vor | 2

Beantwortet
Providing Maximum Value as Initial Value for Single Precision Signal Causes Error due to Quantization
I had similar issues with this. I have requested the Mathworks to do an enhancement but have not seen it in place yet. The p...

fast 8 Jahre vor | 0

| akzeptiert

Beantwortet
how do i create an array of e^x
try exp(x)

fast 8 Jahre vor | 0

Beantwortet
MATLAB App Designer <--> Simulink
Use the build-in model 'f14' as an example, if you drag in a Knob block and connect it to the Gain block Zw, the changing of the...

fast 8 Jahre vor | 1

| akzeptiert

Beantwortet
Reference model vs subsystem
The official document is here. It gives comparison between Subsystems, libraries and model referencing. It also provided some Ge...

fast 8 Jahre vor | 1

Beantwortet
Gathering data from a for loop
something like this: t=0:1200:43200; M=zeros(size(t)); for k=1:numel(t) M(k)=M0 + nn*t(k); end plot(t,M)...

fast 8 Jahre vor | 0

Beantwortet
How to split binary and convert to decimal ?
aaa = ['0000001101001011';'0000011010001010';'0000100100111100']; bbb=[aaa(:,1:8); aaa(:,9:16)]; bbb=reshape(bin2dec(bbb...

fast 8 Jahre vor | 0

| akzeptiert

Beantwortet
Setting Simulink parameter values from script
4. Why has it stopped running properly just because I moved my code into the gui script? When you run "t_step = Simulink.Para...

fast 8 Jahre vor | 0

| akzeptiert

Beantwortet
Access to memory store via global in matlab function
I think the warning message is clear. If you want to ignore this, go to Simulation, Model Configuration Parameters, Diagnostics,...

fast 8 Jahre vor | 0

Beantwortet
Is there a way to index a variable to a certain position in the array
Depending on the value of n, you want to loop through the different dimension of matrix. I think you can utilize the function...

fast 8 Jahre vor | 2

| akzeptiert

Beantwortet
switch in a loop while changing variable name according to iter index
construct your data as 60xn matrix Data(1,:)=[mean_RSI_high,mean_RSI_low,mean_NeNMF_high,mean_NeNMF_low]; ... Data(60...

fast 8 Jahre vor | 1

| akzeptiert

Mehr laden