I joined The MathWorks in the Technical Support department during the summer of 2001 and transferred into the Quality Engineering department in March of 2004. I now work qualifying the core MATLAB numerical functions (PLUS, MINUS, LU, FFT, ODE45, etc.)

Professional Interests: mathematics, MATLAB

For assistance with MATLAB question please post to MATLAB Answers or contact Technical Support using the Contact Us link in the upper-right corner of the page instead of contacting me directly.

Answered

fmincon with external multi-input functions

Use one of the techniques described on this documentation page. While that page specifically mentions fzero and integral, the te...

fmincon with external multi-input functions

Use one of the techniques described on this documentation page. While that page specifically mentions fzero and integral, the te...

약 5시간 ago | 0

Answered

How to compute the moving average of a signal with 6-hour window length and shifted 15 min at a time?

Use movmean with a datetime or duration SamplePoints input. Specify the window using a duration array.

How to compute the moving average of a signal with 6-hour window length and shifted 15 min at a time?

Use movmean with a datetime or duration SamplePoints input. Specify the window using a duration array.

1일 ago | 0

Answered

Keep getting Parse error here

There are two parse errors in that code, both where you've forgotten a comma between indices 256 and the colon character. plot(...

Keep getting Parse error here

There are two parse errors in that code, both where you've forgotten a comma between indices 256 and the colon character. plot(...

3일 ago | 0

Answered

2 integrals at once?

The integral function doesn't care what name your integrand function uses for its input argument. All it really cares about is t...

2 integrals at once?

The integral function doesn't care what name your integrand function uses for its input argument. All it really cares about is t...

3일 ago | 0

Answered

How do I get my license and activation key

If you purchased MATLAB from the online store, I believe you should have received an email with instructions on how to download ...

How do I get my license and activation key

If you purchased MATLAB from the online store, I believe you should have received an email with instructions on how to download ...

3일 ago | 0

Answered

How to fill a graph exclusing given points?

Let's make a random (well, not so random, more arbitrary) polygon. A = nsidedpoly(5, 'Center', [1 1], 'Radius', 2); If you wan...

How to fill a graph exclusing given points?

Let's make a random (well, not so random, more arbitrary) polygon. A = nsidedpoly(5, 'Center', [1 1], 'Radius', 2); If you wan...

3일 ago | 1

| accepted

Answered

Extreme points finding from set

I suspect some combination of islocalmin, islocalmax, and/or ischange will identify the points you've called out with + markers ...

Extreme points finding from set

I suspect some combination of islocalmin, islocalmax, and/or ischange will identify the points you've called out with + markers ...

4일 ago | 0

Answered

fill a polygon with a hole

Consider creating and plotting a polyshape. You will receive a warning but depending on how you've generated your data you may b...

fill a polygon with a hole

Consider creating and plotting a polyshape. You will receive a warning but depending on how you've generated your data you may b...

4일 ago | 0

Answered

How to unfix the seed with Matlab engine?

Every time you call matlab.engine.start_matlab you're starting a new MATLAB process. See this documentation page for how to "Gen...

How to unfix the seed with Matlab engine?

Every time you call matlab.engine.start_matlab you're starting a new MATLAB process. See this documentation page for how to "Gen...

4일 ago | 0

| accepted

Answered

How to generate -1, 0 and 1?

If you want to map ranges of values in your original data to the values -1, 0, and 1 you could discretize your data. Use the syn...

How to generate -1, 0 and 1?

If you want to map ranges of values in your original data to the values -1, 0, and 1 you could discretize your data. Use the syn...

4일 ago | 0

Answered

How to control the randomness of algorithm

See the three topics in the "Control Random Number Generation" section on this documentation page.

How to control the randomness of algorithm

See the three topics in the "Control Random Number Generation" section on this documentation page.

4일 ago | 0

Answered

round off problem in matlab

Based on that display I suspect one or both of the variables zcdOut or slope_count are stored in an integer class. When you comb...

round off problem in matlab

Based on that display I suspect one or both of the variables zcdOut or slope_count are stored in an integer class. When you comb...

4일 ago | 0

| accepted

Answered

HOW to download 2019b iso disc image

As per this message if you are a licensed end user you will need to ask your license administrator to download it.

HOW to download 2019b iso disc image

As per this message if you are a licensed end user you will need to ask your license administrator to download it.

4일 ago | 0

Answered

I cannot open the following tutorial in R2018a version. Photovoltaic Thermal (PV/T) Hybrid Solar Panel

This example was introduced in Simscape Electrical in release R2019b, according to the Release Notes. It doesn't exist in earlie...

I cannot open the following tutorial in R2018a version. Photovoltaic Thermal (PV/T) Hybrid Solar Panel

This example was introduced in Simscape Electrical in release R2019b, according to the Release Notes. It doesn't exist in earlie...

4일 ago | 0

Answered

Banded Matrix Solver in Matlab

Since you've tagged this question with "sparse", try just using the backslash operator. The flowchart on that documentation page...

Banded Matrix Solver in Matlab

Since you've tagged this question with "sparse", try just using the backslash operator. The flowchart on that documentation page...

