Answered
surface plot
[a b] = meshgrid(0:.1:1,0:.01:.1); c = a + b; surfl(a,b,c)

14 years ago | 0

Answered
surface fitting
Add folder which contains this function to search path, and type: help gridfit

14 years ago | 0

Answered
surface fitting
See: <http://www.mathworks.com/matlabcentral/fileexchange/8998-surface-fitting-using-gridfit> You can also write your own ...

14 years ago | 0

| accepted

Answered
meshing in matlab
See: <http://persson.berkeley.edu/distmesh/ DistMesh - A Simple Mesh Generator in MATLAB> Or if you have pdetool: <http...

14 years ago | 0

Answered
change polar axes
See: <http://www-europe.mathworks.com/matlabcentral/answers/18457-how-to-plot-only-half-of-a-polar-plot-i-e-only-the-lower-hemis...

14 years ago | 0

Answered
DelaunayTri output relation to inputs
Analyze this code, I think that it will help you to understand DelaunayTri: [tri_x tri_y] = meshgrid(-1:.5:1); tri_x = t...

14 years ago | 0

| accepted

Answered
Optimization gives only small changes in each step, Why and how to solve it?
What is the objective function? Maybe your starting points are located far from the minimum and the function is flat. Plea...

14 years ago | 0

| accepted

Answered
Removing Background (To count cells in image)
You do not have to do, just follow the assistant instructions :) Here's the example: <http://blogs.mathworks.com/steve/200...

14 years ago | 0

Answered
how to select minimum value from matrix
m = min(sr) see also: doc min

14 years ago | 1

Answered
Errorbar + multiple plots + one legend
Remove the semicolon in legend to errorbar.

14 years ago | 0

| accepted

Answered
Variable names in fsolve
Just replace the variables: function F = myfun(x) Y = x(1); C = x(2); I = x(3); . . .

14 years ago | 0

| accepted

Answered
how to increase the number of rows and columns of an image in Matlab?
Something like this: a = rand(2,2,3) a(3,3,3) = 0

14 years ago | 0

| accepted

Answered
PDEPE and BCFUN
Below is the full code: function heat1D m = 0; xmesh = linspace(0,1,20); tspan = linspace(0,3,60); sol ...

14 years ago | 2

Answered
Solving time shifted differential equations
Read in documentation: <http://www.mathworks.com/help/techdoc/ref/dde23.html> <http://www.mathworks.com/help/techdoc/ref/d...

14 years ago | 0

Answered
Partial Differentiation of a function
One of the possibilities: syms x y f=x^2+2*y^2-22 P=diff(f,x) subs(P,{x,y},{1.5,2})

14 years ago | 7

| accepted

Answered
tab delimited .txt file
Suppose that your Data is: Data = [1 2 3;4 5 6; 7 8 9]; Would you like to create such a file? line1 1 2 3 line2 ...

14 years ago | 2

| accepted

Answered
Recovering list of polling points with patternsearch
The solution is a little dangerous :) Go to directory *matlabroot/toolbox/globaloptim/globaloptim/private/*: cd(matlabroot) ...

14 years ago | 0

Answered
parallel processing patternsearch.m ?
Set the following options using psoptimset: * 'CompletePoll' to 'on'. * 'Vectorized' to 'off' * 'UseParallel' to 'always'.

14 years ago | 1

| accepted

Answered
A bug in Patternsearch with cache on?
*patternsearch* implements Cache as a persistent variable, so you can't use it in this way. You have to set 'cache' to 'off' in ...

14 years ago | 0

| accepted

Answered
gamultiobjective
In documentation is a detailed description (with references): <http://www.mathworks.com/help/pdf_doc/gads/gads_tb.pdf>

14 years ago | 0

Answered
Shaded surface
St11=100; Sc11=St11*2/3; St22=80; Sc22=St22*2/3; S=60; i1 = 0; r = NaN(101,51); for phi=0:pi/50:2...

14 years ago | 0

| accepted

Answered
Shaded surface
[psi phi] = meshgrid(0:0.05:2*pi); r = 1; x=cos(psi).*cos(phi).*r; y=cos(psi).*sin(phi).*r; z=sin(psi).*r; surf...

14 years ago | 0

Answered
patternsearch - ignoring TolFun
Algorithm stops when change in the *objective function* in two consecutive iterations and the *mesh size* are both less than Fun...

14 years ago | 0

Answered
Invert Matrix Command
Statement A=B.\1 doesn't calculate an inverse matrix. You probably mean: A2=B\eye(size(B)) *B^-1* and *inv(B)* give the same...

14 years ago | 0

| accepted

Answered
extract Vector's index from Matrix
*ismember* function might be helpful.

14 years ago | 1

| accepted

Answered
file manipulation
doc movefile doc mkdir

14 years ago | 0

| accepted

Answered
for loop
for i=1:10 mkdir (sprintf('folder_%i',i)) end

14 years ago | 0

| accepted

Answered
convert number of 5 digits to characters
doc sprintf doc num2str

14 years ago | 0

Answered
Sum of Euclidean distances
sum((xyz(2:end,:)-repmat(xyz(1,:),size(xyz,1)-1,1)).^2,2).^0.5 or with loop; for k=2:5 d(k-1) = norm(xyz(1,:)-xyz(k,:)...

14 years ago | 0

Answered
function call
Something like that: function my_fun(directory,n) a = dir(directory); % a(1) is folder '.' % a(2) is folder '..' ...

14 years ago | 0

Load more