Answered
Trouble with finding appropriate conditions for logic
Could you have an issue with the orientation of your facets, e.g. by coding vertice IDs clockwise when they should be coded coun...

13 years ago | 1

| accepted

Question


Is it possible to dynamically add methods to an object, or to build a generic method that "catches attempts to access nonexistent methods"?
Dear all, I have seen similar questions asked serveral times, e.g. here <http://www.mathworks.com/matlabcentral/newsreader/v...

13 years ago | 3 answers | 3

3

answers

Answered
Creating a Matrix with for loop
If I understand well and if you want to keep it simple with an explicit for loop, what you want to do is something like that I g...

13 years ago | 0

| accepted

Answered
Why is NaN not equal to NaN
Most times, you don't want this test to return true indeed. Imagine testing |a==b| and having a |true| result when both |a| and ...

13 years ago | 2

| accepted

Answered
Is {} used as index array in class?
Your question is not related to OOP. Look at the following: >> c = {5, {'Hello', 'World'}, struct( 'a', 8, 'b', 9 )} ; c =...

13 years ago | 2

| accepted

Answered
Is there a faster way than repeating this calculation manually?
function F = TEST6lijn300(x, p) F = [(x(1)^2 + x(2)^2 - p(1)); ((1447.5-x(3))^2 + (876.3-x(4))^2-p(2)); ((-72....

13 years ago | 0

| accepted

Answered
Improve performance in 'expansion of data' function
Hi Stephen, See if the following brings an improvement in your specific context: function [I_mod Q_mod] = expandIQ(I,Q,ex...

13 years ago | 1

| accepted

Answered
How can I create a method which takes an excel file as an argument in a constructor?
My guess is that it has nothing to do with the fact that you want to read an xls file. If you really have the code that you g...

13 years ago | 0

| accepted

Answered
"for loop" with the out of order inputs
a = zeros(25,1) ; % Prealloc (optional). seq = 0 ; for ii = [0.01, 0.1, 1, 8, 100] for jj = [0.01, 0.1, 1, 8, 100] ...

13 years ago | 0

| accepted

Answered
How to program microcontroller in matlab?
You create |s| in the beginning of your code, which is a serial port object. It can be used as any file handle, in particular wi...

13 years ago | 0

| accepted

Question


Prevent MATLAB from displaying full stack on error.
*EDIT:* see answer by Daniel, throwascaller () is what I needed. Dear all, Is there a way, when generating an error(), to ...

13 years ago | 2 answers | 2

2

answers

Answered
Output argument is not assigned on some execution paths for Embedded matlab function
Look at the following: >> u = [1 2 3] ; >> if u < 2, fprintf( 'OK\n' ) ; end >> if u > 2, fprintf( 'OK\n' ) ; end ...

13 years ago | 1

Answered
Adding space/symbol to the readed line.
Assuming that your number format is characterized by always having 3 digits after the decimal dot, you can use the following ins...

13 years ago | 0

| accepted

Answered
How can I simulate and display data that satisfies several constrains?
If you are new to MATLAB and not looking for efficiency or elegance, you can use the following code that is easy to understand: ...

13 years ago | 0

| accepted

Question


User-defined classes and support for '{}' type linear indexing.
Dear all, I overloaded |subsref()| and |subsasgn()| in a class that I built and I seem unable to reproduce the behavior tha...

13 years ago | 1 answer | 2

1

answer