Respondida
adding numbers in an M file
sum(f) (after the loop)

casi 15 años hace | 0

Respondida
Matrix of Galois Field Elements
You must have a different version of MATLAB than I do (2010b). The error message I get is: ??? Error using ==> gf.gf at 66 X ...

casi 15 años hace | 1

| aceptada

Respondida
Solving a differential equation
If your equations contain only linear combinations of the derivatives, you could formulate it as a mass matrix problem |M(t,y)y'...

casi 15 años hace | 1

| aceptada

Respondida
evaluate expression
It would be simpler to provide |y| and solve for |x|: y = -1:0.01:1; x = y.*exp(- (1-y)./(A*y)*B ); In plotting this, y...

casi 15 años hace | 0

Respondida
Double sigmoid fit
Here is an example of how you could use |cfittool| to create a sigmoid fit. First, enter these commands in the Command Window. ...

casi 15 años hace | 0

| aceptada

Respondida
Plot symbolic polynomial
This plots the real part of |y| against |x|: syms x y ezplot(y-x^2-1i-2) Of course, it looks just the same as syms x y ez...

casi 15 años hace | 0

| aceptada

Respondida
Do you suffer from keyboard latency in this forum?
Here is an approach that I hope will make life easier for people with keyboard latency that is not too extreme. I used it to wri...

casi 15 años hace | 1

Respondida
Solving a differential equation
I have been floundering a bit with this problem, but now I see what you need: a variable z = [y; g] with y'(t) = (g-a)*y(t) ...

casi 15 años hace | 1

Respondida
Apply colormap to plot(x,y)
To create the colormap, you could use |spectrumRGB| in <http://www.mathworks.com/matlabcentral/fileexchange/7021 Spectral and XY...

casi 15 años hace | 1

| aceptada

Respondida
Availability PDF
A PDF doesn't have to be restricted to 100% (or 1, as I usually think of it) - as long as the integral of the PDF is 1, it's o.k...

casi 15 años hace | 0

Respondida
Combining 2 different models
out1 = model1(in1); out2 = model2(out1,otherVariables);

casi 15 años hace | 0

Respondida
Solving a differential equation
If I understand your question, you have a delay differential equation with one variable y(t), and your equation has the form y'(...

casi 15 años hace | 0

Respondida
How to avoid NaN with numerical integration (quadrature)
If you set a debugging breakpoint at the call where the warning occurs, then Futpd(LimInf_) ans = NaN *EDIT*: The ...

casi 15 años hace | 1

| aceptada

Respondida
Second derivative of Gaussian function
Sure: syms yo A w X c Gaussian=yo+A/w*exp(-((X-c)/w)^2); diff(Gaussian,w,2) I have cleaned up some redundancy in your expres...

casi 15 años hace | 0

Respondida
A problem using ode23s and lsqcurvefit
You need to learn some debugging techniques. Look at <http://www.mathworks.com/help/techdoc/matlab_env/brqxeeu-151.html Preventi...

casi 15 años hace | 0

Respondida
pde solver
This would be hard to solve numerically because it is ill-defined. Any function of the form |f(c*z-b*t)| is a solution.

casi 15 años hace | 0

Respondida
Minimization falls in wrong minima
This problem seems under-constrained. A rotation matrix |R| should satisfy |R.' = inv( R )| and should have a total of three ind...

casi 15 años hace | 0

| aceptada

Respondida
Output values from a loop
Do you use the MATLAB Editor? You should because it has some very useful diagnostics. Look at the right margin of the editor and...

casi 15 años hace | 0

Respondida
Create plot with specified handle?
I doubt it. If you could create one plot with handle |32|, you could create another, and then it wouldn't be unique any more. Th...

casi 15 años hace | 0

Respondida
Odd triangles using Matlab's contour and contourf functions
I think your main problem is that there aren't many data, so it is hard to make nice contours out of it. Look at the bit-mapped ...

casi 15 años hace | 0

| aceptada

Respondida
plot transperant 3d sphere
As you suggested yourself, you can use |sphere| to generate the sphere: r = 24.04; [x,y,z] = sphere(50); x0 = 16.5; y0 = 14.8...

casi 15 años hace | 5

Respondida
Any idea on how to create a n by n square matrix.
Use |meshgrid|: npanels=3; %number of panels dP=2.4/npanels; %equal length panels P=[-1.2+(2.4/npanels)/2:dP:1.2-(2.4/npa...

casi 15 años hace | 2

Respondida
How to multiply a vector with each column of a matrix most efficiently?
I don't find that. If my input is clear t=(1:1000)'; A=rand(length(t),200); [n,m] = size(A); %% 1. Looping tic for...

casi 15 años hace | 0

Respondida
I need help.
Thank you for formatting it. Do you use the MATLAB editor? It displays syntax errors on the right margin as red lines. You can ...

casi 15 años hace | 1

| aceptada

Respondida
Why is it used?
As written, your code cannot possibly run because of some of the spaces. I will substitute underlines: I=find(and(dR > min...

casi 15 años hace | 0

Respondida
resolution of PDE
Here is one error: in this line, pl = [C1(1);q0-Cl(2)]; the first |C1| is |C| followed by the numeral |1|, but it should...

casi 15 años hace | 0

Respondida
Using MATLAB with Chessboard arrangements problem
If the positions don't need to be legal, you can use combinatorial calculations. For example, let's first suppose that you can't...

casi 15 años hace | 1

Respondida
Load a Text File in a GUI
Based on your description of the file, this code might be able to read the file: fid = fopen('testInput.txt'); data2 =...

casi 15 años hace | 0

| aceptada

Respondida
Incorrect equilibrium values using fsolve
The answer provided by |fsolve| looks better than yours: >> odefun_dynamic_droop([2.6605e-07 3.6300e-06 2.5009e-06]) a...

casi 15 años hace | 0

Respondida
Find the Error - FZero Function. Constant loop.
The root of the problem is that you're trying to solve for |NCons = NFirm| by minimizing each of these functions at each step. T...

casi 15 años hace | 0

| aceptada

Cargar más