Beantwortet
Error: Inner matrix dimensions must agree.
<http://www.mathworks.com/matlabcentral/answers/2210-error-correction-inner-matrix-dimensions-must-be-same-how-to-correct Error ...

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
Left digits
n=num2str(1234) n1=str2num(n(1:end-1))

etwa 15 Jahre vor | 0

Beantwortet
How do I make an if, elseif, else statement?
The correct way to do the conditions is this: if 0<x & x<10 y=4*x elseif 10<x & x<40 y=10*x else ...

etwa 15 Jahre vor | 2

| akzeptiert

Beantwortet
Help with execution-programs
<http://www.mathworks.com/products/demos/compiler/deploytool/index.html Maybe this will help you>

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
Selecting part of a string
surely not the best way to do it but here is my way v=['a.txt' 'b.txt' 'c.txt' 'd.txt'] cell2mat(arrayfun(@(x)strtok(x,'.tx...

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
Karhunen-Loeve Transform
You can get some examples on the <http://www.mathworks.com/matlabcentral/fileexchange/ FEX>, just search for them or other ways ...

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
Curl in Polar Coordinates
doc cart2pol

etwa 15 Jahre vor | 0

Beantwortet
Calling a variable from a variable
assignin('base',char(V(2)),3000)

etwa 15 Jahre vor | 0

Beantwortet
GUI handles problem... throughout code it vanishes!?
When you do handles.LAIi=LAIi; you must also update the handles structure guidata(hObject, handles);

etwa 15 Jahre vor | 0

Beantwortet
Making a NxN matrix.
We don't make homeworks, we only help with answers to specific questions and if we are kind enough we might give some tips: d...

etwa 15 Jahre vor | 1

Beantwortet
Changing the atan function so that it ranges from 0 to 2*pi
The <http://en.wikipedia.org/wiki/Atan2 Wikipedia> got all explained, you just need to do the code, it's very simple. functio...

etwa 15 Jahre vor | 1

Beantwortet
trying to accounting the number of zeros in random script
a=randint(1000,1); numel(a(a==0)) or sum(a==0) or numel(a)-nnz(a)

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
Other uses of the unique function
unique(a,'rows')

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
putting a text in a white space on a plot
What you are asking for isn't easy to implement but can be done, what the code has to do is the search for one empty space big e...

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
put a space in a text
s=['this is ' num2str(1) ' my cat'] strcat ignores trailing ASCII white space characters and omits all such characters from t...

etwa 15 Jahre vor | 2

| akzeptiert

Beantwortet
Finding If a sub-array (1d) is there in a 2d array
For the example provided array2D = [1 2 3; 4 5 6; 6 7 8] v1= [4 5 6] [tf,loc]=intersect(array2D,v1,'rows') loc gi...

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
get the name of variable
No variable was assigned to x, the code x=myData; just copies the contents of the variable myData to the variable x, you are the...

etwa 15 Jahre vor | 0

Beantwortet
How can comet3 be modified to have a disappearing tail?
edit comet3 change all the erasemodes to background, it's in the line functions, example: 'erase','none' -> 'erase','ba...

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
set and get on two gui
The error is in the line: mainGUIhandle = main; In that context MATLAB doesn't know what the variable main is because i...

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
strcat including space (i.e, ' ')
c=[a ' ' b] strcat ignores trailing ASCII white space characters and omits all such characters from the output. White space c...

etwa 15 Jahre vor | 5

Beantwortet
Automated concatenation of variables into matrix then separation of matrix into variables containing original variable names
%without any verification of the format of all variables a=[1 2 3] b=[4 5 6] lvar=who; c=cell2mat(cellfun(@eval,lv...

etwa 15 Jahre vor | 0

Beantwortet
command doesn't work from inside a loop in a script but works fine in the command window
Do you have one m file or function called z.m? having one can cause the error: _Undefined function or method 'z' for input ar...

etwa 15 Jahre vor | 0

Beantwortet
Creating simulink block and hidding the code
http://www.mathworks.de/matlabcentral/answers/552-protecting-a-simulink-block-with-a-password

etwa 15 Jahre vor | 0

Beantwortet
save
save(['C:\' s],s) %save the mat file with the same name as the variable

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
naming variables
s='myData' Var1=[1 2 3] assignin('base',s,Var1)

etwa 15 Jahre vor | 0

| akzeptiert

Beantwortet
Save
To save all the variables that are inside the function to the file MyFunVariables.mat in the current directory do this save('...

etwa 15 Jahre vor | 0

Beantwortet
What is your unusual use of MATLAB?
I used MATLAB to see how bad was the damage on my phone touch screen and to minimize the error, got the alignment values from th...

etwa 15 Jahre vor | 3

Beantwortet
Why do I receive an error when I run this code?
Bad use of the poly2sym function, you give a string for the first argument but the function expects one array. Also the z shoul...

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
How can I convert num and den to strings?
nums=num2str(num{:}); dens=num2str(den{:});

etwa 15 Jahre vor | 1

| akzeptiert

Beantwortet
what's the time of pause(1)
*pause(n) pauses execution for n seconds before continuing*, where n can be any nonnegative real number. The resolution of the c...

etwa 15 Jahre vor | 1

Mehr laden