Statistics
0 Questions
6.807 Answers
RANK
14
of 298.634
REPUTATION
16.850
CONTRIBUTIONS
0 Questions
6.807 Answers
ANSWER ACCEPTANCE
0.00%
VOTES RECEIVED
1.957
RANK
of 20.631
REPUTATION
N/A
AVERAGE RATING
0.00
CONTRIBUTIONS
0 Files
DOWNLOADS
0
ALL TIME DOWNLOADS
0
RANK
of 161.859
CONTRIBUTIONS
0 Problems
0 Solutions
SCORE
0
NUMBER OF BADGES
0
CONTRIBUTIONS
0 Posts
CONTRIBUTIONS
0 Public Channels
AVERAGE RATING
CONTRIBUTIONS
0 Highlights
AVERAGE NO. OF LIKES
Feeds
Display data in a while loop as a table
clear, clc format longg f=@(x) x^3-5; df=@(x) 3*x^2; [n,X,Y] = newtonimproved_4_7(f,df,1,0.00001); t=table((1:n).',X',Y'); ...
ongeveer 3 uur ago | 0
Constraints to a Second Order Curve Fit
x = [150, 190, 400, 330, 115, 494].'; y = [1537, 1784, 3438, 2943, 1175, 4203].'; C = [x.^2,x,ones(numel(x),1)]; d = y; lb =...
ongeveer 8 uur ago | 0
How to express constants of integral
MATLAB's "int" only returns one possible antiderivative. If you want to show the free integration constants, you could use "ds...
ongeveer 9 uur ago | 2
| accepted
solve set of inequalities and plot the solution
A = [-0.0664057051742095,0.0900076050430003;... 0.147476397055133,0.160063987615969;... -0.122381054306963,0.1252339...
1 dag ago | 0
| accepted
Fitting exponential using derivatives
As far as I understand, your model is a differential equation dr/dt = a*1.5^(c+d)*(5-r)^c*(3-r)^d, r(0) = r0 with unknown para...
2 dagen ago | 0
Apply boundary condition (upper and lower limit) to parameters during the fitting using the function nlinfit?
If you restrict parameters by imposing upper and/or lower bounds, a statistical analysis of the results like that offered by "nl...
3 dagen ago | 0
The problem is that when I use vpa(U(x,t), 7) to get the solution with 7-digit decimal precision, MATLAB still outputs a very long and complicated expression. how do I fix it?
The documentation says xVpa = vpa(x,d) uses at least d significant digits instead of the value of digit...
3 dagen ago | 0
how to solve 2DOF linear time variant differential equations in matlab with non-diagonal mass, stiffness and damping matrixes
x0 = [0;0;0;0]; tspan = [0 13.28]; [T,X] = ode45(@fun,tspan,x0); for i = 1:numel(T) dxdt = fun(T(i),X(i,:)); q1ddot(i) ...
4 dagen ago | 1
How can I solve the problem in integral code?
Loop over the values of the sigma-vector - thus call "vpaintegral" for each sigma value separately. Or alternatively make your ...
4 dagen ago | 1
| accepted
Warning: Error updating FunctionLine in using fplot
In R2024b, I get the warning (see above): Warning: Function behaves unexpectedly on array inputs. To improve performance, pro...
5 dagen ago | 0
find sequence in a matrix
I = [0 1 0 1 1 1 0 0 0 1 1 1 0 0 1 0 1 0]; k = 3; saved = k + find(diff(I(k:end))==-1,1) If I is a matrix, you will have to t...
5 dagen ago | 0
| accepted
Pass Additional Arguments into Guess Function for BVP
lambda = 15; additional_parameters = 22; solinit = bvpinit(linspace(0,pi,10),@(x)mat4init(x,additional_parameters),lambda); s...
7 dagen ago | 0
| accepted
Solve BVP with Arrays as Coefficients
If you have functions depending on x for a, b and f, you are done. If not, you can try the following: Use "interp1" to interpo...
7 dagen ago | 0
| accepted
Why the integration can not be calculated out correctly?
That's the best you can get, I guess: V = 0.46:0.01:1; for i = 1:numel(V) v = V(i); lower_x = 9.578251022212591 - v; ...
7 dagen ago | 0
| accepted
Not exactly the exact answer using Symbolic Math Toolbox
syms t f = sin(t); frms = sqrt(1/(2*sym(pi))*int(f^2,t,[0 2*sym(pi)])) % rms value from definition
8 dagen ago | 1
| accepted
How to implement time dependent heat generation
I leave the rest to you: %% Create thermal model PDE thermalmodel = createpde(1); %% Create Geometry R2= [3,4,-1.5,1.5,1...
10 dagen ago | 0
| accepted
2 eqns in 2D with different BCs applied to each variable on the same edge? On E1, u1=0 and du2/dn=0, on E2 u2=1 and =du1/dn=0. The solution is all zeros. Example code is below
I think applyBoundaryCondition (model, "mixed", Edge=1, u=0, EquationIndex=1,q=[0 0;0 0],g=[0;0]); applyBoundaryCondition (mod...
10 dagen ago | 0
| accepted
Error msg: Undefined function or variable 'optimproblem'. Error in optimize_plant_operation (line 6) prob = optimproblem('ObjectiveSense', 'maximize');
"optimproblem" was introduced in R2017b: https://uk.mathworks.com/help/optim/ug/optimproblem.html at the bottom of the page un...
12 dagen ago | 0
Computing velocity with Forward Euler method
@Riccardo Are you sure you can leave temperature fixed with a pressure difference of 12 bar ? And did you try plotting your re...
12 dagen ago | 0
model non-autonomous system with neural ode
You can easily convert your non-autonomous system into an autonomous one by defining an additional ODE y2 as dy/dt = y2, y(0...
12 dagen ago | 0
| accepted
Orthotropic Conductivity on Face
I found orthoK = [0.75*kappa; 0.85*kappa]; in the documentation - thus a column instead of a row vector.
14 dagen ago | 0
| accepted
Using fprintf in a for loop to display the output as a set of coordinate points
syms x y real y=x*(4-x)^3;dy=diff(y); x_roots=solve(dy,x); y_x_roots=subs(y,x_roots); for j=1 disp('The critical point(...
15 dagen ago | 0
| accepted
Average Flux Across Edge
Should be averageFlux = 1/(Nodes_Xa(end)-Nodes_Xa(1))*trapz(Nodes_Xa,flux_Xa)
15 dagen ago | 0
| accepted
What do you think of my numerical Jacobian, using the central-difference method?
It cannot be correct because F1,...,F6 are scalars, not functions. And if F1,...,F6 were functions, the 2*h expression must be...
17 dagen ago | 0
How should I compute the Jacobian for my equations of motion?
According to your description, at some stage of your procedure, the right-hand side of your ODE system is available as a symboli...
21 dagen ago | 0
| accepted
Trouble animating a double pendulum
theta_1 = 19*pi/180; theta_2 = 30*pi/180; l_1 = 1; l_2 = 1; g = 9.8; m_1 = 1; m_2 = 1; M = m_1 + m_2; dt = .00...
21 dagen ago | 0
Numerical Methods for Singular systems
The loop index i does not equal time t. So expressions like d_1=floor(1.5+sin(0.5*i*h)); x1(:,i-d_1-1) x2(:,i-d_1-1) x3(:,i...
25 dagen ago | 1
| accepted
Does anyone know how to use an IF statement with ODE's? I am trying to create an IF statement sigma > 0 , tau > 0 if dx(3,1) > 0, dx(1,1) > 0 and sigma = 0 , tau = 0 otherwise
You mean % linear ODEs dx(1,1) = alpha * y - beta * r * y; dx(3,1) = - theta * w + lambda * y * w - mu * w * w; if dx(1,...
28 dagen ago | 2
Integral Recurrence Formula Implementation
This seems to work: xl = 0; xu = 4; q = 12; C1 = 2; vl = (xl*sqrt(xl^2+C1^2)+C1^2*log(xl+sqrt(xl^2+C1^2)))/2; vu = (xu*sqr...
29 dagen ago | 0
| accepted
How to solve a thermal model? NEED HELP!!
Params = load('Params.mat'); S_matrix = load('S_matrix.mat'); MC = Params.MC; Q = Params.Q; S = S_matrix.S; T0 = 298.15; T...
29 dagen ago | 1
| accepted