2023-09-11T08:22:00.000-0400

Simcenter STAR-CCM+
Simcenter STAR-CCM+ Virtual Reality
Teamcenter Share
Simcenter Cloud HPC
Simcenter STAR-CCM+ Viewer
Simcenter STAR-CCM+ Application Specific Solutions

Use a modulation function on $Time to define $PseudoTime. This new, pseudo-time, function is periodic and can be used to interpolate an imported table.

When running transient, unsteady, CFD we may want to define a periodically varying boundary condition. Often this function can be defined from simple algebraic expressions, however, in some instances we may like to use a tabular input from experiment or defining one period of a complex function.
*Echo Cardiogram profile*

If the function can be defined from simple algebraic expressions, such as a simple sinusoidal function, we can simply use a, User Defined Field-function, such as:

Setting the above function to a pressure boundary, for example, would produce a pressure which oscillates with magnitude A at a frequency of B/(2*pi) about a value of D.

If the function cannot be defined from a simple algebraic expression, we can alternatively use a tabular input such as the “table(time)”. This table can be created in an external tool such as MS-Excel and imported into Simcenter STAR-CCM+ as a csv file.

However, for long transient runs with periodic boundary conditions it may be undesirable, and impractical, to define a table covering the entire simulated time. In some instances one period of data may also require many data points generating undesirably large tabular inputs. In this instance we can use a modulation function to interpolate a single period of data to obtain a continuous, periodic function.

For example lets imagine we are simulating the flow through an artificial heart valve. Consider we are given a simplified generic pressure profile for one heart beat event and would like to apply this as a time varying pressure boundary condition in our simulation.

*Here we can see this only gives us a single profile.*

We can now use the "interpolateTable" field function to convert a table of values into a filed function. If we were to simply interpolate the table by time, we would obtain a field function defining the same data as the table but interpolated into a field function. Here we would like our data to be interpolated with our periodic pseudo time function “$TimeMod”.

A*sin(B*$Time - C) + D

Setting the above function to a pressure boundary, for example, would produce a pressure which oscillates with magnitude A at a frequency of B/(2*pi) about a value of D.

If the function cannot be defined from a simple algebraic expression, we can alternatively use a tabular input such as the “table(time)”. This table can be created in an external tool such as MS-Excel and imported into Simcenter STAR-CCM+ as a csv file.

However, for long transient runs with periodic boundary conditions it may be undesirable, and impractical, to define a table covering the entire simulated time. In some instances one period of data may also require many data points generating undesirably large tabular inputs. In this instance we can use a modulation function to interpolate a single period of data to obtain a continuous, periodic function.

For example lets imagine we are simulating the flow through an artificial heart valve. Consider we are given a simplified generic pressure profile for one heart beat event and would like to apply this as a time varying pressure boundary condition in our simulation.

First, we can import our csv file as a table into Simcenter STAR-CCM+. The tables can be imported into STARCCM+ by selecting the “Tables” folder by right-clicking Tools > Tables and creating a new table from file.

Next, we can define a new pseudo time function. We were given 100 seconds of data so we would like our pseudo time function to always cycle over the values from 0 - 99.99… To accomplish this we can use a modulation function on time with a value of 100.

We can now use the "interpolateTable" field function to convert a table of values into a filed function. If we were to simply interpolate the table by time, we would obtain a field function defining the same data as the table but interpolated into a field function. Here we would like our data to be interpolated with our periodic pseudo time function “$TimeMod”.

The interpolate table function requires we give it a imported table were one of the columns defines a pre-existing field-function. This function will be used to interpolate the data given by another column using the interpolation method chosen {Step, Linear, or Spline}. Here we have setup the function to interpolate the pressure column by the time column with a spline interpolation. The simulation knows what the independent variable of our function is by the existing function we have linked it to ($TimeMod in this case).

We can now set our pressure boundary conditions method to field-function and select our interpolated function. Below we can see the plots of both our interpolated pressure profiles, one showing the interpolating with time and one the interpolation with our modulated time.

We can now set our pressure boundary conditions method to field-function and select our interpolated function. Below we can see the plots of both our interpolated pressure profiles, one showing the interpolating with time and one the interpolation with our modulated time.