Commit Graph

138 Commits

Author SHA1 Message Date
Christoph Kords 3c53f3ec9a last version contains buggy mesh.f90; corrected typo in initialization 2012-11-09 07:52:44 +00:00
Christoph Kords 366ac28694 parallelized mesh_build_subNodeCoords and mesh_build_ipCoordinates 2012-11-09 07:47:14 +00:00
Martin Diehl 5214b93342 fixed bug when reading in geometry for spectral solver 2012-11-06 17:16:01 +00:00
Christoph Kords 5b6baa7c0d introduced distinction between ip coordinates and cell center coordinates; the former can be globally calculated by subroutine mesh_build_ipCoordinates, the latter locally by the function mesh_cellCenterCoordinates; renamed mesh_ipCenterOfGravity to mesh_ipCordinates 2012-11-06 14:37:13 +00:00
Christoph Kords 93cc466749 third entry in mesh_ipNeighborhood stores the neighbor_index that points from each neighbor back to the central ip; needed in nonlocal model 2012-10-24 14:03:02 +00:00
Christoph Kords b99a846503 new scaling feature in numerics (unitlength) did not scale the reference coordinates in the first place; now this is taken care of in mesh.f90, so scaling should work properly 2012-09-25 16:21:58 +00:00
Martin Diehl 96ba5ecae4 moved some more 'mesh related' functions for post processing from math.f90 to mesh.f90
f2py functions remaining in math.f90 now uses assumed size arrays in order to have simpler interfaces. This is only working with python 2.7!
changed python pre- and postprocessing scripts.
If you encounter any problems whith core modules, try to remove the old core.so in the lib/damask
2012-08-27 08:04:47 +00:00
Martin Diehl b96df9987e fixed reading/writing of integer arrays with function for real arrays 2012-08-16 14:55:23 +00:00
Krishna Komerla 08c7be7d15 adaptive regrid now working, updates F and F_lastInc based on mapping. 2012-08-10 15:48:27 +00:00
Martin Diehl 7e3a837640 moved calculation and output of geometry related data to mesh.f90, moved output of command line related information to DAMASK_spectral_interface.f90.
improved new solver structure (use with make SOLVER=NEW)
2012-08-06 12:43:05 +00:00
Martin Diehl ee1bde0cd7 enabling regridding more than once by introducing deallocation of arrays
added J2 test (stub from Taymour)
2012-07-31 15:37:49 +00:00
Martin Diehl 9c0a161ec0 in case of regridding, undeformed configuration is written out correctly. Restart improve by reading in additional data from converged step. 2012-07-24 12:21:41 +00:00
Philip Eisenlohr 4d09ef0648 changed variable name "debug_what" to "debug_level" 2012-07-05 09:54:50 +00:00
Martin Diehl bd462d12c6 fixed some bugs in the regridding routine 2012-06-20 18:33:20 +00:00
Martin Diehl d650972904 corrected some bugs concerning the regridding
prevented FEsolving from potentially write to a none existing file
started to introduce petsc into the make chain (nothing happens if PETSC_DIR is not set)
2012-06-20 12:49:46 +00:00
Martin Diehl 481268c8c2 fixed closing of file (unit 222) statement in FEsolving.f90
added missing keyword in mesh.f90 with ifndef Spectral statement (needed for Marc and Abaqus)
2012-06-19 14:33:24 +00:00
Krishna Komerla 06be437bc9 added minRes to regridding function and writing out of new geometry file
updated f2py wrapper to enable the use of init functions.
added 2 new error messages to io
2012-06-19 13:31:15 +00:00
Martin Diehl b2fd3e1180 introduced preprocessor identifiers Marc, Abaqus, and Spectral to enable conditional compilation. This allows deleted dummy functions that are used by one solver only.
Mainly affected modules are IO and mesh. Most of the changes in mesh result from reordering the functions when grouping them depending on their solver.
Further advantage is that FE solver do not need FFTW and kdtree2 anymore. The include files for these two libraries moved to DAMASKROO/lib now as I figured out how to use a include path in the Makefile.
Put all the files I got when testing compilation with abaqus in a folder which to become the abaqus compilation test.
2012-06-15 16:10:21 +00:00
Martin Diehl cec3357e8f corrected bug causing wrong element construction when using spectral solver. Also improved error messages for invalid resolution, dimension, and homogenization. 2012-05-21 09:06:02 +00:00
Krishna Komerla fbd075dc6e corrected automatic determination of resolution 2012-05-08 15:12:43 +00:00
Krishna Komerla c752dd5474 regridding is now working, changed the subroutine into a function
changed order of arrays in nearest neighbor search to make it fortran fast
constitutive.f90 and homogenization.f90 write state size out during initialization
setup/setup_processing.py is using byterecl to be compatible with binary files written out by solver
2012-05-08 14:57:06 +00:00
Krishna Komerla 4b18278781 reworked neares neigbor search subroutine, now also works for voronoi tesselation (general nn search in periodic cell) 2012-05-04 13:07:37 +00:00
Krishna Komerla 83e89fba3c improved regridding, especially interfacing to python (also for nearest neighbor search) 2012-04-24 17:02:27 +00:00
Martin Diehl d2c4874db3 several small corrections/polishing 2012-04-20 11:58:41 +00:00
Philip Eisenlohr dbc5a3a3ce subnodeparent check is now running only over actual number (not max) of parent nodes... 2012-04-17 09:19:44 +00:00
Martin Diehl 8c559cbdc9 fixed bug concerning file handling. 2012-04-11 18:46:36 +00:00
Martin Diehl 37fa6c2e14 merged code for python and spectral solver interfacing (shared most of it anyway).
put functionality for getting header information (dimension, homogenization, resolution) in functions in mesh.f90
2012-04-11 17:28:08 +00:00
Martin Diehl f2da887899 added missing ":" in mesh.f90, introduced absolute stress tolerance for spectral solver in numerics.config/numerics.f90 2012-04-11 12:57:25 +00:00
Krishna Komerla f20cecd421 integrated subroutine for regridding into mesh.f90 and made it available for python 2012-04-10 15:15:46 +00:00
Martin Diehl bd9667bd4b added new, flexible debugging scheme.
now all modules have their own debug specification.
compiles and runs, I hope nothing is broken
did a lot of polishing
2012-03-08 20:25:28 +00:00
Martin Diehl 87a83d82b7 changed assumed arrays (:) to properly defined ones (gfortran 4.7 was complaining) and remove use statements that are not needed 2012-02-21 15:39:36 +00:00
Martin Diehl 6c0f9d163b polishing: removed variable names like 'unit' and 'data' that are keywords of fortran and ensured that integer and real precision matches independent of machine standard.
removed cut_off parameter for damask_spectral
removed outpot of derived divergence measures and added RMS output in brackets
added comments and options to the makefile
2012-02-15 18:58:38 +00:00
Christoph Kords c786336af3 reordered (and partly redistributed) error message identifiers, deleted those which are not in use anymore.
all constitutive as well numerics now raises an error, if an unknown keyword is found in the respective config file
2012-02-13 17:41:27 +00:00
Martin Diehl 37ac7bf1b4 fixing inconsistencies in variable assignments 2012-02-10 11:56:05 +00:00
Christoph Kords bbf4f25898 renamed subroutine "mesh_marc_get_mpieOptions" to "mesh_get_damaskOptions" which is now also used for abaqus and spectral input files. The only available option so far is "periodic", which allows for periodic fluxes in the specified direction. Examples for usage (add the following lines to the respective input file, in case of spectral file this goes into the header):
- periodicity in x and z direction for marc:
   $damask periodic x z  
