https://sites.google.com/site/kolukulasivasrinivas/

Professional Interests: Mathematical Computing

Answered

how can i do image processing and stitching

Check the below demo code which stitches (joins) all the RGB images given inbuit in matlab tool boxes. You may take your own dir...

how can i do image processing and stitching

Check the below demo code which stitches (joins) all the RGB images given inbuit in matlab tool boxes. You may take your own dir...

1 hour ago | 0

Answered

find in cell array

A={[1,2,3,4,5],[1,3],[1],[1,3,4,5,6,7,89,0],[1,3],[1,3,4,5],[4,6]}; N = cellfun(@length,A) ; A(N==2) = []

find in cell array

A={[1,2,3,4,5],[1,3],[1],[1,3,4,5,6,7,89,0],[1,3],[1,3,4,5],[4,6]}; N = cellfun(@length,A) ; A(N==2) = []

1 hour ago | 0

Answered

How to draw and connect three points

x = rand(1,3) ; y = rand(1,3) ; plot(x,y) ; n = 1:3 ; text(x,y,num2str(n'))

How to draw and connect three points

x = rand(1,3) ; y = rand(1,3) ; plot(x,y) ; n = 1:3 ; text(x,y,num2str(n'))

17 hours ago | 0

Answered

how to find intersection point of these graph??

Use this file exchange function: https://in.mathworks.com/matlabcentral/fileexchange/22441-curve-intersections?focused=5165138...

how to find intersection point of these graph??

Use this file exchange function: https://in.mathworks.com/matlabcentral/fileexchange/22441-curve-intersections?focused=5165138...

23 hours ago | 0

| accepted

Answered

How can I connect my connected-components?

I = imread('QQ20190319105427.png') ; I1 = rgb2gray(I) ; imshow(I) hold on [c,h] = contour(I1) ;

How can I connect my connected-components?

I = imread('QQ20190319105427.png') ; I1 = rgb2gray(I) ; imshow(I) hold on [c,h] = contour(I1) ;

1 day ago | 0

Answered

infinity in an inequality for input in a function?

x = 0:0.05:1 ; % x = linspace(0,1,100) ; y = 0:-0.05:1 ; % y = linspace(0,1,150) ; [X,Y] = meshgrid(x,y) ; mesh(X,Y)

infinity in an inequality for input in a function?

x = 0:0.05:1 ; % x = linspace(0,1,100) ; y = 0:-0.05:1 ; % y = linspace(0,1,150) ; [X,Y] = meshgrid(x,y) ; mesh(X,Y)

1 day ago | 0

Answered

Select groups of data with a specific size

Let x,y be your data points A = [1 1 1 1 2 2 2 3 3 3 3]'; for i = 1:max(X) idx = A==i ; if nnz(idx)<3 plo...

Select groups of data with a specific size

Let x,y be your data points A = [1 1 1 1 2 2 2 3 3 3 3]'; for i = 1:max(X) idx = A==i ; if nnz(idx)<3 plo...

1 day ago | 0

Answered

split a diagonal matrix

v = [2 1 4]; nx = length(v) ; M = zeros(nx,nx,nx) ; for i = 1:nx M(i,i,i) = v(i) ; end

split a diagonal matrix

v = [2 1 4]; nx = length(v) ; M = zeros(nx,nx,nx) ; for i = 1:nx M(i,i,i) = v(i) ; end

1 day ago | 1

| accepted

Answered

Using two colormaps on the same image (no subplots)

Refer here: https://in.mathworks.com/matlabcentral/answers/194554-how-can-i-use-and-display-two-different-colormaps-on-the-same-...

Using two colormaps on the same image (no subplots)

Refer here: https://in.mathworks.com/matlabcentral/answers/194554-how-can-i-use-and-display-two-different-colormaps-on-the-same-...

2 days ago | 0

Answered

Help! i'm new

Read about fprintf for i = 1:6 fprintf('Here we go the loop %d\n',i) end

Help! i'm new

Read about fprintf for i = 1:6 fprintf('Here we go the loop %d\n',i) end

2 days ago | 0

Answered

Unable to perform assignment because the indices on the left side are not compatible with the size of the right side.

function [images, labels, imageFiles] = readDataset(dirPath) imageFiles = ''; % Get a list of all files and folders in this fo...

Unable to perform assignment because the indices on the left side are not compatible with the size of the right side.

function [images, labels, imageFiles] = readDataset(dirPath) imageFiles = ''; % Get a list of all files and folders in this fo...

2 days ago | 0

Answered

what is causing this error?

Note that in matlab the indexing shoul dbe always a posittive integer or a logical. You are suing negative number, so error. ...

what is causing this error?

Note that in matlab the indexing shoul dbe always a posittive integer or a logical. You are suing negative number, so error. ...

2 days ago | 0

Answered

How to make overlaped 3 rectangle fill in color RGB (255/ make white)

R = [0 0 ; 1 0 ; 1 1 ; 0 1] ; figure hold on patch(R(:,1),R(:,2),'r') patch(R(:,1)+rand,R(:,2)+rand,'b') patch(R(:,1)+rand,...

How to make overlaped 3 rectangle fill in color RGB (255/ make white)

R = [0 0 ; 1 0 ; 1 1 ; 0 1] ; figure hold on patch(R(:,1),R(:,2),'r') patch(R(:,1)+rand,R(:,2)+rand,'b') patch(R(:,1)+rand,...

2 days ago | 0

Answered

plot a snake graph

Play around with this: x = 1:100 ; y = 1:100 ; ind1 = reshape(y,5,[])' ; y(ind1(1:2:end,:)) = -0.5 ; y(ind1(2:2:end,:)) =...

plot a snake graph

Play around with this: x = 1:100 ; y = 1:100 ; ind1 = reshape(y,5,[])' ; y(ind1(1:2:end,:)) = -0.5 ; y(ind1(2:2:end,:)) =...

2 days ago | 0

Answered

element mean of matrices

A = rand(5,5,7) ; % some random data for demo iwant = zeros(7,1) ; % initialize the required for i = 1:7 Ai = A(:,:,i...

element mean of matrices

A = rand(5,5,7) ; % some random data for demo iwant = zeros(7,1) ; % initialize the required for i = 1:7 Ai = A(:,:,i...

2 days ago | 0

Answered

save result in while loop

index_A=cell([],1); while (ibd <= max_it) i=i+1; index_A{i}= t ;% save what you want ; end index_A = cell2mat(i...

save result in while loop

index_A=cell([],1); while (ibd <= max_it) i=i+1; index_A{i}= t ;% save what you want ; end index_A = cell2mat(i...

2 days ago | 1

Answered

How to combine string and numbers before using xlswrite to export data into an Excel file?

cruise = {'SE_01', 'SE_01','SE_01'}' ; Longitude = [-126 -123 -121]' ; Latitude = [35 31 27]' ; Year = [2017 2017 2017]' ; M...

How to combine string and numbers before using xlswrite to export data into an Excel file?

cruise = {'SE_01', 'SE_01','SE_01'}' ; Longitude = [-126 -123 -121]' ; Latitude = [35 31 27]' ; Year = [2017 2017 2017]' ; M...

2 days ago | 0

| accepted

Answered

Find the interval of an envelope corresponding to a specific peak after peak detection

Let (x,y) be your data. [val,idx] = max(y) ; x_max = x(idx) ; y_max = y ; Read about max

Find the interval of an envelope corresponding to a specific peak after peak detection

Let (x,y) be your data. [val,idx] = max(y) ; x_max = x(idx) ; y_max = y ; Read about max

2 days ago | 0

Answered

Can I divide a linear array by a number which larger than its size ?

You interpolate your data into your desired size and then reshape. Read about interp1.

Can I divide a linear array by a number which larger than its size ?

You interpolate your data into your desired size and then reshape. Read about interp1.

4 days ago | 0

Answered

How can blur an image

I = imread('peppers.png') ; for i = 1:3 I(:,:,i) = uint8(conv2(I(:,:,i),ones(20)/20^2,'same')); end imshow(I) ;

How can blur an image

I = imread('peppers.png') ; for i = 1:3 I(:,:,i) = uint8(conv2(I(:,:,i),ones(20)/20^2,'same')); end imshow(I) ;

4 days ago | 0

Answered

Change dashed line spacing on plot

You may follow something like this: x = 1:100 ; y = rand(size(x)) ; % make dashed line with gaps idx = reshape(x,10,[])'...

Change dashed line spacing on plot

You may follow something like this: x = 1:100 ; y = rand(size(x)) ; % make dashed line with gaps idx = reshape(x,10,[])'...

5 days ago | 0

Answered

how to combine multiple files contain one column only into one file only

files = dir('*.csv') ; N = length(files) ; A = cell(N,1) ; for i = 1:N data = csvread(files(i).name ; A{i} = data ;...

how to combine multiple files contain one column only into one file only

files = dir('*.csv') ; N = length(files) ; A = cell(N,1) ; for i = 1:N data = csvread(files(i).name ; A{i} = data ;...

5 days ago | 0

Answered

how can I display a specific region in Africa ?

You have the folliwng options: Get the limits of your region and use xlim/ylim or axis Get the shape file of your intereste...

how can I display a specific region in Africa ?

You have the folliwng options: Get the limits of your region and use xlim/ylim or axis Get the shape file of your intereste...

5 days ago | 0

Answered

Error using table (line 253) All variables must have the same number of rows.

The first input is a column and rest are rows..so the error. Try: table(step,Psi0',Psi1',Psi2',Psi3',Psi4',Psi5') You need ...

Error using table (line 253) All variables must have the same number of rows.

The first input is a column and rest are rows..so the error. Try: table(step,Psi0',Psi1',Psi2',Psi3',Psi4',Psi5') You need ...

5 days ago | 1

| accepted

Answered

Not enough input arguments. Error in ratio_magnitude (line 6) RV1 =1/sqrt(1+((f*s)/p)^2);

It seems you are not providing inputs to the function and starught away running to code.......you cannot use a function like tha...

Not enough input arguments. Error in ratio_magnitude (line 6) RV1 =1/sqrt(1+((f*s)/p)^2);

It seems you are not providing inputs to the function and starught away running to code.......you cannot use a function like tha...

5 days ago | 1

| accepted

Answered

function that checks multiple numbers

function [output] = my_func(input) output = zeros(size(input)) ; c = mod(sqrt(input,1)) ; idx = c==0 ; output(idx) = sqrt(...

function that checks multiple numbers

function [output] = my_func(input) output = zeros(size(input)) ; c = mod(sqrt(input,1)) ; idx = c==0 ; output(idx) = sqrt(...

5 days ago | 0

Answered

How to Plot y=sin(2*pi*m*x)+sin(2*pi*n*x) , where m and n are positive integers and x is a variable

m = 0:1:10 ; n = 0:1:10 ; [M,N] = meshgrid(m,n) ; x = pi/4 ; Y=sin(2*pi*M*x)+sin(2*pi*N*x); surf(M,N,Y) If you wan...

How to Plot y=sin(2*pi*m*x)+sin(2*pi*n*x) , where m and n are positive integers and x is a variable

m = 0:1:10 ; n = 0:1:10 ; [M,N] = meshgrid(m,n) ; x = pi/4 ; Y=sin(2*pi*M*x)+sin(2*pi*N*x); surf(M,N,Y) If you wan...

5 days ago | 0

| accepted

Answered

how to divide a column vector by a scalar?

A = rand(54,1) ; scalar = rand ; iwant = A/scalar ;

how to divide a column vector by a scalar?

A = rand(54,1) ; scalar = rand ; iwant = A/scalar ;

5 days ago | 0