Risposto
Help with the Deflection of a Plate in MATLAB
You are trying to solve the heat conduction equation with a homogeneous heat sink -q/D and boundary temperature 0. Is this the s...

oltre un anno fa | 0

| accettato

Risposto
Time dependent variable in plot.
The simplest method is to define x, compute y in a loop and plot: x = 0:0.1:15; for i = 1:numel(x) if x(i) >= 0 & x(i) < ...

oltre un anno fa | 1

| accettato

Risposto
Solving Advection Equation PDE with 2nd order Accuracy
Usual second-order schemes for the advection equation will always produce oscillations. Section 3.1.3 of the enclosed article su...

oltre un anno fa | 0

| accettato

Risposto
How can I use fmincon with general (user defined) nonlinear constraints?
g = @(x)deal([gl(x(1:nx),x(nx+1:nx+ny));gf(x(1:nx),x(nx+1:nx+ny))],[])

oltre un anno fa | 0

| accettato

Risposto
Assign fitlme output to a variable
See https://uk.mathworks.com/help/stats/linearmixedmodel.html The functions that can be applied to a fitlme object are: a...

oltre un anno fa | 0

| accettato

Risposto
Avoiding -0.0000 as an output
The results for d2,...,d4 aren't exactly 0 because of floating point errors in their computation. So without artificially manipu...

oltre un anno fa | 0

| accettato

Risposto
solve symbolic eigenvalue problem
If you want an analytical expression for the eigenvalues dependent on the parameter a, your matrix A must have dimension <= 4. ...

oltre un anno fa | 0

Risposto
problem to solve incorrrect
%% R-RRR clear all; clc; close all % Input data AB=0.325; %(m) BC=0.938; %(m) CD=0.675; %(m) CE=0.6; %(m) xD=0.8; %(m) y...

oltre un anno fa | 0

Risposto
Monte Carlo integration (hit or miss) to find the area of a circle of radius R
You compare the area of the square with side length R and corner points (0,0), (R,0), (R,R) and (0,R) with the area of the quart...

oltre un anno fa | 0

| accettato

Risposto
Finding parameters by fitting data to a system of ODEs with lsqnonlin
syms T1(t) T0(t) s d g eqn1 = diff(T0,t) == s - (d+g) *T0 ; eqn2 = diff(T1,t) == 2*d*T0 + (d-g)*T1; sol = dsolve([eqn1,eqn2])...

oltre un anno fa | 1

Risposto
Can pdepe solve a system of two second-order equations?
Goto https://uk.mathworks.com/matlabcentral/fileexchange/97437-pde1dm download the code, goto folder "documents" and study ex...

oltre un anno fa | 0

| accettato

Risposto
Error in flood_algorithm_rtc_pv (line 22) best_fitness = objective_function(best_solution, V_data, I_data); i don not understand this error
V_data and I_data must be of the same size. This is not the case in your code.

oltre un anno fa | 1

| accettato

Risposto
Issues solving a system of 2, second order, differential equations with ode45
Replace Cd = 0,45 ;% drag coef aircraft [-] rho_Air = 1,2 ...

oltre un anno fa | 2

| accettato

Risposto
simulating rolling 1 and 2 dice
You get a discrete pdf and cdf for the one and two dice-roll experiments you describe. So it doesn't make sense to smoothe resul...

oltre un anno fa | 0

Risposto
Very new to this and need help making a contour plot that shows correlation between weight of powder, bullet seating depth, and group size.
What is the problem using the contourf command ? All you need is the matrix MOA - I created it using random numbers. Varget = 4...

oltre un anno fa | 0

Risposto
Hello everyone, can anyone provide me the matlab code of FD SLIC algorithm or FM SLIC algorithm
https://uk.mathworks.com/matlabcentral/fileexchange/50184-slic-superpixels-for-e-cient-graph-based-dimensionality-reduction-of-h...

oltre un anno fa | 1

Risposto
Eliminate for-loop in recursive computation?
pn_out = cumprod(fact).*(-y).^(m+1) But I'm not sure this will be faster than your loop, especially y.^(1:n) compared to a recu...

oltre un anno fa | 0

| accettato

Risposto
What happens if I set both RelTol and AbsTol for ODE45 and/or both TolX and Tolfun for FSOLVE?
Do these functions refine steps, etc. until both requirements are satisfied or only one of them? Both. Read about error contro...

oltre un anno fa | 0

Risposto
Which statistic is minimized in curve fitting app
My question is what parameter/statistic is minimized to make a fit? SSE (maybe weighted if you specify weights for the measurem...

oltre un anno fa | 1

Risposto
Help with MATLAB symbolic toolbox
Can't you use "dsolve" ? If not, use % Find the value of C1 interm of C2 C1_sol = vpa(solve(yp, C1),4) % Sub C1 into equat...

oltre un anno fa | 0

| accettato

Risposto
Find limits satisfying a condition on an integral
x = linspace(0, 2*pi, 20); y = sin(x); lowLimIndex = 1; target = 2; [~,upLimIndex] = min(abs(cumtrapz(x(lowLimIndex:end),y(l...

oltre un anno fa | 0

| accettato

Risposto
How plot density of function ?
Your function only depends on x, not on x and y. I'm not sure how you want to make it 2d. Thus I simply defined g(x,y) = f(x)*...

oltre un anno fa | 1

Risposto
Problem with lsqnonlin and error function implementing a bovine pericardium constitutive model
strain(1) = 0 - thus you must remove the first data point since you divide by strain(i). Maybe your model function does not all...

oltre un anno fa | 1

Risposto
Error on Symbolic calculation : "Empty sym : 0-by-1"
v1 = [393 393 393 393 393 393 393 393 393 393 ; 3850 4340 4760 5320 5740 6160 6580 7140 7980 8960]; v2 = [408 408 408 408 408 4...

oltre un anno fa | 0

Risposto
Erron on Symbolic calculation [Case 2] : "Empty sym : 0-by-1"
If Λ is some kind of maximum likelihood function you try to maximize, I suggest you use "mle". We had this problem already - I ...

oltre un anno fa | 0

| accettato

Risposto
cosine of a matrix returns weird values.
"cos" and "tan" can be applied to angles in radians, not in degrees. Use "cosd" and "tand" instead.

oltre un anno fa | 0

| accettato

Risposto
How can I use Createpde to solve a fourth degree partial differential equation?
You have a system of two second-order differential equations. Thus instead of defining one equation, you have to define two and ...

oltre un anno fa | 1

Risposto
mono- objective optimization and multiopjective optimisation, I would like to use GA with option but there is a fault that I can't to resolve
You mean objective = @(x) 1.002 - ((1 - exp(-0.00003 * x)) ./ (0.00003 * (x + 1.5) + 0.00063 * (1 - exp(-0.00003 * x)))); a = ...

oltre un anno fa | 0

Risposto
How to place random CNT's in a box domain with random curves and orientation ?
https://uk.mathworks.com/matlabcentral/fileexchange/93250-generate-thick-fibers?s_tid=srchtitle

oltre un anno fa | 0

Risposto
how to use fmincon to optimize a functio with more than one control vector where the control vectors used in constrains also?
If all three vectors/matrices are to be treated as solution variables for "fmincon", use v = [p(:);X(:);L(:)] It's useful to t...

oltre un anno fa | 1

Carica altro