- periodicity in y direction for abaqus:
   **damask periodic y
- periodicity in x and y direction for spectral:
   periodic y x
2012-02-03 12:37:52 +00:00
Martin Diehl 800e291240 made code standard conform to Fortran 2008 (ignoring warning concerning comments beyond character 132). Basically, changing "x" format specifier to "Nx" ("1x") plus removing $ format specifier
added compiler switches for gfortran and ifort to check for standard conformity
old gnu compilers <4.4 are not longer supported because they don't provide the c binding for fftw
2012-01-31 19:18:55 +00:00
Martin Diehl 80583fefb5 added compilation_info.f90, to store compilation date,time and compiler info in each file
added #include statement at each init() routine
2012-01-31 14:54:49 +00:00
Christoph Kords 1032ff3d47 corrected definition of element base node, which was still flawed 2012-01-19 14:15:26 +00:00
Christoph Kords 6c2a61e489 corrected node coordinates and sorting for spectral method 2012-01-17 16:53:56 +00:00
Philip Eisenlohr f3bb2271c9 parsing of spectral geom file now accepts two-dimensional microstructure definition (plus range indications by 'x to y')
For instance:
1 2 3 4
5 6 7 8
9 10 11 12
...
2012-01-12 17:01:24 +00:00
Pratheek Shanthraj 2ea3c68d3f removed spectralPicturemode 2012-01-12 10:36:17 +00:00
Martin Diehl 680ba9082f removed deadlock when calling IO_warning(33)
polished IO_error and IO_warning
checked OpenMP critical statements in DAMASK_spectral.f90
corrected writing of headed in DAMASK_spectral.f90
2011-11-02 14:38:42 +00:00
Martin Diehl 6cf464b8a9 added 'spectralPictureMode' for reading in geometries with 1to1 mapping (e.g. EBSD pattern)
polishing
!incremental update, wait for commit of damask_spectral.f90 before checking out
2011-10-18 09:20:29 +00:00
Martin Diehl c35ea33f8e did a lot of polishing:
- removed unnecessary "return" before end of subroutine or function:
- changed undetermined array length (:) to (1:3)

