29 total contributions since 2014

Mechanical Engineer in R&D

Professional Interests: Control Systems

Answered

Getting an error in a listener callback function to trigger an error in/terminate execution of the calling function

I'm also having the same issue. It would be better if the error stopped execution immediately rather than continue on. For examp...

Getting an error in a listener callback function to trigger an error in/terminate execution of the calling function

I'm also having the same issue. It would be better if the error stopped execution immediately rather than continue on. For examp...

10 months ago | 0

Question

Defining classdef property validations for gpuArrays

Here are two scenarios I'm unsure how to handle when it comes to constructing class property validations with GPU types. c...

1 year ago | 2 answers | 1

Answered

How to clear gpuArray, which is a property of a class, from memory when deleting an object class instance

In the delete method you created for the handle, instead of clear, did you try something F.Z_d(:)=[] or Z_id(:)=[]?

How to clear gpuArray, which is a property of a class, from memory when deleting an object class instance

In the delete method you created for the handle, instead of clear, did you try something F.Z_d(:)=[] or Z_id(:)=[]?

1 year ago | 0

Answered

How to ensure that onCleanup destroys last

<https://www.mathworks.com/matlabcentral/answers/2245-oncleanup-order-of-execution#answer_338728 Try cellular vectors of onCle...

How to ensure that onCleanup destroys last

<https://www.mathworks.com/matlabcentral/answers/2245-oncleanup-order-of-execution#answer_338728 Try cellular vectors of onCle...

1 year ago | 1

Answered

onCleanup order of execution

onCleanup objects can be stored in a cellular vector, and will be performed first to last. You should know the number of total t...

onCleanup order of execution

onCleanup objects can be stored in a cellular vector, and will be performed first to last. You should know the number of total t...

1 year ago | 0

Question

Make subclasses inheret a method to look for past work

Preface: I am a mechanical engineer with effectively zero background in software engineering. I can read most C/++/#, Java, and ...

2 years ago | 1 answer | 1

Answered

syntax for call to java library function with byte[] (reference) parameter?

*A SOLUTION* I haven't figured out how to pass the byte reference, but I have found a way to read a fixed number of bytes fro...

syntax for call to java library function with byte[] (reference) parameter?

*A SOLUTION* I haven't figured out how to pass the byte reference, but I have found a way to read a fixed number of bytes fro...

2 years ago | 2

Answered

syntax for call to java library function with byte[] (reference) parameter?

_What is a *byte[] buf* in MATLAB, and how do I pass it to read from the GZIP_INPUT_STREAM to retrieve a fixed number of bytes?_...

syntax for call to java library function with byte[] (reference) parameter?

_What is a *byte[] buf* in MATLAB, and how do I pass it to read from the GZIP_INPUT_STREAM to retrieve a fixed number of bytes?_...

2 years ago | 0

Answered

syntax for call to java library function with byte[] (reference) parameter?

Bob Gilmore, a software engineer for Mathworks at the time of this <https://www.mathworks.com/matlabcentral/newsreader/view_thre...

syntax for call to java library function with byte[] (reference) parameter?

Bob Gilmore, a software engineer for Mathworks at the time of this <https://www.mathworks.com/matlabcentral/newsreader/view_thre...

2 years ago | 1

Question

Where is the Horizontal property for area plots

I'm trying to create graphics for a presentation involving many inequalities. Several charts define x<=max and x>=min. I've been...

2 years ago | 0 answers | 0

Submitted

MLExampleJavaSecurityMessageDigest

Demonstrate how to hash data with Java

2 years ago | 1 download |

Solved

Swap the first and last columns

Flip the outermost columns of matrix A, so that the first column becomes the last and the last column becomes the first. All oth...

2 years ago

Solved

Make a checkerboard matrix

Given an integer n, make an n-by-n matrix made up of alternating ones and zeros as shown below. The a(1,1) should be 1. Examp...

2 years ago

Solved

Find all elements less than 0 or greater than 10 and replace them with NaN

Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

2 years ago

Solved

Triangle Numbers

Triangle numbers are the sums of successive integers. So 6 is a triangle number because 6 = 1 + 2 + 3 which can be displa...

2 years ago

Solved

Column Removal

Remove the nth column from input matrix A and return the resulting matrix in output B. So if A = [1 2 3; 4 5 6]; and ...

2 years ago

Solved

Select every other element of a vector

Write a function which returns every other element of the vector passed in. That is, it returns the all odd-numbered elements, s...

2 years ago

Solved

Pizza!

Given a circular pizza with radius _z_ and thickness _a_, return the pizza's volume. [ _z_ is first input argument.] Non-scor...

2 years ago

Solved

Determine if input is odd

Given the input n, return true if n is odd or false if n is even.

2 years ago

Solved

Find the sum of all the numbers of the input vector

Find the sum of all the numbers of the input vector x. Examples: Input x = [1 2 3 5] Output y is 11 Input x ...

2 years ago

Solved

Make the vector [1 2 3 4 5 6 7 8 9 10]

In MATLAB, you create a vector by enclosing the elements in square brackets like so: x = [1 2 3 4] Commas are optional, s...

2 years ago

Solved

Times 2 - START HERE

Try out this test problem first. Given the variable x as your input, multiply it by two and put the result in y. Examples:...

2 years ago

Question

Voronoi regions of line segment sites

My question continues from one found <http://www.mathworks.com/matlabcentral/answers/18138-voronoi-diagram-for-lines here>. I'm ...

3 years ago | 0 answers | 0

Question

Trying to replace num2cell with subasgn

I am trying to avoid using num2cell when assigning data between arrays and structs. %% e.g. data A = rand(5,4,3) B =...

4 years ago | 0 answers | 0

Question

Why does isInterior of Delaunay Triangulation fail if I remove a point constraint between two colinear constraints

When generating a Constrained Delaunay Triangulation object (CDT for short), any points that fall on a constraint split the cons...

4 years ago | 0 answers | 0

Answered

Using loop in strings for import

I have a similar problem. I have data taken from multiple machines with variable conditions, and a consistent heirarchy. E.g. ...

Using loop in strings for import

I have a similar problem. I have data taken from multiple machines with variable conditions, and a consistent heirarchy. E.g. ...

5 years ago | 0