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

difference volVectorField and vectorField

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 21, 2018, 09:25
Default difference volVectorField and vectorField
  #1
Member
 
annan
Join Date: Nov 2016
Posts: 70
Rep Power: 6
annan is on a distinguished road
Hello everyone,

I am quite new to OpenFOAM, and I have some issues understanding the difference between vectorField and volVectorField, can anyone help me understand ?

Thank you very much

Annan
annan is offline   Reply With Quote

Old   December 13, 2018, 06:59
Default
  #2
New Member
 
Karl Yang
Join Date: Jul 2016
Posts: 11
Rep Power: 6
HoneyBadger is on a distinguished road
Quote:
Originally Posted by annan View Post
Hello everyone,

I am quite new to OpenFOAM, and I have some issues understanding the difference between vectorField and volVectorField, can anyone help me understand ?

Thank you very much

Annan

I do have the same question? Have you figure it out?
HoneyBadger is offline   Reply With Quote

Old   January 4, 2019, 02:32
Default
  #3
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,168
Rep Power: 29
olesen will become famous soon enougholesen will become famous soon enough
The Field class is just a List with reference counting. So vectorField is really just a list of vectors.
The volVectorField contains the vectors for each cell (the internal field) and a list of ones for each boundary patch.

It probably makes sense if you look at the source code documentation.
olesen is offline   Reply With Quote

Old   January 4, 2019, 03:03
Default
  #4
New Member
 
Karl Yang
Join Date: Jul 2016
Posts: 11
Rep Power: 6
HoneyBadger is on a distinguished road
Quote:
Originally Posted by olesen View Post
The Field class is just a List with reference counting. So vectorField is really just a list of vectors.
The volVectorField contains the vectors for each cell (the internal field) and a list of ones for each boundary patch.

It probably makes sense if you look at the source code documentation.

Thank you Olesen for your replying. I also found some documents sharing the same idea that vectorField is only a list of vectors without geometric information, while volVectorField does. Thank you for confirming that. I think vectorField is a base class which derived to volVectorField, while itself probably is not very useful for users?


Regards
Juntao
HoneyBadger is offline   Reply With Quote

Old   January 8, 2019, 03:28
Default
  #5
Senior Member
 
Timofey Mukha
Join Date: Mar 2012
Location: Gothenburg, Sweden
Posts: 115
Rep Power: 11
tiam is on a distinguished road
A vectorField can certainly be useful, for instance for working with boundary data but not only. Compared to a List, besides for reference counting mentioned by Mark, a Field also has all sorts of mathematical operations implemented.
tiam is offline   Reply With Quote

Reply

Tags
openfoam 1712, openfoam 1806, programming

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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
dot product of vectorField and volVectorField sahm OpenFOAM 2 August 28, 2017 03:56
Multiplication of two volVectorField ChGr OpenFOAM Programming & Development 1 May 30, 2016 11:08
How to extract ONLY ONE Boundary data to make a VectorField File from volVectorField hy1112006 OpenFOAM Programming & Development 2 April 14, 2016 12:11
power of vectorField matthias OpenFOAM Programming & Development 0 August 19, 2014 08:52
Create a Vectorfield joskate OpenFOAM Pre-Processing 0 May 8, 2013 10:22


All times are GMT -4. The time now is 04:45.