5일 ago | 1

| accepted

Answered

accuracy problems in uint64 numbers

It really depends on how you performed your computations. Let's take a somewhat large number, 3^40. xDouble = 3^40; xUint64 = ...

accuracy problems in uint64 numbers

It really depends on how you performed your computations. Let's take a somewhat large number, 3^40. xDouble = 3^40; xUint64 = ...

5일 ago | 1

| accepted

Answered

PLOT THE GRAPH OF VECTOR FUNCTIONS

If you have a picture in your mind of how you want the graph to look, open the Plots tab in the Toolstrip and click the triangle...

PLOT THE GRAPH OF VECTOR FUNCTIONS

If you have a picture in your mind of how you want the graph to look, open the Plots tab in the Toolstrip and click the triangle...

5일 ago | 0

Answered

Convert table and obtain column values

Use ismissing to locate the missing values (you can tell ismissing what it should consider as a missing value) then use the logi...

Convert table and obtain column values

Use ismissing to locate the missing values (you can tell ismissing what it should consider as a missing value) then use the logi...

5일 ago | 0

Answered

What is the best way to insure that all of my functions are using the same constant values?

You could define a class with Constant properties. classdef myconstants properties(Constant) g = 9.8; g_...

What is the best way to insure that all of my functions are using the same constant values?

You could define a class with Constant properties. classdef myconstants properties(Constant) g = 9.8; g_...

6일 ago | 4

| accepted

Answered

can I return more than one argument in the "odefun" when called from ode45

What you've described sounds not like an ordinary differential equation (ODE) but like a delay differential equation (DDE). This...

can I return more than one argument in the "odefun" when called from ode45

What you've described sounds not like an ordinary differential equation (ODE) but like a delay differential equation (DDE). This...

6일 ago | 1

Answered

Find specific date/time from a series of datenums

If you're going to be doing a lot of processing of this data based on the times, consider turning your column of date numbers in...

Find specific date/time from a series of datenums

If you're going to be doing a lot of processing of this data based on the times, consider turning your column of date numbers in...

6일 ago | 0

Answered

Undefined function or variable 'ranova'

The only ranova function I see in the documentation is this one. In order to call this function, the first input must be a Repea...

Undefined function or variable 'ranova'

The only ranova function I see in the documentation is this one. In order to call this function, the first input must be a Repea...

6일 ago | 0

| accepted

Answered

Write class methods outside the class file

Rather than defining the class methods in the classdef file to call a separate function, I'd just define them in a separate file...

Write class methods outside the class file

Rather than defining the class methods in the classdef file to call a separate function, I'd just define them in a separate file...

7일 ago | 1

| accepted

Answered

Event function with multiple events

When you define your options structure with: option2 = odeset('Events', @comp); the ODE solver will call your Events function ...

Event function with multiple events

When you define your options structure with: option2 = odeset('Events', @comp); the ODE solver will call your Events function ...

7일 ago | 0

| accepted

Answered

Extract Variable/column with variable name from table

In what form do you want the extracted variables to be stored? A = magic(4); T = array2table(A) % Variable names A1 through A4...

Extract Variable/column with variable name from table

In what form do you want the extracted variables to be stored? A = magic(4); T = array2table(A) % Variable names A1 through A4...

7일 ago | 0

| accepted

Answered

Is there a way that we can identify the output of the figures that fall within the assigned range?

Use the discretize function.

Is there a way that we can identify the output of the figures that fall within the assigned range?

Use the discretize function.

9일 ago | 0

| accepted

Answered

Roots function is solving eigth order polynomial equation as fifth order.

Specify the 'All' option in your call to coeffs to return all the coefficients, even those that are 0.

Roots function is solving eigth order polynomial equation as fifth order.

Specify the 'All' option in your call to coeffs to return all the coefficients, even those that are 0.

9일 ago | 0

| accepted

Answered

Separate out every fourth element of a Vector

If by " so you have to make it clear that this is not the intention." you mean you don't want to delete every fourth element but...

Separate out every fourth element of a Vector

If by " so you have to make it clear that this is not the intention." you mean you don't want to delete every fourth element but...

10일 ago | 0

Answered

How do I turn off the automatic updates of the legend function, a lot of the times I only want to label just a few of the curves to avoid over-crowding. Is there a switch I can turn off automatic updates of “legend”? (From help: “legend creates a ...

On the legend documentation page the third entry in the Compatibility Considerations section states "If you do not want the lege...

How do I turn off the automatic updates of the legend function, a lot of the times I only want to label just a few of the curves to avoid over-crowding. Is there a switch I can turn off automatic updates of “legend”? (From help: “legend creates a ...

On the legend documentation page the third entry in the Compatibility Considerations section states "If you do not want the lege...

10일 ago | 0

| accepted

Answered

Create variable from an excel entry

Are you required to store this data in an Excel spreadsheet? I'd prefer storing this in a plain text file. Plot.Shift=20; Plot...

Create variable from an excel entry

Are you required to store this data in an Excel spreadsheet? I'd prefer storing this in a plain text file. Plot.Shift=20; Plot...

10일 ago | 0