Answered
How to get unknown number of variables to be all same length through interpolation
Try this approach: V1 = sort(rand(1,5)); % Original Vector V2 = sort(rand(1,10)...

6 years ago | 0

Answered
ode15s error(Genetic algorithm for differential equation parameter identification)
I cannot follow your code. See Ode system solution with unknown constant for one example of an approach that generally works....

6 years ago | 0

| accepted

Answered
Chi-squared for multiple groups
Consider Perform One-Way ANOVA instead.

6 years ago | 0

Answered
ODE with time-varying coefficients
The Answers Comment and Answer windows are malfunctioning. I am having serious problems with the lack of formatting and other o...

6 years ago | 0

| accepted

Answered
designing a chebyshev type 2 high pass filter
Start with the cheb2ord function to define all the variables appropriately.

6 years ago | 0

| accepted

Answered
Differential eq of a hot storage tank
The time intervals the ODE solvers use are whatever you define them to be, since they have no inherent unit. In the ‘m’ assignm...

6 years ago | 0

Answered
Output numeric array from symbolic evaluation
After the loops: T = vpa(T) creates the entire array as decimal fractions.

6 years ago | 0

| accepted

Answered
How can I draw the fitted curve and find the initial slope of the attached plot?
Try this: D = readmatrix('Example.xlsx'); x = D(:,1); y = D(:,2); p = polyfit(x, y, 3); yfit = polyval(p, x); dp = poly...

6 years ago | 0

| accepted

Answered
Mathematical Modelling for parametric analysis
See the documentation for regress to understand how to work with the ‘carsmall.mat’ file. You should have it, since it’s been...

6 years ago | 0

| accepted

Answered
Invalid indexing for dsolve
The equations are nonlinear, and for most nonlinear differential equations, an analytic solution does not exist. Try this ins...

6 years ago | 0

Answered
How to extract numbers from .dat file
One option: fidi = fopen('Nasis Vangelis.dat','rt'); k = 1; while ~feof(fidi) readline = fgetl(fidi); C{k} = regex...

6 years ago | 0

Answered
read data from delimited text file
This is one of the more difficult files I have managed to import! See if this does what you want: fidi = fopen('water.txt')...

6 years ago | 0

| accepted

Answered
A simple LowPass Filter
Using a window inplies a FIR filter. Start with the fir1 function to design it, and freqz to analyse it. Filter your signal wi...

6 years ago | 0

Answered
Printing my Integration step by step
Use cumtrapz instead of trapz: L=F./W; lambda= 2*cumtrapz(W,L) figure plot(W, lambda) grid xlabel('W') ylabel('\int\la...

6 years ago | 0

| accepted

Answered
Cell-Matrix, I can't extract values
Change the code slightly to: F = openfig('phi_1.fig'); ax = gca; lines = findobj(ax, 'Type','Line'); for k = 1:numel(lines)...

6 years ago | 0

| accepted

Answered
Mesh with griddata, how eliminate undesidered extra surface
Without your data, posting an exact solution (if one even exists) is not possible. One possibility is that your data are actu...

6 years ago | 1

Answered
why surface plot is connecting its edges?
Try this for the file provided, and the others that likely have similar formats. Note — It is only necessary to reshape the ...

6 years ago | 0

| accepted

Answered
Help finding R^2 value for curves
I appreciate your quoting my code! The value is not difficult to calculate. One example using a much simpler single-var...

6 years ago | 1

| accepted

Answered
Predicting the kinetic constant of a reaction based on experimental data
If you have the Global Optimization Toolbox, the code I attached will estimate the parameters with reasonable accuracy, although...

6 years ago | 0

| accepted

Answered
Trouble with my function
You need to tell your ‘derivative’ function what ‘y’ is. Changing ‘derivative’ to an anonymous function (for my convenience) ...

6 years ago | 0

Answered
Error using plot3 - Vectors must be the same length
See if this does what you want: theta = [0:0.101:pi/2,3*pi/2:0.01:2*pi]; rho = sqrt(cos(theta)); [x,y]=pol2cart(theta,rho); ...

6 years ago | 0

| accepted

Answered
Plotting a Sequence over a Given Interval
I have no idea. I would just do something like this, and hope for the best with respect to whatever that exp() call is suppos...

6 years ago | 0

| accepted

Answered
help pease, how to use syms? why this is not working?
It is working. Ths eolution is simply not as straightforward as it might first appear. Consider: syms h Q = 10; k = 50...

6 years ago | 1

| accepted

Answered
How can I resolve Error Using max function
I am not certain what you want. One option is to enclose all the arguments within square brackets [], effectively concatenati...

6 years ago | 0

| accepted

Answered
Coordinates parameter & colormap
Try this for the plot: figure scatter(T(:,1),T(:,2),10,T(:,3),'filled') set(gca, 'XColor','none', 'YColor','none', 'Gri...

6 years ago | 0

Answered
Generate GA Plot after the algorithm has finnished
I am not certain what you want to do. If you want to save the interim results to plot later (or to save them in the event tha...

6 years ago | 0

| accepted

Answered
2d filled contour plot
Try this: x = [0;0.03;0.03;0.01;0.01;0;0.02;0.02;0.01;0;0.01;0.02;0.015;0.005;0.025;0.03;0.025;0.01;0.005;0;0.01;0.005;0]; y ...

6 years ago | 0

| accepted

Answered
ode45 function matrix dimensions problem
Do not use global variables! Pass the additional parameters as arguments to the function, and use an appropriate anonymous fu...

6 years ago | 0

Answered
Band-Stop Filter Design
You actually want the sos matrix and scaling factor, even if you do not realise it, since they create a stable filter when the t...

6 years ago | 0

Answered
New to matlab problem plotting
See: how to convert 2D graph to 3D? for one approach. The second image looks as though it was copied from my Answer in tha...

6 years ago | 1

| accepted

Load more