Re: [deal.II] p4est tree initilization

2019-05-29 Thread Wolfgang Bangerth
On 5/29/19 4:40 AM, Gabriel Peters wrote:
> 
> I am working with a parallel::distributed::triangulation.
> In my program I load a coarse grid from a file.
> 
> Is there a function to manually initialize trees in my triangulation, 
> according to some regions of my domain (just as p4est does) or
> is this automatically done by calling p::d::tria, in some way? If this is the 
> case, how many trees are initialized then?

The GridGenerator and GridIn functions can take a p::d::Triangulation as 
argument and will then automatically fill all of the necessary p4est data 
structures. They will in general create one p4est tree per coarse mesh cell, 
though that is a detail of no particular importance from the user's perspective.

Best
  W>


-- 

Wolfgang Bangerth  email: bange...@colostate.edu
www: http://www.math.colostate.edu/~bangerth/

-- 
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/43505b06-9410-016b-028e-d09f0be3b136%40colostate.edu.
For more options, visit https://groups.google.com/d/optout.


[deal.II] deal.II Newsletter #81

2019-05-29 Thread Rene Gassmoeller
Hello everyone!

This is deal.II newsletter #81.
It automatically reports recently merged features and discussions about the 
deal.II finite element library.


## Below you find a list of recently proposed or merged features:

#8296: Sort implementations of GridTools::cell_measure by dimension. (proposed 
by bangerth) https://github.com/dealii/dealii/pull/8296

#8294: Add InterpolatedUniformGridData::gradient(). (proposed by bangerth) 
https://github.com/dealii/dealii/pull/8294

#8291: Dont install logfiles (proposed by drwells) 
https://github.com/dealii/dealii/pull/8291

#8288: Update a couple of comments for DataOutFaces. (proposed by bangerth; 
merged) https://github.com/dealii/dealii/pull/8288

#8287: [master] Take over changes and news from 9.1 branch (proposed by tamiko; 
merged) https://github.com/dealii/dealii/pull/8287

#8286: [9.1.1] update changes and news for release (proposed by tamiko; merged) 
https://github.com/dealii/dealii/pull/8286

#8285: fix test concurrency (proposed by tamiko; merged) 
https://github.com/dealii/dealii/pull/8285

#8284: [9.1.1] CMake: Disable default compilation of examples (proposed by 
tamiko; merged) https://github.com/dealii/dealii/pull/8284

#8283: Rename TARGET{,_SRC,_INC} to target{,_src,_inc} in CMakeLists.txt files. 
(proposed by bangerth) https://github.com/dealii/dealii/pull/8283

#8282: [9.1.1] Take over #8269 (proposed by masterleinad; merged) 
https://github.com/dealii/dealii/pull/8282

#8281: mpi/solution_transfer_03: fix test concurrency (proposed by tamiko; 
merged) https://github.com/dealii/dealii/pull/8281

#8280: [9.1.1] Take over #8279 (proposed by tamiko; merged) 
https://github.com/dealii/dealii/pull/8280

#8279: Fix GridIn::read_msh (proposed by masterleinad; merged) 
https://github.com/dealii/dealii/pull/8279

#8278: conversion operator is written for table accessor (proposed by 
rezarastak; merged) https://github.com/dealii/dealii/pull/8278

#8277: Fix compressing TrilinosWrappers::SparsityPattern with empty column map 
(proposed by masterleinad) https://github.com/dealii/dealii/pull/8277

#8269: Add tests for gmsh-4.3 (proposed by masterleinad; merged) 
https://github.com/dealii/dealii/pull/8269

#8226: Updates to the step-63 program. (proposed by bangerth; merged) 
https://github.com/dealii/dealii/pull/8226


## And this is a list of recently opened or closed discussions:

#8295: Changes page not reachable. (opened) 
https://github.com/dealii/dealii/issues/8295

#8293: Code optimizations for >100k MPI ranks (opened) 
https://github.com/dealii/dealii/issues/8293

#8292: Provide some documentation for package maintainers (opened) 
https://github.com/dealii/dealii/issues/8292

