# Questions tagged [fenics]

Questions about the finite element method software FEniCS and its subpackages (Dolfin, UFL, FFC).

91 questions
Filter by
Sorted by
Tagged with
39 views

### Add orthogonality constraint to PDE over entire domain finite element

I have a nonlinear differential equation for $u:\mathbb{R}^2\rightarrow\mathbb{R}^3$ that I can express in the form: $\nabla (g(u)_{ij} \nabla(u)^j) = 0$ which is similar to the "Nonlinear Poisson" ...
140 views

### Time-dependent Schrodinger equation implementation in FEniCS

For our Bachelors thesis we're trying to solve the Schrodinger equation $i\partial_tu = -\nabla^2u+Vu$ in FEniCS. Given the domain $[-5, 5]^2$ with an initial value of $u_0(x, y)=e^{(-2(x^2+y^2))}$ ...
75 views

### Heat diffusion simulation in a 3D piston using FENICS

I'm trying to simulate the heat diffusion in a 3D piston. I marked the boundaries on GMSH. I have used a Dirichlet BC of 300 on the top face of piston. But the results look abnormal. There is a ...
147 views

### Immersed boundary method in FEniCS?

I have looked at the FEniCS tutorials and documentation but I cannot find any mention to the possibility of implementing an immersed boundary method (IBM) for fluid dynamics. In particular, I want ...
118 views

### How to use natural logarithm inside Expression on FENICS

I'm trying to evaluate the exact solution of heat diffusion in circular plate. I'm not able to use the natural logarithm inside expression. ...
59 views

### DirichletBC definition on boundary subdomain for component of vector valued function in FEniCS

I am trying to impose a no-outflow condition for a velocity-field over a boundary sub-boundary domain in FEniCS. What I have find challenging is imposing the condition on a component of a vector-...
67 views

### FEniCS, refinement not 'respecting' domain boundary

Short question: how to ensure that extra points are not included as 'boundary' points after calling the refine function. More details. I am working with a hexahedral mesh in $3$d. Let $X$ be the set ...
33 views

### Setting up diffusion with integral B.C. in Fenics

I'm trying to model diffusion through a cylindrical domain $D = \{ (x,y,z) : x^2 + y^2 \leq 1, \;\; 0 \leq z \leq 1\}$. The is an initial concentration of the diffusant at the upper flat surface, ...
153 views

### Fenics: solving the same PDE multiple times

I am new to Fenics and just started reading the tutorial Solving PDEs in Python. For simplicity, we can refer to simplest example, page 17 (the linear poisson equation), despite not necessary. My ...
63 views

### FEniCS implementation of Maxwell equations for a dipole antenna

someone knows where I can find a FEniCS implementation of Maxwell equations for a dipole or other type of antenna? I mean a dipole antenna with an arbitrary geometry of every 'leg' in the dipole.
30 views

### Coupling 1D-3D problem in FENICS

I was wondering whether any of you knew if FENICS has the capability to solve coupled 1D-3D problems that are linear non-iteratively? As an example, pipes embedded in a porous domain will provide ...
251 views

### Library for Discontinuous Galerkin method: FEniCS vs deal.ii

I am aware that both FEniCS and deal.ii are capable of solving problems with Discontinuous Galerkin (DG) method. I would like to specifically know if any of these two softwares can cater these ...
610 views

### Spectral Element vs Finite Element

I am trying to understand the difference between SEM and FEM. If I go by this paper, spectral element methods are a subset of FEM methods and the only difference lies in the choice of basis functions. ...
414 views

119 views

### Penalization parameter for DG with jump penalization

I adapted this FEniCS code for my problem and I'm wondering if there is any good resource about how to choose the penalty parameter $\alpha$? Best case would be, if I can define it through some ...
112 views

### Computable alternative to “almost everywhere”

I am working with finite elements for Maxwell's Equations (i.e. with Nedelec's edge elements) and for computation I'm using the FEniCS-project. While implementing the Augmented Lagragian Method, I ...
112 views

### Hello word in FEniCS? [closed]

I am trying to start using FEniCS, but have a problem with the simple hello world examples given in the books. Could you please give me the simplest hello world ...
73 views

### Anyone knows where I can find a simple FEniCS code where I can understand basic implantation? [closed]

I found this one, but does not work: http://www.karlin.mff.cuni.cz/~hron/warsaw_2014/pl2014_lecture5.pdf
668 views

224 views

### FENICS subdomains - restriction/ prolongation operators

I am trying to implement my own multigrid method in fenics. Is there any "smart/ fenics" way how to assemble subdomains and obtain restriction/ prolongation operators ? Thanks!
129 views

### Petrov-Galerkin enrichment method for Darcy equation

I was reading about Petrov-Galerkin Enrichment Method for Darcy equations. Here are a couple papers that discuss this in detail: A Petrov–Galerkin enriched method: A mass conservative finite element ...
226 views

### Please explain the meaning of these Boundary conditions [closed]

I am trying to learn Gmsh and Fenics and was looking at an example which shows the application of Boundary conditions on a simple Poisson problem. Here is the link: http://fenicsproject.org/...
305 views

### Comparing various implementations/software packages for large-scale finite element simulations

I currently use FEniCS and Deal.II to solve various FEM problems. I am also writing my own implementation of these problems by directly implementing the data structures, routines, and solvers within ...
337 views

### Stationary 2D/3D Navier-Stokes source code

Trying to solve stationary Navier-Stokes problem for incompressible laminar Newtonian fluid. I've found a couple solutions for instationary Navier-Stokes equations (like FeniCS examples or CFD Python)...
377 views

### Filling out a mesh (for Fenics FEM)

I have been using Fenics to model some simple electrostatic problems, but now I need to simulate more complicated geometries. Assuming I have created a mesh of several objects, and know their ...
1k views

### Poisson equation with pure Neumann boundary conditions (using FEM)

I am trying to derive the correct variational form for the Poisson equation with pure Neumann boundary conditions, and an additional contraint $\int_{\Omega} u \, {\rm d} x = 0$, as described in this ...
198 views

520 views

### Tensor notation in fenics [closed]

Within Fenics what ordering is used for storing vectors as upper triangular matrices? Th:e question really is I define a green Lagrange strain tensor in the following way: ...
600 views

### Integrating an Ordinary Differential Equation over a domain in Finite Element Methods

I'm trying to get a deeper understanding of the Finite Element Method (FEM) to better understand what I do in COMSOL and FEniCS. The sketch below shows the problem that I want to solve in FEM. The ...
613 views

### Basic Finite Element Method (FEM) question: assembly and re-assembly

I'm reading up on the Finite Element Method (Zienkiewicz's Book), so I understand better what I'm doing in FEniCS and COMSOL. Currently, I'm wondering about this: Using FEM to solve fluid flow ...
460 views

### PETSc Krylov Subspace and nullspace

How is the nullspace correction implemented in the PETSc conjugate gradient solver? I searched the source code and documentation, but could not find references on the actual implementation. For ...