To prevent problems with some code analysing tools:
- "3D oneliner loops" (with ";) only for "do" and "enddo" at the same time
- removed line continuation in OMP statements

made the makefile more flexible, removed heap-arrays switch
2011-09-13 15:54:06 +00:00
Christoph Kords 1ffb59a96a Calculation of current ip volumes now working. Crystallite output also reflects current grain volume, not reference volume. However, this is only available for Marc. Abaqus and spectral method still return the reference ip volume. The ip coordinates though are correctly updated for all solver types. 2011-08-10 16:37:17 +00:00
Philip Eisenlohr 06a4ac2565 fixed bug (segmentation fault) occurring for non-renumbered meshes: ipNeighborhood building did use FE IDs of twin nodes to address memory -- dangerous..! 2011-07-31 15:42:59 +00:00
Philip Eisenlohr a26d9c844b max size of crystallite result is now based on actual use within the mesh, not just picking the largest chunk from the material.config file... 2011-06-08 09:16:48 +00:00
Franz Roters 08d39342e4 reworked restarting for compatibility with abaqus (not yet fully working)
added new orientation feature for direct simulation:
  component type (random) asigns random orientation to an entire grain
2011-05-28 09:44:43 +00:00
Christoph Kords cac45cff96 ip coordinates are now updated every cycle; this is needed for the nonlocal internal stress fields
* Marc: node displacements are added to initial node coordinates (mesh_node0) to get current node positions (mesh_node), then ip coordinates are deduced
* Abaqus: ip coordinates are directly updated, no update of node coordinates!
* Spectral: for the moment no update of either ip or node coordinates! passing only dummy values with initial ip coordinates
2011-05-24 15:57:59 +00:00
Philip Eisenlohr fa98133f8e renamed interface from "mpie_interface" to "DAMASK_interface" 2011-05-11 17:01:03 +00:00
Philip Eisenlohr e5a2d829b0 new substructure with 'include' and 'config' directories
renaming of mpie_... to DAMASK for main usersubroutines

extension of element outputs from 5 to 8 digits (FFT!!!)
2011-05-11 16:38:45 +00:00
Franz Roters 7d84a0911e removed unused variables 2011-04-13 14:16:22 +00:00
Philip Eisenlohr e00d073ee3 added new 2D triangle elements
added some sourcecode commenting on internal database formats
corrected database to allow for ipVol and Area calc in 2D element cases
2011-04-06 08:35:37 +00:00
Franz Roters fcdb805225 added copyright text to all f90 (free) format files 2011-04-04 14:09:54 +00:00
Franz Roters 78d4e7d1dc mpie_cpfem_abaqus_std.f: first call is with kinc==1
mesh: allow multiple element sets with identical material
2011-03-23 16:20:12 +00:00
Christoph Kords 11138e3ee2 debugging output is now controlled by the "verbosity" parameter in the debug.config ranging from 0 (=almost no output) to 8 (=very detailed output)
0 : only version infos and all from "hypela2"/"umat"
1 : basic outputs from "CPFEM.f90", basic output from initialization routines, debug_info
2 : extensive outputs from "CPFEM.f90", extensive output from initialization routines
3 : basic outputs from "homogenization.f90"
4 : extensive outputs from "homogenization.f90"
5 : basic outputs from "crystallite.f90"
6 : extensive outputs from "crystallite.f90"
7 : basic outputs from the constitutive files 
8 : extensive outputs from the constitutive files

If verbosity is equal to zero, all counters in debug are not set during calculation (e.g. debug_StressLoopDistribution or debug_cumDotStateTicks). This might speed up parallel calculation, because all these need critical statements which extremely slow down parallel computation.
2011-03-21 10:31:17 +00:00
Christoph Kords 235266b169 openmp parallelization working again (at least for j2 and nonlocal constitutive model).
In order to keep it like that, please follow these simple rules:

DON'T use implicit array subscripts:
example:    real, dimension(3,3) :: A,B
                  A(:,2) = B(:,1)               <--- DON'T USE
                  A(1:3,2) = B(1:3,1)       <--- BETTER USE
In many cases the use of explicit array subscripts is inevitable for parallelization. Additionally, it is an easy means to  prevent memory leaks.

Enclose all write statements with the following:
!$OMP CRITICAL (write2out)
<your write statement>
!$OMP END CRITICAL (write2out)

Whenever you change something in the code and are not sure if it affects parallelization and leads to nonconforming behavior, please ask me and/or Franz to check this.
2011-03-17 10:46:17 +00:00
Martin Diehl a6d1e5c911 now deleted old _single files 2011-02-25 12:49:18 +00:00
Martin Diehl cd5407b08b removed all math functions only for double precision by the more flexible counterpart, e.g. "dsqrt --> sqrt", "dsin --> sin". Should not cause any harm, as long as "implicit none" is used.
Now it is possible to compile a single precision spectral solver/crystal plasticity by replacing mesh.f90 and prec.f90 with mesh_single.f90 and prec_single.f90.
For the spectral method, just call "make precision=single" instead of "make". Use "make clean" evertime you switch precision
2011-02-25 09:25:53 +00:00
Christoph Kords 8aef9b1c13 check for twin nodes only in direction of the surface normal. this solves a problem with models of single element thickness and periodic fluxes. 2011-02-24 09:26:30 +00:00
Christoph Kords fed53a7e60 in subroutine "mesh_marc_get_mpieOptions": need at least one additional string after keywords "$mpie" and "periodic", not two as it used to be 2011-02-23 12:33:51 +00:00
Christoph Kords 8f626c8989 Now able to have real periodicity for fluxes (fluxes leaving the model on one side enter on the other side).
To enable this feature one has to add the following somewhere in the marc input file:
   $mpie periodic x y z
      for having periodicity in all directions
   $mpie periodic z x
      for having periodicity in x and z direction
   etc.
Note that this only works for regular meshes!!!
2011-02-16 16:23:08 +00:00
Martin Diehl 9927cd7adb changed format of resolution. instead of reading exponent of two, now the number given equals directly to the number of FPs. Allows us to use arbitrary number of FPs.
example:
OLD: reading 5 results in 2^5=32 FPs
NEW: reading 33 results in 33 FPs
2010-10-01 10:42:15 +00:00
Philip Eisenlohr b259fbd9c6 1) added distribution of leapfrog breaks
2) lattice_symmetryType is now a function (former lookup array was buggy)
3) stricter check of state var values (>0!) and memory deallocation done
2010-09-30 07:31:53 +00:00
Christoph Kords 7d4c7f7fa7 corrected bug in debug: stressloop info was erroneous
mesh init now showing much more ip statistics in verbose mode
2010-09-07 09:06:02 +00:00
Philip Eisenlohr bb9899e7de 1) added element type 57 (C3D20R) reduced quadratic hexahedral
2) need discussion about the present omission of the FE_nodesAtIP for type 8 --> added comment into source code
2010-08-16 22:53:24 +00:00
Philip Eisenlohr 298cecbfec corrected syntax errors (long lines, line continuation by \) and logical mistake in mpie_cpfem_marc / abq_std which went unnoticed in ifort. Using SunStudio f90 surfaced those... 2010-08-03 23:47:00 +00:00
Philip Eisenlohr 4d110126da adopted improvements done by Arun Prakash.
mesh:
elemType identification based on lower case
Abaqus now reports more errors

