Convert differential equation to finite difference equation

Click For Summary

Discussion Overview

The discussion revolves around converting a differential equation related to the mass change of a sphere into a finite difference equation. It involves examining the relationship between mass, radius, and density, with a focus on the implications of integrating the density function over time and space.

Discussion Character

  • Technical explanation
  • Mathematical reasoning
  • Debate/contested

Main Points Raised

  • One participant presents a differential equation for mass change and attempts to convert it into a finite difference formula, questioning the appearance of a factor of 1/3 in the conversion.
  • Another participant points out the omission of an integral term that accounts for the local rate of change of the density function in the mass change equation.
  • There is a reiteration of the full form of the mass change equation, which includes both the density and the integral term, but confusion remains regarding the source of the 1/3 factor in the finite difference equation.
  • A participant discusses the case of constant density and derives a relationship for mass change, but questions persist about the origin of the 1/3 factor and the role of the radius cubed in the equations presented.
  • Further clarification is sought regarding the integration process and how it relates to the finite difference conversion, with concerns about the dimensionality of terms involved.

Areas of Agreement / Disagreement

Participants express differing views on the conversion process and the role of various terms in the equations. There is no consensus on how to properly account for the factor of 1/3 or the implications of the integral term in the finite difference formulation.

Contextual Notes

Participants note limitations in their understanding of how certain terms arise in the equations, particularly regarding the integration over time and the implications of density dependence on the mass change equation.

Hypatio
Messages
147
Reaction score
1
I have the differential equation

[itex]\frac{dM}{dt}=4\pi \rho(r,t)r(t)^2\frac{dr}{dt}[/itex]

which is the first term from

[itex]M(t)=4\pi\int_0^{r(t)}C(r,t)r(t)^2dr[/itex]

This describes the change in mass (M) of a sphere from a change in radius (r) given a density (rho) that depends on radius and time (t).

My problem is somewhat simple. I tried to convert this equation into a finite difference formula as follows:

[itex]M_1-M_0=4\pi \rho(r,t)r^2(r_1-r_0)[/itex]

where subscript 1 indicates the value at a new timestep.

I must be doing something wrong because the volume of a sphere requires a 1/3 to come from somewhere on the right hand side..
 
Physics news on Phys.org
Hmm..
1. Haven't you forgotten the integral term in dM/dt that sums up the rate of mass change due to the local rate of change of the density function?
 
arildno said:
Hmm..
1. Haven't you forgotten the integral term in dM/dt that sums up the rate of mass change due to the local rate of change of the density function?

Yes the full form is

[itex]\frac{dM}{dt}=4\pi \rho(r,t)r(t)^2\frac{dr}{dt}+4\pi\int_0^{r(t)}\frac{\partial \rho}{\partial t}x^2 dx[/itex]

but I don't see how the 1/3 for the first term can come from the additional term. My problem with the finite-difference conversion would remain if I assumed [itex]\rho[/itex] did not depend on time (thus removing the last term).
 
Hypatio said:
Yes the full form is

[itex]\frac{dM}{dt}=4\pi \rho(r,t)r(t)^2\frac{dr}{dt}+4\pi\int_0^{r(t)}\frac{\partial \rho}{\partial t}x^2 dx[/itex]

but I don't see how the 1/3 for the first term can come from the additional term. My problem with the finite-difference conversion would remain if I assumed [itex]\rho[/itex] did not depend on time (thus removing the last term).
As it should be.
Let's review the case in which the density is constant.

We then have:
[tex]M(t+\bigtriangleup{t})=\frac{4\pi\rho}{3}r(t+\bigtriangleup{t})^{3}\approx\frac{4\pi\rho}{3}(r(t)+\frac{dr}{dt}\bigtriangleup{t})^{3}\approx\frac{4\pi\rho}{3}r(t)^{3}+{4\pi}r(t)^{2}\frac{dr}{dt}\bigtriangleup{t}=M(t)+{4\pi}r(t)^{2}\frac{dr}{dt}\bigtriangleup{t}[/tex]
when we discard non-linear terms in the time interval.
 
Last edited:
I still don't see where 1/3 and the r^3 are coming from. It looks like it comes out of an integration over time but the dr/dt in such an integral seems to make it go to r^4.
 
Hypatio said:
Yes the full form is

[itex]\frac{dM}{dt}=4\pi \rho(r,t)r(t)^2\frac{dr}{dt}+4\pi\int_0^{r(t)}\frac{\partial \rho}{\partial t}x^2 dx[/itex]

but I don't see how the 1/3 for the first term can come from the additional term. My problem with the finite-difference conversion would remain if I assumed [itex]\rho[/itex] did not depend on time (thus removing the last term).

[tex]\frac{dM}{dt}=\frac{4\pi}{3} \rho(r^3,t)\frac{dr^3}{dt}+\frac{4\pi}{3}\int_0^{r^3(t)}\frac{\partial \rho}{\partial t}dx^3[/tex]
 

Similar threads

  • · Replies 0 ·
Replies
0
Views
4K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 4 ·
Replies
4
Views
4K
  • · Replies 25 ·
Replies
25
Views
4K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 4 ·
Replies
4
Views
6K
  • · Replies 1 ·
Replies
1
Views
3K