Skip to main content
4 votes
Accepted

Flux sign and face normal confusion in finite volume method

When dealing with conservation laws like your case, you can often make use of the divergence theorem (as you did). You can then express the fact that the total mass within your integration region is ...
MPIchael's user avatar
  • 2,985
4 votes
Accepted

Solving geodesics on triangular meshes gives negative distances

The solution to the final Poisson equation is defined only up to an additive constant. So you just need to shift the solution vector so the smallest value is zero.
Keenan's user avatar
  • 156
4 votes
Accepted

2D Heat equation solved with finite element method converges in skewed way

The problem was that the LHS of the weak form was wrong, the correct one is: $$ -\int u_{x} v_{x} + u_{y} v_{y} dxdy $$ Instead of $$ -\int (u_{x}+u_{y}) (v_{x}+v_{y})dxdy $$ Thanks to whpowell96 for ...
Boiler4562's user avatar
3 votes
Accepted

Problem with my Octave code (unsteady heat equation with FEM)

Reading quickly through your code, it seems that you never update B. So the term $T^n$ of the previous step remains unchanged, hence you are effectively computing the same step over and over again... ...
Laurent90's user avatar
  • 1,943
3 votes

Two-dimensional heat equation with Neumann boundary conditions: any hope to find an analytical solution?

Expanding (sort of) on @MPIchael's answer, you can pick any smooth function you like and plug it into the heat equation to give a problem to then work the other way. In numerical methods, we call this ...
Bill Barth's user avatar
  • 10.9k
3 votes
Accepted

Physical interpretation of L2 norm of heat equation solution

In these slide there are some comments about the energy. At pag 4 it focus on the fact that this energy is not a physical energy, but it is a mathematical tool. At pag 8 it observes that: From ...
Mauro Vanzetto's user avatar
3 votes
Accepted

Lumped matrices in thermal analysis using finite elements

No, you can't lump the $K$ matrix: that would not be a consistent approximation to the second-order differential operator it is supposed to represent. But if you're trying to be a bit more formal, ...
Wolfgang Bangerth's user avatar
3 votes
Accepted

