12,573 total contributions since 2012

Hic sunt dracones!

PROFESSIONAL: Physician (M.D.): Diplomate of the American Board of Internal Medicine; M.Sc. Biomedical Engineering: Instrumentation, Signal Processing, Control, System Identification, Parameter Estimation

NON-PROFESSIONAL: Amateur Extra Class Amateur Radio Operator; Private Pilot, Airplane Single Engine Land, Instrument Rating Airplane; Gamer

NOTE: I do not respond to emails or personal messages, unless they are about my File Exchange contributions.

Answered

Find intersection of 2 normal distribution

The ‘val’ value is the x-value of the intersection, however you need to start fzero in the correct region for it to return the c...

Find intersection of 2 normal distribution

The ‘val’ value is the x-value of the intersection, however you need to start fzero in the correct region for it to return the c...

14 hours ago | 2

| accepted

Answered

solving similtanous equations in loop

One approach: x = [1,2,3,4,5,6,7]; y = [1,2,3,4,5,6,7]; [X,Y] = meshgrid(x,y); xv = X(:); yv = Y(:); % -3*w*sin(x)+ 5*q...

solving similtanous equations in loop

One approach: x = [1,2,3,4,5,6,7]; y = [1,2,3,4,5,6,7]; [X,Y] = meshgrid(x,y); xv = X(:); yv = Y(:); % -3*w*sin(x)+ 5*q...

15 hours ago | 0

Answered

Low Pass filter not working

Your stopband attenuation is likely not sufficient to produce any difference. Try this instead: Rs = 60; ...

Low Pass filter not working

Your stopband attenuation is likely not sufficient to produce any difference. Try this instead: Rs = 60; ...

15 hours ago | 0

Answered

How to plot a 3D grid in MATLAB which has been exported from Petrel with the MATLAB-Petrel plugin?

You do not need meshgrid with them, since they are already matrices: D = load('TEST.mat'); Node = D.Node produces: Node = ...

How to plot a 3D grid in MATLAB which has been exported from Petrel with the MATLAB-Petrel plugin?

You do not need meshgrid with them, since they are already matrices: D = load('TEST.mat'); Node = D.Node produces: Node = ...

17 hours ago | 0

Answered

Plotting bacterial growth using odes

I believe Monod kinetics and curve fitting can help. You are not fitting data, so just use the ODE and ode45 call syntax. ...

Plotting bacterial growth using odes

I believe Monod kinetics and curve fitting can help. You are not fitting data, so just use the ODE and ode45 call syntax. ...

18 hours ago | 0

| accepted

Answered

What is the best non-linear least square fitting method that will parameter error in addition to parameters?

If you have the Statistics and Machine Learning Toolbox, see if the fitnlm function will do what you want. Other options are nl...

What is the best non-linear least square fitting method that will parameter error in addition to parameters?

If you have the Statistics and Machine Learning Toolbox, see if the fitnlm function will do what you want. Other options are nl...

19 hours ago | 0

Answered

How does Matlab divide two row vectors by each other to get a scalar?

To expand slightly on that, ‘C’ is the least-squares estimate of the slope of with the y-intercept forced through the origin: ...

How does Matlab divide two row vectors by each other to get a scalar?

To expand slightly on that, ‘C’ is the least-squares estimate of the slope of with the y-intercept forced through the origin: ...

21 hours ago | 0

| accepted

Answered

How can I get the equation of CDF curve in matlab figure?

The cdfplot function plots an empirical distribution based on the characteristics of your data. You can see if it corresponds t...

How can I get the equation of CDF curve in matlab figure?

The cdfplot function plots an empirical distribution based on the characteristics of your data. You can see if it corresponds t...

1 day ago | 0

Answered

Bandwidth analysis of a system with multidimensional input

The length of the input vector is likely irrelevant, and is not even an argument to the bandwidth function. Note however that t...

Bandwidth analysis of a system with multidimensional input

The length of the input vector is likely irrelevant, and is not even an argument to the bandwidth function. Note however that t...

