Dear Robert,
I have a 2D body of hyperelastic material which contracts and I would like
to compute the total force developed by the body from the cauchy stress. I
am trying to follow some of your indications I found in this group, but I
still couldn't make it works. Could you please help me to fix the problem?
I am getting the following error:
key = (region.name, integral.order, integration)
AttributeError: 'dict' object has no attribute 'name'
I am trying to do the following, inside stress_strain post-processing
function:
def stress_strain(out, problem, state, extend = False ):
from sfepy.base.base import Struct
from sfepy.mechanics.tensors import StressTransform
from sfepy.mechanics.tensors import transform_data
from sfepy.discrete.common.mappings import get_normals
ev = problem.evaluate
field = problem.fields['displacement']
region = problem.domain.regions['Gamma']
integral = problem.integrals['i2']
n = get_normals(field,integral,regions)
stress = ev('dw_tl_fib_a.1.Omega(f1.fmax, f1.eps_opt, f1.s, f1.fdir,
f1.act, v, u )',mode='qp', term_mode= 'stress');
F = ev('ev_def_grad.1.Omega(u)',mode='el_avg');
transform = StressTransform(F)
Cstress = transform.get_cauchy_from_2pk(stress)
T = Cstress*n;
Force = ev('ev_surface_integrate.2.Gamma(T)')
And here it is part of the problem configuration file.
fields = {
'displacement': ('real', 'vector', 'Omega', 1),
}
materials = {
'solid' : (None, 'get_elastic_pars'),
'load' : (None, 'linear_tension'),
'f1' : 'get_pars_fibres1',
}
variables = {
'u': ('unknown field', 'displacement', 0),
'v': ('test field', 'displacement', 'u'),
}
regions = {
'Omega' : 'all',
'Fix1' : ('vertices in x < %.10f' % (fix_point + eps2), 'facet'),
'Fix2' : ('vertices in x > %.10f' % (fix_point - eps2), 'facet'),
'Fix' : ('r.Fix1 *v r.Fix2', 'facet'),
'Gamma' : ('vertices of surface','edge'),
}
ebcs = {
'fixb' : ('Fix', {'u.all' : 0.0}),
}
integrals = {
'i1' : ('v', 1),
'i2' : ('s', 2),
}

In examples/large_deformation/hyperelastic.py a rotation by displacements is applied. By using a similar function the vectors defining the force couples could be defined for dw_surface_ltr (IMHO). Does it make sense?
r.
----- Reply message -----
From: "Andre Smit" <freev...(a)gmail.com>
To: <sfepy...(a)googlegroups.com>
Subject: Torque
Date: Sat, Dec 18, 2010 05:10
What is the best way to apply a torque load to a model?
--
Andre
--
You received this message because you are subscribed to the Google Groups "sfepy-devel" group.
To post to this group, send email to sfepy...(a)googlegroups.com.
To unsubscribe from this group, send email to sfepy-devel...(a)googlegroups.com.
For more options, visit this group at http://groups.google.com/group/sfepy-devel?hl=en.

Hi
Has there been anyone who has used 1D elements to perform analysis of a system of beams?
I have not found much information regarding the use of 1D elements and how one would assign geometric properties to this type of element.
Any help would be much appreciated.
Kind regards
Mishal Mohanlal

Hi Robert,
I was looking for a postprocessing method to calculate the displacements for points on the surface of the mesh that are not necessarily node points. Precisely I need a interpolation function that gives me the displacement of these points. The input would be the already calculated linear elastic problem from my earlier example with the node displacements as result.
In the sfepy documentation I found the probing described here: http://sfepy.org/doc-devel/primer.html#sec-primer
Is this the right way to solve the interpolation? Do you recommend something different?
Thank you and regards,
Kathrin

