Re: [deal.II] Re: Problem with postprocessor

2017-06-07 Thread Thomas Wick

Hi Seyed,

I am old-fashioned in this sense: indeed yes, I just plot the output 
into a file:


make run | tee my_results.txt

Then I `grep' the quantity (for example PStress) that I want and then 
plot with gnuplot.


Of course it would be a bit more efficient to write all output of 
interest directly into
a file. Honestly this is not so difficult either with deal.II functions 
or directly

C++ (fstream, write, etc.).

In step-7 you will get an idea how to use deal.II functions for latex 
output.


Best Thomas


On 06/07/2017 12:26 PM, 'Seyed Ali Mohseni' via deal.II User Group wrote:

Dear Thomas,

Would you be so kind to tell me how am I able to create the 
load-displacement curves like in your paper? Did you use gnuplot?
And does deal.II have a built-in function that allows one to output 
the necessary data directly to gnuplot or to a textfile?


Thank you in advance.

Kind regards,
Seyed Ali
--
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 
.

For more options, visit https://groups.google.com/d/optout.


--
++++
Dr. Thomas Wick
Maitre de conferences / Assistant Professor

Centre de Mathematiques Appliquees (CMAP)
Ecole Polytechnique
91128 Palaiseau cedex, France

Email:  thomas.w...@cmap.polytechnique.fr
Phone:  0033 1 69 33 4579
www:http://www.cmap.polytechnique.fr/~wick/
++++
--

--
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.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] Re: Problem with postprocessor

2017-05-31 Thread Thomas Wick



On 05/31/2017 05:00 PM, 'Seyed Ali Mohseni' via deal.II User Group wrote:



The only thing I changed a bit is the integration from quadratic to 
linear, but I am not sure, if seeting quadrature_formula(2)



In

https://github.com/tjhei/cracks/blob/master/cracks.cc

line 982,

you need to change the "degree", but it should be already "1".

And the quadrature formula - what you mentioned above - should be 
sufficiently high, "2" should do the job.



Best Thomas






alone is enough for linear shape functions. You also had 
face_quadrature_formula or this Lobatto integration.
Would you be so kind and explain what lines I have to change in order 
to obtain linear shape functions and not quadratic like set in the 
original version?

How many changes and the code would help a lot.
Just to be sure I did it correct.

Thank you.

Best,
Seyed Ali
--
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 
.

For more options, visit https://groups.google.com/d/optout.


--
++++
Dr. Thomas Wick
Maitre de conferences / Assistant Professor

Centre de Mathematiques Appliquees (CMAP)
Ecole Polytechnique
91128 Palaiseau cedex, France

Email:  thomas.w...@cmap.polytechnique.fr
Phone:  0033 1 69 33 4579
www:http://www.cmap.polytechnique.fr/~wick/
++++
--

--
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.
For more options, visit https://groups.google.com/d/optout.


[deal.II] Re: Problem with postprocessor

2017-05-31 Thread 'Seyed Ali Mohseni' via deal.II User Group
I did another trick: Increasing G_c has the same effect to achieve purely 
elastic behavior. So, I chose a high enough G_c value and it works!
I obtain the same results and the duh values grow correctly. 

Still I cannot understand fully why when cracking is initiated, there is no 
increase of the strains except the strain in the loaded direction.
Maybe you are right, I try to compare a bigger example, but I already 
compared two phase-field codes.
I have my own version with staggered scheme and it was not identical to 
your results after crack initiation.
As mentioned before, in the elastic regime everything is identical and fine.

The only thing I changed a bit is the integration from quadratic to linear, 
but I am not sure, if seeting quadrature_formula(2) alone is enough for 
linear shape functions. You also had face_quadrature_formula or this 
Lobatto integration.
Would you be so kind and explain what lines I have to change in order to 
obtain linear shape functions and not quadratic like set in the original 
version?
How many changes and the code would help a lot.
Just to be sure I did it correct.

Thank you.

Best,
Seyed Ali 

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] Re: Problem with postprocessor

2017-05-31 Thread Thomas Wick


I hope you could explain me what could cause such a behavior in your 
implementation that deal.II gives different values for duh although 
the same postprocessor implementation is being used.

Is it because of the coupled formulation?



I really would think so. What you could do is to disable the phase-field 
variable
such that you have in both codes really only elasticity and have a fair 
comparison.


How do you do this?

You could erase in our code (Heister/Wick) all the phase-field (pf) 
appearances in the solid

mechanics equations. Then the phase-field values do not enter any more
and led to wrong results with the fracture.


Best Thomas






Thank you for your help so far.

Kind regards,
Seyed Ali
--
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 
.

For more options, visit https://groups.google.com/d/optout.


--
++++
Dr. Thomas Wick
Maitre de conferences / Assistant Professor

Centre de Mathematiques Appliquees (CMAP)
Ecole Polytechnique
91128 Palaiseau cedex, France

Email:  thomas.w...@cmap.polytechnique.fr
Phone:  0033 1 69 33 4579
www:http://www.cmap.polytechnique.fr/~wick/
++++
--

--
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.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] Re: Problem with postprocessor

2017-05-31 Thread Thomas Wick

Hi Toby,

I appreciate your additional comments.

Thanks and best,

Thomas

On 05/31/2017 02:16 PM, Tobi Young wrote:
I'm going to jump in with one of my random comments uninvited. 
Hopefully you don't mind. :-)



I already run the example with uniform mesh, hence global
refinement with 0 refinement cycles.
The problem is, a specimen with 100 or 1000 elements is difficult
to check due to the terminal output being flooded.


I think what Thomas is kindly trying to point out is, that a single 
cell is a useless test case for almost all possible test cases that 
deal with practical problems.


It seems your case is one of many examples.

Try 16 cells. Look at the data and then try 32 cells and compare. 
Maybe write a procedure that will look at the data for you and put 
useful results into a file for you to look at? Can you plot results 
with gnuplot (for example)?


Machines are stupid, they only can do what you tell them to do! So, 
why not reserve a day or so to calmly write the algorithms needed to 
extract the data you want in a way you can visualise?


You need to do your analysis in some way. You can not expect a machine 
to do things for you. You have to instruct her what it is you want to 
be done. Write the code...   :-)


That is scientific computing.

I could just output the result for one element, but then wheres
the difference.


Big difference in numerical analysis of this kind! ;-)

I am not being unkind - though, maybe its time to get dirty, write 
some code, and look at the numbers, in order to figure out where the 
problem lies. If you can do that, there are alot of dealii users and 
developers that will help you out, and you'll get there in the end. :-)


Best,
   Toby



--
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 
.

For more options, visit https://groups.google.com/d/optout.


--
++++
Dr. Thomas Wick
Maitre de conferences / Assistant Professor

Centre de Mathematiques Appliquees (CMAP)
Ecole Polytechnique
91128 Palaiseau cedex, France

Email:  thomas.w...@cmap.polytechnique.fr
Phone:  0033 1 69 33 4579
www:http://www.cmap.polytechnique.fr/~wick/
++++
--

--
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.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] Re: Problem with postprocessor

2017-05-31 Thread Tobi Young
I'm going to jump in with one of my random comments uninvited. Hopefully
you don't mind. :-)


I already run the example with uniform mesh, hence global refinement with 0
refinement cycles.
The problem is, a specimen with 100 or 1000 elements is difficult to check
due to the terminal output being flooded.


I think what Thomas is kindly trying to point out is, that a single cell is
a useless test case for almost all possible test cases that deal with
practical problems.

It seems your case is one of many examples.

Try 16 cells. Look at the data and then try 32 cells and compare. Maybe
write a procedure that will look at the data for you and put useful results
into a file for you to look at? Can you plot results with gnuplot (for
example)?

Machines are stupid, they only can do what you tell them to do! So, why not
reserve a day or so to calmly write the algorithms needed to extract the
data you want in a way you can visualise?

You need to do your analysis in some way. You can not expect a machine to
do things for you. You have to instruct her what it is you want to be done.
Write the code...   :-)

That is scientific computing.

I could just output the result for one element, but then wheres the
difference.


Big difference in numerical analysis of this kind! ;-)

I am not being unkind - though, maybe its time to get dirty, write some
code, and look at the numbers, in order to figure out where the problem
lies. If you can do that, there are alot of dealii users and developers
that will help you out, and you'll get there in the end. :-)

Best,
   Toby

-- 
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.
For more options, visit https://groups.google.com/d/optout.


Re: [deal.II] Re: Problem with postprocessor

2017-05-31 Thread Thomas Wick



On 05/31/2017 01:31 PM, 'Seyed Ali Mohseni' via deal.II User Group wrote:

Dear Thomas,

I already run the example with uniform mesh, hence global refinement 
with 0 refinement cycles.
The problem is, a specimen with 100 or 1000 elements is difficult to 
check due to the terminal output being flooded.


This I understand, but you could write everything into a file ...


I could just output the result for one element, but then wheres the 
difference.


See below.


Don't you ever do some simple FE patch examples?


Never. Because simply the theory of finite elements tell you that the 
discretization error is so huge

that any result is nearly meaningless.


If I am interested in stress values or the stress tensor, but I am not 
sure if this
will help you or if you are interested, is to compute typical quantities 
of interest.

That is not only a point-wise stress, but for example a line integral:

\int_{part of boundary} \sigma\cdot n \ds.

Or indeed you compute the stress in a specific point in the domain
but really using more than one element.

Many examples and benchmarks for elasticity and plasticity and also 
quantities

of interest (goal functionals) are given in the book:

http://eu.wiley.com/WileyCDA/WileyTitle/productCd-0471496502.html


For instance two examples from this book with point values of stresses 
(e.g., \sigma_yy),
again on more than one element, are provided in the deal-DOpElib 
library, see pages 42 - 45 on


http://wwwopt.mathematik.tu-darmstadt.de/dopelib/description_full.pdf


Best Thomas




Kind regards,
S. A. Mohseni
--
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 
.

For more options, visit https://groups.google.com/d/optout.


--
++++
Dr. Thomas Wick
Maitre de conferences / Assistant Professor

Centre de Mathematiques Appliquees (CMAP)
Ecole Polytechnique
91128 Palaiseau cedex, France

Email:  thomas.w...@cmap.polytechnique.fr
Phone:  0033 1 69 33 4579
www:http://www.cmap.polytechnique.fr/~wick/
++++
--

--
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.
For more options, visit https://groups.google.com/d/optout.


[deal.II] Re: Problem with postprocessor

2017-05-31 Thread 'Seyed Ali Mohseni' via deal.II User Group
Dear Thomas,

I already run the example with uniform mesh, hence global refinement with 0 
refinement cycles.
The problem is, a specimen with 100 or 1000 elements is difficult to check 
due to the terminal output being flooded.
I could just output the result for one element, but then wheres the 
difference. 
Don't you ever do some simple FE patch examples?

Kind regards,
S. A. Mohseni

-- 
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.
For more options, visit https://groups.google.com/d/optout.