Ouh, I forgot to reply to deal.ii Javier
Hi Katie I finally have time to install trilinos. I guess that with wrong answer you mean that the solution should converge to the boundary value but it doesn't. Have you tried changing the tolerance value in SolverControl solver_control (pressure_matrix.m(),pressure_rhs.l2_norm()); to something like: SolverControl solver_control (pressure_matrix.m(),1.e-10); Regards On mié, 2012-06-27 at 06:31 +0000, Katie Leonard wrote: > No worries :) If you could take a look I would be very grateful. > > Thanks, > > Katie > > > Katie Leonard > > DPhil student in Computational Biology, > The University of Oxford. > ________________________________________ > From: Jose Javier Muñoz Criollo [[email protected]] > Sent: 26 June 2012 17:35 > To: Katie Leonard > Subject: Re: [deal.II] Applying time dependent boundary conditions > > Of course, it makes sense now. I was giving it a quick look and get confused. > Now I'm trying to run it and I realized that I don't have trilinos installed. > I'll try to give it a look after install it. > > Regards > Javier > > > 2012/6/26 Katie Leonard > <[email protected]<mailto:[email protected]>> > Hello Javier, > > The problem I sent around is not the problem I want to solve in the end; it > is more complicated and has time-dependent features. In order to demonstrate > the error/difficulty I am having with my code, I have just written code for a > very simple problem (minimal working example) so that it is easy to see the > problem and fix... Obviously if I was really solving this particular > equation I would do it analytically! I hope that makes sense? > > Thanks > > Katie > > Katie Leonard > > DPhil student in Computational Biology, > The University of Oxford. > ________________________________________ > From: Jose Javier Muñoz Criollo > [[email protected]<mailto:[email protected]>] > Sent: 26 June 2012 16:57 > To: [email protected]<mailto:[email protected]> > Cc: Katie Leonard > Subject: Re: [deal.II] Applying time dependent boundary conditions > > Hello Katie > > > Is the equation that you are trying to solve time-dependant? For the look of > your assembly function it appears that you're solving the stationary equation > with different boundary conditions. In the run function you advance through > time and solve the equation each time step although you're not using the > previous solution to calculate the current one, and you're only saving the > output for a few time steps, wouldn't be same just to calculate those time > steps without compute the intermediate ones? > > > Regards > Javier > > > > 2012/6/22 Katie Leonard > <[email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>>> > Hello, > > I am having trouble applying time-dependent boundary conditions properly. I > attach two minimal working examples, and a picture to show what I mean. > > In these examples I am solving Laplace equation on a circle, with zero flux > boundary conditions, and time dependent Dirichlet boundary conditions, so that > > \nabla^2 p = 0 in \Omega > > with > \nabla p \cdot \mathbf{n} = 0 on \partial \Omega > p = f(t) on \partial \Omega > > > In the first example (no_constraints_t_dependent_boundary.cc) I implement the > boundary conditions using VectorTools::interpolate_boundary_values and > MatrixTools::apply_boundary_values each time assemble_pressure_system () is > called. > In the second example (with_constraints_matrix_t_dependentBCs.cc) I use a > constraints matrix, and call VectorTools::interpolate_boundary_values within > setup_pressure_dofs_for_boundary (), calling this at the beginning of each > timestep. > > Both codes produce the same results - but giving the wrong answer (see > Example_pressure_plot.jpeg) > > If anyone has any ideas why this is occurring, and how to solve it, I would > be very grateful! > > > Many thanks and have a good weekend! > > Katie > > > > Katie Leonard > > DPhil student in Computational Biology, > The University of Oxford. > _______________________________________________ > dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii > > > > > -- > José Javier Muñoz Criollo > PhD Student | Cardiff University School of Engineering > E-mail: > [email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>> > > > > > -- > José Javier Muñoz Criollo > PhD Student | Cardiff University School of Engineering > E-mail: [email protected]<mailto:[email protected]> > _______________________________________________ dealii mailing list http://poisson.dealii.org/mailman/listinfo/dealii
