PolymathPlus Report
📈   Nonlinear Equation 2022-04-01 12:33 

# Example 17 - Single NLE with 'if' condition
# Terminal Velocity
# Verified Solution: vt = 0.015782
# Ref.: Comput. Appl. Eng. Educ. 6: 174, 1998

f(vt)=vt^2*(3*CD*rho)-4*g*(rhop-rho)*Dp
rho=994.6
g=9.80665
rhop=1800
Dp=0.208e-3
vis=8.931e-4
Re=Dp*vt*rho/vis
CD=if (Re < 0.1) then (24/Re) else (24*(1+0.14*Re^0.7)/Re)
vt(min)=0.0001
vt(max)=0.05


Calculated values

    Variable Value f(x) Initial Guess Initial f(x)
1 vt 0.01578162 1.4E-10 0.02505 4.9E00

    Variable Value Initial Value
1 CD 8.8426583 6.1187912
2 Dp 0.000208 0.000208
3 g 9.80665 9.80665
4 Re 3.6556385 5.8025572
5 rho 994.6 994.6
6 rhop 1800 1800
7 vis 0.0008931 0.0008931

Root Finding Plot

 -10 0 10 20 0 0.01 0.02 0.03 0.04 0.05 vt Zero Line f(vt)



Formatted equations

  f v t ( ) = v t ( ) 2 3 C D ρ 4 g ρ p ρ ( ) D p = 0
  ρ = 9 9 4 . 6
  g = 9 . 8 0 6 6 5
  ρ p = 1 8 0 0
  D p = 0 . 2 0 8 e - 3
  v i s = 8 . 9 3 1 e - 4
  R e = D p v t ρ v i s
  C D = i f R e < 0 . 1 ( ) t h e n 2 4 R e e l s e 2 4 + 1 0 . 1 4 R e ( ) 0 . 7 R e
  0 . 0 0 0 1 < v t < 0 . 0 5

Nonlinear equations

1 f(vt) = vt^2*(3*CD*rho)-4*g*(rhop-rho)*Dp = 0

Explicit equations

1 rho = 994.6
2 g = 9.80665
3 rhop = 1800
4 Dp = 0.208e-3
5 vis = 8.931e-4
6 Re = Dp*vt*rho/vis
7 CD = if (Re < 0.1) then (24/Re) else (24*(1+0.14*Re^0.7)/Re)

General Settings

Total number of equations 8
Number of implicit equations 1
Number of explicit equations 7
Elapsed time 0.00 sec
Reporting digits 10
Solution method safenewt
Max iterations 150
Tolerance F 1E-07
Tolerance X 1E-07
Tolerance min 1E-07