118 views (last 30 days)

Show older comments

This question was flagged by Walter Roberson

I

Rik
on 28 Feb 2021

Deleted comments:

Hello, i tried it with the following code:

syms rho_w w(t) p_u d_0 D_0 l h_0 t kappa m_St m_w rho_L c_w A_Q v(t) h_d lambda zeta n

eqn = (rho_w / 2) * w(t)^2 + p_u == (rho_w / 2) * (d_0 / D_0)^4 * w(t)^2 + ((l - h_0) / (l - h_0 + (d_0 / D_0)^2 * w(t) * t))^kappa + (rho_w / (m_St + m_w - rho_w * (pi / 4) * d_0^2 * w(t) * t)) * (rho_w * (pi / 4) * d_0^2 * w(t)^2 - (rho_L / 2) * c_w * A_Q * v(t)^2) * (h_0 + h_d - (d_0 / D_0)^2 * w(t) * t) + (rho_w / 2) * (d_0 / D_0)^4 * w(t)^2 * (lambda * ((h_0 - (d_0 / D_0)^2 * w(t) * t) / D_0) + sum(zeta,i,1,n)) ;

solx = solve(eqn, w(t))

This equation is now to be solved for w (t), but under the condition that v (t) is known.

Walter Roberson
on 31 Jan 2021

syms rho_w w(t) p_u d_0 D_0 l h_0 t kappa m_St m_w rho_L c_w A_Q v(t) h_d lambda zeta n

syms sum_of_zeta

eqn = (rho_w / 2) * w(t)^2 + p_u == (rho_w / 2) * (d_0 / D_0)^4 * w(t)^2 + ((l - h_0) / (l - h_0 + (d_0 / D_0)^2 * w(t) * t))^kappa + (rho_w / (m_St + m_w - rho_w * (pi / 4) * d_0^2 * w(t) * t)) * (rho_w * (pi / 4) * d_0^2 * w(t)^2 - (rho_L / 2) * c_w * A_Q * v(t)^2) * (h_0 + h_d - (d_0 / D_0)^2 * w(t) * t) + (rho_w / 2) * (d_0 / D_0)^4 * w(t)^2 * (lambda * ((h_0 - (d_0 / D_0)^2 * w(t) * t) / D_0) + sum_of_zeta) ;

syms W V

eqnW = subs(eqn, w(t), W)

solw = solve(eqnW, W)

char(eqnW)

Walter Roberson
on 1 Feb 2021

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

Start Hunting!