IO:
new function to inquire whether inputfile contains "parts"
new function to assemble multiply included inputfile into a flat one
awareness of range generation in element numbers
error reporting
2010-07-13 10:26:07 +00:00
Martin Diehl 661bb97800 corrected some problems in building mesh 2010-07-01 15:20:39 +00:00
Philip Eisenlohr 8ea52ac495 mpie_spectral now can read loadcase data
adapted error codes
2010-06-10 14:51:10 +00:00
Christoph Kords 19b6fae88b added a missing exclamation mark in front of an $OMP directive 2010-05-18 08:07:55 +00:00
Franz Roters 483584ceb3 improved version of general I/O functions
renamed module cpfem_interface to mpie_interface
2010-05-11 06:57:15 +00:00
Philip Eisenlohr 0416c9a616 reworked build_ipNeighborhood
added C3D8R reduced integration hexahedral element
2010-05-10 14:54:59 +00:00
Philip Eisenlohr 97f206d0bc new errors regarding Spectral method input file parsing
mesh setup from Spectral input file
$Id$ in FEsolving activated
2010-05-06 16:40:47 +00:00
Franz Roters e8719cb6b8 Table driven input works wirh 2010!
That leaves DDM to do for tomorrow ;-)
2010-04-29 09:43:31 +00:00
Christoph Kords 1730a90e12 corrected ip numbers in FE_ipNeighbor for element type 21; used to get wrong neighborhood for this element type 2010-04-06 11:45:23 +00:00
Denny Tjahjanto 40b1478dac the latest RGC model + corrections for "element homogeneous" feature 2010-03-24 13:20:12 +00:00
Philip Eisenlohr c3cd75c2c2 small polishing 2010-02-18 10:12:45 +00:00
Franz Roters 9c63005c8f allow for longer pathes when openening files
corrected error messages concerning file openening
2010-02-18 08:29:57 +00:00
Christoph Kords ac080e0b52 corrected small mistake in calculation for ip center of gravity / ip coordinates; used to ignore subnodes that had coordinates (0.0, 0.0, 0.0) 2009-12-22 13:23:20 +00:00
Philip Eisenlohr 7f84961c93 less debug clutter... 2009-10-14 13:23:52 +00:00
Philip Eisenlohr 21cad32137 # new interface for Abaqus
# IO has some additional functionality for Abaqus parsing
# ping pong scheme in FE interface now similar (and more human understandable) in both versions
# mesh has better splitting of different tasks, plus operation on database whenever possible
# FEsolver as new global var to indicate FEM solver type
# computation mode reshuffling: 6 is now Marc special case of recycling...
2009-10-12 16:01:49 +00:00
Christoph Kords 4ff497e5ba mesh_build_sharedElems does not need an input argument anymore 2009-10-08 09:23:15 +00:00
Philip Eisenlohr e7247551f0 changed "build_sharedElements" to use (then existing) internal element data structure instead of reading again from the input file. The data structure is already established by "build_elements"... 2009-10-08 09:01:59 +00:00
Franz Roters 2029b23f98 added version information to all files
do NOT edit text like this:
$Id: constitutive_phenopowerlaw.f90 406 2009-08-31 14:13:10Z MPIE\f.roters $
2009-08-31 15:09:15 +00:00
Christoph Kords 2aae7b7574 added dislocation multiplication to dotState in constitutive_nonlocal.f90
cleaned up debugging output statements to *.out file
2009-08-12 11:22:02 +00:00
Christoph Kords 8ed3ddc03b now with first draft of nonlocal constitutive law
debugging memory leak closed
debugging counters corrected

center of gravity stored in mesh

state updated is now split into a collecting loop and an execution

updateState and updateTemperature fill sequentially separate logicals and evaluate afterwards to converged

added 3x3 transposition function, norm for 3x1 matrix and 33x3 matrix multiplication in math

non-converged crystallite triggers materialpoint cutback (used to respond elastically)

non-converged materialpoint raises terminal illness which in turn renders whole FE increment useless by means of odd stress/stiffness and thus waits for FE cutback
2009-08-11 16:31:57 +00:00
Franz Roters a6ccfe2e44 restructured the repository: renamed trunk into code, moved documentation one directory up, therefore you can now checkout either code or documentation only if you like 2009-06-25 07:17:59 +00:00