1 day ago | 1

| accepted

Answered

Get t co-ordinate based off y co-ordinate

Try these: t = 0 * pi:0.119:4 * pi; a = 57; phase_angle = 0.26; y = a*sin((67*pi*t) + phase_angle); y_ofst = y-40; zci ...

Get t co-ordinate based off y co-ordinate

Try these: t = 0 * pi:0.119:4 * pi; a = 57; phase_angle = 0.26; y = a*sin((67*pi*t) + phase_angle); y_ofst = y-40; zci ...

1 day ago | 0

Answered

Fitting an experiment using the results of an ODE

I cannot understand what you are doing from the code you posted. You need to describe what you want to do in some detail. What...

Fitting an experiment using the results of an ODE

I cannot understand what you are doing from the code you posted. You need to describe what you want to do in some detail. What...

1 day ago | 0

Answered

Unique ID Min and Max with multiple values per Unique ID

One approach: M = [10 10 17 17 17 201 1000; 0.1 69 1.7 33 55 67 0.99].'; [UM1, ia,ic] = unique(M(:,1), 'stable'); Vmx = acc...

Unique ID Min and Max with multiple values per Unique ID

One approach: M = [10 10 17 17 17 201 1000; 0.1 69 1.7 33 55 67 0.99].'; [UM1, ia,ic] = unique(M(:,1), 'stable'); Vmx = acc...

2 days ago | 0

Answered

List Variables through loop

I am not certain what you want to do. In any event, this is likely more efficient: idx = sort(randi(9, 1, 10)); sla = diff...

List Variables through loop

I am not certain what you want to do. In any event, this is likely more efficient: idx = sort(randi(9, 1, 10)); sla = diff...

2 days ago | 0

Answered

Split .wav file into equal time segments

Use the Signal Processing Toolbox buffer function.

Split .wav file into equal time segments

Use the Signal Processing Toolbox buffer function.

2 days ago | 0

Answered

how can I solve non polynomial equations.

FIRST: see Getting Started. What you posted is not valid MATLAB code. There may be many solutions, depending on the initia...

how can I solve non polynomial equations.

FIRST: see Getting Started. What you posted is not valid MATLAB code. There may be many solutions, depending on the initia...

2 days ago | 0

| accepted

Answered

Error using plot Data must be numeric, datetime, duration or an array convertible to double. Error in prueba3 (line 12) plot(x,Vol);