#8290: Version 9.1.1 installs detailed.log and summary.log into $PREFIX (opened 
and closed) https://github.com/dealii/dealii/issues/8290

#8289: Compute eigenvalues of rank-4 symmetric tensors (opened) 
https://github.com/dealii/dealii/issues/8289

#8276: Read mesh issue introduced by gmsh-4.1 fix (opened and closed) 
https://github.com/dealii/dealii/issues/8276

#8275: Detection of external boost fails with clang 8.0.0 (opened) 
https://github.com/dealii/dealii/issues/8275


A list of all major changes since the last release can be found at 
https://www.dealii.org/developer/doxygen/deal.II/changes_after_8_5_0.html.


Thanks for being part of the community!


Let us know about questions, problems, bugs or just share your experience by 
writing to dealii@googlegroups.com, or by opening issues or pull requests at 
https://www.github.com/dealii/dealii.
Additional information can be found at https://www.dealii.org/.

-- 
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/5ceec8e1.1c69fb81.a7192.0d10SMTPIN_ADDED_MISSING%40gmr-mx.google.com.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] prepare_for_coarsening_and_refinement() for FE_Bernstein-elements

2019-05-29 Thread 'Maxi Miller' via deal.II User Group
I tried to implement this idea with the following code:
TrilinosWrappers::MPI::Vector distributed_q_solution(locally_owned_dofs, 
mpi_communicator);
TrilinosWrappers::MPI::Vector distributed_old_q_solution(
locally_owned_dofs, mpi_communicator);
TrilinosWrappers::MPI::Vector distributed_really_old_q_solution(
locally_owned_dofs, mpi_communicator);

TrilinosWrappers::MPI::Vector distributed_local_present_solution(
locally_owned_dofs, mpi_communicator);
TrilinosWrappers::MPI::Vector distributed_local_old_solution(
locally_owned_dofs, mpi_communicator);
TrilinosWrappers::MPI::Vector distributed_local_really_old_solution(
locally_owned_dofs, mpi_communicator);

distributed_local_present_solution = present_solution;
distributed_local_old_solution = old_solution;
distributed_local_really_old_solution = really_old_solution;

//Transfer data from FE_Bernstein to FE_Q

const ComponentMask fe_mask(fe.get_nonzero_components(0).size(), true);

std::vector fe_to_real(fe_mask.size(),
 numbers::invalid_unsigned_int);
unsigned int  size = 0;
for (unsigned int i = 0; i < fe_mask.size(); ++i)
{
if (fe_mask[i])
fe_to_real[i] = size++;
}

const FESystem *fe_system =
dynamic_cast *>();
Assert(fe_system, ExcNotImplemented());
unsigned int degree = numbers::invalid_unsigned_int;

// Get information about the blocks
for (unsigned int i = 0; i < fe_mask.size(); ++i)
if (fe_mask[i])
{
const unsigned int base_i =
fe_system->component_to_base_index(i).first;
Assert(degree == numbers::invalid_unsigned_int ||
   degree == fe_system->base_element(base_i).degree,
   ExcNotImplemented());
Assert(fe_system->base_element(base_i).is_primitive(),
   ExcNotImplemented());
degree = fe_system->base_element(base_i).degree;
}

FESystem feq(FE_Q(fe_degree_to_use), n_components);
DoFHandler dhq(dof_handler.get_triangulation());
dhq.distribute_dofs(feq);

FullMatrix transfer_forward(feq.dofs_per_cell, fe.dofs_per_cell
);

FullMatrix local_transfer_forward(fe.dofs_per_cell);

const std::vector>  = feq.get_unit_support_points();

std::vector fe_to_feq(feq.dofs_per_cell,
numbers::invalid_unsigned_int);

unsigned int  index = 0;
for (unsigned int i = 0; i < feq.dofs_per_cell; ++i)
if (fe_mask[feq.system_to_component_index(i).first])
fe_to_feq[i] = index++;

