View Issue Details

IDProjectCategoryView StatusLast Update
0000404OpenFOAMBugpublic2012-02-01 12:29
Reporteruser19Assigned Tohenry  
PrioritynormalSeverityminorReproducibilityN/A
Status resolvedResolutionfixed 
Summary0000404: operator*(Vector2D<Cmpt>const&, Vector2D<Cmpt>const&) unusable
DescriptionThe outer product operator for two vectors defined also for Vector2D in Vector2DI.H is unusable because the typeOfRank meta-function always returns Tensor<Cmpt> for rank 2 since it has no nCmpt template argument which would allow it to distinguish between the 3D and 2D case.
Steps To ReproduceThe following code demonstrates the problem:

#include "vector2D.H"
#include "tensor2D.H"
using namespace Foam;
int main()
{
    vector2D v1(1.,2.), v2(3.,4.);
    tensor2D t = v1*v2;
}
TagsNo tags attached.

Activities

wyldckat

2012-01-31 21:33

updater   ~0000986

Question: If the outer product is to be disabled in 2D, then what happens if someone wants to create a template that is to be used for both 2D and 3D?
For example, a mechanical interaction solver, where interconnected particles are disturbed by surrounding fluid, in both 2D and 3D? ;)

henry

2012-02-01 12:29

manager   ~0000987

Thanks for the bug-report.

Resolved by commit b820d4a7219bb3df3fe65673cf34f583788d68be

Issue History

Date Modified Username Field Change
2012-01-31 20:12 user19 New Issue
2012-01-31 21:33 wyldckat Note Added: 0000986
2012-02-01 12:29 henry Note Added: 0000987
2012-02-01 12:29 henry Status new => resolved
2012-02-01 12:29 henry Resolution open => fixed
2012-02-01 12:29 henry Assigned To => henry