I have no idea what you want ‘x’ to be. Try this: figure fplot(Vol, [0 C]); Make appropriate changes to define ‘x’ (defin...

Error using plot Data must be numeric, datetime, duration or an array convertible to double. Error in prueba3 (line 12) plot(x,Vol);

I have no idea what you want ‘x’ to be. Try this: figure fplot(Vol, [0 C]); Make appropriate changes to define ‘x’ (defin...

2 days ago | 1

| accepted

Answered

How do i find points where slope is zero.

If you want to use the gradient function to find the inflection points, and since you are dealing with finite-precision values, ...

How do i find points where slope is zero.

If you want to use the gradient function to find the inflection points, and since you are dealing with finite-precision values, ...

3 days ago | 0

| accepted

Answered

Insert zero in an array when a certain value is exceeded

The vectors do not have the same numbers of elements. Correcting for that: Y= [175 175 175 175 175 175 175 175 175 175 175 ...

Insert zero in an array when a certain value is exceeded

The vectors do not have the same numbers of elements. Correcting for that: Y= [175 175 175 175 175 175 175 175 175 175 175 ...

3 days ago | 0

Answered

How to user polarplot when theta and rho are matrix?

It depends what they are. Using pol2cart and then plotting them using a Cartesian plot is an option, although you would have to...

How to user polarplot when theta and rho are matrix?

It depends what they are. Using pol2cart and then plotting them using a Cartesian plot is an option, although you would have to...

3 days ago | 0

Answered

how to plot f (x,y) at x=1

See if this does what you want: y = ...; % Choose A Vector fy = f(1,y); figure plot(y,...

how to plot f (x,y) at x=1

See if this does what you want: y = ...; % Choose A Vector fy = f(1,y); figure plot(y,...

3 days ago | 0

| accepted

Answered

How do I make a 21x21 array from the center of a 200x150 array?

I called your image ‘parrot grayscale.png’. I = imread('parrot grayscale.png'); [r,c] = size(I); sr = fix((r-21)/2); sc = ...

How do I make a 21x21 array from the center of a 200x150 array?

I called your image ‘parrot grayscale.png’. I = imread('parrot grayscale.png'); [r,c] = size(I); sr = fix((r-21)/2); sc = ...

3 days ago | 0

Answered

how can I fit the following points to equation "f(x) = a + b*exp(-c*x)"

Try this: x = [30, 60, 90, 120, 150, 180, 240, 270, 300, 330, 360, 390, 420]; y = [333.15, 332.15, 330.65, 330.15, 329.15, 32...

how can I fit the following points to equation "f(x) = a + b*exp(-c*x)"

Try this: x = [30, 60, 90, 120, 150, 180, 240, 270, 300, 330, 360, 390, 420]; y = [333.15, 332.15, 330.65, 330.15, 329.15, 32...

3 days ago | 0

| accepted

Answered

Remove noise from EMG signal

Those are actually sampling artifacts, not parts of the EMG signal. Probably the best way to deal with them is to use findpeaks...

Remove noise from EMG signal

Those are actually sampling artifacts, not parts of the EMG signal. Probably the best way to deal with them is to use findpeaks...

3 days ago | 0

Answered

Why, Array indices must be positive integers or logical values

It is saying that because ‘r’ is not an integer, and even if it was, there are only some instances in which ‘r/12’ would be an i...

Why, Array indices must be positive integers or logical values

It is saying that because ‘r’ is not an integer, and even if it was, there are only some instances in which ‘r/12’ would be an i...

4 days ago | 2

Answered

Segmentation of a signal 184148x1

See if the buffer function will do what you want.

Segmentation of a signal 184148x1

See if the buffer function will do what you want.

4 days ago | 1

Answered

Why do i get this error? can you explain it to me please

You have a script that you named ‘image’: C:\Users\WASD\Documents\MATLAB\image.m That is the problem. The solution is to ren...

Why do i get this error? can you explain it to me please

You have a script that you named ‘image’: C:\Users\WASD\Documents\MATLAB\image.m That is the problem. The solution is to ren...

4 days ago | 1

Answered

Adding two matrix together

Try this: A = rand(1,30); % Create Vector B = [zeros(1,30) rand(1,30)]; ...

Adding two matrix together

Try this: A = rand(1,30); % Create Vector B = [zeros(1,30) rand(1,30)]; ...

4 days ago | 1

| accepted

Answered

Use fprintf for data from a table

Try this: M = [3 7 2005 30 1 4 2005 35 1 5 2005 24 2 6 2005 25]; MDate = datetime(M(:,3),M(:,2),M(:,1)); ...

Use fprintf for data from a table

Try this: M = [3 7 2005 30 1 4 2005 35 1 5 2005 24 2 6 2005 25]; MDate = datetime(M(:,3),M(:,2),M(:,1)); ...

4 days ago | 1

| accepted

Answered

Parameter Estimation First Order ODE

See: Parameter fit differential equation to dataset for a relevant example of how to approach this problem.

Parameter Estimation First Order ODE

See: Parameter fit differential equation to dataset for a relevant example of how to approach this problem.

4 days ago | 0

Answered

What is wrong with this code?

You forgot to use element-wise division ... P = - ( (0.2*0.5)./Vf).*( (1 - sqrt(Vf/0.5))./( (16/pi^3)*(200^2/181e9).*sqrt(0.85....

What is wrong with this code?

You forgot to use element-wise division ... P = - ( (0.2*0.5)./Vf).*( (1 - sqrt(Vf/0.5))./( (16/pi^3)*(200^2/181e9).*sqrt(0.85....

4 days ago | 0

| accepted