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

3D Plotting in matlab

I assume ‘complex’ just means complicated, and not a function with real an imaginary arguments or output. If it is actually com...

3D Plotting in matlab

I assume ‘complex’ just means complicated, and not a function with real an imaginary arguments or output. If it is actually com...

alrededor de 2 horas ago | 0

Answered

plotting ode warning with nor plot returned

It helps to look at the dsolve results: Bsol = S.B Asol = S.A that are: Bsol = 0 ...

plotting ode warning with nor plot returned

It helps to look at the dsolve results: Bsol = S.B Asol = S.A that are: Bsol = 0 ...

alrededor de 2 horas ago | 0

Answered

RMSE between original and predicted values.

Please see my Comment replying to your Comment.

RMSE between original and predicted values.

Please see my Comment replying to your Comment.

alrededor de 3 horas ago | 0

| accepted

Answered

standard deviation on power vs. frequency graph

It would help to have your data, however I created some to illustrate the approach: f = linspace(0, 0.5, 25); ...

standard deviation on power vs. frequency graph

It would help to have your data, however I created some to illustrate the approach: f = linspace(0, 0.5, 25); ...

alrededor de 4 horas ago | 0

Answered

How to plot two MATLAB polar plot in a single figure?

The hold calls must go after the appropriate figure call, not before it. Example— a = linspace(0, 2*pi); r1 = abs(cos(a));...

How to plot two MATLAB polar plot in a single figure?

The hold calls must go after the appropriate figure call, not before it. Example— a = linspace(0, 2*pi); r1 = abs(cos(a));...

alrededor de 5 horas ago | 1

Answered

Multiple Linear Regression using fitlm function

In a linear regression of any sort, there is only one intercept.

Multiple Linear Regression using fitlm function

In a linear regression of any sort, there is only one intercept.

alrededor de 5 horas ago | 0

Answered

How to calculate the derivate of an equation ?

To calculate a numerical derivative of a vector, use the gradient function. If ‘N’ is a vector, use gradient on it, then mult...

How to calculate the derivate of an equation ?

To calculate a numerical derivative of a vector, use the gradient function. If ‘N’ is a vector, use gradient on it, then mult...

alrededor de 6 horas ago | 0

| accepted

Answered

take values from old matrix to newer

