[Kratos] Write element results in gid

Víctor B victorbzs en yahoo.es
Jue Jun 11 20:11:04 CEST 2015

Thanks Pablo, it works! 

     El Jueves 11 de junio de 2015 19:38, Pablo Becker <pbecker en cimne.upc.edu> escribió:

 Hello Victor.First you must add the printing function to your element 
   //TO PRINT ELEMENTAL VARIABLES (ONLY ONE GAUSS POINT PER ELEMENT)    void FluidPhasePFEM22D::GetValueOnIntegrationPoints(const Variable<double>& rVariable,            std::vector<double>& rValues,            const ProcessInfo& rCurrentProcessInfo) { if (rVariable == VISCOSITY) { // Set output vector (for a single integration point) rValues.resize(1, false); rValues[0]=this->GetValue(VISCOSITY); } else if (rVariable == TAU) { // Set output vector (for a single integration point) rValues.resize(1, false); rValues[0]=this->GetValue(TAU); }  else // Default behaviour (returns elemental data) { rValues.resize(1, false); }  }

and then, from python, the command is :

Hope that helps,
On 11 June 2015 at 18:14, Víctor B <victorbzs en yahoo.es> wrote:

Hi everyone,
How I could write in the gid output from kratos variables by element?. I mean variables from the element database... I've tried with writeElementalResults but it doesn't work (I found a document from the internet with that method: writeElementalResults)

Thanks in advanced

Kratos mailing list
Kratos en listas.cimne.upc.edu

------------ próxima parte ------------
Se ha borrado un adjunto en formato HTML...
URL: http://listas.cimne.upc.edu/pipermail/kratos/attachments/20150611/665af6d5/attachment.htm 

Más información sobre la lista de distribución Kratos