Réponse apportée
Using num2str inside the for loop
You got only 5 because you haven't used f as an array. Here the right code: firstDay = 1; lastDay = 5; for i=...

environ 11 ans il y a | 1

Réponse apportée
Indexing a 3D array with a vector
try this: x = [[1,2,3,4];[5,6,7,8];[2,8,9,7]]; y = [[1,3,5,3];[7,9,0,2];[2,4,5,4]]; z = [[2,4,6,6];[3,5,7,1]...

environ 11 ans il y a | 0

Réponse apportée
use any/all test with while loop in range 0:1:10
Hi, while loops until the condition is true, so you to change looping condition: grades = input('Please enter the...

environ 11 ans il y a | 0

| A accepté

Réponse apportée
fmincon is giving error
fmincon must be used for monoobjective optimization so it expect a scalar value instead in your code he gets four different valu...

environ 11 ans il y a | 1

Réponse apportée
print acsii characters in tabular format using char
try this: function mychar(y) if y > 129 disp('Please enter less than 129.') else x = char(uint8(y...

environ 11 ans il y a | 0

| A accepté

Question


How to remove transient effect in the beginning of the filtered signal?
Hi all, I have to filter a signal with a low pass filter but the filtered data has strong spikes at its beginning and its en...

plus de 11 ans il y a | 2 réponses | 1

2

réponses

Réponse apportée
How do I find non zero cells in a cell array?
Here an axample: testcell={0,1,1,0,1}; matcell=cell2mat(testcell); find(matcell==0)

plus de 11 ans il y a | 1

| A accepté

Question


Concatenation of arrays of structure
Hi all I have to concatenate the field of an array of structure. Here a simple example: a=struct('a',[]); a(1).a...

plus de 11 ans il y a | 3 réponses | 0

3

réponses

Question


Problems in reading XLSX file
Hi all, I have some problems in reading xlsx files. I use the readtable command because I can get a structure where the fiel...

plus de 11 ans il y a | 1 réponse | 0

0

réponse

Réponse apportée
How to get a vector from an excel sheet
xlsread can read a specific range so in case your range is a column you get a column array.

plus de 11 ans il y a | 0

Question


How getting coordinates of geagraphical locations?
Hi, I have the following struct array. data=struct('Position',[],'Value',[]) data(1).Position='London'; data(...

plus de 11 ans il y a | 3 réponses | 1

3

réponses

Question


How to vectorize the following code
Hi all, I have the following code, is there any way to vectorize it? RMH(1).D=rand(20,4); RMH(2).D=rand(20,4); ...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


how to generate custom bin edges with internal.stats.histbins?
Hi all, I've used the distribution fitting toolbox through the GUI to get the probability distribution. To automate the proc...

plus de 11 ans il y a | 1 réponse | 0

0

réponse

Question


error with using filter
Hi all, I have to filter few signals and I wrote the following code: Fpass = 40; % Passband Frequency Fstop =...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Réponse apportée
Simscape no solver block connected error
Each part must be connected to a solver block. If you have the solver error, probably you haven't rightly connected the eletron...

plus de 11 ans il y a | 0

Réponse apportée
How to save workspace except for one structure field?
Probably there is a shorter way to do it, but this method works: a=1; b=1; c=1; vars=who; p=find(isme...

plus de 11 ans il y a | 0

Question


How to apply OR operation to a matrix?
Hi folk, I need to apply the OR operation to the column of a matrix. Here an example: a=[0 0 1; 0 1 1]; orMa...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


strfind: how to set a cell for the pattern?
Hi all, I need to set a cell as pattern for strfind without using a for. Here an example a={'1','2','3'}; b={'1','2'}...

plus de 11 ans il y a | 5 réponses | 0

5

réponses

Question


subplots destroys the axis properties
Hi all, I have to create a figure with a specific layout of subplots, but when I call the subplot for the second time all th...

plus de 11 ans il y a | 2 réponses | 0

2

réponses

Réponse apportée
How can an engine model be simulated in the "crank angle - domain" instead of the "time - domain" in Simulink?
I don't know if it works, but you can try by parametrizing the time step and the simulation time in function of the engine speed...

plus de 11 ans il y a | 0

Réponse apportée
How to transform struc/field data to single matrix with specific columns
What about using <http://www.mathworks.it/it/help/matlab/ref/struct2cell.html struct2cell?>

plus de 11 ans il y a | 0

Réponse apportée
cycling through both linestyle and linecolor
you can do it by setting the line order style. Here an example: set(gca,'linestyleorder',{'-',':','-.','--','*','+'},... ...

plus de 11 ans il y a | 0

Question


Plot a map with a specific scale
Hi all, I have a long gps track and I need to make several maps of the track. Unfortunately all the maps must have a specifi...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Réponse apportée
my animation of four bar mechanism is not moving it is a still image ,what could be the possible reasons ? also why are the cg's out of the rod as shown in image ?
Check the position CoG CSs. Regarding the movement of the 4 bar linkage, have you plotted the data from the Joint sensor? What i...

plus de 11 ans il y a | 0

| A accepté

Réponse apportée
wat does the following error mean?
Hi, you can solve this problem by making the CSs coincident of the bodies linked with the revolute joint.

plus de 11 ans il y a | 0

| A accepté

Question


Programmatically generation of a PDF file report of some calculations?
Hi all, I need to get an automatic report of some calculations on a PDF file. In the PDF there should some text and some pict...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


how generating evenly spaced vectors with overlap?
Hi all, I need to generate evenly spaced vectors with overlap. How can I do it? Here an example: Input: [0 5 10 15 20]; ...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Question


Why is the estimated distribution truncanted?
Hi all, I'm trying to fit some data with a distribution. I have used a Weibull distribution to fit the data and I used the d...

plus de 11 ans il y a | 1 réponse | 0

1

réponse

Réponse apportée
subtraction and multiplication of two arrays
As you did: A=0.3*(t-T) but in your example t and T are equal, so the result is an array full of zeros

plus de 11 ans il y a | 0

Question


inverse function of zscore?
Hi all, is there any inverse function of zscore?

plus de 11 ans il y a | 2 réponses | 0

2

réponses

Charger plus