aboutsummaryrefslogtreecommitdiff
path: root/Carpet/CarpetLib/src/ggf.cc
Commit message (Collapse)AuthorAge
...
* CarpetLib: Treat op_copy correctly when regriddingErik Schnetter2005-06-08
| | | | | | | Treat the transport operator op_copy correctly when regridding, i.e., do not require more than 1 time level. darcs-hash:20050608114748-891bb-60e3c348364f32f5abe28697266a1b36c51dd678.gz
* CarpetLib: Add new transport operator type op_copyErik Schnetter2005-06-07
| | | | | | | | | | | | | | | Add a new transport operator type op_copy. This "prolongation" operator does not interpolate in time, but rather copies the from the newest time level instead. Such grid functions need only one time level. This is intended for prolongating or restricing grid functions like the ADM constraints; if done properly; they will have the same values on the coarse and fine grids. (However, this does not work for the ADM constraints, because such grid functions still need to be set in EVOL, not in ANALYSIS.) darcs-hash:20050607160833-891bb-cfd1c7630f8996606328d7c7e9fe326561106aba.gz
* CarpetLib, Carpet: implement and use collective communication buffersThomas Radke2005-03-30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Collective buffers are used to gather all components' data on a processor before it gets send off to other processors in one go. This minimizes the number of outstanding MPI communications down to O(N-1) and thus improves overall efficiency as benchmarks show. Each processor allocates a pair of single send/recv buffers to communicate with all other processors. For this the class (actually, the struct) comm_state was extended by 3 more states: state_get_buffer_sizes: accumulates the sizes for the send/recv buffers state_fill_send_buffers: gathers all the data into the send buffers state_empty_recv_buffers: copies the data from the recv buffer back into the processor's components Send/recv buffers are exchanged during state_fill_send_buffers and state_empty_recv_buffers. The constructor for a comm_state struct now takes an argument <datatype> which denotes the CCTK datatype to use for the attached collective buffers. If a negative value is passed here then it falls back to using the old send/recv/wait communication scheme. The datatype argument has a default value of -1 to maintain backwards compatibility to existing code (which therefore will keep using the old scheme). The new communication scheme is chosen by setting the parameter CarpetLib::use_collective_communication_buffers to "yes". It defaults to "no" meaning that the old send/recv/wait scheme is still used. So far all the comm_state objects in the higher-level routines in thorn Carpet (restriction/prolongation, regridding, synchronization) have been enabled to use collective communication buffers. Other thorns (CarpetInterp, CarpetIO*, CarpetSlab) will follow in separate commits. darcs-hash:20050330152811-776a0-51f426887fea099d1a67b42bd79e4f786979ba91.gz
* CarpetLib: remove unused send_listvect argument in copycat() and intercat()Thomas Radke2005-03-23
| | | | darcs-hash:20050323191002-776a0-4a40d844dee2a66e8802669d960709e3488216c4.gz
* CarpetLib: Whitespace changeErik Schnetter2005-02-01
| | | | darcs-hash:20050201231759-891bb-db87543a706110d2cd819a7f38c1e67cf27e16a3.gz
* global: Change the way in which the grid hierarchy is storedErik Schnetter2005-02-01
| | | | | | | | | | | | | | | | | | | | Change the way in which the grid hierarchy is stored. The new hierarchy is map mglevel reflevel component timelevel i.e., mglevel moved from the bottom to almost the top. This is because mglevel used to be a true multigrid level, but is now meant to be a convergence level. Do not allocate all storage all the time. Allow storage to be switched on an off per refinement level (and for a single mglevel, which prompted the change above). Handle storage management with CCTK_{In,De}creaseGroupStorage instead of CCTK_{En,Dis}ableGroupStorage. darcs-hash:20050201225827-891bb-eae3b6bd092ae8d6b5e49be84c6f09f0e882933e.gz
* CarpetLib: Rename some variables to avoid shadowing class membersErik Schnetter2005-01-01
| | | | darcs-hash:20050101191615-891bb-20b262ff1a4468d5e1c5ac8626a3ead0727c2da9.gz
* global: Turn CarpetLib templates into classesErik Schnetter2005-01-01
| | | | | | | | | | | | | | | | | | | Turn most of the templates in CarpetLib, which used to have the form template<int D> class XXX into classes, i.e., into something like class XXX by setting D to the new global integer constant dim, which in turn is set to 3. The templates gf and data, which used to be of the form template<typename T, int D> class XXX are now of the form template<typename T> class XXX The templates vect, bbox, and bboxset remain templates. This change simplifies the code somewhat. darcs-hash:20050101182234-891bb-c3063528841f0d078b12cc506309ea27d8ce730d.gz
* global: Replace "&&" and "||" by "and" and "or"Erik Schnetter2005-02-01
| | | | darcs-hash:20050201214347-891bb-286c20316478d9f1c8384f94764174cab5adb9e0.gz
* global: Remove $Header$ keywords from Carpet arrangementErik Schnetter2005-01-01
| | | | darcs-hash:20050101162121-891bb-ac9d070faecc19f91b4b57389d3507bfc6c6e5ee.gz
* CarpetLib: Use new style instead of old style C++ headersErik Schnetter2004-12-25
| | | | | | That is, say e.g. <cmath> instead of <math.h>. darcs-hash:20041225182902-891bb-2a4502d6a76ed830ab978030fc4e4765b183509f.gz
* UNDO: Initialise_decomposeswhite2004-12-01
| | | | | | | Broke this mama of a function into a couple of levels of functional parts. darcs-hash:20041201155737-32473-d59b9f090a4d5bac0bce2d668c7ae674d545e660.gz
* Initialise_decomposeswhite2004-12-01
| | | | | | | Broke this mama of a function into a couple of levels of functional parts. darcs-hash:20041201155737-32473-ce364db1ab14403a823d0bf0937ff4520ed04639.gz
* Remove CVS header tagsErik Schnetter2004-09-18
| | | | | | Replace all CVS header tags with the standard "$Header:$". darcs-hash:20040918132147-891bb-dea889bdd94a479ec412d14d08e9efca63e5c24d.gz
* Recompose vector groups on multiple refinement levels correctly.schnetter2004-09-17
| | | | darcs-hash:20040917143726-07bb3-cdfed6bde9278cc33ad4ad0a04ed13d6a700b65d.gz
* Re-introduce the parameter Carpet::prolongate_initial_data with theschnetter2004-08-07
| | | | | | | | | | | Re-introduce the parameter Carpet::prolongate_initial_data with the default "yes". If set to "no", newly created refinement levels are not initialised through prolongation, which saves quite some time. Remove the unused optional argument checkpoing_recovery from Carpet::Regrid. darcs-hash:20040807174712-07bb3-78054ad80959a2e26238531d9ea54eaac161ffce.gz
* Copy the whole exterior during regridding instead of relying onschnetter2004-05-29
| | | | | | | Copy the whole exterior during regridding instead of relying on boundary prolongation. darcs-hash:20040529093622-07bb3-743ef08b661877e18b6772d31ecb6e18134773da.gz
* Add option to use less memory during regridding.schnetter2004-05-21
| | | | | | | | | Add option to use less memory during regridding. Some more internal consistency checks. Some reformatting. darcs-hash:20040521161341-07bb3-de11e460fb175d3dbbd94708730c18a6e94e370a.gz
* Replaced some time comparison asserts by a (hopefully) more robust choice.bzink2004-05-11
| | | | | | - bzink darcs-hash:20040511105326-5b8bb-7120c4b070169b13fd49d63a783cce544482dc68.gz
* Removed an assert in line 556. This assert compares CCTK_REALs, and canbzink2004-05-11
| | | | | | lead to a code stop after recovery. darcs-hash:20040511055304-5b8bb-fb243c24af5033c8486914703840895e0bbc82f1.gz
* While regridding, initialise only the interior of the grid functions.schnetter2004-04-20
| | | | | | | | While regridding, initialise only the interior of the grid functions. There is in general not be enough parent to intialise the outer boundaries. darcs-hash:20040420095552-07bb3-812459eafff1161f31a5cb26686ced00b7512b68.gz
* Regrid all grid functions at once. This is necessary to treate vectorschnetter2004-04-19
| | | | | | | | | | Regrid all grid functions at once. This is necessary to treate vector grid functions correctly, where otherwise storage would be released too early. This requires the regridding interface between the dh and ggf classes to change. Another advantage is that this should now be faster on multiple processors. darcs-hash:20040419193833-07bb3-f7474744feaa57f8a1621aeca34de11b65eaeed8.gz
* Loop over all components of the parent grid when regridding.schnetter2004-04-19
| | | | darcs-hash:20040419130015-07bb3-1ec081e478db9a67b131f6f351719b45c9b12a9c.gz
* Remove the parameters Carpet::prolongate_initial_data; this is nowschnetter2004-04-18
| | | | | | | | | | | | Remove the parameters Carpet::prolongate_initial_data; this is now always done. Remove arguments initialise_from and do_prolongate from Regrid(). Regridding is now done in level mode instead of meta mode. Furthermore, CarpetRegrid is called in singlemape mode. darcs-hash:20040418112943-07bb3-2e392df1737ab75f3f0d553bb53bde2ed41f8773.gz
* Use vector::at() instead of vector::operator[] to access vector elements.schnetter2004-03-23
| | | | darcs-hash:20040323183014-07bb3-4562b1a7b1dda25fbcccc7689c19bbd432b8a1ff.gz
* Implement vector groups correctlyschnetter2004-03-23
| | | | darcs-hash:20040323114027-07bb3-1ac44b7b144e8936307942bc999d54ecb579719f.gz
* Remove unused codeschnetter2004-03-23
| | | | darcs-hash:20040323082649-07bb3-12b7902da4c7dd33c6ed3298e50e9b714a8098aa.gz
* When regridding, prolongate the boundaries before synchronising.schnetter2004-03-22
| | | | darcs-hash:20040322171233-07bb3-e2f320128e8e821ee4f339defcaf7ca93c6e3b16.gz
* Fix severe bug in mglevel array indexing.schnetter2004-02-27
| | | | darcs-hash:20040227152553-07bb3-62fdc4ce251d7f202068d1ee030448e75b96b4a9.gz
* Do not restrict nor prolongate when the prolongation operator has beenschnetter2004-02-03
| | | | | | | Do not restrict nor prolongate when the prolongation operator has been set to "none". darcs-hash:20040203133322-07bb3-7fd7e5fc85efe04ecd39864cba0385a4570bf46a.gz
* Import the recently announced changes:schnetter2004-01-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Import the recently announced changes: 1. Carpet has now an infrastructure for multiple maps (aka "grid patches"). Instead of a single grid hierarchy there can now be several. This is largely untested, because the remainder of Cactus cannot handle multiple coordinate systems. 2. The order in which the schedule bins are called has changed. As Ian Hawke pointed out, the previous order during time evolution was inconsistent. The initial data ordering did not allow for recovering and was not usable for progressively solving elliptic equations for initial data. 3. Carpet now supports convergence levels. The convergence level specifies by how many factors of two the resolution in the parameter file should be coarsened (or refined, if negative). This should make convergence tests and test runs much easier. It is, in principle, also possible to run several convergence levels at once. This has not been tested because the remainder of Cactus cannot handle multiple resolutions. This will be necessary for a multigrid solver, and also for having a shadow hierarchy to determine where to refine adaptively. 4. Carpet works together with the new CoordBase domain specification parameters. Without these, using convergence levels will lead to very strange results. 5. The "modes" have changed. There are now: meta mode: the whole simulation global mode: one convergence level level mode: one refinement level singlemap mode: one map on one refinement level local mode: as previously The whole mode handling has been cleaned up. 6. The regridding thorn has been cleaned up. 7. The kind of prolongation stencil is now determined in Carpet, i.e. at a fairly hight level, instead of in CarpetLib. 8. The low-order prolongation operators have been made much more efficient (as have previously the higher-order ones). 9. Assorted smaller changes. For Carpet users, there should be no major incompatibilities. The major improvements are 3 and 4 combined. Here is an example: CoordBase::domainsize = extent CoordBase::spacing = gridspacing CoordBase::zero_origin_x = yes CoordBase::zero_origin_y = yes CoordBase::zero_origin_z = yes CoordBase::xextent = 20.0 CoordBase::yextent = 20.0 CoordBase::zextent = 20.0 CoordBase::dx = 1.0 CoordBase::dy = 1.0 CoordBase::dz = 1.0 CoordBase::boundary_shiftout_x_lower = 1 CoordBase::boundary_shiftout_y_lower = 1 CoordBase::boundary_shiftout_z_lower = 1 Carpet::domain_from_coordbase = yes Carpet::convergence_level = 0 grid::type = coordbase grid::domain = octant grid::avoid_origin = no This gives you a grid that extends from the origin ("zero_origin") up to 20.0 with a grid spacing of 1.0. Symmetry zones and boundary zones are added automatically. The "shiftout" says that there is no boundary point on the origin. The staggering parameters (not shown) default to "no". In order to change the resolution, only the convergence level has to be adjusted. Note that the old way of specifying the domain extent still works. For Carpet developers, one major change is the new mode handling. As described in 5, the looping macros (that loop over all refinement levels, or all components) have changed. darcs-hash:20040125135727-07bb3-51c9647c1b5080e7e180b52a1b81fa155cfd19e9.gz
* Many changes that accumulated while Cactus and Carpet diverged.schnetter2003-11-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Many changes that accumulated while Cactus and Carpet diverged. Add processor splitting mechanism "along-dir" that splits along a specified direction. Rename group PostRestrict to bin POSTRESTRICT. Prolongate initial data only when desired. This saves much time. Sorry, Ian. Fix bug in time level cycling of grid arrays. (Note: grid arrays should not have time levels.) Fix time_t bug on IRIX. Make sure that there is no integer overflow when there are many refinement levels. Always put parentheses around (maxreflevelfact/reflevelfact). Fix typo in Carpet verbose output. Add debug output in processor splitting. Communicate in three stages: Irecv, (work), Isend, Wait. This might be more efficient. Much more, potentially. Fix bug in processor layout of grid arrays. Sorry, Ian. Make the interpolator interpolate between time levels. Untested. Fix bug in processor communication in interpolator. Sorry, Ian. Rewrite prolongation operators to make them twice as fast. There you are, Ian. Move prolongation operator kind handling from data to gdata. Add official hyperslabbing interfaces to CarpetSlab. Adapt to new cGH * handling. darcs-hash:20031105151837-07bb3-758a87ff0355dba053269df4b7d7d79bea018669.gz
* Make gf and data objects store a Cactus variable index that thisschnetter2003-10-14
| | | | | | | | Make gf and data objects store a Cactus variable index that this object is associated with. This can be used to access various kinds of information, e.g. variable names. darcs-hash:20031014143916-07bb3-678d114393008db7790b5ed72d6462673414c06a.gz
* bbox::size() and bboxset::size() return the number of grid points, notschnetter2003-09-19
| | | | | | | | | bbox::size() and bboxset::size() return the number of grid points, not the product of the shape. This makes larger grids possible. Mark necessary future changes for vector grid functions with VGF. darcs-hash:20030919140641-07bb3-94c1897464dcc159725618d611ac28f3f75a3011.gz
* Fix bug in three timelevel initialisation:schnetter2003-08-10
| | | | | | | | | Fix bug in three timelevel initialisation: Change order of time level flipping and restricting. ggf.cc: Remove commented out code. darcs-hash:20030810105209-07bb3-40c12c5fb838cd56a99f26c8ca71529bfe11a900.gz
* Major update after a quiet time.schnetter2003-06-18
| | | | | | | | | | | | | | | | | | | | Major update after a quiet time. Carpet: The flesh now has new cGH fields cctk_levoff[], cctk_levoffdenom[], and cctk_timefac that describe the spatial offset and temporal refinement factor between the base and the current refinement level. These fields are now set and used; they change how coordinates are handled. CarpetIOASCII: Fix bugs regarding choosing the output hyperslab and the output coordinates. ID*, *Toy*: New WaveToy examples with various formulations and different integrations methods. Currently, none of them converge to second order except the standard WaveToy formulation. These updates require the recent flesh, base thorn (and MoL) updates. darcs-hash:20030618162427-07bb3-70761f74bce6ae246b5a2943a385647657d46d34.gz
* Do not initialise the finer levels of the grid functions at initialschnetter2003-05-02
| | | | | | | Do not initialise the finer levels of the grid functions at initial time through prolongation. darcs-hash:20030502122312-07bb3-ad2023a18bb9177cae3fbbe0df5aa4401f0a0259.gz
* Remove #warning statements that are not understood by the SGIschnetter2003-03-28
| | | | | | | Remove #warning statements that are not understood by the SGI compiler. What was I thinking? darcs-hash:20030328091154-07bb3-dc9908d5049478c1e85f72a4bb4a1703fdf83fb1.gz
* bboxset.cc: Output setsize as well.schnetter2003-03-26
| | | | | | | | | | | | | | | | | | | | | | bboxset.cc: Output setsize as well. dh.cc: Add #warning statements where future improvements might be necessary. dh.cc: Allow prolongation bbox set with more than one element. dh.cc: Normalise the bbox sets for the prolongation and boundary prolongation. dh.hh: Add a comment regarding what is synced and what not. ggf.cc: Add #warning statement where future improvements might be necessary. vect.cc: Instantiate vect<bool,3>. vect.hh: vect::replace is const. darcs-hash:20030326163443-07bb3-3b2f685d3fd928e5a0b75a633aff5a67bf54bf47.gz
* Handle empty bboxes.schnetter2003-02-25
| | | | | | | | | | | | | | | | | | | | | | Handle empty bboxes. *.F77: Better error checking whether the active region is contained in the source and destination arrays. *.F77: Temporarily activated per-gridpoint checking of array accesses. bbox.cc bboxset.cc: Handle empty bboxes better -- either handle them correctly, or abort. gdata.cc: Recognise empty regions. ggf.cc: Remove line that was commented out for a long time. dh.cc: Choose send and recv regions for syncing and prolongation so that they don't overlap. dh.cc: Handle empty bboxes. darcs-hash:20030225215700-07bb3-a7296dd92353c003bc0bd3ff435e4939f8041eae.gz
* Removed the "dimgeneric_*" data types from CarpetLib. They were neverschnetter2003-01-03
| | | | | | | | | | | | | Removed the "dimgeneric_*" data types from CarpetLib. They were never really used anyway. Changed "th" into "th<D>". Renamed "generic_*" to "g*". Propagated these changes to all other places. darcs-hash:20030103144936-07bb3-c4d74d2d94a56a898f9bb735666eefc01e2610e2.gz
* Changed the variable types for the time from int to real. This allowsschnetter2002-09-25
| | | | | | | | | | | | | Changed the variable types for the time from int to real. This allows more flexibility for time interpolation. The time interpolators now accept an explicit argument for the current time, instead of using the current time from the time hierarchy. This allows arbitrary current times, which are necessary for the intermediate time steps for time interpolators. The times that are interpolated _from_ still come from the time hierarchy. darcs-hash:20020925134915-07bb3-26927a425ca5c0b52a2ca02bc54673c4b9e1781e.gz
* Fixed some compiler warnings. Mostly added C++ "typename" keywords.schnetter2002-08-30
| | | | darcs-hash:20020830140318-07bb3-061e0233bad17df8536c1dba820b560d6578f4df.gz
* In restrict, changed assert into a warning messageshawley2002-07-18
| | | | darcs-hash:20020718123418-e415b-1f58e4f24030a94d4165ffb2866626680f1335ef.gz
* Fixed bugs.schnetter2002-06-06
| | | | | | | Fixed bugs. Added "flip timelevels" capability. darcs-hash:20020606122015-07bb3-7eab2bcf55becde5136b2b9051c4133bd595b9bd.gz
* Removed user choice of C++ template instantiation model. In myschnetter2002-05-05
| | | | | | | | | | | | | | | | | Removed user choice of C++ template instantiation model. In my experience, only one model works, namely explicit template instantiaion. No need to pretend that the other things work with Cactus. (Don't complain to me -- I also think it's a shame that something that calls itself "compiler" isn't able to do this automatically. Many other compilers for many other languages do this kind of thing without even mentioning it. So there's either something fundamentally wrong with the C++ standard, or with the C++ compiler writers, or with the perceived wishlists of C++ users. And I would bet an arm and a leg that it's not the second of these.) darcs-hash:20020505201656-07bb3-a1b8dfc5587d59c718ad25ce89d0c8973c2b3e6f.gz
* Added a bit of convenient functionality.schnetter2001-12-14
| | | | | | | Added a bit of convenient functionality. Fixed a few bugs that were uncovered by dynamic regridding. darcs-hash:20011214153941-07bb3-c31c15cec651b5c3c992f529b7409c081fda5ba8.gz
* Changed handling of interpolation orders; they are now stored in theschnetter2001-12-09
| | | | | | | | | Changed handling of interpolation orders; they are now stored in the grid functions and don't have to be passed around. Speeded up some prolongation operators. They are still slow. darcs-hash:20011209154308-07bb3-caa74a89a87c290852f2b59160ed26d9361f3cf1.gz
* Broke the file "carpet.cc" into several files.schnetter2001-07-04
| | | | | | | | Broke the file "carpet.cc" into several files. Simplified support for arrays with a dimension different from 3. Added a testing thorn. darcs-hash:20010704102946-07bb3-82132f0c643e91f0de33bbaef93f9c693ce7227f.gz
* Second stab at having arrays with a dimension different than gridschnetter2001-07-02
| | | | | | | Second stab at having arrays with a dimension different than grid functions. Not yet tested. darcs-hash:20010702112209-07bb3-816053f629c333189a63014698d4b34c124168aa.gz