Answered
Fimplicit not plotting properly
fun1=@(x,y) a.*x.^2+2*h.*x.*y+b*y.^2+2*g.*x+2*f.*y+c; a=2; h=0; b=0; g=3/2; f=1/2; c=7; fimplicit(fun1,[-3 2 -12 -5])

alrededor de 2 meses ago | 1

| accepted

Answered
How to rotate a video 180 degrees?
vidName = 'xylophone.mp4'; vidPath = strcat(videosPathToBeEdited, vidName); V = VideoReader(vidName); % read the complete ...

alrededor de 2 meses ago | 1

| accepted

Answered
How to loop function for a 2 column matrix
You do not need a loop - the distance function is vectorized and accepts vector-inputs. You simply need to use indexing to get w...

alrededor de 2 meses ago | 1

| accepted

Answered
differential evalution code Error using * Inner matrix dimensions must agree.
@(x)sum((minus((x(1)),V).*sin(2.*pi.*x(2).*t+x(3)).^2))/n % ^ % | % ...

alrededor de 2 meses ago | 1

| accepted

Answered
Hi there, can anyone help me create a function which calculates the least amount of notes and coins needed for any amount entered in ATM please ?
You can treat it as an optimization problem - since intlinprog is used you can be sure to find optimal solutions: Amount = inpu...

alrededor de 2 meses ago | 1

Answered
converting from integer time to datetime in 3-hourly data
Heres an approach: I believe the idea behind this: is that the integer values start counting by 1979-12-01 00:00 --> 0 19...

alrededor de 2 meses ago | 0

Answered
Stop Sign Detection Using Thresholding
There is a detailled example of a - you wont believe it - Stop Sign detector in the documentation here: https://de.mathworks.co...

alrededor de 2 meses ago | 0

Answered
problem with plotting a 1D graph
You dont save the results of find anywhere - try: % plot of time : U(5,6,t) t=linspace(0,2,0.15); for i=1:np % np number o...

alrededor de 2 meses ago | 0

Answered
Fmincon Errors with objective function definition
Try: x0 = [0 0]; LB = [-5 -5]; UB = [7 7]; ii = 1; for jj = 0:0.01:1 xopt(ii,:) = fmincon(@funhw2q1, x0, [], [], [],...

alrededor de 2 meses ago | 2

| accepted

Answered
Particle size measurement from SEM image
You can use the imfindcircles function (example here) which gives back the radii of detetcted circles in combination with houghl...

alrededor de 2 meses ago | 0

Answered
System of differential equations with many input arguments.
Try: % l stands for \tau, u for \Theta, v for a, o for b (from utility) and j for ΞΎ syms S(t) P(t) c(t) h(t) z(t) A b d e g k ...

alrededor de 2 meses ago | 0

| accepted

Answered
How can I solve an equation with more than one variable?
You can solve for all cases in one calculation and save teh result as a matrix by using a function handle: G=44*10^3; b=2.95e-...

alrededor de 2 meses ago | 0

| accepted

Answered
median line in the histogram of the image
A = randn(100,1) histogram(A) xline(median(A),'-r','LineWidth',2)

alrededor de 2 meses ago | 1

| accepted

Answered
Index exeeded error for ode45 function
This is an ode of order 4 - so odeToVectorField will reformulate it to a system of 4 ode with order 1: >> pretty(V) / ...

alrededor de 2 meses ago | 1

| accepted

Answered
Help with creating a certain 16x16 Matrix
Hint: read about the function zeros and ones and also about array indexing.

alrededor de 2 meses ago | 0

Answered
Merge different excel files into one big matrix with a loop
Here is how to start with this: https://de.mathworks.com/help/matlab/import_export/process-a-sequence-of-files.html If the fil...

alrededor de 2 meses ago | 0

| accepted

Answered
Inserting Elements in middle of 1-D, 2-D, N-D Array
This may help https://de.mathworks.com/help/matlab/ref/griddedinterpolant.html X = [ 1.0 2.0 3.0 4.0 5.0 6.0 7....

alrededor de 2 meses ago | 0

Answered
delete elements from the given array
X(2:2:end-1) = []

alrededor de 2 meses ago | 0

Answered
Solver stopped prematurely. fmincon stopped because it exceeded the function evaluation limit, options.MaxFunctionEvaluations = 3.000000e+03.
You have to give the options to the solver and to insert the MaxFunctionEvaluations Option into the optimoptions struct: MyValu...

alrededor de 2 meses ago | 0

| accepted

Answered
Hi everyone! How do i want to plot graph the graph for this values?
To plot single points use scatter: x = 5 y = 2 scatter(x,y) plot can not visualize single points, but vectors: x = 5:10 y ...

alrededor de 2 meses ago | 0

| accepted

Answered
Error using dde23 : Derivative and history vectors have different lengths.
You did not define your constants - i took some fake values for them. n and T are unused. Also for good reasons, try to avoid gl...

alrededor de 2 meses ago | 0

Answered
Is it possible to vectorize this loop?
w_new = (sum(w + A.*B(:),2))';

alrededor de 2 meses ago | 0

| accepted

Answered
How can I solve this BVP problem which is second-order ODE with variable coefficient?
Your function handle appears to be incorrect: syms y(x) eq = diff(y,x,2) + ((1-10*x^2)/x)*diff(y,x,1) == 0; [V,S] = odeToVect...

alrededor de 2 meses ago | 0

| accepted

Answered
Error using odearguments (line 93) must return a column vector
Add this line in your ode function at the last line: NameOfYourOutputVariable = NameOfYourOutputVariable(:); This should...

alrededor de 2 meses ago | 0

Answered
Error using odearguments (line 93) BANANA must return a column vector.
You make a vector of R1 with size 1x391 in the BANANA function. Thus you have a vector of 1x391 as result - one entry for every ...

alrededor de 2 meses ago | 0

| accepted

Answered
How to solve Error - Index in position 1 is invalid. Array indices must be positive integers or logical values.
A1 = load('Mtxj_FULL_ASCENDING.txt'); A2 = load('Mtxj_FULL_DESCENDING.txt'); B1 = load('N2j1c_FULL_ASCENDING.txt'); B2 = load...

alrededor de 2 meses ago | 1

| accepted

Answered
Solving a matrix equation with a parameter in the coefficient matrix
syms theta S F r = 0.025; h = 0.3; rho = 7850; g = 9.81; m = r^2 * pi * h * rho; phi = atan((0.15 - 0.15*sin(theta))/(0....

alrededor de 2 meses ago | 0

| accepted

Answered
How to solve this error while using ode15s.
%prob settings lb=[0 0 0 0 0 0 ]; ub= [100 120 1 100 110 20 ]; % parameters for differential evolution np=10; it=100; cr...

alrededor de 2 meses ago | 0

| accepted

Answered
Curve fitting with custom equation, not using toolbox
This example shows how to curve fit with the inbuilt basic function <https://de.mathworks.com/help/matlab/ref/fminsearch.html |*...

alrededor de 2 meses ago | 0

Answered
Minimize a function with 2 variables and 2 inequality constraints.
<https://de.mathworks.com/help/optim/ug/fmincon.html *|fmincon|*> appears to be the right choice for this. Note that you in fact...

alrededor de 2 meses ago | 0

| accepted

Load more