Answered
Unable to find an installed compiler
What do you have when you type in windows command mex -setup What is your OS? 32 bit or 64 bit

13 years ago | 0

| accepted

Answered
how to use non-positive or fractional integer as power in matlab
Example a=2^(1/2) b=4^(-4.5)

13 years ago | 0

| accepted

Answered
matrix operation make matrix
a=repmat(1:8,8,[]); b=a' a=a(:)' b=b(:)'

13 years ago | 0

| accepted

Answered
Open window in maximized size.
figure, set(gcf,'position',get(0,'ScreenSize'));

13 years ago | 0

| accepted

Answered
hii...i want to save my images as abc1.pgm, abc2.pgm, abc3.pgm...abc5.pgm
for k=1:3 filename=sprintf('E:\\prajube\\abc1%d.pgm',k) imwrite(image1{k},filename); end

13 years ago | 0

| accepted

Answered
How to write e in matlab
You can check if it's correct or not, in windows command type t=10 T=5 a = 100*exp(-2*t/T)*(sin(2*pi*t/T).^2)

13 years ago | 0

Answered
counting frequency of strings
x=strvcat('USA','ALG','FRA','ALG','FRA'); y=unique(x,'rows'); for k=1:size(y,1) freq(k)=sum(ismember(x,y(k,:),'rows'));...

13 years ago | 3

Answered
simulink and m file connection
In simulink model use *from workspace* block to read data from workspace and *to workspace* block to export data to workspace

13 years ago | 1

Answered
what is the meaning of this instruction?
x=[1 2;3 4;5 6] size(x) ans = 3 2 % 3 lines and 2 columns ones(size(x)) % create 3x2 array with 1 ans =...

13 years ago | 0

| accepted

Answered
delete rows with a special number
A(any(A==99,2),:)=[]

13 years ago | 1

| accepted

Answered
Simulink - Data Importing Problem
Use a from <http://www.mathworks.com/help/simulink/slref/fromworkspace.html workspace block>

13 years ago | 0

| accepted

Answered
How to determine if elements in a column are negative
any(A(:,3)<0) % find if any of column 3 of matrix A is negative

13 years ago | 3

| accepted

Answered
generating matlab code to reproduce simulink model
Use # new_system # open_system # add_block # add_line # set_param Look at this <http://www.mathworks.com/matlabcentra...

13 years ago | 0

| accepted

Answered
matrix operation resize matrix
A=rand(36,44) % example A(36+1:48,44+1:48)=0

13 years ago | 0

| accepted

Answered
how to compare 3 matrix
a=A(:,1:2) D=a(ismember(a,B(:,1:2),'rows') & ismember(a,C(:,1:2),'rows') ,:)

13 years ago | 0

| accepted

Answered
Plotting columns of differend 3-D matrices
for k=1:size(A,3) plot(A(:,:,k),B(:,:,k)) hold all end

13 years ago | 0

Answered
how to write in the graph
You can use <http://www.mathworks.com/help/matlab/ref/legend.html legend>

13 years ago | 0

| accepted

Answered
how do we read a .dat file in simulink so that it can be used as an input in a block diagram?
Load your data to Workspace, using textscan or dlmread and use <http://www.mathworks.com/help/simulink/slref/fromworkspace.html ...

13 years ago | 0

Answered
How do I circularly shift the alphabet without using circshift function?
shiftn=12 s='A':'Z'; str='I HATE MATLAB' idx=regexp(str,'[A-Z]') for k=idx a=strfind(s,str(k)) str(k)=s(mod(a+sh...

13 years ago | 0

Answered
How do I circularly shift the alphabet without using circshift function?
s='A':'Z'; s=[s(end-2:end) s(1:end-3)]

13 years ago | 0

Answered
How do I limit the repmat?
x=[2,4,6,3] y=repmat(x,1,2) % Duplicate horizontally twice y=y(1:6)

13 years ago | 0

Answered
In a symbolic expression, how can I extract all terms that have a common specific variable?
Use <http://www.mathworks.com/help/symbolic/collect.html collect> function collect(dxdt,x1) and <http://www.mathworks.co...

13 years ago | 0

| accepted

Answered
How to output a figure from a function?
function curv(x,y,z) figure(1);plot(x,y) figure(2);plot(y,z)

13 years ago | 0

Answered
Automaticly generate plots and different legend
t=0:0.01:100 speed1=cos(0.01*t); speed2=sin(0.05*t); speed3=cos(0.1*t); y=[speed1;speed2;speed3]; plot(t',y'); for k=1:s...

13 years ago | 5

| accepted

Answered
Get averages for different ranges
for k=1:6 P{k}=mean(data((k-1)*15+1:k*15)) end

13 years ago | 0

| accepted

Answered
Wrong way to index: Index exceeds matrix dimensions
Check this size(Y) max(Z) What did you get?

13 years ago | 0

Answered
Comment a block or subsystem in simulink
put it in <http://www.mathworks.com/help/simulink/ug/triggered-subsystems.html triggered subsystem> without triggering it or <ht...

13 years ago | 0

Answered
Rectangular Function implementation in Matlab
rect=@(x,a) ones(1,numel(x)).*(abs(x)<a/2) % a is the width of the pulse x=-10:0.001:10 y=rect(x,2) plot(x,y)

13 years ago | 4

| accepted

Answered
How to delete rows of a matrix when one column contains a dummy variable
idx=Data(:,6)~=1 newdata=Data(idx,:)

13 years ago | 0

| accepted

Answered
How to reshape a vector in a particular way
b=reshape(a,2,[])'

13 years ago | 3

| accepted

Load more