// If index is not the same as feq.dofs_per_cell, we won't
// know how to invert the resulting matrix. Bail out.
Assert(index == fe.dofs_per_cell, ExcNotImplemented());

for (unsigned int j = 0; j < feq.dofs_per_cell; ++j)
{
const unsigned int comp_j = feq.system_to_component_index(j).first;
if (fe_mask[comp_j])
for (unsigned int i = 0; i < points.size(); ++i)
{
if (fe_to_real[comp_j] ==
fe.system_to_component_index(i).first)
local_transfer_forward(i, fe_to_feq[j]) =
feq.shape_value(j, points[i]);
}
}



// Now we construct the rectangular interpolation matrix. This
// one is filled only with the information from the components
// of the displacement. The rest is set to zero.
local_transfer_forward.invert(local_transfer_forward);
for (unsigned int i = 0; i < feq.dofs_per_cell; ++i)
if (fe_to_feq[i] != numbers::invalid_unsigned_int)
for (unsigned int j = 0; j < fe.dofs_per_cell; ++j)
transfer_forward(i, j) = local_transfer_forward(fe_to_feq[i
], j);

// The interpolation matrix is then passed to the
// VectorTools::interpolate() function to generate the correct
// interpolation.
pcout << "Data transferred to feq, interpolating\n";

VectorTools::interpolate(dof_handler, dhq, transfer_forward, 
distributed_local_present_solution, distributed_q_solution);
VectorTools::interpolate(dof_handler, dhq, transfer_forward, 
distributed_local_old_solution, distributed_old_q_solution);
VectorTools::interpolate(dof_handler, dhq, transfer_forward, 
distributed_local_really_old_solution, distributed_really_old_q_solution);

pcout << "Vectortools::interpolate done\n";

parallel::distributed::SolutionTransfer> solution_transfer(dhq);
parallel::distributed::SolutionTransfer> old_solution_transfer(dhq);
parallel::distributed::SolutionTransfer> really_old_solution_transfer(dhq);

pcout << "SolutionTransfer created\n";

solution_transfer.prepare_for_coarsening_and_refinement(
distributed_q_solution);
old_solution_transfer.prepare_for_coarsening_and_refinement(
distributed_old_q_solution);

Re: [deal.II] Thermal Expansion

2019-05-29 Thread Muhammad Mashhood
Hi Andrew! I am also working on the same problem and would be interested to 
have a look into Thesis but the link says it has been removed.

On Tuesday, October 7, 2014 at 12:27:09 PM UTC+2, mac wrote:
>
> The link below is to an MSc thesis that details all the steps to solve the 
> thermoelastic problem in deal.II
> https://copy.com/lGuC3Md4aiIRk9t8
>
> Andrew
>
> On 7 Oct 2014, at 12:18, Ehsan > wrote:
>
> Hi,
>
> I want to model a plate under mechanical and thermal loadings.
> The plate is in steady state condition and the material is considered to 
> be homogeneous isotropic elastic material.
>
> The Thermal BCs are:
> Left edge: prescribed temperature change.
> Right edge: constant temperature (zero temperature change)
> Top and bottom edges: adiabatic.
>
> I modelled this problem with only mechanical loading and now I want to add 
> thermal part. I want to solve the problem in monolithic way.
>
> My question is:
> Which steps I should I study?
>
> Best regards.
> Ehsan
>
> -- 
> 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 dea...@googlegroups.com .
> For more options, visit https://groups.google.com/d/optout.
>
>
>

-- 
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/6da372dd-5e32-4452-8e2f-d30c0bd0dac3%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[deal.II] p4est tree initilization

2019-05-29 Thread Gabriel Peters
Hey everyone,

I am working with a parallel::distributed::triangulation.
In my program I load a coarse grid from a file.

Is there a function to manually initialize trees in my triangulation, 
according to some regions of my domain (just as p4est does) or 
is this automatically done by calling p::d::tria, in some way? If this is 
the case, how many trees are initialized then?

Thaks a lot
and best regards

Gabriel


-- 
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/4ac1c3d5-df2c-4a4c-bd35-4f0952580453%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.