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

Making Diracbs delta function

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 30, 2008, 06:52
Default createMpSource.H:17: error: no
  #1
Senior Member
 
Henrik Rusche
Join Date: Mar 2009
Location: Wernigerode, Sachsen-Anhalt, Germany
Posts: 281
Rep Power: 18
henrik is on a distinguished road
createMpSource.H:17: error: no matching function for call to 'Foam::fvMesh::findCell(Foam::dimensionedVector&)'
/home/sea/OpenFOAM/OpenFOAM-1.5/src/OpenFOAM/lnInclude/primitiveMesh.H:662: note: candidates are: Foam::label Foam::primitiveMesh::findCell(const Foam::point&) const

The compiler trys to tell you that your variable sp of type dimensionedVector cannot automatically converted into a point. Try sp.value(). (Vectors can be converted into points)

Henrik
henrik is offline   Reply With Quote

Old   December 1, 2008, 05:14
Default Dear Henrik, Thank you very
  #2
New Member
 
Seiji Adachi
Join Date: Mar 2009
Location: Stuttgart, Germany
Posts: 5
Rep Power: 17
seiji_adachi is on a distinguished road
Dear Henrik,

Thank you very much for your reply.

Now I understand the difference between point(=vector) and dimensionedVector. The latter has a name and dimensions in addition to its value. This is why value() is needed to extract the value here. I made the same mistake at line 19. The code was rewrote as follows and it worked!

------------------------------------------------
// Add value of 1/v to deltaFunc at the point of sp!!!
label celli(mesh.findCell(sp.value()));
dimensionedScalar vol = mesh.V()[celli];
deltaFunc[celli] = 1.0/vol.value();
------------------------------------------------

Cheers,

Seiji
seiji_adachi is offline   Reply With Quote

Reply


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
Scalar Dissipation - delta function assumption Tristan Collins FLUENT 0 December 13, 2007 07:15
How to calculte \Delta t from CFL? Annie Main CFD Forum 4 March 23, 2005 09:48
LES delta turb Main CFD Forum 2 March 2, 2005 14:27
Making the density a function additional variab. Sebastien Perron CFX 4 August 8, 2003 08:03
Delta wing Thomas Pettersson FLUENT 1 April 22, 2000 20:18


All times are GMT -4. The time now is 07:02.