segunda-feira, 6 de julho de 2020

Glossary of basic concepts

State of matter: In physics, a state of matter is one of the distinct forms in which matter can exist. Four states of matter are observable in everyday life: solidliquidgas, and plasma.


Thermodynamic System: thermodynamic system is a body of matter and/or radiation, confined in space by walls, with defined permeabilities, which separate it from its surroundings.

Phase: In the physical sciences, a phase is a region of space (a thermodynamic system), throughout which all physical properties of a material are essentially uniform. Examples of physical properties include densityindex of refractionmagnetization and chemical composition. 

Phase boundary: In thermal equilibrium, each phase (i.e. liquidsolid etc.) of physical matter comes to an end at a transitional point, or spatial interface, called a phase boundary, due to the immiscibility of the matter with the matter on the other side of the boundary. This immiscibility is due to at least one difference between the two substances' corresponding physical properties.

Interface (matter): For a liquid film on flat surfaces, the liquid-vapor interface keeps flat to minimize interfacial area and system free energy. For a liquid film on rough surfaces, the surface tension tends to keep the meniscus flat, while the disjoining pressure makes the film conformal to the substrate

Phase Boundary Beer Image & Photo (Free Trial) | Bigstock

Solution: In chemistry, a solution is a special type of homogeneous mixture composed of two or more substances.

Homogeneus and heterogeneus mixture: homogeneous mixture is a solid, liquid or gaseous mixture that has the same proportions of its components throughout any given sample. In physical chemistry and materials science this refers to substances and mixtures which are in a single phase. This is in contrast to a substance that is heterogeneous.


Phase diagram: Is a type of chart used to show conditions (pressure, temperature, volume, etc.) at which thermodynamically distinct phases (such as solid, liquid or gaseous states) occur and coexist at equilibrium.

Miscibility: Is the property of two substances to mix in all proportions (that is, to fully dissolve in each other at any concentration), forming a homogeneous solution. The term is most often applied to liquids but also applies to solids and gases. For example, water and ethanol are miscible because they mix in all proportions.
Miscible Liquids: Definition & Examples - Video & Lesson ...

Thermodynamic Equilibrium: Is a system that are simultaneously in mutual thermalmechanical and chemical equilibria.

        Thermal Equilibrium: All temperatures in the system is the same. 0th law of thermodynamics.

        Mechanicam Equilibrium: the pressure in all points of the system is the same.

       Chemical Equilibrium: J. W. Gibbs suggested in 1873 that equilibrium is attained when the Gibbs free energy of the system is at its minimum value (assuming the reaction is carried out at constant temperature and pressure). What this means is that the derivative of the Gibbs energy with respect to reaction coordinate (a measure of the extent of reaction that has occurred, ranging from zero for all reactants to a maximum for all products) vanishes, signaling a stationary point. This derivative is called the reaction Gibbs energy (or energy change) and corresponds to the difference between the chemical potentials of reactants and products at the composition of the reaction mixture.[1] This criterion is both necessary and sufficient. If a mixture is not at equilibrium, the liberation of the excess Gibbs energy (or Helmholtz energy at constant volume reactions) is the "driving force" for the composition of the mixture to change until equilibrium is reached. The equilibrium constant can be related to the standard Gibbs free energy change for the reaction by the equation

Continuum Mechanics: Materials, such as solids, liquids and gases, are composed of molecules separated by space. On a microscopic scale, materials have cracks and discontinuities. However, certain physical phenomena can be modeled assuming the materials exist as a continuum, meaning the matter in the body is continuously distributed and fills the entire region of space it occupies. A continuum is a body that can be continually sub-divided into infinitesimal elements with properties being those of the bulk material.

domingo, 5 de julho de 2020

Computational Thermodynamics

MultiPhase basic theory

Welcome to hell! 

This IS a very complex topic, there's no way to get out instead of spending a LOT of time reading, studying, trying to understand, looking for every term that you do not understand, and trying to figure out what's going on behind the beautiful color maps that CFD shows...But, I'll try to explain most of the basics bellow in an organized and intuitive manner.

