Re: [deal.II] How do I set initial solution vector to boundary values in DG?

2022-12-04 Thread Timo Heister
I would consider the boundary conditions part of the nonlinear
iteration (in contrast to step-15, where they are strongly enforced
and as such are only needed in step 0). Every step you can evaluate
your nonlinear residual which contains a residual in the boundary
condition and that difference needs to be applied in every step
(assuming you solve for an update in each Newton step).

On Sat, Dec 3, 2022 at 10:56 AM Wolfgang Bangerth
 wrote:
>
> On 12/3/22 07: 11, Abbas wrote: > > Something like this doesn't work with DG. 
> > Loosely speaking, my initial approach would be to solve a system with just 
> the > BC terms but I am not sure. Do I have other options? In DG methods,
> ZjQcmQRYFpfptBannerStart
> This Message Is From an External Sender
> Use caution when opening links or attachments if you do not recognize the 
> sender.
>
> ZjQcmQRYFpfptBannerEnd
>
> On 12/3/22 07:11, Abbas wrote:
> >
> > Something like this doesn't work with DG.
> > Loosely speaking, my initial approach would be to solve a system with just 
> > the
> > BC terms but I am not sure. Do I have other options?
>
> In DG methods, you impose boundary values weakly, using the same strategy with
> which you impose continuity between cells weakly. You might want to look at
> papers on DG methods: pretty much every single one will show the jump terms
> corresponding to Dirichlet boundary values.
>
> Best
>   W.
>
> --
> 
> Wolfgang Bangerth  email: bange...@colostate.edu
> www: 
> https://urldefense.com/v3/__http://www.math.colostate.edu/*bangerth/__;fg!!PTd7Sdtyuw!Vf-IQx7HQQ5bIq8xBQu1BzCdpZiz9Q3UC6emGlg1Z50xBT-oA9UeUBtyamyADtrTV0zLEZpa0RBQ_lV6jh5B8Uo$
>
>
> --
> The deal.II project is located at 
> https://urldefense.com/v3/__http://www.dealii.org/__;!!PTd7Sdtyuw!Vf-IQx7HQQ5bIq8xBQu1BzCdpZiz9Q3UC6emGlg1Z50xBT-oA9UeUBtyamyADtrTV0zLEZpa0RBQ_lV6CDq7NmU$
> For mailing list/forum options, see 
> https://urldefense.com/v3/__https://groups.google.com/d/forum/dealii?hl=en__;!!PTd7Sdtyuw!Vf-IQx7HQQ5bIq8xBQu1BzCdpZiz9Q3UC6emGlg1Z50xBT-oA9UeUBtyamyADtrTV0zLEZpa0RBQ_lV6qJBbcDU$
> ---
> You received this message because you are subscribed to the Google Groups 
> "deal.II User Group" group.
> To unsubscribe from this group and stop receiving emails from it, send an 
> email to dealii+unsubscr...@googlegroups.com.
> To view this discussion on the web visit 
> https://urldefense.com/v3/__https://groups.google.com/d/msgid/dealii/c1d413d2-3c55-0523-19fd-9f399d1781da*40colostate.edu__;JQ!!PTd7Sdtyuw!Vf-IQx7HQQ5bIq8xBQu1BzCdpZiz9Q3UC6emGlg1Z50xBT-oA9UeUBtyamyADtrTV0zLEZpa0RBQ_lV6CppyxvM$
>  .



-- 
Timo Heister
http://www.math.clemson.edu/~heister/

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/CAMRj59GL%2BCqwUB-cEwvdLB%3DeQu%2BkgmROszd%3D5iP_SRUjMz2WjQ%40mail.gmail.com.


[deal.II] Re: How would you document a step/code/module?

2022-12-04 Thread Marc Fehling
Hello Abbas,

if you are willing the share your code with the deal.II community, you can 
submit your code to the deal.II code gallery. The documentation for each of 
the example programs use the same doxygen formatting as deal.II.
https://www.dealii.org/code-gallery.html
https://github.com/dealii/code-gallery

Doxygen in general is a powerful tool to document your code, but other 
tools exist as well as for example Jupyter as you pointed out. I feel like 
it boils down to personal taste which one you would like to use. But kudos 
to you in thinking about documenting and sharing your code!

Marc

On Sunday, December 4, 2022 at 6:26:41 AM UTC-7 Abbas wrote:

> Hello, 
>
> Let's say you made 1000+ lines of code with dealii, and you want to 
> document and share it in a format similar to that of the dealii steps, how 
> would you go about doing this?
>
> MAYBE in the future people will share single "modules" with some 
> "tutorial" like documentation. This might be something some of us are 
> thinking about or considering. I guess? 
>
> I have been suggested to use a jupyter notebook but I feel like that's a 
> huge waste of white space. Having a dedicated web link is also very 
> attractive so I was considering having a website hosted on github pages. I 
> tried that using Gatsby and it, but I feel like this is unnecessarily 
> over-complicated.
>
> Has anyone done something similar to this? If not, any ideas?
>
> Thank you for reading this far.  
>

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/c1155573-c9b9-4061-95c4-95de1db760c1n%40googlegroups.com.


Re: [deal.II] Re: Error in compiling step-1

2022-12-04 Thread X. Zhu
Hello Jan and Prof. Bangerth,
Thanks for your reply. I fixed the issue by removing the package. After
that, I can run step-1 by the "apt-get" version 9.1.1 and also by the git
clone package (version 9.5.0). Thank you all.



On Sat, Dec 3, 2022 at 2:31 PM Jan Philipp Thiele <
thi...@ifam.uni-hannover.de> wrote:

