# Problems with saving results to file using trilinos

I am running code based on cbc.block, which use Trilinos as linear algebra backend.

Recently I tried to run the code in parallell, but I cannot write to file and I get the following error:

*** Error: Unable to update ghost values.

*** Reason: Not implemented by current linear algebra backend.

*** Where: This error was encountered inside GenericVector.h.

Would be so happy if anyone responded to my first question ever on this or any similar list :o)

Karen

## Question information

- Language:
- English Edit question

- Status:
- Answered

- For:
- DOLFIN Edit question

- Assignee:
- No assignee Edit question

- Last query:
- 2013-01-25

- Last reply:
- 2013-01-31

Johan Hake (johan-hake) said : | #1 |

update_ghost_values is implemented in EpetraVector so that should not be

the problem. Are you using another linear algebra backend?

If you are able to write a simple script that reproduces the error it

would be easier to find what is failing.

Johan

On 01/25/2013 10:45 AM, Karen Støverud wrote:

> New question #220121 on DOLFIN:

> https:/

>

> I am running code based on cbc.block, which use Trilinos as linear algebra backend.

> Recently I tried to run the code in parallell, but I cannot write to file and I get the following error:

>

> *** Error: Unable to update ghost values.

> *** Reason: Not implemented by current linear algebra backend.

> *** Where: This error was encountered inside GenericVector.h.

>

>

> Would be so happy if anyone responded to my first question ever on this or any similar list :o)

>

> Karen

>

Joachim Haga (jobh) said : | #2 |

This is a simple example that fails in parallel (with any linear algebra backend). It looks like update... isn't implemented in the Vector wrapper.

from dolfin import *

m = UnitSquareMesh(2,2)

V = FunctionSpace(m, 'CG', 1)

v = TestFunction(V)

b = assemble(v*dx)

u = Function(V, b)

f = File('u.pvd')

f << u

Johan Hake (johan-hake) said : | #3 |

Thanks for reporting.

This should now be fixed in trunk.

Johan

On 01/30/2013 10:31 PM, Joachim Haga wrote:

> Question #220121 on DOLFIN changed:

> https:/

>

> Joachim Haga posted a new comment:

> This is a simple example that fails in parallel (with any linear algebra

> backend). It looks like update... isn't implemented in the Vector

> wrapper.

>

> from dolfin import *

> m = UnitSquareMesh(2,2)

> V = FunctionSpace(m, 'CG', 1)

> v = TestFunction(V)

> b = assemble(v*dx)

> u = Function(V, b)

> f = File('u.pvd')

> f << u

>

Joachim Haga (jobh) said : | #4 |

Thanks Johan! I suggest also 1.1, since it's a straightforward bug.

Den 30. jan. 2013 23:11 skrev "Johan Hake" <

<email address hidden>> følgende:

> Question #220121 on DOLFIN changed:

> https:/

>

> Johan Hake proposed the following answer:

> Thanks for reporting.

>

> This should now be fixed in trunk.

>

> Johan

>

> On 01/30/2013 10:31 PM, Joachim Haga wrote:

> > Question #220121 on DOLFIN changed:

> > https:/

> >

> > Joachim Haga posted a new comment:

> > This is a simple example that fails in parallel (with any linear algebra

> > backend). It looks like update... isn't implemented in the Vector

> > wrapper.

> >

> > from dolfin import *

> > m = UnitSquareMesh(2,2)

> > V = FunctionSpace(m, 'CG', 1)

> > v = TestFunction(V)

> > b = assemble(v*dx)

> > u = Function(V, b)

> > f = File('u.pvd')

> > f << u

> >

>

> --

> You received this question notification because you are a member of

> DOLFIN Team, which is an answer contact for DOLFIN.

>

Johan Hake (johan-hake) said : | #5 |

Then I guess you do not get the commit emails, because that was done

yesterday ;)

Johan

On 01/31/2013 08:51 AM, Joachim Haga wrote:

> Question #220121 on DOLFIN changed:

> https:/

>

> Joachim Haga proposed the following answer:

> Thanks Johan! I suggest also 1.1, since it's a straightforward bug.

> Den 30. jan. 2013 23:11 skrev "Johan Hake" <

> <email address hidden>> følgende:

>

>> Question #220121 on DOLFIN changed:

>> https:/

>>

>> Johan Hake proposed the following answer:

>> Thanks for reporting.

>>

>> This should now be fixed in trunk.

>>

>> Johan

>>

>> On 01/30/2013 10:31 PM, Joachim Haga wrote:

>>> Question #220121 on DOLFIN changed:

>>> https:/

>>>

>>> Joachim Haga posted a new comment:

>>> This is a simple example that fails in parallel (with any linear algebra

>>> backend). It looks like update... isn't implemented in the Vector

>>> wrapper.

>>>

>>> from dolfin import *

>>> m = UnitSquareMesh(2,2)

>>> V = FunctionSpace(m, 'CG', 1)

>>> v = TestFunction(V)

>>> b = assemble(v*dx)

>>> u = Function(V, b)

>>> f = File('u.pvd')

>>> f << u

>>>

>>

>> --

>> You received this question notification because you are a member of

>> DOLFIN Team, which is an answer contact for DOLFIN.

>>

>

Joachim Haga (jobh) said : | #6 |

Lovely! No, I'm just an innocent bystander ;)

On 31 January 2013 09:01, Johan Hake

<email address hidden>wrote:

> Question #220121 on DOLFIN changed:

> https:/

>

> Johan Hake proposed the following answer:

> Then I guess you do not get the commit emails, because that was done

> yesterday ;)

>

> Johan

>

> On 01/31/2013 08:51 AM, Joachim Haga wrote:

> > Question #220121 on DOLFIN changed:

> > https:/

> >

> > Joachim Haga proposed the following answer:

> > Thanks Johan! I suggest also 1.1, since it's a straightforward bug.

> > Den 30. jan. 2013 23:11 skrev "Johan Hake" <

> > <email address hidden>> følgende:

> >

> >> Question #220121 on DOLFIN changed:

> >> https:/

> >>

> >> Johan Hake proposed the following answer:

> >> Thanks for reporting.

> >>

> >> This should now be fixed in trunk.

> >>

> >> Johan

> >>

> >> On 01/30/2013 10:31 PM, Joachim Haga wrote:

> >>> Question #220121 on DOLFIN changed:

> >>> https:/

> >>>

> >>> Joachim Haga posted a new comment:

> >>> This is a simple example that fails in parallel (with any linear

> algebra

> >>> backend). It looks like update... isn't implemented in the Vector

> >>> wrapper.

> >>>

> >>> from dolfin import *

> >>> m = UnitSquareMesh(2,2)

> >>> V = FunctionSpace(m, 'CG', 1)

> >>> v = TestFunction(V)

> >>> b = assemble(v*dx)

> >>> u = Function(V, b)

> >>> f = File('u.pvd')

> >>> f << u

> >>>

> >>

> >> --

> >> You received this question notification because you are a member of

> >> DOLFIN Team, which is an answer contact for DOLFIN.

> >>

> >

>

> --

> You received this question notification because you are a member of

> DOLFIN Team, which is an answer contact for DOLFIN.

>

## Can you help with this problem?

Provide an answer of your own, or ask Karen Støverud for more information if necessary.