Be careful about where do you start looking at this theory, it can be presented for expert users, and most of them are not prepared for beginners, this is why I'm here.

Multiphase flow covers a wide range of problems, including suspended grain dust or coal dust, droplets and sprays, propellant burning, charring, soot, smoke formation, slurries, bubbles in liquids, rain, and sedimentation. Because each of these subjects has its own distinguishing characteristics, different scientific communities have formed that use their own specific formulations, approximations, and measurement methods. 

Example of two phase flow: air bubbles injection in a venturi (water) 
CFD image of the generation of bubbles with the venturi type ...

Velocity contours generated inside the venturi; a) simulation with ...

A major problem and point of continuing confusion in multiphase flows is the lack of a unique set of equations and supporting assumptions that fit every multiphase situation.

Multiphase flow is intrinsically a nonequilibrium process. Generally it is assumed that each phase is in local thermodynamic equilibrium, but that the different phases are not necessarily in equilibrium with each other. In the corresponding mathematical models, it is necessary to specify the rates of transfer of mass, momentum, and energy among the phases in order to close the set of equations. Multiphase flow equations may be derived from continuum mechanics constraints based on conservation of mass, momentum, and energy. However, these equations require additional phenomenological terms to described the additional phases and their interactions with each other.


There are 4 types of differences between a single-phase fluid and one with two or more coexisting phases:

(1) There are chemical changes that occur when chemical reactions change the relative numbers of molecules of each phase. These can also include special surface reactions at the phase interfaces. Then it is often necessary to treat the phases and species individually as well as consider their interactions. 

(2) There are thermal differences, which occur when the different phases have different temperatures and because velocity equilibration can be much faster than temperature equilibration. 

(3) There are dynamic differences, which occur when it is necessary to describe each phase by its own separate velocity field

(4) Finally, there are spatial separations, which means that the granularity of the different phases is large enough that it must be taken into consideration.


Many important multiphase flow problems involve the flow of “obstacles,” such as drops, bubbles, or solid particles, in a background gas or liquid flow. A number of levels of complexity have been postulated to treat these types of problems:

        (i) In single-fluid models, the different phases are considered a single fluid whose properties are composites of those of the various phases present. All phases of the flow are assumed to be closely coupled and thus move with the same velocity. Flows containing very small droplets or particles can often be treated this way, but such a model improperly describes rain for which the relative motion between air and water droplets is important. 

        (ii) In two-fluid models, it is assumed that the different phases move at very nearly the same mean velocity. However, the small velocity difference may be significant in differential compression or expansion or to describe settling of heavier particles over an extended period. 

        (iii) In multifluid models, each volume of fluid is characterized by a distribution of particle or droplet sizes and characteristics. Solving these equations is difficult and expensive because separate momentum equations are needed for each phase or particle size.


Liquid droplets in a background gas describe a wide range of problems from rain to atomization of liquid fuel. Types and levels of models used to study these problems include locally homogeneous flow models, which are similar to the single-fluid models, separated flow models, which are multifluid models, and drop life history models, which describe the detailed behavior of individual droplets. 

In locally homogeneous flow models, the gas and liquid phases are assumed to be in dynamic and thermodynamic equilibrium, so that the phases have the same velocity and temperature. This limiting case only accurately represents a spray consisting of very small drops. 

In separated flow models, the effects of finite rates of transport between the phases are considered. This is really a very broad category of models, ranging from those in which particulates are treated as Lagrangian particles in a continuum background to the case of full multiphase, multifluid continuum models such as those based on the types of equations shown above. 

The third type of model, drop-life history models, focuses on individual droplets and attempts to calculate their dynamic behavior self-consistently with changes in their environments.


OpenFOAM, how to get started?

If you are a complete new OpenFOAM user's, here is something that WHAT you need to know:

*
*
*

Linux for OpenFOAM user's

Here I'm gonna show some videos and tips about installing Linux Ubuntu to install OpenFOAM :)