← Back to team overview

ffc team mailing list archive

Re: ffc ValueError

 

Quoting Brandon Chabaud <brandonc1933@xxxxxxxxx>:

> Hi,
> 
> I coded a .form file for an elasticity problem that I'm trying to simulate,
> but I'm getting an error when I run ffc that I don't know how to fix.  Here
> is the part of my code that is giving me the error:
> 
> Element1 = VectorElement("Discontinuous Lagrange", "triangle", 0, 4)
> Element2 = VectorElement("Discontinuous Lagrange", "triangle", 0, 4)
> Element3 = VectorElement("Discontinuous Lagrange", "triangle", 0)
> Element4 = FiniteElement("Discontinuous Lagrange", "triangle", 0)
> combo = Element1 + Element2 + Element3 + Element4

I believe this will result in something like:
combo = ((Element1 + Element2) + Element3) + Element4

You want:

combo = MixedElement([Element1, Element2, Element3, Element4])
 
Kristian

> (z, w, v, q) = TestFunctions(combo)
> 
> Here is the error message I get when I type ffc -l dolfin -d1 Solid.form at
> the terminal:
> 
> This is FFC, the FEniCS Form Compiler, version 0.5.1.
> For further information, go to http://www.fenics.org/ffc/.
> 
> Preprocessing form file: Solid.form --> Solid.py
> 
> Traceback (most recent call last):
>   File "/home/grad/chabaud/local/bin/ffc", line 218, in <module>
>     sys.exit(main(sys.argv[1:]))
>   File "/home/grad/chabaud/local/bin/ffc", line 107, in main
>     execfile(script, {})
>   File "Solid.py", line 15, in <module>
>     (z, w, v, q) = TestFunctions(combo)
> ValueError: need more than 2 values to unpack
> 
> Does anyone know how to fix this?
> 
> Thanks.
> 




References