필터 지우기
필터 지우기

Need help to create this equation

조회 수: 1 (최근 30일)
Kevin Isakayoga
Kevin Isakayoga 2021년 1월 21일
댓글: Bjorn Gustavsson 2021년 2월 18일
Hi everyone, I am a little bit confused about this
Could someone helping me to create this? It seems that to many partial derivatives, since I am not good at it.
*you can assume the parameter by yourself or let them be in coefficient
Hope someone could help me to understand clearly how to perform this equation. Thankyou very much!
  댓글 수: 2
Kevin Isakayoga
Kevin Isakayoga 2021년 2월 17일
can somebody help me?
Thanks
Kevin Isakayoga
Kevin Isakayoga 2021년 2월 18일
편집: Kevin Isakayoga 2021년 2월 18일

댓글을 달려면 로그인하십시오.

채택된 답변

Walter Roberson
Walter Roberson 2021년 2월 17일
syms rho_eff_hcp
syms p_w(x,t)
syms w(p_w_)
syms w_r(t)
dw_dp_w = diff(w(p_w_),p_w_)
dw_dp_w = 
dp_w_dt = diff(p_w(x,t),t);
LHS = 1/rho_eff_hcp * dw_dp_w * dp_w_dt;
dp_w_dx = diff(p_w(x,t),x)
dp_w_dx = 
syms K
RHS_temp1 = K*w(p_w_)*dp_w_dx
RHS_temp1 = 
RHS_temp2 = diff(RHS_temp1,x)
RHS_temp2 = 
dw_r_dt = diff(w_r(t),t);
RHS = -RHS_temp2 + dw_r_dt;
eqn = LHS == RHS
eqn = 
Now you are faced with the problem that w should be a function of p_w instead of p_w_ but p_w is a function. You are trying to take the derivative of a function with respect to a function, which requires Calculus of Variations instead of regular calculas.
You also have three functions but only one equation. There is no hope that you would be able to resolve this symbolically, even if the equations were ODE instead of PDE.
  댓글 수: 9
Kevin Isakayoga
Kevin Isakayoga 2021년 2월 18일
I'm pretty sure that all of my coefficient such as dh/dw and Dh are correct.However, I just confuse my calculation and maybe my boundary condition was wrong.
Bjorn Gustavsson
Bjorn Gustavsson 2021년 2월 18일
No, it doesn't look right. When you write your C-N function you will get to a stage where you have to multiply the RHS with the inverse of the LHS-matrix. You have neither an inv nor a \ in your C-N section. Take a pen and paper, sit down and write out the expressions for the LSH and RHS matrices and then implement those expressions. You will get a step looking something lke this:
I_next = invMLHS*([Mrhs]*I_prev + Q_t_p_half);
HTH

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Calculus에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by