Question

Solving an optimal control problem using filter?
I'm trying to solve a pair of difference equations for an economic problem. It appears from the web that the appropriate matlab...

5 years ago | 0 answers | 0

### 0

Problems opening matlab from a remote shell from Ubuntu 14.04.
Opening matlab with the -nojvm flag fixed this problem.

5 years ago | 1

| accepted

matlabFunction forces me (unnecessarily) to include a dummy integration variable as an argument of the anonymous function it creates.
I talked to matlab support about this. The problem goes away if you set the IgnoreAnalyticConstraints flag to true. sym...

5 years ago | 2

| accepted

Question

matlabFunction forces me (unnecessarily) to include a dummy integration variable as an argument of the anonymous function it creates.
In the example below, I use matlabFunction to create the anonymous function intF{2}. The function to be created has five argum...

5 years ago | 1 answer | 1

### 1

Question

Using dsolve, replace arbitrary constants like C11 with one's own parameter name.
when one solves a differential equation using dsolve, without specifying terminal conditions, matlab outputs the solution with a...

5 years ago | 1 answer | 0

### 1

Question

summing over a multi-dimensional cartesian product using nested arrayfun commands
I have an anonymous function with multiple arguments and I want to sum over all of them. For example, consider the simple fun...

5 years ago | 2 answers | 0

### 2

Question

anonymous function which outputs a vector of sums when the input is a vector of indices.
I'd like to write an anonymous function such as f = @(X,m,A) sum(X(m:A)) where X is a vector, m < numel(X), ...

5 years ago | 1 answer | 0

### 1

Question

preserving variable class when extracting fields from a struct
I have a program that requires passing a large number of variables to a function. Rather than have a long list of global vari...

5 years ago | 4 answers | 0

### 4

for loop to update frequency count
This gets close I think A = floor(rand(500)*1001);B=A(:);I = find(B<501); [N,X] = hist(B(I),501); X contains the c...

5 years ago | 0

Question

maximum variable size allowed by the program is exceeded but it's not
There have been many many threads on this topic but none seem to apply to my case. I'm running 64 bit matlab so that [~...

5 years ago | 0 answers | 0

### 0

Question

Problems opening matlab from a remote shell from Ubuntu 14.04.
I've upgraded from Ubuntu 12.04 to 14.04, and this has created a problem which I didn't have with Ubuntu 12.04 when I open a ...

5 years ago | 1 answer | 0

### 1

Question

output matlab markers as part of a character string.
It's amazing that nobody has asked this before, but I'd like to insert the standard matlab plot markers---square, diamond, circl...

6 years ago | 1 answer | 1

### 1

Question

Condition on whether or not matlab is running in 'nodesktop' mode
is there a way to condition on whether or not I called matlab in 'nodesktop' mode? Thanks in advance!

6 years ago | 1 answer | 0

### 1

Question

Preventing matlab from reversing my signs in symbolic expressions
The symbolic toolbox reverses the signs of the expressions I type. For example syms a b f = (1-x)*a + b return...

6 years ago | 1 answer | 0

### 1

Question

double summation without a loop
I have an anonymous function f that has two indices, i and t. i runs from 1 to n; t runs from 1 to m != n. For example: ...

6 years ago | 1 answer | 0

### 1

clc clears the screen before printing the reminder, but indeed, not a big deal, thanks!

6 years ago | 0

After I run my startup script, it announces Academic License and then the >> prompt.

6 years ago | 0

Question

I know this is trivial in the grand scheme of things, but I'd love to remove the notification everytime I start matlab R15a that...

6 years ago | 6 answers | 0

### 6

Question

Can I assign a single value to multiple elements of a cell array without a loop
For example, I have an array that looks like myArray = [3] [] [3] [] I'd like to fill out the empty ele...

6 years ago | 2 answers | 0

### 2

Question

Prevent matlab figures from jumping from one virtual desktop to another
Not sure of the right language to describe this issue... I run matlab in Ubuntu, using fvwm, which allows me to have multiple...

6 years ago | 0 answers | 2

### 0

Question

displaying the colors of a color matrix
Hi, I have a matrix of colors, C = [.5142 0.7695 0.7258; 0.9300 0.8644 0.4048; 0.6929 0.6784 ...

6 years ago | 1 answer | 0

### 1

Question

flag whether or not a program has been called by createTask
I run certain jobs either as standalone jobs, or in parallel, for example called by createTask. Is there some way to distingu...

6 years ago | 1 answer | 1

### 1

Question

Use index from max() to extract matching values from another array
Suppose I have 2 n x m arrays A and B and I get the maximum element of each column of A with [~,I] = max(A) Now I want...

6 years ago | 1 answer | 0

### 1

Question

find element of a cell or char array that matches a nonleading substring
This question seems closely related to thread 50624-testing-for-the-presence-of-a-substring-in-a-cell-array-of-strings but has a...

6 years ago | 2 answers | 0

### 2

Question

Using dir with multiple wildcards for directories
I'd like to be able to use dir to list all files in the grandchildren directories of my cwd, as in dir('*/*') As far...

6 years ago | 1 answer | 0

### 1

Question

assigning an empty numeric value to a cell array
Hi, I need to be able to assign an empty numeric value to a cell array, as in Cell = {}; Cell = [ Cell , [] ]; But th...

6 years ago | 1 answer | 0

### 1

Question

Getting output from parallel jobs that would regularly go to a diary
Using the parallel computing toolbox, is it possible to get each individual job spawned by createTask to write output to a diary...

6 years ago | 1 answer | 1

### 1

Question

Is there a one-step command that identifies the name of the caller workspace
Obviously, I could use dbstack, but it seems there should be a simple command that simply prints out the name of the caller work...

6 years ago | 1 answer | 1

### 1

Question

Maximizing the number of workers used in a parfor loop using the "batch" command
I have four cores, and would like to use all four of them in parallel. To accomplish this, I have attempted to use the "batch"...

7 years ago | 1 answer | 0

### 1

Question

force fsolve termination if not progressing
Hi. I'm running repeated fsolves. With bad starting points, the engine goes nowhere. I can see this looking at th...

7 years ago | 1 answer | 0