Subject: [FFC-dev] Best way of doing powers of Functions?

From: Marie Rognes <[email-masked]>
Date: Tue, 11 Mar 2008 02:52:26 +0100

After diving into some non-linear elasticity, I've suddenly the need to 
do u^k, that is u to the power k, where u is some Function and k is an 
arbitrary natural number.

Is there a good way of doing this with ffc?

... and are there any immediate plans for making the NonLinearPDE work 
in PyDOLFIN?

-- 
Marie E. Rognes
Ph.D Fellow, 
Centre of Mathematics for Applications, 
University of Oslo
http://folk.uio.no/meg

---

From: Jed Brown <[email-masked]>
Date: Tue, 11 Mar 2008 09:12:57 +0100

> arbitrary natural number.

I actually need this when k is not an integer which means that it cannot
be done exactly, even with enough quadrature points.  For the case when
k is an integer greater than 2, it is likely not desirable to perform
the integration exactly because it entails too many quadrature points
(perhaps for k=2 as well) so my understanding is that you must make a
separate form to computes the nonlinear part.

Jed

---

From: "Garth N. Wells" <[email-masked]>
Date: Tue, 11 Mar 2008 09:44:38 +0000

> separate form to computes the nonlinear part.

The best way to do this will be to use quadrature. With the quadrature 
option you can specify the number of integration points you want to use. 
  Also, you'll can generate a correct linearisation. Kristian is 
currently working on some optimisations of quadrature code, after which 
we will add some illustrative demos.

Garth

> Jed
> 
> 
> ------------------------------------------------------------------------
> 
> _______________________________________________
> DOLFIN-dev mailing list
> [email-masked]
> http://www.fenics.org/mailman/listinfo/dolfin-dev

---

From: Marie Rognes <[email-masked]>
Date: Wed, 12 Mar 2008 01:02:20 +0100

Garth N. Wells wrote:
>>> do u^k, that is u to the power k, where u is some Function and k is 
>>> an arbitrary natural number.
>>
> option you can specify the number of integration points you want to 
> use.  Also, you'll can generate a correct linearisation. Kristian is 
> currently working on some optimisations of quadrature code, after 
> which we will add some illustrative demos.
>

Ok. Excellent!

---

From: Kristian Oelgaard <[email-masked]>
Date: Tue, 18 Mar 2008 17:33:22 +0100

> > which we will add some illustrative demos.

This might not happen in the nearest future, but there should be something in
the FFC manual about the QuadratureElement and how it can be used to solve a
non-linear problem.

Kristian
 
> FFC-dev mailing list
> [email-masked]
> http://www.fenics.org/mailman/listinfo/ffc-dev
>