Create the output matrix ‘B’ as: B = A(all(A(:,3:5) >= 0, 2),:) % Result Example— A = [randi(9...

take values from old matrix to newer

Create the output matrix ‘B’ as: B = A(all(A(:,3:5) >= 0, 2),:) % Result Example— A = [randi(9...

alrededor de 6 horas ago | 0

| accepted

Answered

Matlab gives no result when I use the ODE (Ordinary Differential Equations)

The differential equation is nonlinear (the ‘y^2’ term) and very few nonlinear differential equations have analytic solutions. ...

Matlab gives no result when I use the ODE (Ordinary Differential Equations)

The differential equation is nonlinear (the ‘y^2’ term) and very few nonlinear differential equations have analytic solutions. ...

alrededor de 6 horas ago | 0

Answered

How to filter data that detects peaks or irregularities?

Several functions already exist to do that, among which are findpeaks, islocalmax, ischange, and others.

How to filter data that detects peaks or irregularities?

Several functions already exist to do that, among which are findpeaks, islocalmax, ischange, and others.

alrededor de 8 horas ago | 0

Answered

Get an image as an input from webcam

I assume here that you are using a USB webcam, and not the Image Aquisition Toolbox. To take picture, use the snapshot functi...

Get an image as an input from webcam

I assume here that you are using a USB webcam, and not the Image Aquisition Toolbox. To take picture, use the snapshot functi...

alrededor de 18 horas ago | 0

Answered

How to get a 3D image from 2D countourf?

Black surf plots are common with very densely-gridded data. To avoid that, set 'EdgeColor' to 'none': D = load('Pedobarograp...

How to get a 3D image from 2D countourf?

Black surf plots are common with very densely-gridded data. To avoid that, set 'EdgeColor' to 'none': D = load('Pedobarograp...

alrededor de 23 horas ago | 0

| accepted

Answered

Reverse calculate a table of values

I am not certain what a ‘3D table’ is. Perhaps you intend a three column table or array. If that is true, then the interp1 f...

Reverse calculate a table of values

I am not certain what a ‘3D table’ is. Perhaps you intend a three column table or array. If that is true, then the interp1 f...

1 día ago | 1

Answered

Sequence a_n =1/n

Use element-wise division: n = 1:100; format short Seq = 1./n producing: Seq = 1.0000 0.5000 0.3333 0.2500 ...

Sequence a_n =1/n

Use element-wise division: n = 1:100; format short Seq = 1./n producing: Seq = 1.0000 0.5000 0.3333 0.2500 ...

1 día ago | 1

| accepted

Answered

Calculate area under curve of multiple peaks

Using cumtrapz: [peaks,loc]=findpeaks(crestbar, 'MinPeakProminence', 30); [trofs,troflocs] = findpeaks(-crestbar, 'MinPeakPro...

Calculate area under curve of multiple peaks

Using cumtrapz: [peaks,loc]=findpeaks(crestbar, 'MinPeakProminence', 30); [trofs,troflocs] = findpeaks(-crestbar, 'MinPeakPro...

1 día ago | 0

Answered

We need to install Global Optimization Tool

Try running these lines from a script or your Command Window first: restoredefaultpath rehash toolboxcache That may fix th...

We need to install Global Optimization Tool

Try running these lines from a script or your Command Window first: restoredefaultpath rehash toolboxcache That may fix th...

1 día ago | 0

Answered

convert plot3 to contour plot

Use the griddata function: a = randi(9, 10, 3); x = a(:,1); y = a(:,2); z = a(:,3); xv = linspace(min(x), max(x), 6); ...

convert plot3 to contour plot

Use the griddata function: a = randi(9, 10, 3); x = a(:,1); y = a(:,2); z = a(:,3); xv = linspace(min(x), max(x), 6); ...

1 día ago | 0

Answered

Index exceeds matrix dimensions error "for my code"

It is unfortunate that we do not get the opportunity to see what ‘X’ is for the various files, nor anything else about them. ...

Index exceeds matrix dimensions error "for my code"

It is unfortunate that we do not get the opportunity to see what ‘X’ is for the various files, nor anything else about them. ...

1 día ago | 0

| accepted

Answered

this is a part of my test and i cant find the mistake in this .

The obvious observation is that ‘x’ is going to be less than 10 from the initial iteration through how many iterations it takes ...

this is a part of my test and i cant find the mistake in this .

The obvious observation is that ‘x’ is going to be less than 10 from the initial iteration through how many iterations it takes ...

2 días ago | 0

| accepted

Answered

Error in saveas, Invalid figure handle

I cannot run your code because I do not have the necessary files. However: %% Let's plot T and RH times...

Error in saveas, Invalid figure handle

I cannot run your code because I do not have the necessary files. However: %% Let's plot T and RH times...

2 días ago | 0

| accepted

Answered

Custom colour bar, excluding the Blue from RGB.

Define ‘CustomColourMap’ as: CustomColourMap = @(x) [linspace(0,1,x).' linspace(1,0,x).' zeros(x,1)]; then to use it: Cust...

Custom colour bar, excluding the Blue from RGB.

Define ‘CustomColourMap’ as: CustomColourMap = @(x) [linspace(0,1,x).' linspace(1,0,x).' zeros(x,1)]; then to use it: Cust...

2 días ago | 0

| accepted

Answered

how to make fuction from changing varibles

That is relatively straightforward to do with ndgrid or meshgrid. Try this hypothetical example: Z = @(x,y,z) x.^2 + y.^2 +...

how to make fuction from changing varibles

That is relatively straightforward to do with ndgrid or meshgrid. Try this hypothetical example: Z = @(x,y,z) x.^2 + y.^2 +...

2 días ago | 0

Answered

Add 0.5 *0.5 degree grid on figure (country)

This illustrates the general approach: x = linspace(44, 64); y = linspace(25, 40); t = linspace(0,2*pi); circx = 0.25*(ma...

Add 0.5 *0.5 degree grid on figure (country)

This illustrates the general approach: x = linspace(44, 64); y = linspace(25, 40); t = linspace(0,2*pi); circx = 0.25*(ma...

2 días ago | 0

| accepted

Answered

How can i plot with if statement ?

Try this: x=[10 20 30 40 50 ] ; for k = 1:numel(x) if x(k)==10 y(k)=((10*10^6)*.1523)./ x(k) ; end if...

How can i plot with if statement ?

Try this: x=[10 20 30 40 50 ] ; for k = 1:numel(x) if x(k)==10 y(k)=((10*10^6)*.1523)./ x(k) ; end if...

2 días ago | 0

Answered

Make a Plot using loop

Subscript ‘Cp’ and the plot magically appears! Dg=150; %mg Vd=50; %L Ke=0.4; %h^-1 Ka=1.6; %h^-1 t=0:0.1:10; for k = 1...

Make a Plot using loop

Subscript ‘Cp’ and the plot magically appears! Dg=150; %mg Vd=50; %L Ke=0.4; %h^-1 Ka=1.6; %h^-1 t=0:0.1:10; for k = 1...

2 días ago | 0

| accepted

Answered

titel for tables with spce between the words

The R2019b release allows spaces and other (inluuding Unicode) characters in table variable names. Upgrade to it and you will b...

titel for tables with spce between the words

The R2019b release allows spaces and other (inluuding Unicode) characters in table variable names. Upgrade to it and you will b...

2 días ago | 1

Answered

How to change the size of error bar?

I am not certain what you want. Try this: errs = rand(1,10); x = 1:10; y = randi([10 20],1,10); figure plot(x, y) ho...

How to change the size of error bar?

I am not certain what you want. Try this: errs = rand(1,10); x = 1:10; y = randi([10 20],1,10); figure plot(x, y) ho...

3 días ago | 1

| accepted

Answered

Ending a recursive function

I have not run your posted code, however two things are immediately apoparent. First, in the calls to ‘mysequence’, the fun...

Ending a recursive function

I have not run your posted code, however two things are immediately apoparent. First, in the calls to ‘mysequence’, the fun...

3 días ago | 0

Answered

Relational operator == doesn't work properly in some cases!

You are seeing the effects of floating-point approximation error. See for example: Why is 0.3 - 0.2 - 0.1 (or similar) not e...

Relational operator == doesn't work properly in some cases!

You are seeing the effects of floating-point approximation error. See for example: Why is 0.3 - 0.2 - 0.1 (or similar) not e...

3 días ago | 0

| accepted