CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

define time varying location of nodes

Register Blogs Community New Posts Updated Threads Search

Like Tree4Likes
  • 1 Post By ghorrocks
  • 1 Post By Jiricbeng
  • 1 Post By ghorrocks
  • 1 Post By Jiricbeng

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 11, 2017, 07:52
Default define time varying location of nodes
  #1
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
hi
i have location of almost 400 points of my geometry in time, and i want to define this motion in ansys cfx
i tried using function and editing it with a ccl but in didn't work
it seems that i have to use a user routine but i don't know how, so help me please!
f.yn is offline   Reply With Quote

Old   May 11, 2017, 08:21
Default
  #2
Senior Member
 
urosgrivc
Join Date: Dec 2015
Location: Slovenija
Posts: 365
Rep Power: 11
urosgrivc is on a distinguished road
You will definitly have to provide more data about your simulation.
What is it about
urosgrivc is offline   Reply With Quote

Old   May 11, 2017, 08:52
Default
  #3
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
it's left ventricle of human heart
in some points i extracted locations, for example this is the x-component of one point in time:
t x
0.0 66.8695
0.04 66.428
0.08 65.3977
0.12 61.1296
0.16 60.3938
0.20 59.5107
0.24 59.0692
0.28 58.7748
0.32 58.922
0.40 58.922
0.44 59.3635
0.48 59.9522
0.52 60.5409
0.56 61.424
0.60 61.5712
0.64 61.5712
0.68 62.307
0.72 63.0429
0.76 63.6316
0.80 63.7788
0.84 63.926
0.88 64.0732
0.92 64.9562
0.96 65.5449
1.00 67.1638

i have this type of data about displacement of 400 points in x-y-z directions and now i want to define this displacement in cfx to define wall motion
f.yn is offline   Reply With Quote

Old   May 11, 2017, 08:57
Default
  #4
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,854
Rep Power: 144
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
If the geometry is known in advance (ie no FSI) then generate a series of geometries describing the geometry at each time increment, mesh them all and then do a simulation where you use each mesh for a short period of time then stop the simulation and restart on the next geometry and interpolate the initial conditions from the results of the previous one.

You can define all these geometries and meshes parameterically, so generating them is not necessarily as scary as it may appear.
f.yn likes this.
ghorrocks is offline   Reply With Quote

Old   May 11, 2017, 09:13
Default
  #5
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
If the geometry is known in advance (ie no FSI) then generate a series of geometries describing the geometry at each time increment, mesh them all and then do a simulation where you use each mesh for a short period of time then stop the simulation and restart on the next geometry and interpolate the initial conditions from the results of the previous one.

You can define all these geometries and meshes parameterically, so generating them is not necessarily as scary as it may appear.
thanks!
can you be more specific? specially about how to interpolate the initial condition
and wall should move the fluid inside, does this method apply force to fluid?
f.yn is offline   Reply With Quote

Old   May 11, 2017, 11:14
Default
  #6
Senior Member
 
Jiri
Join Date: Mar 2014
Posts: 221
Rep Power: 13
Jiricbeng is on a distinguished road
If I understand it correctly:
you know points x,y,z (left ventrical) and displacements x,y,z for each point.
And you want to run a simulation including the periodic motion of the ventrical, right? If so, you can use mesh deformation technique (periodic mesh motion), you can define the frequency of the motion, it is similar to a flutter analysis. It is not difficult to set.
f.yn likes this.
Jiricbeng is offline   Reply With Quote

Old   May 11, 2017, 12:20
Default
  #7
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
Quote:
Originally Posted by Jiricbeng View Post
If I understand it correctly:
you know points x,y,z (left ventrical) and displacements x,y,z for each point.
And you want to run a simulation including the periodic motion of the ventrical, right? If so, you can use mesh deformation technique (periodic mesh motion), you can define the frequency of the motion, it is similar to a flutter analysis. It is not difficult to set.
i have locations
i have to set x,y and z component of displacement with expression,that's the problem! don't know how to import the data i have to cfx, i don't have a equation and if i had, i must define 400 equation for all 400 nodes individually!!
f.yn is offline   Reply With Quote

Old   May 11, 2017, 20:01
Default
  #8
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,854
Rep Power: 144
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
If you can define a mesh deformation using a CEL expression of similar then the mesh deformation method described by Jiri is the best option. If that is too complex and you need more complex solid modelling to get the shapes then consider the approach I described previously.

If you are saying you have 400 nodes you want to move then Jiri's option using CEL sounds impractical. You could do it using user fortran, but that would still be a little clumsy I suspect. So then consider the approach I suggested.

Quote:
how to interpolate the initial condition
Just a normal simulation restart using the initial conditions interpolation.

Quote:
wall should move the fluid inside, does this method apply force to fluid?
Yes, providing you also use moving mesh to smooth the motion out between meshes.

A final comment: This is going to be a complex simulation which will take a lot of development which ever way you are doing it. If you are a CFX beginner then you have no hope of completing it, please do a simpler simulation. If you are experienced at CFX you will know the options which have been discussed so far.
f.yn likes this.
ghorrocks is offline   Reply With Quote

Old   May 12, 2017, 04:54
Default
  #9
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
Quote:
Originally Posted by ghorrocks View Post
If you can define a mesh deformation using a CEL expression of similar then the mesh deformation method described by Jiri is the best option. If that is too complex and you need more complex solid modelling to get the shapes then consider the approach I described previously.