Where am I making a mistake in solving the heat equation using the spectral method (Chebyshev's differentiation matrix)?

The answer is quite simple: You have to set the Neumann boundary condition $u_x(-1,x)=0$ explicitly Add following line (fifth line): ...
ConvexHull's user avatar
  • 1,379
2 votes
Accepted

Python Finite Difference Schemes for 1D Heat Equation: How to express for loop using numpy expression

numpy arrays and methods are incredibly helpful. They are usually optimized and much faster than looping in python. Always look for a way to use an existing numpy method for your application. ...
uhoh's user avatar
  • 1,058
2 votes

Finite Difference Grid Spacing and Scaling

Let's assume the following heat transient heat transfer equation in 1D : $$ \frac{\partial T} {\partial t} = \alpha \frac{\partial^2 T}{\partial x^2} $$ If we take its finite difference ...
BlaB's user avatar
  • 1,157
2 votes
Accepted

Heat equation with Neumann and Dirichlet conditions on same boundary

In the comments Christian directed me towards lateral Cauchy problems and the fact that this is a textbook example of an ill-posed problem. Following this lead, I found that this is more specifically ...
Steve's user avatar
  • 531
2 votes

(FEM) 1D time-dependent heat equation convergence problem

From the comments, I believe you are struggling with the FEM formulations and therefore fail to see what happens if the diffusion coefficient tends to zero. I don't have access to your book, but I ...
mfnx's user avatar
  • 172
2 votes

Simulating the heat equation with insulating material

Why even bother to simulate the left half? Why not just simulate the right half with the left BC being the constant value? Seems simpler and more accurate to what you want to actually model, because ...
EMP's user avatar
  • 2,089
2 votes

Flux sign and face normal confusion in finite volume method

Normal direction depends on the cell that you are writing equation for. the word outward is relative to the cell under study. In order to write equation for each of cells, i.e. $\Sigma \nabla T.n S_f=...
Naghi's user avatar
  • 235
2 votes
Accepted

Solution method of nonlinear heat transfer analysis

The Newton-Raphson method can be used to solve non-linear systems of equations. The first step is to write your system as a root finding problem: $$ f(T_n) = \left( \frac{C}{\Delta t} + K \right) ...
helloworld922's user avatar
2 votes
Accepted

Incorporating heat flux into Laplace Equation

Because a heat flux has a direction, and from what you are describing, you are adding a heat flux in the normal direction -- out of the domain. So if you started with a constant temperature plane and ...
Wolfgang Bangerth's user avatar
2 votes

Flux sign and face normal confusion in finite volume method

An extended answer. For more arbitrary meshes you have to consider that generally CFD/FEM solvers rely on generic data-structures with element and side lists: Element list Side list Consider the ...
ConvexHull's user avatar
  • 1,379
2 votes

Two-dimensional heat equation with Neumann boundary conditions: any hope to find an analytical solution?

TL DR: $$u_1(x_1) = \cos(2\pi~(\frac{x_1}{L_1}) - \pi) + 1$$ $$u_2(x_2) = \cos(2\pi~(\frac{x_2}{L_2}) - \pi) + 1$$ $$u(x,t) = \exp(-a t) u_1(x_1) u_2(x_1)$$ How to construct it: Sines and cosines are ...
MPIchael's user avatar
  • 2,985
2 votes

How to get a normalized gradient with FreeFem++?

I actually believe you can do this without needing to compute any complicated derivatives at all and only using basically what you have already. In FEM, you need to solve the Poisson equation $\Delta \...
whpowell96's user avatar
  • 2,636
2 votes
Accepted

Why does scipy Conjugate Gradient solver fail to converge for non-steady heat equation using Crank-Nicolson method

Continuous Formulation If I understood everything correctly you are trying to solve the heat equation on some domain $\Omega\subseteq \mathbb{R}^d$ with space-variant diffusivity $\kappa:\Omega\to [0,\...
lightxbulb's user avatar
  • 2,197
2 votes

How to handle non bilinear weak form?

You can move the term with $h T_\infty v$ to the right hand side so it becomes part of the linear form and the load vector.
knl's user avatar
  • 2,104
2 votes
Accepted

How to handle non bilinear weak form?

From your formulation it's still unclear what are the boundary conditions. But from the sentence about replacing $n\cdot \nabla u$ with $h(T_{\infty} - u)$ and your comment it sounds like your ...
lightxbulb's user avatar
  • 2,197
1 vote
Accepted

Heat equation in non-dimensional form behaving differently than in usual format

The applied division is fine, what went wrong here, is the application of Stoke's theorem. If you multiply with the test function you get following term: $$\int \frac{1}{c_p}\nabla\left(-k\nabla u\...
Bort's user avatar
  • 1,285
1 vote

How to use the Thomas-Algorithm to the Heat-diffusion-equation correctly

For a linear PDE, like the Laplace equation, when you discretize it you should get a linear system. Since you're 1D, the Thomas algorithm should be able to solve the system, and it's executed by ...
EMP's user avatar
  • 2,089
1 vote

Produce vertex displacements from volumetric shrinkage data on unstructured meshes

Based on our discussion in the comments, it seems vtkCellDataToPointData is what you want to convert volume shrinkage, which is stored as cell data, to nodal values ...
Mithridates the Great's user avatar
1 vote
Accepted

Simulating the heat equation with insulating material

I was expecting to see my solution in the right half and then having the left half mostly constant with a value of 0 and rapidly changing close to the interface for continuity. This would make sense ...
Stefano M's user avatar
  • 3,839
1 vote
Accepted

(FEM) 1D time-dependent heat equation convergence problem

You don't need MFnx answer to find out why if $k = 0$, $h$ also MUST be zero ($h = 0$). Look at your initial PDE for heat transfer: $$\rho C_{p}\frac{\partial T}{\partial t} = k \frac{\partial^{2} T}{...
Mithridates the Great's user avatar
1 vote
Accepted

Heat diffusion - Is this the correct approach to include Newmann boundary conditions?

The choice of the boundary conditions is dependent on the physics you want to model. If you're doing heat diffusion through a lake, and you want constant temp on top you'll have a different boundary ...
EMP's user avatar
  • 2,089
1 vote

Modeling Diodes in Autodesk CFD

The natural convection of the oil shouldn't be an issue and can be solved without any 'assumptions' to be made. The challenge comes with the diodes temperature control. CFD doesn't currently have a ...
user29108's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible