Re: [firedrake] Mixed system
OK, I will try to discuss this with Onno on Thursday once he has finished being Examiner In Chief. cheers --cjc On 10 October 2016 at 18:29, Mitchell, Lawrence < lawrence.mitchell@imperial.ac.uk> wrote:
On 10 Oct 2016, at 18:19, Colin Cotter <colin.cotter@imperial.ac.uk> wrote:
OK, this is the problem then - you need to find an appropriate preconditioner.
You need to start by finding an appropriate preconditioner for the system without the R space part.
Lawrence: once that is done, is there anything special to do to incorporate it into the system with the R space part [asking because you seem to have thought about this previously], or do we just recommend block preconditioning in this case?
I think you could use block first. It's easier. Otherwise I think the firedrake webpages sketch how to do sherman-morrison.
Lawrence _______________________________________________ firedrake mailing list firedrake@imperial.ac.uk https://mailman.ic.ac.uk/mailman/listinfo/firedrake
-- http://www.imperial.ac.uk/people/colin.cotter www.cambridge.org/9781107663916
Leaving the preconditioning aside for a while, I am trying to extend the problem into a mixed space of 5 function spaces, but get the error below when the solver is called. The code can be found here<https://bitbucket.org/annakalog/buoy2d/src/1289802514f6bbc8bc6ea6679aec5e717d327bbb/Inequality%20constraint/Mixed%20system/?at=master>. Any ideas what’s wrong? Thanks, Anna. Traceback (most recent call last): File "buoy-swe.py", line 128, in <module> (phi0, eta0, W0, Z0, LM_lam0_5, LM_mu0_5) = solvers_SV(LM_lam0_5, F_solver, phi_solver1, eta0, phi0, Z0, W0, eta1, phi1, Z1, W1, W0_5, rho, Mass, dt); File "/Users/matak/Documents/Simulations/Firedrake/Ship/Modules/Inequality constraint/Mixed system/solvers.py", line 176, in solvers_SV F_solver.solve() # Solve for phi0_5, eta1, lambda0_5, mu0_5 File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/variational_solver.py", line 201, in solve self.snes.solve(None, v) File "PETSc/SNES.pyx", line 537, in petsc4py.PETSc.SNES.solve (src/petsc4py.PETSc.c:170012) File "PETSc/petscsnes.pxi", line 261, in petsc4py.PETSc.SNES_Function (src/petsc4py.PETSc.c:33328) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/solving_utils.py", line 216, in form_function form_compiler_parameters=problem.form_compiler_parameters) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/assemble.py", line 81, in assemble inverse=inverse, mat_type=mat_type, appctx=appctx) File "<decorator-gen-295>", line 2, in _assemble File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/utils.py", line 62, in wrapper return f(*args, **kwargs) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/assemble.py", line 120, in _assemble inverse=inverse) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/tsfc_interface.py", line 192, in compile_form number_map).kernels File "/Users/matak/firedrake/lib/python2.7/site-packages/pyop2/caching.py", line 198, in __new__ obj = make_obj() File "/Users/matak/firedrake/lib/python2.7/site-packages/pyop2/caching.py", line 188, in make_obj obj.__init__(*args, **kwargs) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/tsfc_interface.py", line 112, in __init__ tree = tsfc_compile_form(form, prefix=name, parameters=parameters) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 43, in compile_form kernels.append(compile_integral(integral_data, fd, prefix, parameters)) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 83, in compile_integral integration_dim, entity_ids = lower_integral_type(fiat_cell, integral_type) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 267, in lower_integral_type basedim, extrdim = dim TypeError: 'int' object is not iterable On 10 Oct 2016, at 18:33, Colin Cotter <colin.cotter@imperial.ac.uk<mailto:colin.cotter@imperial.ac.uk>> wrote: OK, I will try to discuss this with Onno on Thursday once he has finished being Examiner In Chief. cheers --cjc On 10 October 2016 at 18:29, Mitchell, Lawrence <lawrence.mitchell@imperial.ac.uk<mailto:lawrence.mitchell@imperial.ac.uk>> wrote:
On 10 Oct 2016, at 18:19, Colin Cotter <colin.cotter@imperial.ac.uk<mailto:colin.cotter@imperial.ac.uk>> wrote:
OK, this is the problem then - you need to find an appropriate preconditioner.
You need to start by finding an appropriate preconditioner for the system without the R space part.
Lawrence: once that is done, is there anything special to do to incorporate it into the system with the R space part [asking because you seem to have thought about this previously], or do we just recommend block preconditioning in this case?
I think you could use block first. It's easier. Otherwise I think the firedrake webpages sketch how to do sherman-morrison. Lawrence _______________________________________________ firedrake mailing list firedrake@imperial.ac.uk<mailto:firedrake@imperial.ac.uk> https://mailman.ic.ac.uk/mailman/listinfo/firedrake -- http://www.imperial.ac.uk/people/colin.cotter www.cambridge.org/9781107663916<http://www.cambridge.org/9781107663916> [http://assets.cambridge.org/97811076/63916/cover/9781107663916.jpg] _______________________________________________ firedrake mailing list firedrake@imperial.ac.uk<mailto:firedrake@imperial.ac.uk> https://mailman.ic.ac.uk/mailman/listinfo/firedrake
Not sure which file are you running from your link, but the failure suggests that you might be using an extruded measure (ds_t, ds_v, etc.) with a non-extruded mesh. On Tue, Oct 11, 2016 at 8:04 PM +0100, "Anna Kalogirou" <A.Kalogirou@leeds.ac.uk<mailto:A.Kalogirou@leeds.ac.uk>> wrote: Leaving the preconditioning aside for a while, I am trying to extend the problem into a mixed space of 5 function spaces, but get the error below when the solver is called. The code can be found here<https://bitbucket.org/annakalog/buoy2d/src/1289802514f6bbc8bc6ea6679aec5e717d327bbb/Inequality%20constraint/Mixed%20system/?at=master>. Any ideas what’s wrong? Thanks, Anna. Traceback (most recent call last): File "buoy-swe.py", line 128, in <module> (phi0, eta0, W0, Z0, LM_lam0_5, LM_mu0_5) = solvers_SV(LM_lam0_5, F_solver, phi_solver1, eta0, phi0, Z0, W0, eta1, phi1, Z1, W1, W0_5, rho, Mass, dt); File "/Users/matak/Documents/Simulations/Firedrake/Ship/Modules/Inequality constraint/Mixed system/solvers.py", line 176, in solvers_SV F_solver.solve() # Solve for phi0_5, eta1, lambda0_5, mu0_5 File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/variational_solver.py", line 201, in solve self.snes.solve(None, v) File "PETSc/SNES.pyx", line 537, in petsc4py.PETSc.SNES.solve (src/petsc4py.PETSc.c:170012) File "PETSc/petscsnes.pxi", line 261, in petsc4py.PETSc.SNES_Function (src/petsc4py.PETSc.c:33328) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/solving_utils.py", line 216, in form_function form_compiler_parameters=problem.form_compiler_parameters) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/assemble.py", line 81, in assemble inverse=inverse, mat_type=mat_type, appctx=appctx) File "<decorator-gen-295>", line 2, in _assemble File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/utils.py", line 62, in wrapper return f(*args, **kwargs) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/assemble.py", line 120, in _assemble inverse=inverse) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/tsfc_interface.py", line 192, in compile_form number_map).kernels File "/Users/matak/firedrake/lib/python2.7/site-packages/pyop2/caching.py", line 198, in __new__ obj = make_obj() File "/Users/matak/firedrake/lib/python2.7/site-packages/pyop2/caching.py", line 188, in make_obj obj.__init__(*args, **kwargs) File "/Users/matak/firedrake/lib/python2.7/site-packages/firedrake/tsfc_interface.py", line 112, in __init__ tree = tsfc_compile_form(form, prefix=name, parameters=parameters) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 43, in compile_form kernels.append(compile_integral(integral_data, fd, prefix, parameters)) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 83, in compile_integral integration_dim, entity_ids = lower_integral_type(fiat_cell, integral_type) File "/Users/matak/firedrake/lib/python2.7/site-packages/tsfc/driver.py", line 267, in lower_integral_type basedim, extrdim = dim TypeError: 'int' object is not iterable On 10 Oct 2016, at 18:33, Colin Cotter <colin.cotter@imperial.ac.uk<mailto:colin.cotter@imperial.ac.uk>> wrote: OK, I will try to discuss this with Onno on Thursday once he has finished being Examiner In Chief. cheers --cjc On 10 October 2016 at 18:29, Mitchell, Lawrence <lawrence.mitchell@imperial.ac.uk<mailto:lawrence.mitchell@imperial.ac.uk>> wrote:
On 10 Oct 2016, at 18:19, Colin Cotter <colin.cotter@imperial.ac.uk<mailto:colin.cotter@imperial.ac.uk>> wrote:
OK, this is the problem then - you need to find an appropriate preconditioner.
You need to start by finding an appropriate preconditioner for the system without the R space part.
Lawrence: once that is done, is there anything special to do to incorporate it into the system with the R space part [asking because you seem to have thought about this previously], or do we just recommend block preconditioning in this case?
I think you could use block first. It's easier. Otherwise I think the firedrake webpages sketch how to do sherman-morrison. Lawrence _______________________________________________ firedrake mailing list firedrake@imperial.ac.uk<mailto:firedrake@imperial.ac.uk> https://mailman.ic.ac.uk/mailman/listinfo/firedrake -- http://www.imperial.ac.uk/people/colin.cotter www.cambridge.org/9781107663916<http://www.cambridge.org/9781107663916> [http://assets.cambridge.org/97811076/63916/cover/9781107663916.jpg] _______________________________________________ firedrake mailing list firedrake@imperial.ac.uk<mailto:firedrake@imperial.ac.uk> https://mailman.ic.ac.uk/mailman/listinfo/firedrake
participants (3)
- 
                
                Anna Kalogirou
- 
                
                Colin Cotter
- 
                
                Homolya, Miklós