If you are saying you have 400 nodes you want to move then Jiri's option using CEL sounds impractical. You could do it using user fortran, but that would still be a little clumsy I suspect. So then consider the approach I suggested.



Just a normal simulation restart using the initial conditions interpolation.



Yes, providing you also use moving mesh to smooth the motion out between meshes.

A final comment: This is going to be a complex simulation which will take a lot of development which ever way you are doing it. If you are a CFX beginner then you have no hope of completing it, please do a simpler simulation. If you are experienced at CFX you will know the options which have been discussed so far.
thank you so much!!!
i will try your approach in fluent, it has replacing mesh option
f.yn is offline   Reply With Quote

Old   May 12, 2017, 09:48
Default
  #10
Senior Member
 
Jiri
Join Date: Mar 2014
Posts: 221
Rep Power: 13
Jiricbeng is on a distinguished road
Well, I would really prefere to try the mesh deformation technique:

1) set the analysis as transient
2) In domain setting enable mesh motion: Mesh deformation - regions of motion specified (now you enabled that mesh can deform)
3) create .csv file as shown below (without the stars ) The csv will include x,y,z coordinates of your nodes and displacements in x,y,z.
You set also the frequency. This csv will be interpolated onto your mesh.

***************************
[Name]
mode1

[Parameters]
Frequency = 331 [Hz]
Maximum Displacement = 0.0005 [m]

[Spatial Fields]
Initial X,Initial Y,Initial Z

[Data]
Initial X [m], Initial Y [m], Initial Z [m], meshdisptot x [m], meshdisptot y [m], meshdisptot z [m], Sector Tag []
0.79202, 0.15263, -0.012177, -0.00000039438, 0.000019937, 0.000045797, 1
0.79186, 0.15374, -0.010593, -0.0000014854, 0.000020617, 0.000045203, 1
0.7919, 0.15343, -0.0086445, -0.0000023093, 0.000021531, 0.000045366, 1
.
.
.
etc
**************************

When you have prepared the csv, upload it into your CFX:
Tools -> initialize profile data -> your .csv.

4) In CFX go to the surface boundary of the ventrical which will be moving.
a) tick the "use profile data" + generate values
b) under mesh motion -> periodic displacement
You will see all the rows for x,y,z coordinate automatically filled by the expressions linked to the csv file.
Thats it.

Now, if you run the analysis, you can see in different transient results (.trn) how the mesh moves.
If you have surface adjacent to the oscilating, set to this adjacent surface also mesh deformation as "unspecified" instead of stationary. Because adjacent stationary surface can cause issues because it does not move and adjacent surface must oscilate.
f.yn likes this.
Jiricbeng is offline   Reply With Quote

Old   May 14, 2017, 09:44
Default
  #11
New Member
 
Join Date: Nov 2016
Posts: 18
Rep Power: 10
f.yn is on a distinguished road
Quote:
Originally Posted by Jiricbeng View Post
Well, I would really prefere to try the mesh deformation technique:

1) set the analysis as transient
2) In domain setting enable mesh motion: Mesh deformation - regions of motion specified (now you enabled that mesh can deform)
3) create .csv file as shown below (without the stars ) The csv will include x,y,z coordinates of your nodes and displacements in x,y,z.
You set also the frequency. This csv will be interpolated onto your mesh.

***************************
[Name]
mode1

[Parameters]
Frequency = 331 [Hz]
Maximum Displacement = 0.0005 [m]

[Spatial Fields]
Initial X,Initial Y,Initial Z

[Data]
Initial X [m], Initial Y [m], Initial Z [m], meshdisptot x [m], meshdisptot y [m], meshdisptot z [m], Sector Tag []
0.79202, 0.15263, -0.012177, -0.00000039438, 0.000019937, 0.000045797, 1
0.79186, 0.15374, -0.010593, -0.0000014854, 0.000020617, 0.000045203, 1
0.7919, 0.15343, -0.0086445, -0.0000023093, 0.000021531, 0.000045366, 1
.
.
.
etc
**************************

When you have prepared the csv, upload it into your CFX:
Tools -> initialize profile data -> your .csv.

4) In CFX go to the surface boundary of the ventrical which will be moving.
a) tick the "use profile data" + generate values
b) under mesh motion -> periodic displacement
You will see all the rows for x,y,z coordinate automatically filled by the expressions linked to the csv file.
Thats it.

Now, if you run the analysis, you can see in different transient results (.trn) how the mesh moves.
If you have surface adjacent to the oscilating, set to this adjacent surface also mesh deformation as "unspecified" instead of stationary. Because adjacent stationary surface can cause issues because it does not move and adjacent surface must oscilate.
thanks for your reply
but the displacement will be different in every 30ms
and because of the change in boundary conditions i can't use periodic displacemnet
f.yn is offline   Reply With Quote

Reply

Tags
moving mesh, user routines


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Other] Contribution a new utility: refine wall layer mesh based on yPlus field lakeat OpenFOAM Community Contributions 58 December 23, 2021 03:36
pimpleDyMFoam computation randomly stops babapeti OpenFOAM Running, Solving & CFD 5 January 24, 2018 06:28
same geometry,structured and unstructured mesh,different behaviour. sharonyue OpenFOAM Running, Solving & CFD 13 January 2, 2013 23:40
Installing OF 1.6 on Mac OS X gschaider OpenFOAM Installation 129 June 19, 2010 10:23
Errors running allwmake in OpenFOAM141dev with WM_COMPILE_OPTION%3ddebug unoder OpenFOAM Installation 11 January 30, 2008 21:30


All times are GMT -4. The time now is 01:15.