Subject: Re: [Ufl] [Branch ~ufl-core/ufl/main] Rev 860: Redefine grad().T --> grad()

From: Marie Rognes <[email-masked]>
Date: Fri, 04 Dec 2009 20:31:41 +0100

[email-masked] wrote:
> ------------------------------------------------------------
> revno: 860
> committer: Anders Logg <[email-masked]>
> branch nick: ufl-dev
> timestamp: Tue 2009-12-01 18:09:26 +0100
> message:
>   Redefine grad().T --> grad()
>   

Have you updated div() too?

--
Marie

---

From: Anders Logg <[email-masked]>
Date: Fri, 4 Dec 2009 11:45:54 +0100

> Have you updated div() too?

No, I forgot that. I'll take a look.

Are there any other operators that do something strange and should be fixed?

--
Anders

---

From: Anders Logg <[email-masked]>
Date: Fri, 4 Dec 2009 11:54:10 +0100

> Are there any other operators that do something strange and should be fixed?

Strange... UFL seemed to already to compute the correct div:

  def div(self, o, a):
        i = Index()
        g = a[i] if a.rank() == 1 else a[...,i]
        return g.dx(i)

But I spotted what I think is a bug in the Div class. I pushed a fix
for that but I don't think it has any consequences.

--
Anders

---

From: Harish Narayanan <[email-masked]>
Date: Fri, 04 Dec 2009 11:18:55 +0000

>         g = a[i] if a.rank() == 1 else a[...,i]

This looks correct. Someone who uses curl should look at curl as well.

Harish

---

From: Marie Rognes <[email-masked]>
Date: Fri, 04 Dec 2009 21:17:05 +0100

> This looks correct. Someone who uses curl should look at curl as well.

The curl does what I expect it to do. (And the convention we used in the 
div/curl ffc paper.)

--
Marie

---

From: Anders Logg <[email-masked]>
Date: Fri, 4 Dec 2009 12:21:43 +0100

> This looks correct. Someone who uses curl should look at curl as well.

That would be Marie and Evan. :-)

--
Anders

---

From: "Garth N. Wells" <[email-masked]>
Date: Fri, 04 Dec 2009 11:24:12 +0000

> The curl does what I expect it to do. (And the convention we used in the

The manual should be updated too.

Garth

> -- 
> Marie
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~ufl
> Post to     : [email-masked]
> Unsubscribe : https://launchpad.net/~ufl
> More help   : https://help.launchpad.net/ListHelp

---

From: Anders Logg <[email-masked]>
Date: Fri, 12 Feb 2010 11:40:39 +0100

> The manual should be updated too.

Should be fixed now.

I thought that the definition of div of a matrix still needed to be
fixed (to differentiate over the last axis) but it looks like it was
correct already.

Can someone confirm this? Harish?

--
Anders

---

From: Harish Narayanan <[email-masked]>
Date: Mon, 15 Feb 2010 16:50:44 +0000

> Can someone confirm this? Harish?

I too thought that div() needed to be redefined, but I looked at [1]
it's OK.

Harish

[1] ufl/algorithms/transformations.py

---

From: Anders Logg <[email-masked]>
Date: Mon, 15 Feb 2010 17:55:36 +0100

> [1] ufl/algorithms/transformations.py

Yes, that's where I also looked.

ok, then we're all set.

--
Anders