Hi Robert,
I have a specific request which derives from my work to couple SfePy with
SPARRKS (an open source kMC solver by Sandia National Labs). In essence, I
would like a way to recreate the "under the hood" steps that occur inside
the typical for loop presented in many examples:
for step, time, state in tss():
....
I have dug into the source code and came up with what I thought were the
equivalent lines from sfepy.solvers.ts_solvers --> SimpleTimeSteppingSolver:
totalsteps = 3
for i in range(totalsteps):
#### solving commands
state = tss.solve_step(tss.ts, state0)
staten1 = state.copy(deep=True)
problemInstance.advance(tss.ts)
However, I have found that "state" remains equivalent to "state0", so I
know I've missed some crucial bit of understanding here. I have attached a
simplified version of my code (a diffusion problem solving an initial
gaussian profile over a 1d finite element mesh) that shows my
implementation details.
In greater detail, I will briefly describe our convergence strategy between
the FE and kMC domains and how it pertains to the SfePy functionality we
need. We need to be able to solve for the next FE state from an initial
state with a specific boundary condition (essential/natural). The catch is
that we also need the ability to choose whether to accept this new state
(dependent on our convergence criteria) as the next time step OR if we need
to change the applied boundary condition (essential/natural) and resolve
from the same initial state. This iterative procedure continues until
convergence is attained and that final state is used as the next FE
timestep.
Thank you in advance for your time here, and please let me know if I can
clarify anything in the above. I know it's an atypical request due to my
unique implementation of SfePy.
Cheers,
James

Hi Robert,
Thanks for the quick reply! I have tried the options you have suggested but
I have not had success. When I attempt to set
problem.conf.options.save_steps, I find that the options dictionary is
apparently empty. I have attached a simplified version of my working 2D
diffusion code and mesh for reference. The line-numbers where I am
attempting to investigate and set the save_steps parameter are at 217-221.
Please let me know if you have any further advice! Dumping a .vtk every
timestep for my simulation run-time builds up gb's of data rather quickly.
Cheers,
James

Hi
Has anyone used 1D elements to perform structural analysis of beams/trusses ect?
I have not found much information regarding the use of 1D elements on sfepy
Any help would be greatly appreciated.

Hi,
I am very new to sfepy. I am currently working on an FSI project, and I want to use Sfepy for my simulation (open-source is must, and based on http://feacompare.com/sortbyfeatures.html, it seems that Sfepy is pretty feature-rich and has modern design). My main focuses are on the time-integrator and solution translator between interfaces. I want to use Sfepy as structure and fluid solvers.
So my questions are: a) is it possible to get data (through memory) in each step? Also, b) is it possible to modify bc's and loads from external sources in each step?
P.S. I know that I should do more self research before I post something here. But since the project schedule is very tight, and I do hope to get some quick answers. Thank you very much.
Best,
Chiao

Hi Robert,
I am running a linear elastic simulation, as in my examples described some weeks ago.
The current problem is as follows: After running the simulation with some small test meshes (3D with tetrahedrons) I changed to bigger meshes.
The first example, with 71759 nodes and 310106 tetrahedrons, worked fine. Now I switched to a mesh with 105579 nodes and 460442 tetrahedrons and get the following output:
sfepy: saving regions as groups...
sfepy: Omega
sfepy: Surface
sfepy: Bottom
sfepy: ...done
sfepy: updating variables...
sfepy: ...done
sfepy: setting up dof connectivities...
sfepy: ...done in 0.83 s
sfepy: matrix shape: (313416, 313416)
sfepy: assembling matrix graph...
sfepy: ...done in 3.52 s
sfepy: matrix structural nonzeros: 11941254 (1.22e-04% fill)
sfepy: updating materials...
sfepy: solid
sfepy: f
sfepy: load
sfepy: ...done in 0.80 s
sfepy: nls: iter: 0, residual: 2.878127e+07 (rel: 1.000000e+00)
Can't expand MemType 1: jcol 311926
Do you have a suggestion what the problem could be?
Thanks for your help.
Kathrin

Hello,
under the applications section on the homepage it mentions:
"flow of a two-phase non-Newtonian fluid medium in a general domain - oil expression in screw presses/extruders"
is there already work done on the implementation of non-Newtonian flow in Sfepy?
and what about application to extruders?
regards,
Niels