> ldconfig told you that the deal.II 9.1.1 shared object library is in
> /lib/x86_64-linux-gnu/
> Additionally, there is an installation of deal.II 9.5.0-pre, which is the
> current development branch of deal.II, in /usr/local
>
> This second one actually fits to apt-get install libdeal.ii-dev, so I'm
> not 100% sure if the 9.1.1 is a proper installation, for that There would
> have to be an include folder as well.
> Additionally, fitting to the second installation the environment as well
> as the cmake variable DEAL_II_DIR are set to /usr/local which is why cmake
> only finds 9.5.0-pre.
> You might try to set the cmake variable to the proper directory via -D
> DEAL_II_DIR, but you'd probably have to figure out where the matching
> include files are and set the variable to the parent directory of /include
>
> If you installed, uninstalled and installed again I would not be sure
> whether the object libraries in /lib/x86_64-linux-gnu/ are still useable.
> And I also think that on the first install you chose a different deal.II
> version.
>
> I however, have never installed deal.II via apt so I don't know how to
> choose the correct version there, but if it was 9.1.1 before it might be in
> your Terminals call history.
> Best,
> Philipp
>
>
>
> On Saturday, December 3, 2022 at 6:57:56 AM UTC+1 zhuxy...@gmail.com
> wrote:
>
>> Hello Prof. Bangerth and developers,
>> I have already installed the deal.ii library (9.1.1-9build2) by apt
>> package (just by "apt-get install libdeal.ii-dev") in my ubuntu 20.04LTS
>> machine. I did compilations in step-1 and step-2, same errors occur.
>> The environment information is as follows:
>>
>> *
>> $ ldconfig -p |grep deal
>>libdeal.ii.so.9.1.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libdeal.
>> ii.so.9.1.1
>>libdeal.ii.so (libc6,x86-64) => /lib/x86_64-linux-gnu/libdeal.ii.so
>>libdeal.ii.g.so.9.1.1 (libc6,x86-64) => /lib/x86_64-linux-gnu/libdeal.
>> ii.g.so.9.1.1
>>libdeal.ii.g.so (libc6,x86-64) => /lib/x86_64-linux-gnu/libdeal.
>> ii.g.so
>>
>> $ export | grep deal
>> declare -x DEAL_II_DIR="/usr/include/deal.II"
>> declare -x PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/
>> sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/
>> include/deal.II:/usr/include/deal.II"
>>
>> $ ls /usr/include/deal.II/
>> algorithms   distributed  grid matrix_free   numerics
>>  physics
>> base dofs hp   meshworkeropencascade
>> sundials
>> boost_adaptors   fe   integrators  multigrid optimization
>> differentiation  gmsh lac  non_matching  particles
>>
>> $ ls /usr/local/include/deal.II/
>> algorithms  cgal gmsh matrix_free   opencascade
>> arborx  differentiation  grid meshworkeroptimization
>> basedistributed  hp   multigrid particles
>> boost_adaptors  dofs integrators  non_matching  physics
>> bundled fe   lac  numerics  sundials
>>
>> $ ls /usr/local/lib/
>> cmakelibdeal_II.g.so.9.5.0-pre  libdeal_II.so.9.5.0-pre
>>  python3.8
>> libdeal_II.g.so  libdeal_II.so  pkgconfig
>> **
>>
>> I copy the example files into another directory and run commands in
>> step-2 folder:
>>
>> 
>> $ cmake .
>> -- Using the* deal.II-9.5.0*-pre installation found at /usr/local (***
>> PS ***: I don't know why deal.ii-9.5.0 is involved.)
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_add_test.
>> cmake
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_
>> initialize_cached_variables.cmake
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_invoke_
>> autopilot.cmake
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_pickup_
>> tests.cmake
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_query_
>> git_information.cmake
>> -- Include macro /usr/local/share/deal.II/macros/macro_deal_ii_setup_
>> target.cmake
>> -- The C compiler identification is GNU 9.4.0
>> -- The CXX compiler identification is GNU 9.4.0
>> -- Check for working C compiler: /usr/bin/cc
>> -- Check for working C compiler: /usr/bin/cc -- works
>> -- Detecting C compiler ABI info
>> -- Detecting C compiler ABI info - done
>> -- Detecting C compile features
>> -- Detecting C compile features - done
>> -- Check for working CXX compiler: /usr/bin/c++
>> -- Check for working CXX compiler: /usr/bin/c++ -- works
>> -- Detecting CXX compiler ABI info
>> -- Detecting CXX compiler ABI info - done
>> -- Detecting CXX compile features
>> -- Detecting CXX compile features - done
>> -- Autopilot invoked
>> ###
>>

[deal.II] How would you document a step/code/module?

2022-12-04 Thread Abbas
Hello, 

Let's say you made 1000+ lines of code with dealii, and you want to 
document and share it in a format similar to that of the dealii steps, how 
would you go about doing this?

MAYBE in the future people will share single "modules" with some "tutorial" 
like documentation. This might be something some of us are thinking about 
or considering. I guess? 

I have been suggested to use a jupyter notebook but I feel like that's a 
huge waste of white space. Having a dedicated web link is also very 
attractive so I was considering having a website hosted on github pages. I 
tried that using Gatsby and it, but I feel like this is unnecessarily 
over-complicated.

Has anyone done something similar to this? If not, any ideas?

Thank you for reading this far.  

-- 
The deal.II project is located at http://www.dealii.org/
For mailing list/forum options, see 
https://groups.google.com/d/forum/dealii?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"deal.II User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to dealii+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/dealii/00ee1344-6c78-4115-946e-2e741632b6c6n%40googlegroups.com.