Answered
how to comment a mathmatical expression
I didn't download your file, but if you want to display something like 'cut value must be between -4 and 4' you can si...

11 years ago | 0

Answered
Enforcing a rule in a symbolic expression
I suppose you want to solve the equation? You can give additional arguments. In this case, I think, you must use strings: ...

11 years ago | 0

| accepted

Answered
plotting multiple variables in a listbox
You only plot the last Parameter, you need to change the line plot(Data(:,2),Parameter(:,k)); to plot(Data(:,2),Pa...

11 years ago | 0

Answered
Using values from an array as titles in generated figures
var_name = ['VAR1, VAR2, VAR3, VAR4']; I think you rather want it as a cell: var_name = {'VAR1', 'VAR2', 'VAR3', 'VAR...

11 years ago | 0

Answered
Empty system, 1 equation 1 unknow with solve
- What is the value of S1, Gamma, R, Temp, Pin and mdot_1? It will strongly depend on these values if there is a solution. -...

11 years ago | 0

Answered
a Line to plot by using handles ?
_Of course i could use gca / get(...,'children') / x = get(children,'xdata') to replot, but is there anyway to add the new Data ...

11 years ago | 0

| accepted

Answered
How to detect repeated values between rows?
You can use the diff function: if any(sum(abs(diff(a,1)),2)==0) msgbox('hello') end

11 years ago | 1

| accepted

Answered
How to select multiple elements from cell containing multiple double's
cellfun(@(x) x(1,1),var)

11 years ago | 0

| accepted

Answered
How can I merge Excel files into only one file in Matlab?
files=dir('input*.csv'); output='out.csv'; fidout=fopen(output,'w'); for cnt=files' fidin=fopen(cnt.name); ...

11 years ago | 1

Answered
How can i append my csv file during looping?
I guess you don't want to append something to the csv file but to append something at your z,y,x variables, right? Also, I suppo...

11 years ago | 0

Answered
Indexing to subtract sections of an array
Let's bring it down to some more handsome numbers, say a row vector of 17 and you want to have blocks of three. A=rand(1,1...

11 years ago | 0

Answered
Vectorization with a loop and repmat
That sounds like a nice cody task ;-) I'm sure there are dozens of solution, so my suggestion is: m=k+mod(bsxfun(@(x,y) y+...

11 years ago | 1

| accepted

Answered
how to feel an array with 3 numbers randomly
Do I understand you correctly? In case of the 10 values array, you'd like to have e.g. A=[90 120 105 105 120 90 90 90 120 105...

11 years ago | 1

| accepted

Answered
loop and save problem
I don't know the context of your question, but I'm pretty sure that a structure is not the best solution for that. Also, the nam...

11 years ago | 0

Answered
Plot magnitude on y-axis and time on x-axis read from an excel file
Please try this: [num,txt]=xlsread('test.xlsx'); figure dates=datestr(datenum(txt(2:end,end-1),'mm.dd.yyyy')+num(:,e...

11 years ago | 0

Answered
Matlab Extracting X and Y coordinates??
Some quick and dirty method is the variable editor. Double click on your x/y variables in the Workspace window and you will get ...

11 years ago | 0

Answered
How to shuffle some arrays of a matrix?
x=rand(1,6); [~,y]=sort(x); a(y) If a is always just 1:6, you can directly use y instead.

11 years ago | 0

Answered
How to find coordiates of the LAST point of the aray which has been plotted?
So I believe you know the position inside the axis you want to focus, right? Let's say you've plotted something between x=100:10...

11 years ago | 0

Answered
Selective plotting from .csv file
Will the design number always be equal to the length? Or might Design163 correspond to a length of 250 mm? If the numbers are...

11 years ago | 0

| accepted

Answered
Import multiple text file with one header
files=dir('test*.txt'); output='data.txt'; fidout=fopen(output,'w'); for cnt=1:length(files) fprintf(fidout,'%s\n...

11 years ago | 0

Answered
How do I vectorize a sum involving an anonymous function?
So you have a matrix g, right? Then, you don't need to sum by hand but just multiply g*A. Such as >> x=(1:4)'; >> k=0:5;...

11 years ago | 0

Answered
Arrows of the same length in a quiver plot
Scale is not the right parameter for your purpose. You need to normalize the velocity: un=du./sqrt(du.^2+dw.^2); wn=dv./s...

11 years ago | 3

| accepted

Answered
Problem using textscan to read strings with space inbetween from CSV file
First, you have 4 columns (not 2), so the format is '%s%s%s%s'. Additionally, you have to set the delimiter (which seems to be c...

11 years ago | 0

| accepted

Answered
How can I select specific text files ?
Just specify your dir query: list_files2load = dir(fullfiles(directory1,'Mod1*00k.txt'));

11 years ago | 0

Answered
How to import multiple ascii files into an array using textscan or dlmread?
I think the dlmread version is fine here. No need to make things more complicated than necessary. Please change the following: ...

11 years ago | 0

| accepted

Answered
operands to the and && operators must be convertible to logical scalar
You have to use & instead of && (as Sara suggested) AND your last statement must be inside the find brackets. [ind_x,ind_y...

11 years ago | 0

| accepted

Answered
How to calculate integral of a function ?
The function is quad, quadl, or quadgk: fun = @(k) k.^2./exp(sqrt(k.^2 + m.^2)/T) + 1; quad(fun,kmin,kmax) ans = 9.0...

11 years ago | 1

| accepted

Answered
The problems when 'solve' using MAPLE
Well, I don't believe that there exists an explicit solution of this problem. So most likely, you have to be happy with a numeri...

11 years ago | 0

Answered
how can I do this fast addition and multiplication?
Savenewdata1=bsxfun(@plus,(R*X1_full),T)'; can replace your loop and should be faster than your solution.

11 years ago | 0

| accepted

Answered
random generation and ploting its pdf
n=randi(101,1000,1)-1; hist(n,101) m=mean(n),s=std(n)

11 years ago | 0

| accepted

Load more