[firedrake] problems with importing a mesh
Francis Poulin
fpoulin at uwaterloo.ca
Thu Nov 9 03:24:47 GMT 2017
Thank you for the info.
I know that when we impose Dirichlet BCs we know what the values at the boundary should be but I was thinking of evaluating the solution as a sanity check. I will give this a try.
------------------
Francis Poulin
Associate Dean, Undergraduate Studies
Associate Professor
Department of Applied Mathematics
University of Waterloo
email: fpoulin at uwaterloo.ca
Web: https://uwaterloo.ca/poulin-research-group/
Telephone: +1 519 888 4567 x32637
________________________________
From: firedrake-bounces at imperial.ac.uk <firedrake-bounces at imperial.ac.uk> on behalf of Lawrence Mitchell <lawrence.mitchell at imperial.ac.uk>
Sent: Wednesday, November 8, 2017 4:15 AM
To: firedrake at imperial.ac.uk
Subject: Re: [firedrake] problems with importing a mesh
On 08/11/17 09:13, Lawrence Mitchell wrote:
>
>
> On 03/11/17 20:15, Francis Poulin wrote:
>> If yes, then I think I'm in good shape. One problem is that the
>> boundary layer is very narrow for my choice of parameters so it's hard
>> to know whether the boundary value is really zero. I don't suppose
>> there is an easy way to find out the maximum of the boundary value in
>> the numerical solution?
>
> If you are imposing strong (Dirichlet) conditions, then the solution
> on the boundary nodes is, by definition, whatever you set it to.
>
> If you have some other means of enforcing boundary conditions and just
> want to know that the values are on the boundary, you could do:
>
> V = FunctionSpace(...)
>
> selector = DirichletBC(V, 0, "on_boundary")
>
> f = Function(V)
>
> # solve into f
>
> boundary_values = f.dat.data_ro[selector.nodes, ...]
Note this assumes that inspecting the point values of your space makes
sense: this is fine for CG and DG, not so for other spaces.
Lawrence
_______________________________________________
firedrake mailing list
firedrake at imperial.ac.uk
https://mailman.ic.ac.uk/mailman/listinfo/firedrake
-------------- next part --------------
HTML attachment scrubbed and removed
More information about the firedrake
mailing list