Answered
How to generate a line at the bottom of square and then movement of line from bottom to top side of square with a constant speed?
x=[0 10] figure; plot([0 10 10 0 0],[0 0 10 10 0],'r') xlim([0 10]) ylim([0 10]) hold on; for k=0:0.01:10 h=plot(x,...

13 years ago | 1

| accepted

Answered
Compute the infinite sum of pi/4 up to 5 correct decimals.
tol = 10^(-5) d=1; sn=0; % n=0; while d>tol sn = sn+(-1)^n/(2*n+1); n=n+1; ...

13 years ago | 0

| accepted

Answered
how to read complicated text file
Use <http://www.mathworks.com/help/matlab/ref/fgetl.html fgetl> to read your file then parse the result fid = fopen('file...

13 years ago | 0

Answered
what is the use of .mat file?
A mat file is a Matlab binary file with extension .mat. For example: A=[1 2;3 4]; B=10; C='word' save filename A B C ...

13 years ago | 0

Answered
How to plot selective data?
If A is your matrix plot(A(:,1),A(:,2)) %or plot(A(:,1),A(:,3)) If your data are in a text file you can read...

13 years ago | 0

Answered
Subscripted assignment dimension mismatch.
Maybe you should use cell array |ff{i,j}| instead of |ff(i,j)|

13 years ago | 0

Answered
What do the x- and y-axes of this pulse oximeter signal represent?
You can read about <http://en.wikipedia.org/wiki/Pulse_oximetry Pulse_oximetry> the range of y depends on your Pulse_oximetr...

13 years ago | 0

| accepted

Answered
Create An Array That Contains All the Values of F(x)? Help!
x=-5:5 y=(x<1).*x+(x>=1).*x.^2

13 years ago | 0

Answered
How to remove multiple elements from an array?
a=1:50 a(~mod(a,3)|~mod(a,4)|~mod(a,5))=[]

13 years ago | 2

| accepted

Answered
How do I create a vector combinations in pairs
a=fliplr(fullfact([4 4])) a(~diff(a')',:)=[] or [ii,jj]=ndgrid(1:4,1:4); a=[jj(:) ii(:)]; a(~(a(:,1)-a(:,2)),:)=[]...

13 years ago | 1

| accepted

Answered
Populate Array with duplicate variables
x = [1,2,3,4,5,6,4,2,7,5,3] y=[x;x] y=y(:)' %Or n=2 x=repmat(x,n,1); y=y(:)'

13 years ago | 0

| accepted

Answered
How to generate say 100 points randomly in a square or rectangle?
x=rand(1,100)*5 y=rand(1,100)*5 scatter(x,y) or a=rand(2,100)*5 scatter(a(1,:),a(2,:))

13 years ago | 3

| accepted

Answered
How to forbid opening of two copies of Matlab? Is it possible?
Why to click a second time on your Matlab icone?, maybe it's in your desktop toolbar. I advise to unpin Matlab shortcut from yo...

13 years ago | 0

Answered
ask to an user a *.txt file
file=input('file name','s'); tamiz=importdata([file '.txt']);

13 years ago | 0

Answered
How to re-use parameter from other script?
make your script a function function re=pdemeshpop_final_re_sens

13 years ago | 1

| accepted

Answered
how can i do this summation
s=zeros(1,88); for k=1:88 for a=0:n+1 for b=0:m+1 s(k)=s(k)+v(a+1,b+1)^(k+1)-v(a+1,b+1)^k ...

13 years ago | 1

| accepted

Answered
how can i do this summation
m=100 out=sum(0:m)

13 years ago | 0

Answered
how can stopping run matlab program when i am need this stop
ctrl+c

13 years ago | 1

| accepted

Answered
Integration in MATLAB with symbolic integration limits
syms x y=x^2 f=int(y,1,x) % integration between 1 and x

13 years ago | 1

| accepted

Answered
Find: Simulink callbacks from where?
Right click on your model, then choose model properties, you will find callbacks, look for Init or other callbacks

13 years ago | 0

Answered
Executable or Matlab App from Simulink+GUI
<http://www.mathworks.com/support/solutions/en/data/1-196RW/> you will need a <http://www.mathworks.com/products/simulink-co...

13 years ago | 0

Answered
Delimiter at particular column
Read all your data with delimiter then recreate the first column. If A{1}={'03';'03';'03'} A{2}={'30';'30';'30'} A{3}=...

13 years ago | 0

Answered
Using ismember to seek out pairs
A = [1 2 5; 4 5 7; 7 8 9; 4 7 10; 6 7 2] B = [2 3; 4 9; 7 9; 7 6] for k=1:size(A,1) out(k)=any(all(ismember(B,A(k,:)),...

13 years ago | 0

| accepted

Answered
How to change code to user input parameter
Use input help input

13 years ago | 0

Answered
How to store a pixel location in an array?
a=[1 2 3;4 5 6;7 8 9] % your array [ii,jj]=find(a>4) % In this example the criteria is a>4, ii and jj are the coordinate coo...

13 years ago | 1

Answered
how to save data with name changing by number
use save(outputString)

13 years ago | 0

Answered
Simple function to transform matrix?
*Edit* v=rand(622080,5);% your array out=reshape(v',720,[])';

13 years ago | 0

| accepted

Answered
Real Roots of a Polynomial
%P=x^4+7*x^3-8*x^2+5*x+2 p=[1 7 -8 5 2] result=roots(p)

13 years ago | 1

Answered
display values in particular order
use sort function help sort EXAMPLE v=[2 4 1 8 0 12] out=sort(v)

13 years ago | 0

| accepted

Answered
Exporting figures to eps format issue
<http://www.mathworks.com/matlabcentral/fileexchange/23629-exportfig export_fig>

13 years ago | 0

Load more