dolfin team mailing list archive
-
dolfin team
-
Mailing list archive
-
Message #23314
[Bug 784774] [NEW] Saving tensor to compressed file in pvd format
Public bug reported:
This bug results in a malloc() memory corruption error. It occurs when attempting to save a tensor in compressed pvd format (something which works for scalar and vector quantities). The error is apparent when saving to (for example):
efile = File("strain_rate.pvd", "compressed")
When saving to an uncompressed file (e.g. efile =
File("strain_rate.pvd")) , no error is observed.
"""
CODE SNIPPET
"""
from dolfin import *
# Load mesh from file
mesh = Rectangle(0, 0, 1.0, 1.0, 10,10)
# Define function spaces
V = VectorFunctionSpace(mesh, "CG", 2)
# Create function
u1 = Function(V)
# Create file for storing solution
efile = File("strain_rate.pvd", "compressed")
# Attempt to save strain rate to file
eps_proj = project(sym(grad(u1)),TensorFunctionSpace(mesh,"CG",1))
efile << eps_proj
** Affects: dolfin
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of DOLFIN
Team, which is subscribed to DOLFIN.
https://bugs.launchpad.net/bugs/784774
Title:
Saving tensor to compressed file in pvd format
Status in DOLFIN:
New
Bug description:
This bug results in a malloc() memory corruption error. It occurs when attempting to save a tensor in compressed pvd format (something which works for scalar and vector quantities). The error is apparent when saving to (for example):
efile = File("strain_rate.pvd", "compressed")
When saving to an uncompressed file (e.g. efile =
File("strain_rate.pvd")) , no error is observed.
"""
CODE SNIPPET
"""
from dolfin import *
# Load mesh from file
mesh = Rectangle(0, 0, 1.0, 1.0, 10,10)
# Define function spaces
V = VectorFunctionSpace(mesh, "CG", 2)
# Create function
u1 = Function(V)
# Create file for storing solution
efile = File("strain_rate.pvd", "compressed")
# Attempt to save strain rate to file
eps_proj = project(sym(grad(u1)),TensorFunctionSpace(mesh,"CG",1))
efile << eps_proj
Follow ups
References