Fluids

Fluids

Topics related to Fluent, CFX, Turbogrid and more.

UDS Flow Rate

    • rkoomul
      Subscriber

      I am looking for some help in estimating the number of particles leaving a computational domain, when I am using a UDS. The computational domain is a cube. The UDS that I am using is (number of particles)/m^3. I specified a flux for the UDS at the bottom surface and defined a custom field function (UDS*cell volume) to get the number of particles in a cell.  I initialized the UDS to be zero at the beginning of the simulation. When I solved the transport equation by setting all boundaries as solid walls, and calculated the total number of particle in the cube (I used a volumetric report of “sum” of the custom field function), I got the exact number of particles released from the bottom surface for a given duration.  

      In the second case, I set the front surface as a velocity inlet, back surface as a pressure outlet, set the UDS flux at the bottom surface as the same as the first case, and initialized UDS to be zero and velocity to be uniform.  In this case, I would like to estimate how many particles leave the cube in a given duration. To do this, I created two reports, 1) volume flow rate out of the cube (m^3/s), 2) area-averaged value of UDS on the outlet surface (#/m^3). I multiplied these two values, which is supposed to give the number of particles leaving through the surface per second.  Then I multiplied this number by the timestep size, and added everything up for all timesteps to get the total number of particle went out of the cube. But, this number is coming out to be bigger than the total number of particle that are released from the bottom surface. Any comments why this approach is not working? Is there any easy way to estimate the number of particles leaving the cube?

      Thank you for your help.

    • Rob
      Forum Moderator
      Which model are you using to track the particles?
    • rkoomul
      Subscriber
      I have turned off the flow equation under "Solution -> Controls" and solving only the transport equation for the UDS. My UDS is defines as number of particles per unit volume. To get the number of particles in a cell, I am multiplying the UDS by the cell volume. In short, I am calculating the number of particles based on the UDS values. I am not tracking individual particles.
    • Rob
      Forum Moderator
      So no multiphase you're just tracking the scalar. Is the cell volume uniform? Whilst the UDS might be constant could that mean the number of particles is then based on the cell volume so the number entering (small cells) isn't balanced with those leaving (big cells)?
    • rkoomul
      Subscriber
      You are right, I am not modeling multiphase flow. It is just tracking the UDS and from there calculating the number of particles. The mesh is a uniform Cartesian mesh. What I am trying to do is to estimate the number of particle leaving the computational domain due to advection and diffusion, and to ensure the number of particle release during a time period is same as the number of particles inside the cube plus the number of particle left the computational domain. This is a testcase to validate simulation process and I would like to apply this for a more complicated system with multiple outlets.
    • Rob
      Forum Moderator
      As you're mimicking a tracer why not use species and simply monitor the mass flow through each section/outlet? Or use a multiphase model (possibly DPM) to track the particles?
    • rkoomul
      Subscriber
      The actual problem that we want to model is exosomes (signaling molecules) transport in tissues. There are millions of these molecules. Exosomes are nanometer in size and the distribution falls well within the continuum assumption. That is why I want to model this as continuum and track the concentration using UDS.
      Once I set all the boundaries as walls and I set no particles leave the computational domain, I can get UDS concentration very nicely and I can see the number of particles released is exactly the same as number of particles in the computational domain estimated from the UDS concentration. Only problem is when I set one boundary as an outflow, I am not able to accurately estimate number of particle leaving the domain. So, I am looking for a way to calculate this.
    • Rob
      Forum Moderator
      Mass flux times concentration maybe? You'd need to account for density too as scalars don't have a density.
    • rkoomul
      Subscriber
      Thank you Rob for the suggestions. I calculated the number of particle leaving the cube using mass flux approach that you mentioned. But I got the same result as I was getting before. Here are the steps that I used.
      1) Used a mass flow rate flux report at the outlet. The unit is kg/s
      2) Calculated the average value of UDS at the outlet. The unit is (number per m^3).
      3) Multiplied the numbers from steps 1 and 2, and divided by density. So, the unit is (kg/s)*(Number/m^3)*(m^3/kg). This will result the unit in (number /s)
      4) Multiplied number from step 3 with the time step.

    • rkoomul
      Subscriber
      Here is an update. Instead of using the mass flow rate and average value of the UDS on the boundary surface to estimate the number, I have written a DEFINE_ON_DEMAND function to add particle flow rate through each cell-face on the boundary to get the total number. This is also giving the same number as before.

    • Rob
      Forum Moderator
      Not sure, I trust the UDS to be returning the correct values, but equally they're not always clear when set up. What are you using for the UDS boundary?
    • rkoomul
      Subscriber
      Initially, I set the boundary condition for UDS as "Specified Flux" and set it as zero. Then, I used a UDF to extrapolate the cell values to the face. Both didn't make much difference in the final numbers. Here is the UDF that I used for the UDS boundary condition.
      DEFINE_PROFILE(UDS_Profile, t, i)
      {
      face_t f; cell_t c0;
      Thread *t0=t->t0;
      begin_f_loop(f, t)
      {
      c0 = F_C0(f, t);
      F_PROFILE(f, t, i) = C_UDSI(c0, t0, 0);
      }
      end_f_loop(f, t)
      }

    • Rob
      Forum Moderator
      Pass, I think we're also getting beyond where I can help under the Forum rules. Hopefully is around: he's not staff so isn't constrained by the same rules.
    • Syco Saab
      Subscriber

      It seems like you are trying to estimate the total number of particles leaving the computational domain by using the UDS approach and setting the boundary conditions. However, your second case where you are using a velocity inlet and pressure outlet is not giving you accurate results.

      One of the reasons for the discrepancy in the total number of particles could be due to the assumption that the UDS field is uniformly distributed throughout the domain, which may not be true for non-uniform flows. Additionally, there could be numerical errors in the simulation that are causing the discrepancy.

      To estimate the number of particles leaving the cube, you could try using a particle tracking approach. In this approach, you would inject a large number of particles at the inlet and track their trajectories as they move through the domain and exit through the outlet. You can then count the number of particles that exit the domain in a given time period to estimate the total number of particles leaving the cube. This approach can be computationally expensive, but it can give more accurate results.

      Another approach you could try is to use a mass balance approach. In this approach, you would track the total mass of particles in the domain at each timestep and calculate the mass leaving the domain through the outlet. You can then convert the mass to the number of particles using the density of the particles. This approach may be easier to implement and less computationally expensive, but it assumes that the density of particles is constant throughout the domain.

    • Muhammad Aslam
      Subscriber

      It's great to see that you're using computational fluid dynamics (CFD) to model particle transport in a cube. Based on your description, it seems like you're on the right track, but there are a few things you should consider when estimating the number of particles leaving the cube.

      First, it's important to note that when you set the front surface as a velocity inlet and the back surface as a pressure outlet, you're creating a flow through the cube, which means that particles are being transported through the cube by the flow. Therefore, it's not enough to simply estimate the number of particles leaving through the outlet surface. You also need to consider the number of particles that are being transported through the cube by the flow.

      To estimate the number of particles leaving the cube, you can follow a similar approach to the first case. You can calculate the total number of particles in the cube using a volumetric report of the custom field function (UDS*cell volume), but this time, you should subtract the total number of particles in the cube at the beginning of the simulation from the total number of particles in the cube at the end of the simulation. This will give you the net change in the number of particles in the cube, which is equal to the total number of particles that have left the cube. 

      Alternatively, you can use a particle tracking method to track the movement of individual particles through the cube. This method involves injecting a large number of particles into the cube and tracking their movement using CFD. You can then count the number of particles that exit the cube during a given duration to estimate the number of particles leaving the cube. Get more Information from https://dreamyworldinfo.com/gepco-online-bill-gepco-online-bill-check-dreamyworldinfo/

Viewing 14 reply threads
  • The topic ‘UDS Flow Rate’ is closed to new replies.