|
[Sponsors] |
compiled errors while using DimensionedField<Type, GeoMesh> |
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
October 3, 2020, 03:46 |
compiled errors while using DimensionedField<Type, GeoMesh>
|
#1 |
New Member
Chaoran Guan
Join Date: Aug 2019
Posts: 5
Rep Power: 7 |
I encountered a compiled error while using Dimensioned<tensor, volMesh>. Here is what I wrote in the createFields.H of the icoFoam:
Code:
volTensorField Ut = fvc::grad(U); DimensionedField<tensor, volMesh> Ud = Ut.internalField(); Info << Ud << endl; Info << Ud.T() << endl; Code:
error: no matching function for call to ‘T(const Foam::Field<Foam::Tensor<double> >&, const Foam::Field<Foam::Tensor<double> >&)’ Foam::T(result(), *this); Code:
template<class Type> void T(Field<Type>& res, const UList<Type>& f); Code:
template<class Type, class GeoMesh> tmp<DimensionedField<Type, GeoMesh>> DimensionedField<Type, GeoMesh>::T() const { tmp<DimensionedField<Type, GeoMesh>> result ( DimensionedField<Type, GeoMesh>::New ( name() + ".T()", mesh_, dimensions_ ) ); Foam::T(result(), *this); return result; } So, I modify the above code: Code:
Foam::T(result(), *this); Code:
Foam::T(result.ref(), *this); And I was using openFOAM 8 version. Is this a bug that has not been noticed in OpenFOAM yet? |
|
October 4, 2020, 14:29 |
|
#2 |
Senior Member
Hrvoje Jasak
Join Date: Mar 2009
Location: London, England
Posts: 1,907
Rep Power: 33 |
This is a bug - missed in script changes. Can you report it please in the bug tracker?
Hrv
__________________
Hrvoje Jasak Providing commercial FOAM/OpenFOAM and CFD Consulting: http://wikki.co.uk |
|
October 4, 2020, 22:33 |
|
#3 | |
New Member
Chaoran Guan
Join Date: Aug 2019
Posts: 5
Rep Power: 7 |
Quote:
|
||
October 14, 2020, 11:48 |
|
#4 | |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,714
Rep Power: 40 |
Quote:
https://develop.openfoam.com/Develop.../-/issues/1868 |
||
Tags |
bugs, dimensionedfield, fieldfunctons |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
[solidMechanics] Support thread for "Solid Mechanics Solvers added to OpenFOAM Extend" | bigphil | OpenFOAM CC Toolkits for Fluid-Structure Interaction | 686 | December 22, 2022 10:10 |
Building OpenFOAM1.7.0 from source | ata | OpenFOAM Installation | 46 | March 6, 2022 14:21 |
LES, Courant Number, Crash, Sudden | Alhasan | OpenFOAM Running, Solving & CFD | 5 | November 22, 2019 03:05 |
decompose dependent solution | arionfard | OpenFOAM | 3 | December 10, 2018 10:36 |
AMI interDyMFoam for mixer nu problem | danny123 | OpenFOAM Programming & Development | 8 | September 6, 2013 03:34 |