2019-08-22 Oliver Lemke * arts-2-3-1277 * doc/uguide/development.tex: Updated section "Version numbers". * doc/uguide/concept.tex: Replace one occurrence of svn with git. 2019-08-22 Oliver Lemke * arts-2-3-1276 * .clang-format: Set format as described in developer guide 1.3. Most IDEs use this file automatically. VSCode or CLion will automatically use it if you enable clang-format in the IDE's settings. 2019-08-22 Oliver Lemke * arts-2-3-1275 * GITHUB-INTRO.md, CONTRIBUTING.md: Move section 'Update your working copy' from GITHUB-INTRO to CONTRIBUTING. Add global config setting to enable rebase by default. 2019-08-21 Oliver Lemke * arts-2-3-1274 * CONTRIBUTING.md: Extend paragraph about 'push' a bit based on Freddy's feedback. 2019-08-21 Richard Larsson * arts-2-3-1273 Removes NEWARTSCAT text * src/jacobian.cc,h: * src/linefunctiondata.cc,h: * src/linefunctions.cc,h: * src/linerecord.cc,h: * src/m_linerecord.cc: * src/m_jacobian.cc: * src/m_linemixing.cc: Removed all hidden text from the #ifndef NEWARTSCAT * src/absorption.cc, src/hitran_xsec.cc, src/nlte.cc: Added include to polynominal interpolation routines since they used to be included from the chain: linerecord<-linefunctiondata<-linemixingdata<-polyinominal interpolation * src/test_propagationmatrix.cc: Removed tests of old LineFunctionData * src/linemixingdata.cc,h,src/pressurebroadeningdata.cc,h: Removed * controlfiles/*: Updated test files because two of the new calculations does not appear to work properly at all. These are the derivatives wrt G2 and D2. I am unsure how to fix this because all the numbers appear very similar when printed between the two versions, yet the error is about the same as if someone flipped the line and changed its sign. I choose to update all .xml files of the lineshape tests because the 1e-6 error limit is likely to strict and several of them failed in the 1.2e-6 range. Note that both CIA and Spectroscopy derivative tests also failed but only their derivative matrix is changed. I will continue investigate this error but the code is still viable for forward calculations. I am at this point unsure where and how these errors can have gotten so large... * src/CMakeLists.txt: Removed the two .cc files * src/linefunctiondata.cc (cont): differenceOutput added to return the difference between two Output. Also fixed an assert that should be an exception in Model::vmrs. * src/linerecord.h (cont): Made LineRecord::GetShapeParams_dVMR behave similar as LineFunctionData did. I still believe this is an error and that during pure Air broadening, the self-species should give a positive derivative. But this mimics the old behavior for now. It is somewhat murky, since ARTS renormalizes the VMR whether or not an increase in the VMR of a species means it is proportional to an increase in pressure or not. In the former, the code that is presently commented out should be mostly valid, in the latter the return should be zeroes. In practice, if the retrieval wants to broaden the line more than it is then the altitude grid is most likely wrong, which means there really is more molecules at the distance represented by the Jacobian, but since ARTS has pressure as a constant, we cannot have the sum of the VMR on any level above unity (or the pressure was not constant so it cannot be a grid). So I am unsure how to deal with things here. Presently, the FIXME is left commented out but I believe I will add it in shortly and just leave it to later functions to renormalize pressure to the constant that is required (e.g., by deriving the changed path length) 2019-08-20 Richard Larsson * arts-2-3-1273 This is a temporary update to make a move to a much simplified version of ARTSCAT-5. It contains a lot of #ifndef-statement so that it is possible to go back to this version of ARTS and correct the line reading routines in case some special version of the very multi-dimensional current ARTSCAT-5 IO fails in the new version. It should not but not everything is not tested. By activating NEWARTSCAT in linerecord.h, most tests succeed but some fail. I am investigating and once fixed I will remove all things that are not there when NEWARTSCAT is defined * src/jacobian.cc,h: Changed names of JacPropMatType enums that deal with line shape to fit with the new NEWARTSCAT. This includes changing a few function names. * src/linefunctiondata.cc,h: Includes constants.h and removes all of LineFunctionData if NEWARTSCAT is defined. Fixed LineShape::Variable order to match LineFunctionDataOutput. The latter has string and stream handling by operator<<, variable2string, and string2variable. Added SingleModelParameter to select a single Numeric in a ModelParameters. Adopted SingleSpeciesModel to initialize by names in correct order, and to also allow the interpolation array in its initialization. Littered all functions I had to and likely a few I did not have to with std::terminate() to remove annoying and wrongful compiler warnings in complete switch-statements SingleSpeciesModel has a Get and a Set function call now to access G0-DV by enum instead of by name. Renamed LineShape::ShapeType to LineShape::Type. Made LineShape::Output to match 1-to-1 LineFunctionDataOutput. Added operator<< to print it, mirroredOutput to mirror variables that are frequency shifting somehow, negativeOutput to return a negative Output, si2cgs to return CGS Output from SI input. Added bath_broadening and self_broadening for all cases when air and self broadening has to be addressed by name (e.g., Jacobian calculations). Added Model::OK() to test if the Model is Ok. Extended Model initialization to allow setting the interpolation data. Further extended its initialization by allowing a single SingleSpeciesModel and Type to set Model for pure air-broadening. Further extended its initialization to allow setting individual internal variables one-by-one. Fixed bugs in vmrs. First fix is that Doppler profiles require no VMRS so does not need to return a normal vmr-Vector. Second fix is that the renormalization for non-air broadening recomputed the sum in a loop for a very poor renormalization routine. Added Model::this_species to find this species in mspecies. Returns -1 if the species is not in the species list. Note that self and air are not checked for. Fixed poor naming of VMR-derivatives. Separated temperature derivatives since it requires the summing up. Fixed naming error in line shape parameter derivative calls. Added Output calculators to Model: GetParams, GetTemperatureDerivs, GetVMRDerivs, and GetInternalDeriv to mimic LineFunctionData Added several access variables to part of the internal data. Added Set and Get to individual ModelParameters. Added Model::Remove to erase a species. Added SetLineMixingModel to set all line mixing according to a single SingleSpeciesModel. Added from_linemixingdata and from_pressurebroadeningdata to set a Model after ARTSCAT-5 PB and LM tags. Requires the input stream and modifies it. Fixed IO for Model, operator<< and operator>> did not work properly before for self and air broadening Added namespaces LegacyLineMixingData and LegacyPressureBroadeningData to deal with said legacy reading. * src/linefunctions.cc,h: These files are a lot uglier now because they are the main users of NEWARTSCAT-syntax. Also, I believe there might be a bug in the VMR derivatives for pure air broadening in the present version of ARTS. The current version uses negative influence on air-broadening VMR derivatives since (1-self), but when self is not present the number should of course be positive instead. I will need to update derivatives when making NEWARTSCAT default... * src/linemixingdata.cc,h,src/pressurebroadeningdata.cc,h: Completely covered by a "#ifndef NEWARTSCAT" * src/linerecord.cc,h: Removed some lingering unused variables. Added several "#ifndef NEWARTSCAT"-clauses. Made LineFunctionData's standard-check part of the linerecord. * src/m_jacobian.cc: jacobianAddShapeCatalogParameter needed some "#ifndef NEWARTSCAT"-clauses to work * src/m_linemixing.cc: calculate_xsec_from_relmat_coefficients and abs_xsec_per_speciesAddLineMixedBands needed some "#ifndef NEWARTSCAT"-clauses to work * src/m_linerecord.cc: abs_linesReplaceParameterWithLinesParameter and abs_linesSetLineFunctionDataParameterForMatchingLines needed some "#ifndef NEWARTSCAT"-clauses to work * src/test_propagationmatrix.cc: Two tests not longer works with NEWARTSCAT defined since the explicitly test LineFunctionData. * src/zeemandata.h: Very minor text-alignment miss from before. 2019-08-15 Oliver Lemke * arts-2-3-1272 * .gitignore: Add ignore file for git based on a cleaned up version of 'svn propget -R svn:ignore'. * README.md: Add mkdir command for build dir. 2019-08-15 Oliver Lemke * arts-2-3-1271 * README.md: Convert README to Markdown. * CONTRIBUTING.md: Add documentation on how to contribute to ARTS once we've moved to GitHub. * GITHUB-INTRO.md: Basic info on getting started with git/GitHub. 2019-08-15 Oliver Lemke * arts-2-3-1270 * cmake/modules/ArtsVersion.cmake: Change the format of how the commit hash is presented in the 'arts -v' output. Appending it directly to the version number raised the concern that the hash is now part of the version number. This is not the case. The current arts version will still be major.minor.micro as it has always been. Note that a commit is not a version. The version number will be increased after new features or bug fixes have been merged into the main repository. arts -v output will now look like this: arts-2.3.1269 (git: fc6d7a91-dirty) (compiled Thu Aug 15 09:02:07 2019) [...] The hash is only presented there as an additional information for tracking down issues during development, to identify commits in forks and branches and whether the working copy contains local changes. 2019-08-13 Oliver Lemke * arts-2-3-1269 * CMakeLists.txt, cmake/modules/ArtsVersion.cmake, cmake/scripts/update_auto_version_txt.cmake: Add support for generating the ARTS version number once we have moved to git and the ChangeLog will be dropped. Main version will be read from VERSION file in the top level source directory. If a .git directory is found, the hash of the current commit will be appended to the version number for reference (and displayed in arts -v). In addition, if the working copy contains local changes, a 'dirty' flag is appended to the version string. With git, the main VERSION will not be touched by developers anymore on every commit. As git is decentralized this will be impossible since there is no sequential order in commits across forks anymore. (And that is a _good_ thing :-) ). In the future, the main version will be increased in the master branch after new features have been added via pull requests. 2019-08-12 Oliver Lemke * arts-2-3-1268 * .travis.yml: Remove gcc 4.9 since it generates too many warnings since our recent use of the [[maybe_unused]] attribute. Officially this attribute is only supported since C++17 which we're not using yet. But luckily recent compilers can handle it. We need to have a better discussion (or any at all) in the future before using such features. * README: Update requirements. 2019-08-09 Richard Larsson * arts-2-3-1267 This change removes parts of the LineRecord that only took space and was left unused in the code. This includes quantum number strings, line error parameters, and auxillary data. The quantum number strings are parsed for select species already, so the species of interst can still access this data. If retrieval errors depend on line shape errors then we need a line record that contains the errors to be used in OEM to setup the covariance matrix. If we want this to work automatically, major redesigns are required anyways. The main reduction in functionality comes from auxillary data, which seems to have been an old attempt at implementing line mixing? It looks very odd and I have no way to confirm whether it works or what it was supposed to do. It could cause one runtime error if it had data, but the rest of the data was never used so it should be safe to remove. Also, this version stops printing of ARTSCAT versions that are not version 5. Remaining work to improve LineRecord: Decouple NLTE without losing code-readability. Problem: Each line has its own 'temperature', based on each energy state having a different distribution. Either, each line has to store their own level's distributions, or the NLTE data needs to be placed in a python-like dictionary to be accessed by quantum numbers efficiently. Presently, each line stores a key to the position of its energy level distribution in the NLTE field. I think a map-would be better but cannot write such code myself since I don't understand how to make it efficient. * src/linefunctiondata.cc,h: Remove all access to merrors and to much of the ARTSCAT4 printing. * src/linerecord.cc,h: Remove all errors and strings and Arrays from line record class. Also removed printing of artscat 3 and 4, setting their version to 5 to print as this version. No reading is affected by this change, though not all that is read is kept around * src/m_abs.cc: Removed dablings with line shape parameters for O2. I have no idea what the code I commented out actually does, because there seems to be the intent that some data should exist. However said data is never accessed afterwards in the code. It seems very much like a failed or abandoned attempt at line mixing implementations, where the tests for the code working were put in place but to code actually doing the work was left out. I left the code in, commented out if someone can remember how and why it is there. In case there are someone using data that relies on this part working, we can translate that to a new format... 2019-08-09 Oliver Lemke * arts-2-3-1266 * src/m_linemixing.cc (abs_xsec_per_speciesAddLineMixedBands): Adapt call to apply_linestrength_scaling_by_lte for removed zeeman_scaling argument in previous commit. Fixes compilation if relmat is enabled. * src/quantum.h: Add missing include to fix compilation with clang. 2019-08-08 Richard Larsson * arts-2-3-1265 * controlfiles/*: Updated Zeeman test as the latest JQSRT paper is now computed inside ARTS. The updated code passes old tests when run with old variables * src/absorption.cc: Updated Zeeman calculations and removed some lingering code dealing with this. * src/linefunctiondata.cc,h: Tinkerings with some classes to replace LineFunctionData to make line catalogs easier. Placed in a namespace that can easily be removed if this is unpopular. The new namespace can replace LineFunctionData, and handles its IO already. I believe it would be a good idea to consolidate ARTSCAT5 around this new class before a stable release so that the plethora of different input methods can be cleaned away. Since there exists translation methods today from PressureBroadeningData and LineMixingData into LineFunctionData, if we remove LineFunctionData we can also remove the other two classes. I suggest these classes removal is done after moving the code to github so people can find a version of ARTS that can restore functionality of old line catalogs. Note, the new class will have a heavier memory footprint than LineFunctionData for most common cases, perhaps up to a factor 3 worse. It should be faster, however, since it does not require repeat scan-throughs of abs_species for an entire array of line-records (so long as they are of the same origin), and it is written to allow some more speed-ups using the new C++ execution-policies (perhaps first in C++20, with unseq policy). * src/linefunctions.cc,h: Removed line index and instead demand pre-computed Zeeman information. Zeeman strength is dealt with elsewhere. * src/linerecord.cc,h: Replace all of the old Zeeman stuff with a new class that requires looping over polarization inside the Zeeman routine. Reduces memory footprint of Zeeman lines to less than 1/3. Is not backwards compatible, though it should not change any existing setup that is creating the Zeeman line record on the fly. * src/m_atmosphere.cc: Changed t_nlte* variable in AtmFieldsCalc since I noticed it was using the old name still. * src/m_radiation_field.cc: Adopted to changes in linefunctions.cc,h. * src/m_zeeman.cc: Adopted to use new Zeeman scheme. * src/quantum.h: Noticed that QuantumContainer was dynamic container even though its size is static. So fixed it. * src/rational.cc,h: Made Simplify() return itself. *src/test_propagationmatrix.cc: Made a test to ensure internal code reproduces paper results for Zeeman. * src/zeeman.cc: Updated to deal with the new Zeeman::Model class. * src/zeemandata.cc,h: Updated the Zeeman computations and placed them in a namespace. This is hard-coded into the cc-file with constants from literature. I would have preferred to have a way to input these constants or change them on the fly but with ARTS way of dealing with species-traits I don't think this will happen. Thus it is easier to just hard-copy these values whenever and ifever they are updated into the cc-file. 2019-08-01 Oliver Lemke * arts-2-3-1264 * src/linefunctions.cc: (Linefunctions::set_htp): Precalculate sqrt terms that are regularly used (sqrt(X+Y) and sqrt(y)). Improves performance of propmat_clearskyAddOnTheFly by about 15%. Tested with TestHTP and TestSDVP with 1M frequencies. (dw): Add some linebreaks for readability. 2019-07-19 Richard Larsson * arts-2-3-1263 * 3rdparty/wigner/CMakeLists.txt: Now prints a message * src/complex.h: Added a constexpr conjugate. * src/constants.h: Added some more constants and fixed error in text * src/lin_alg.h,cc: Made the least square-fit remove its asserts. It reports R2 anyways. * src/linefunctiondata.cc: Fixed some comments and minimized some lines * src/linefunctions.cc: made set_htp fully into pCqSDHC. I want to keep the other functions around since they are easier to read but maybe this should be removed because of no use? * src/linemixing.cc: Begun work on the linear relaxation matrix * src/m_atmosphere.cc: added MagFieldsFromAltitudeRawCalc * src/m_jacobian.cc: fixed error output * src/m_linemixing.cc: Some restructure * src/m_oem.cc: Throwing error when yf.nelem() not_eq y.nelem() * src/m_retrieval.cc: giving some numbers when error is thrown. The text is not good but numbers are better for guessing at the error than not having them * src/methods.cc: Added methods as above * src/propagationmatrix.h: Begun adding some comments to make my intellisense aware of the functions. Also helps doxygen some * src/rational.h: returned to passively accepting most errors to keep the code easy 2019-07-19 Oliver Lemke * arts-2-3-1262 * src/matpack*.{h,cc}, complex.{h,cc}: Replace manually implemented default constructors with empty bodies by "defaulted" default constructors. They where only used for providing a member initialization list. Instead, member list-initialization is now used when the member is defined. Big cleanup, removes over 3000 lines of code: Remove all reimplementations of const functions in Views that are already defined in the base (ConstView) class but hidden by the newly defined non-const versions. Instead of reimplementing them in the derived class, they can be made visible by a single 'using' statement. 2019-07-19 Simon Pfreundschuh * arts-2-3-1261 * doc/uguide/development.tex Fixed typo in one latex command. 2019-07-19 Simon Pfreundschuh * arts-2-3-1260 * src/m_linemixing.cc: Replaced arrays allocated using new[] with Vector and ArrayOfIndex to avoid memory leak when an exception is thrown. 2019-07-19 Simon Pfreundschuh * arts-2-3-1259 * doc/uguide/developer.txt: Preparations for migration to git: - Replaced SVN part with description of the git-based workflow - Added short description of the new formatting and naming conventions 2019-07-19 Oliver Lemke * arts-2-3-1258 * CMakeLists.txt: "Deprecated copy warning" from GCC9 is fixed now. * src/array.h, src/matpack*.h, src/complex.h, src/methods.h, src/mystring.h: Add default copy and move constructors. Replace empty destructor implementations with default version. * src/absorption.h: Replace unneeded constructor and operator implementation with default. * .travis.yml: Switch to GCC 9 and LLVM 8. Keep GCC 4.9 as low anchor. 2019-07-17 Oliver Lemke * arts-2-3-1257 * controlfiles/artscomponents/doit/yREFERENCE_DOITaccelerated.xml: Update reference file to account for slight numerical changes. 2019-07-16 Oliver Lemke * arts-2-3-1256 * CMakeLists.txt: Add compiler flag -Wno-deprecated-copy for now to get on top of GCC 9's warning frenzy. Should be fixed eventually though. * src/m_linemixing.cc (abs_xsec_per_speciesAddLineMixedBands): Add macro to suppress warnings of unused parameters when compiling without Fortran support. 2019-07-16 Oliver Lemke * arts-2-3-1255 * 3rdparty/invlib/src/invlib/convergence_criteria.h, src/linemixing.cc Comment out names of unused parameters to silence compiler warnings. * src/m_cloudradar.cc, src/m_optproperties.cc, src/rt4.cc: Don't implicitly convert floats to bool. Replaced by proper comparison for readability and to silence compiler warning. * src/m_optproperties.cc (pha_mat_sptFromMonoData): Initialize T_gp to satisfy clang analyzer. * src/covariance_matrix.cc (CovarianceMatrix::generate_blocks), 3rdparty/invlib/src/invlib/interfaces/arts_wrapper.h (ArtsCovarianceMatrixWrapper::ArtsCovarianceMatrixWrapper): Rename local variable to avoid shadowing a class function of same name. 2019-07-16 Oliver Lemke * arts-2-3-1254 * src/matpackII.cc (Sparse::insert_elements): Set tripletList elements with index operator instead of push_back. Because the tripletList was already pre-allocated with n elements, push_back led to twice the number of elements being added into the Sparse matrix. Since the first half of triplets were all (0, 0, 0), no further bugs should have been caused by this. 2019-07-16 Simon Pfreundschuh * arts-2-3-1253 * 3rdparts/disort1.2/ErrPack.f Replaced STOP statement with RETURN to avoid hard shutdown of ARTS on convergence error. * src/m_psd.cc: Allow D_m and N_0^* to be used as parameters. * src/m_retrieval.cc: Fixed error messages when dimensions of covariance matrix are wrong. src/rt4.cc: Fix required to avoid run_rt4 method from crashing when maximum number of stream is reached. 2019-07-15 Oliver Lemke * arts-2-3-1252 * controlfiles/artscomponents/wfuns/JHyb_*.xml.gz: Replace corrupted gz files with fresh versions provided by Richard. 2019-07-15 Oliver Lemke * arts-2-3-1251 * src/m_basic_types.cc, src/methods.cc: Don't define DiagonalMatrix as a template method. Since only explicit overloads for two types exist and no generic implementation, templates are not needed. 2019-07-15 Oliver Lemke * arts-2-3-1250 * Fix number of issues found by the clang analyzer. * src/m_cloudradar.cc: Comment out unimplemented iy_aux features. * 3rdparty/invlib/src/invlib/map.cpp: Initialize member iterations. * src/disort.cc: Reduce scope of pfct_za_grid_size. * src/libmicrohttpd/daemon.c: Remove shadowing variable. * src/m_linemixing.cc: Improve continue condition. Negative values should be excluded to avoid false positive from clang analyzer about possible use of a garbage value. The analyzer doesn't know that our signed Index can only contain positive values here. * src/legendre.cc: Remove dead assignment. * src/montecarlo.cc: Define evop0 closer to where it's used. Define I1 and Q1 in local scope only. * src/m_montecarlo.cc: Use continue instead of break for consistency. * src/linescaling.cc, src/telsem.cc: Define helper variables locally in scope. * src/check_input.cc: Add missing initialization of any_nlte_lines to avoid use of an uninitialized value. Remove unneeded else statement. Follow clang-tidy's advise. * src/linerecord.cc, src/parser.cc: Initialize Numerics before using double_imanip. 2019-06-27 Oliver Lemke * arts-2-3-1249 * svn propset svn:global-ignores 'heaptrack.*.gz' . 2019-06-26 Richard Larsson * arts-2-3-1248 * controlfiles/*: Updated the lineshapes tests to include a larger variation to showcase easier potential errors. There are many things wrt HTP that I don't follow properly, but the forward shape looks mostly normal now that all the lines are generated from the same input. The derivatives though... I have no idea why they look so strange for the difference between HTP and using the HTP algo with SDVP input. There is also a constant that I don't fully follow why I must use for dF on line 2148 of linefunctions.cc... I get one use, but two??? I don't understand this at all... * controlfiles/CMakeLists.txt: Added some more lineshapes tests but made them much smaller to not take time. * src/constants.h: Saw that, e.g., Fortran defines atan2d not atand2 as I did, so I changed it before it becomes a thing. Also added some comments so my parser can see the variables and functions easier. * src/jacobian.cc,h: Restructured some jacobian keys to work with HTP lineshape easier. * src/linefunctiondata.cc: Made operator<< for LineFunctionDataOutput. Also make use of restructure above to make the code shorter. * src/linefunctions.cc.h: Removed old set_htp. Adopted pCqSDHC to return derivatives. Made a wrapper calling it similar to old set_htp, and called it set_htp. Still have problems understanding this. I don't get why I need line 2148, and I am also unsure how to deal with line mixing for htp... * src/test_propagationmatrix.cc: Removed the previous test implementation. * src/transmissionmatrix.cc: Minor tweaks 2019-06-19 Richard Larsson * arts-2-3-1247 * controlfiles/*: Updated numerical values in complex heavy functions * src/complex.cc,h: Made constexpr Complex operators. The main point of this change was that I found myself having to spend time changing 1/c to 1.0/c. The former clearly indicates the latter, so there is something fishy with C++ std::complex... Anyways, the change had an unforeseen consequence that several tests started to fail. These tests are all those that have several "large" times "small" complex or numerics. So I believe the actual error is just in rounding and not in anything serious. Perhaps this change will actually allow clang and gcc to agree in the future? Mac Clang did not agree with Linux GCC in some previous versions of the updated tests. * src/constants.h: After May SI update, two of the constants have changed numerical values, and as I noted before, when I added constants.h, I have gone back to update these. * src/linefunctiondata.cc,h: Contains CGS2SI and inverse functions. * src/linefunctions.cc,h: Added implementation of HTP lineshape by original authors and adjusted them to fit with how ARTS deal with lineshapes (normalized and the same dispersion-signage). Also made set_htp2 as a temporary test-function to play with values. This requires CGS units as input but outputs in ARTS format * src/rational.cc,h: minor tweaks and a fix to the problem with negative denoms * src/test_complex.cc: Added static tests of the complex implementation * src/test_matpack.cc: Added some static tests * src/test_propagationmatrix.cc: Added runtime tests to play with the HTP implementation. Will have to extend HTP implementation to give the derivatives in the future. 2019-06-14 Richard Larsson * arts-2-3-1246 * src/jacobian.{cc,h}: Split is_line_mixing_line_strength_parameter into real and imaginary parts that are called by the original but also separately * src/linefunctions.{cc,h}: Fix the mirroring in pure lineshape (which no one is using as far as I know). Updated sign usage that confused me in set_voigt. Made apply_linemixing_scaling into apply_linemixing_scaling_and_mirroring since there is supposed to be a conjugate on the line mixing strength component of line mixing when adding the mirrored line. * src/linemixing.{cc,h}: Still experimenting with these things. Noticed that since ARTS uses (1-iY) as line mixing order, there is a need to add a minus sign in creation of Y. Might be that similar things are required for G and DF but since these are squared I am less sure. Important additions are the Molecule class since the computations for O2 Hamiltonian are too complicated to keep repeating outside or by manual data. * src/linerecord.{cc,h}: The biggest change is here and why the code is committed now. ARTS is using internally (1-iY) as first order line mixing factor. It seems LBLRTM is using (1+iY) because the internal linemixing calculations that are still being evaluated shows that this gives better agreement than the other way around. I would recommend anyone that has used the aer catalog to check the sanity of their results after updating to this version of ARTS. Also, I added quadra and di pole handles to LineRecord. * src/m_linemixing.cc: Still experimenting with things here. * src/m_oem.cc: Added MatrixFromCovarianceMatrix convenience function since the typhon CovarianceMatrix reading failed with a strange error and I want to store my final CovarianceMatrix. * src/propagationmatrix.h: Added noexcept at rvalue junction. Don't know exactly what this does but have been informed it is important for copy or move operation selections. * src/rational.{cc,h}: Made Rational constexpr-able because of some extra time while running longer simulations. I also made a slight design change so that it is considered a logical error to use an undefined Rational in any kind of arithmetic operation. Checks on validity of accessing Rational should happen at an earlier stage than inside its operations anyways. Also added a sqrt() function that returns a Numeric (which is not constexpr since we do not have a constexpr sqrt() in ARTS). * src/test_matpack.cc: Added tests of Rational that fails at compile-time if the class gets broken by changes to its interface. There are no runtime code in the updated test. * src/transmissionmatrix.h: Same as propagationmatrix.h changes. * src/wigner_functions.{cc,h}: Added initializations for the direct calls to wigner3j and wigner6j. Also added comment on O2 wigner-symbol. * src/zeemandata.cc: Updated order of operations because while a div-0 operation is valid, it produces an undefined Rational. Since follow-up operations on said undefined Rational are now considered logical errors, the old operations order threw a fit. 2019-05-28 Simon Pfreundschuh * arts-2-3-1245 * src/jacobian.cc(transform_x_back): Missed one term in atanh backtransform. 2019-05-28 Simon Pfreundschuh * arts-2-3-1244 * src/jacobian.[h, cc](transform_x_back): Added option to exclude functional transforms from backtransformation. * src/m_jacobian.cc(transform_jacobian): Fixed indexing of elements in x vector. 2019-05-16 Patrick Eriksson * arts-2-3-1253 * src/m_checked.cc (cloudbox_checkedCalc): Now using .empty() to check if wind WSVs are empty. (sensor_checkedCalc): There was an assert for empty sensor_los. Now catched properly. Added same check for sensor_pos. 2019-05-06 Richard Larsson * arts-2-3-1252 * src/absorption.{cc,h}: Added "getIsotopologueRatio" for a speciesTag * src/constants.h: Added a static field as well. Not sure what it is doing in practice, but the advice I read is that static is good for things that can be constexpr, but in cases that they are not evaluated on compile is good to leave static... * src/linefunctiondata.cc,h: Added method to remove species from broadening data. Mostly to save HD space in LM-modes * src/linefunctions.cc,h: Added lte_linestrength to make life easier * src/linescaling.cc,h: Added some functions to make linemixing derivatives easier. Not used yet... * src/m_linemixing.cc: Added and changed several test functions. Nothing easy to use yet, and definitely not tested, but (abs_xsec_per_speciesAddLineMixedLines) can produce numbers that 1) emulates the values from the HITRAN linemixing code for Y, and 2) that does not look bad in xsec-format. In fact, the HITRAN xsec code seems slightly worse in my view, but I have yet to verify it properly * src/linemixing.cc,h: Modified after many tests to produce reasonable results in xsec. Need to verify modifications step-by-step still... * src/m_linerecord.cc: Added methods to modify a LineRecord in various formats. * src/quantum.h: Added easier way to get quantum numbers back from QID. * src/wigner_functions.cc: Modified an initialization bit. These functions require a bit of work possibly... 2019-04-17 Manfred Brath * arts-2-3-1251 *src/doit.cc (cloud_ppath_update1D, cloud_ppath_update1D_noseq): Removed needless variables *src/doit.cc (doit_scat_fieldNormalize): Adjusted azimuth angle grid check, so that it can now handle case, where the incoming azimuth grid has a size of one. *src/doit.cc (doit_scat_fieldCalc, doit_scat_fieldCalcLimb): Adjusted azimuth angle grid check and adjusted the method, so that it can now handle for 1D atmospheres case where the incoming azimuth grid has a size of one. *src/m_optproperties.cc (pha_matCalc): Changed it so that now for 1D atmospheres the integration over the incoming azimuth direction is already done within pha_matCalc and not within doit_scat_fieldCalc or doit_scat_fieldCalcLimb. *src/m_optproperties.cc (DoitScatteringDataPrepare): Due to above changes in pha_matCalc for 1D atmospheres, the incoming azimuth grid is resized to one, as the integration over the incoming azimuth direction is already done within pha_matCalc. scat_aa_grid is changed from input to input and output. No further integration over incoming azimuth direction is needed in the preceeding calculation steps. *src/methods.cc (DoitScatteringDataPrepare): Changed scat_aa_grid form input to input and output. 2019-04-15 Richard Larsson * arts-2-3-1250 * src/absorption.h: Added a convenience interface for partition functions * src/linefunctiondata.cc,h: Made setting line mixing easier. Also activated a lot of runtime throwing that I had forgotten was commented out. Also changed so that all interpolation has to be exact, not to a relative number. Will revert typhon for thi shortly. * src/linemixing.cc,h: Made several functions easier to access by moving them to .h. Removed asserts and made proper checks instead. Also added least square solver for fitting second order coefficients. Also removed type-by-type interface. * src/linerecord.h: Added interface for changing line mixing AER style. Also made convenience function for line comparisons. * src/m_linemixing.cc: Renamed TestLineMixing to abs_lines_per_bandRelaxationMatrixLineMixingInAir and made it set the line records to GIN line mixing style. 2019-04-15 Oliver Lemke * arts-2-3-1249 * .travis.yml: Use correct gfortran version that matches the gcc version. 2019-04-12 Richard Larsson * arts-2-3-1248 * src/constants.h: Added h_bar for h/2pi and two_pi for 2pi and some functions * src/linemixing.cc,h: Fix some units and question some others. Now I think the ARTS C++ re-implementation of Relmat F90 is very close to working (visually similar y-values as LBLRTM has) * src/linerecord.h: Added some comparison functions and a way to get the dipole moment. * src/m_linemixing.cc: Added SetBandIdentifiersFromLines as a method. Fixed abs_lines_per_bandFromband_identifiers since it did not work. Updated the test-function TestLineMixing to be similar to LBLRTM. It seems to be, but I might be off by some rescaling factor. * src/methods.cc: Added said method. Is the description good enough? * src/quantum.cc,h: Changed the comparisons around because somehow a check failed. I think they are doing the same thing still, but it is clearer for me to read this version, and the results look good now. 2019-04-11 Richard Larsson * arts-2-3-1247 * controlfiles/artscomponents/nlte/TestPopulationDensityNLTE_lineshape.arts: Updated naming of input for selecting NLTE type * src/absorption.cc: Updated interface to temperature derivatives in Linefunctions * src/constants.h: Added several constants used elsewhere in the code * src/jacobian.cc,h: Updated do_vmr_jacobian to be easier to read out from * src/linefunctions.cc,h: Updated to use the Constant namespace. Also simplified interface to the line strength calculators. Also udpated Doppler derivative * src/linemixing.cc,h: Named the interface to the internalized relmat calculator. Doing some more tests on this atm but by workstation cannot handle the ram-usage of some operations so that code is on another machine. TBCS * src/linerecord.cc,h: Removed dual line shape specifications. Also removed Index interface to this so no longer necessary to have "END" as enum variable * src/m_linemixing.cc: As above. * src/m_linerecord.cc: As above * src/m_nlte.cc: Commented out unused agenda. Still kept around because the code should update again in future to allow selection of NLTE method. * src/m_radiation_field.cc: Remove stupid compiler warning * src/methods.cc: Removed some methods related to different line shape selections * src/zeeman.cc: Updated to use things as above 2019-04-08 Jana Mendrok * arts-2-3-1246 * src/methods.cc (scat_dataCheck): Cleaned up messy, redundant doc. 2019-04-04 Jana Mendrok * arts-2-3-1245 * doc/uguide/atmosphere.tex: Explanatory sentence on interpretation of wind directions in 1D case. Upgraded magnetic vector field paragraph to its own section. 2019-04-03 Patrick Eriksson * arts-2-3-1244 * src/workspace.cc: Added information on assumption of implied azimuth angle for 1D and 2D. 2019-04-01 Richard Larsson * arts-2-3-1243 * controlfiles/artscomponents/*: All the files were checked, the change was on the order of the second to the fourth digits at worst. Often much less than that. Still because the check was wanted better than sixth digit in most files, the update is required. * src/absorption.cc,src/linefunctions.cc,src/linemixing.cc: * src/m_linemixing.cc, src/test_propmat_partials.cc: Make use of an external Doppler constant. * src/constants.cc,h: Updated most values to be in constants.h as constexpr. I am trying to follow the planned May-update of SI units as best as I understand it. All constants in this new update can be found from measurements of two other constants. In the implementation, I choose these two other constants to be the fine structure constant and the Rydberg constant. This follows the Wikipedia article on the subject, which in turn follows the NIST recommended CODATA paper from 2016, and a working draft of the SI update (with the exact same numbers). Other constants, such as the electron mass, are then computed from these values. Making this update, ARTS no longer has its own definition of the mol. Instead of multiplying the SI constant by 1000, now this multiplication has to happen elsewhere. This is mostly changed to fix an internal inconsistency of R != k NA. To enforce self-consistency in several of these units, they are computed as part of constexpr (which should mean on compile time if any optimizations are on) instead of as pure values. WARNING: if you need the old ARTS redefinition of the mol, you need to create an ARTS_MOL constant in constants.cc and switch to using it instead of using the old modified AVOGADROS_NUMB Note that you can also use "constants.h" as a standalone include if you wish to use constexpr constants instead of extern statics. I did some limited tests in linefunctions.cc, and it sped several of the short tests up by about 0.05 sec (these tests take about 0.2 sec, so relatively high speed improvement). I did not extend the test to longer running tests, where the static property is able catch up [?!?!] (I started doing some minor extension probing to see how much work was required, which is why the Conversion namespace also exists in constants.h. I will not continue any extensive porting work, but I did test the namespace in some now reverted codepaths, so it should be mostly fine to use.) * src/m_basic_types.cc,src/methods.cc: Added PrintPhysicalConstants to print the constants to the accuracy they are stored in. Here are the differences running that function for old → new constants that change: Avogadro's constant: 6.022045000000000e+26 → 6.022140760000000e+23 Bohr's magneton: 9.274009680000000e-24 → 9.274010070678952e-24 Boltzmann's constant: 1.380662000000000e-23 → 1.380649000000000e-23 Electron charge: -1.602176565000000e-19 → -1.602176634000000e-19 Electron mass: 9.109382910000000e-31 → 9.109383709046823e-31 Ideal gas constant: 8.314462100000000e+00 → 8.314462618153240e+00 Planck's constant: 6.626180000000000e-34 → 6.626070150000000e-34 Vacuum permittivity: 8.854187817620000e-12 → 8.854187816292039e-12 Doppler constant: 4.301401469102398e-07 → 4.301415417776785e-07 So not very large changes, but a 5th digit error running through 100 layers can mean a fourth unit error in outcome. But only for weak signals. 2019-03-27 Oliver Lemke * arts-2-3-1242 * src/agenda_class.cc, src/arts_api.cc, src/interactive_workspace.cc, src/m_abs_lookup.cc, src/m_batch.cc, src/m_cloudbox.cc, src/m_general.cc, src/m_radiation_field.cc, src/main.cc: Replace std::runtime_error by std::exception in catch blocks in several strategic places such as top-level error handling and exception barriers at parallelized loop boundaries. This will prevent abnormal program termination in standalone mode as well as in the Python API mode not only for std::runtime_error, but also all other exceptions. * src/test_matpack_simple.cc: Add simpler matpack test for low-level testing that only depends on the matpack library. The other test_matpack depends on artscore which triggers a complete rebuild when changing any matpack header. This is annoyingly time-consuming when testing changes in matpack. * src/CMakeLists.txt: Link wigner to artscore instead of matpack. 2019-03-22 Richard Larsson * arts-2-3-1241 * src/absorption.cc,h: Added error checking for partition_function as a copy of the error checking that already existed for isotopologue_ratio bar that some values must be positive. * src/m_zeeman.cc: Changed the error checking. Also changed so that the code can now be run for any atmospheric dimensionality IF the magnetic field is set manually. * src/physics_funcs.cc: Changed error checking from asserts to try-catch. My implementation of OEM kept crashing when data input was bad. Oliver confirms the loss of speed is not significant (speed is reduced by a few percentages for some functions, but is faster for for others). NOTE: Instead of just chaninh the asserts, I added physical checks to most of the functions. To some, the checks are mathematical (i.e., 0 frequency and 0 radiance are both reasonable physically, but not during some operations if it means a division by 0). However, because of TestDOIT, TestDOITprecalcInit, TestDOITsensorInsideCloudbox, and TestRteCalcMC, the check that the radiance has to be non-negative if(i < 0) throw "Negative radiance"; has been removed from invrayjean. Each of these four tests operates on negative radiances. Because I am unsure if it is a requirement of the doit and mc formalisms to operate on negative frequencies, I removed the conversion comment. I do, however, strongly suspect that other ARTS files might experience other problems because of these checks. I believe it would be a better idea to let doit and mc have their own non-physical conversion functions rather than using physics_funcs.cc since they need negative radiances. I have not made said change. Instead, invrayjean can still output nonsense results. * src/zeeman.cc,h: Also changed error checking. I think after this the only errors that can occur for m_zeeman.cc that are significant are for bad line record data. Anything else should yield a proper runtime_error, or run through producing zeroes. 2019-03-15 Patrick Eriksson * arts-2-3-1240 * Work to allow that atmospheric and surafec retrieval grids can have length 1. The calculation of Jacobian worked (and the option has been in Qpack since long), but several fixes were needed to make this possible for ARTS-OEM. Basic tests for 3D done, no actual retrieval made yet. A length-1 grid means that the quantity to retrieve is assumed to be constant in this dimension. For example, if you want to retrieve a scaling factor for the complete vertical column, set the pressure retrieval grid to have length 1 and set unit to "rel". A result of 1.1 means that the retrieval indicates that the column is 10% higher than a priori. * src/m_oem.cc (regrid_atmsurf_by_gp_oem): Works as regrid_atmsurf_by_gp, but also handles length-1 retrieval grids. * src/m_oem.cc (regrid_atmfield_by_gp_oem): Works as regrid_atmfield_by_gp, but also handles length-1 retrieval grids including combinations. * src/interpolation.cc (interp): Added asserts in 1D, 2D and 3D version of green interpolation. These should be temporary, but useful as a help to check that length-1 p, lat and lon retrieval grids are handled correctly. * src/m_oem.cc (get_gp_atmsurf_to_rq): Did not work for 2D and 3D! * src/m_oem.cc (xaStandard): Removed sizing of variabls that are set by regrid_atmfield_by_gp. The variable is sized inside the function. 2019-03-14 Oliver Lemke * arts-2-3-1239 * src/methods.cc, src/m_rte.cc: (iyEmissionStandardParallel): Added a parallelized version of iyEmissionStandard. Parallelization over ppath points is achieved at the expense of memory. K and dK_dx at all ppath points are stored into arrays. Transmission calculation is moved into its own loop. With this setup both loops can be parallelized. (iyEmissionStandardOld): Removed. * src/m_radiation_field.cc, src/methods.cc: (doit_i_fieldClearskyPlaneParallel): Add new generic input use_parallel_iy. If set to 1, iyEmissionStandardParallel is called and parallelization of zenith angles is deactivated. (line_irradianceCalcForSingleSpeciesNonOverlappingLines): Add use_parallel_iy (0) parameter to doit_i_fieldClearskyPlaneParallel call. 2019-03-12 Richard Larsson * arts-2-3-1238 Breaks some controlfiles. If you were using the experimental line modification terms for the *2 xsec calculations. * src/linerecord.cc,h: Changed names for the modification terms so they are human-readable. Before, "LSM 1 MTM 1" meant mirrored by Lorentz function. Now it reads "LSM 1 MTM LP". Difficult to understand, but human-readable without lookup tables so long as you know the basics. * src/m_ppath.cc: Added a ppath_fieldCalc which takes sensor_los and sensor_pos to generate the field. Mostly because it helps me plot the ppath_field in python. 2019-03-06 Richard Larsson * arts-2-3-1237 * src/m_nlte.cc: Changed call to line_irradianceCalcForSingleSpeciesNonOverlappingLinesPseudo2D since it now takes a distance variable. This makes very little difference in output results or in speed of achieving said results. * src/m_radiation_field.cc: Added integrate_convolved for TransmissionMatrix. Activated the parallel region of code. The parallel part behaves very poorly, 8 threads speeding up the results only by about a factor 2.5. Also added some computations of line_transmission. * src/propmat_field.cc,h: Added a way to compute the field of local transmission given a propagation matrix field. Not physically correct for large distances, of course, but it is nice to have for the NLTE stuff for now. * src/transmissionmatrix.cc,h: To aid the above, I made an initializer for a transmission matrix that can take only a single propagation matrix. Also added the lazy operations for the interpolated fields to work. * src/propagationmatrix.h: Made the lazy implementation a template class instead to not have to rewrite for the above. 2019-03-06 Richard Larsson * arts-2-3-1236 * src/group.cc: Added ArrayOfPpath to variables. * src/m_ppath.cc: Moved ppath_fieldFromDownUpLimbGeoms here * src/m_radiation_field.cc: Moved ppath_fieldFromDownUpLimbGeoms away from here. Also added some checks and removed some code I had around before attempting to parallelize the main loop. I still don't know why the parallelization won't work... * src/methods.cc,workspace.cc: Added ppath_field and ppath_fieldFromDownUpLimbGeoms as a variable and method, respectively. I want this here mostly so I can plot the geometry externally without having to manually edit code to generate the geometry-output file. 2019-03-05 Richard Larsson * arts-2-3-1235 * src/field.h, special_interp.h: Added defaults for the interps using GridPos. * src/m_nlte.cc: Changed geometry from planar to 1.5D for the NLTE field. Will have to clean up so proper output/input happens. This breaks the dampened keyword. It will do nothing now. * src/m_radiation_field.cc: Added a few functions. integrate_convolved, computes the integration over f of the lineshape convolved by the radiance vector. integrate_zenith computes the zenith-wise integration of unsorted zenith angles. ppath_fieldFromDownUpLimbGeoms creates a zenith-angle coverage of the field by emulating the indicated three sensor types. grid_index_from_gp takes the index of the grid from the GridPos. sorted_index_of_ppath_field is an internal helper. line_irradianceCalcForSingleSpeciesNonOverlappingLinesPseudo2D is the main equation that computes the 1.5D line irradiance. * src/methods.cc: nlte_fieldForSingleSpeciesNonOverlappingLines modified input to take different agendas and the refellopsoid. line_irradianceCalcForSingleSpeciesNonOverlappingLinesPseudo2D is added. * src/propmat_field.cc,h: emission_from_propmat_field is added. It emulates iyEmissionStandard without any jacobian- or aux-stuff. * controlfiles/artscomponents/nlte/testRotationalConvergence.arts: Need to set both the surface altitude and ppath_lmax with new approach. * controlfiles/artscomponents/nlte/testdata/nlte_testdata.xml: Updated values since the new geometry should be better. Also agrees closer to other people's simulations this way. (checking a few field parameters). It is a factor 3 slower though... 2019-03-05 Oliver Lemke * arts-2-3-1234 * src/linefunctiondata.cc (splitLineMixingData): Set correct TemperatureType LM_AER, not T1, for LineMixingOrderType::Interp. Fixes line mixing calculations with AER catalog. (operator<<): Remove spurious counter++ to avoid first element of line mixing interp data being discarded on writing. 2019-03-05 Oliver Lemke * arts-2-3-1233 * src/linerecord.cc (LineRecord::ReadFromLBLRTMStream): Bug fix. LineFunctionData was only initialized for O2NonResonant and LineMixing lines. Thus, all other lines were calculated without any pressure broadening leading to wrong results. * src/linefunctiondata.h (StringSetLineMixingType): LineMixingOrderType::ConstG case was missing preventing ARTS catalogs containing this tag from being read. 2019-03-01 Oliver Lemke * arts-2-3-1232 * src/linerecord.cc (LineRecord::ReadFromArtscat5Stream, operator<<): s/MLM/LML/ 2019-03-01 Richard Larsson * arts-2-3-1231 It should now be possible to do bad linemixing calculations again. * src/linerecord.h: Adding a linemixing_limit to LineRecord. This does the calculations regardless but sets the linemixing values to 0 if outside the pressure range given. Defaults to -1, and any value below 0 is simply going to return the computed values. Also removed unused speedup-variables. * src/linefunctiondata.cc,h: Adding a linemixing boolean to the inpute of all functions computing those parameters * src/linefunctions.cc,h: Removed outdated comments. 2019-02-28 Richard Larsson * arts-2-3-1230 * src/field.h: Small fix because the output operator was only designed for StokesVector and PropagationMatrix 2019-02-28 Richard Larsson * arts-2-3-1229 Some partial code making some complicated 3D field-calculations easier * src/CMakeLists.txt: Adding field.h and propmat_field.cc,h. The former contains a generic 3D field implementation and the latter a way to compute the propagation matrix and source vectors from the emission-case. The latter is only intended to be used internally and need many checks around it to ensure sanity. * src/field.h: Contains Field3D. I am sure better implementations can be made, but this implements a way to call a field with GridPos arguments to get interpolated values. So long as "num * field[pos]" can be sent to the base "operator+=" and "operator=", it should work for the type. (So not for matpack-types, but it should work for Eigen types.) * src/propmat_field.cc,h: Implements a way to compute and fill a FieldOfPropagationMatrix and a couple of FieldOfStokesVector(s) for a very simple atmosphere. The combination with the above interpolations have been tested to produce identical results for TestNLTE.arts file. So long as the ppath_lmax-variable is negative. Otherwise the errors introduced are large (more than a few percentages). I suspect the latter is because we should probably interpolate on xsec rather than propmat, but for my intended use this does not matter as long distances are acceptable. * src/m_nlte.cc: Introduced proper names for variables of the NLTE calculations. * src/m_radiation_field.cc: Same. But also removed unused stuff. * src/methods.cc,workspace.cc: Paired to the above. * src/propagationmatrix.h: Introduced a simple delayed evaluator for adding scaled propagation matrices together. I hope it is lazy (or at least only makes a copy for a single allocator). It works with Field3D anyways. I also found a bug in StokesVector that would have been important if anyone was actually using the zenith and azimuth angle dimensions of this class... 2019-02-26 Oliver Lemke * arts-2-3-1228 * src/groups.cc, src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add WSV group ArrayOfTensor5. * src/agendas.cc: Add dobatch_calc_agenda. * src/m_basic_types.cc, src/methods.cc: Add Compare for ArrayOfTensor7. * src/m_batch.cc, src/methods.cc: Add DOBatchCalc, a batch method tailored to radiation field calculations. * src/workspace.cc: Add dobatch_calc_agenda, dobatch_doit_i_field, dobatch_radiance_field, dobatch_irradiance_field, dobatch_spectral_irradiance_field. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/dobatch/: Add test case for DOBatchCalc. 2019-02-25 Patrick Eriksson * arts-2-3-1227 * src/methods.cc: Added comment to all retrievalAdd-methods to see the corresponding jacoboianAdd for number and order of x elements. * src/workspace.cc: Extended description of *x* and *y*, with focus on order of data inside these vectors. Added comment to jacobian referring to link to x and y. General note: If you add a jacobianAdd... method, make sure you describe the order of elements added to x. The description of *x* refers to these Add-methods about this. 2019-02-21 Oliver Lemke * arts-2-3-1226 * src/partition_function_data.cc, src/species_data.cc: Add remaining cross sections species (if data is available) for RFMIP calculations. 2019-02-21 Richard Larsson * arts-2-3-1225 * controlfiles/artscomponents/nlte/TestNLTE.arts: Renamed nlte_quantum_identifiers→nlte_level_identifiers * controlfiles/artscomponents/nlte/TestPopulationDensityNLTE_lineshape.arts: dito * controlfiles/artscomponents/nlte/testRotationalConvergence.arts: dito. Also using new collision_coefficientsFromSplitFiles. * controlfiles/artscomponents/nlte/testdata/nlte_testdata.xml: Fixed because a previous bug did not use the correct quantum number definitions * src/m_nlte.cc: Added isotopologue_ratios to nlte_fieldForSingleSpeciesNonOverlappingLines for use in collisions. Made collision_coefficientsFromSplitFiles as a way to read collision data. Also renamed variables to fit with intent better * src/nlte.cc,h: Removed all the asserts and debug options because they made the code difficult to read. Found bug in collision coefficients that made the same level collision coefficient be used for all lines. Added check_collision_line_identifiers. * src/workspace.cc: Renames: nlte_quantum_identifiers→nlte_level_identifiers nlte_collision_identifiers→collision_line_identifiers nlte_collision_coefficients→collision_coefficients Retyped collision_coefficients: ArrayOfGriddedField1→ArrayOfArrayOfGriddedField1 to support multiple colliders 2019-02-19 Richard Larsson * arts-2-3-1224 * controlfiles/artscomponents/nlte/testRotationalConvergence.arts: Scale nlte_field by orth-number 0.75. The goal is to update collisional effects to include more species, so the cheat we used to create the same nlte_field as other models have been dismissed. Now instead, to reproduce other models value, rescale our nlte_field to unity per level. * controlfiles/artscomponents/nlte/testdata/H2O.xml: Set VMR to 100% * controlfiles/artscomponents/nlte/testdata/nlte_testdata.xml: Updated numbers here are close enough to 0.75 times old numbers (on 1e-14 order) * src/m_nlte.cc: Moved collisional function (nlte_collision_factorsCalcFromCoeffs) to nlte.cc. Changed so that the ratio is constant at all levels to the original values. * src/nlte.{cc,h}: As above but also removed unused functions. * controlfiles/artscomponents/helpers/TestRegridding.arts: Saw that this failed because of the delayed name-change in xml-data... fixed 2019-02-13 David Duncan * arts-2-3-1223 * src/m_oem.cc(get_gp_atmgrids_to_rq): Fixed indexing of retrieval grids for surface quantities. * src/m_retrieval.cc(retrievalAddSurfaceQuantity): Fixed dimension argument in call to check_and_add_block. 2019-02-13 Oliver Lemke * arts-2-3-1222 * README: Updated how compiler selection for cmake is done. Add info on how to select a specific Fortran compiler. Add info on how to circumvent problems with valgrind limitations. Updated info on OpenMP in Clang. Based on feedback by Richard. 2019-02-09 Richard Larsson * arts-2-3-1221 * src/transmissionmatrix.cc: Switched from 1e-7 to 1e-4 afterthe tests in the other file show this beig a minimum of the four limits of interest. Should be on order of ~1e-8 now, the 1e-7 limit resulted in 1% relative error... * src/test_propagationmatrix.cc: Test of limits. 2019-02-07 Richard Larsson * arts-2-3-1220 * src/transmissionmatrix.cc: Now assumes a value is zero if it is below 1e-7 for the purposes of sin(x)/x, cos(x)/x, cosh(x)/x, and sinh(x)/x Open question: I need something better than this for said type of functions? 2019-02-07 Richard Larsson * arts-2-3-1219 * src/quantum.cc,h: Encountered bug in quantum comparitor (the upper state was never checked during transition-type ID). Decided to redesign comparitor because the overload of < and > were too difficult. Also introduced (InLower) and (InUpper) to reduce copy-creation of QuantumIdentifiers when levels needed to be identified in a transition. * src/zeeman.cc: * src/m_zeeman.cc: * src/m_nlte.cc: * src/m_atmopshere.cc: Removed use of "<" and ">" for quantum IDs. * src/linefunctions.cc: Removed use of "<" and ">" for quantum IDs. Also, named data blocks. * controlfiles/artscomponents/nlte/testdata/nlte_testdata.xml: Updated because it is the only test case affected by the quantum.cc,h bug. Changes are relatively large, and the reason is that ARTS previosly computed the wrong line-collisional quenching. * controlfiles/artscomponents/nlte/testRotationalConvergence.arts: Added an out-commented WriteXML-statement. 2019-02-05 Richard Larsson * arts-2-3-1218 * src/zeeman.cc: Moving some code to make it easier to read. * src/zeemandata.cc: Made the errors clearer. * src/transmissionmatrix.cc: Fix to logic error in dtransmat4. Before, small derivatives caused large errors. Especially, for a very special derivative, something similar to a ZeroDiv- operation could occur. For all small values of the derivatives, additionally, the previous logic performed many computations of the type g(x)~=N, f(y)~=N, C=f(y)-g(x), which of course produced a noisy jacobian as the numerical accuracy is poor for the above operation. The fixed logic makes the Jacobian appear less noisy 2019-02-05 Oliver Lemke * arts-2-3-1217 * controlfiles/artscomponents/lineshapes/TestHTP.arts, controlfiles/artscomponents/lineshapes/TestSDVP.arts, controlfiles/artscomponents/wfuns/TestSpectroscopy.arts: Increased thresholds for testjac and dpropmat_clearsky_dx comparisons with reference values from 1e-4 to 2e-4. Accounts for numerical differences between different compilers (I'm looking at you, Clang). 2019-02-04 Simon Pfreundschuh * arts-2-3-1216 * src/m_fos.cc: Added missing check for jacobian_do for computation of temperature Jacobian. 2019-02-04 Simon Pfreundschuh * arts-2-3-1215 * 3rdparty/invlib/src/invlib/convergence_criteria.h: Removed offending call to unique_ptr constructor. 2019-02-04 Simon Pfreundschuh * arts-2-3-1214 * 3rdparty/invlib/src/invlib/map.cc: Forgot to change syntax here as well. 2019-02-04 Simon Pfreundschuh * arts-2-3-1213 * 3rdparty/invlib/src/invlib/map.h: typename syntax for template template not available in gcc4. * 3rdparty/invlib/src/invlib/map.cc: Removed print statement. * 3rdparty/invlib/src/invlib/optimization/levenberg_marquardt.cc: Fixed compiler warnings. * 3rdparty/invlib/src/invlib/convergence_criteria.h: Fixed compiler warnings. * 3rdparty/invlib/src/invlib/m_oem.cc: Fixed compiler warnings. 2019-02-04 Simon Pfreundschuh * arts-2-3-1212 * src/test_covariance_matrix.cc: Fixed call to Sparse::insert_elements. 2019-02-04 Simon Pfreundschuh * arts-2-3-1211 * src/covariance_matrix.[h, cc]: Take into account inverse block when computing number of rows. Added function that returns diagonal of precision Matrix. * src/matpackII.[h, cc]: Added function to create sparse diagonal matrix from vector. * src/m_oem.cc: Use diagonal of precision matrix as damping matrix in LM algorithm. * src/oem.h: Set convergence criterion to be used by OEM. * 3rdparty/invlib/src/invlib/convergence_criterion.h: Added header file containing convergence criteria. * 3rdparty/invlib/src/invlib/map.[cpp, h]: Handle convergence generic convergence criteria. 2019-02-01 Oliver Lemke * arts-2-3-1210 * src/m_abs.cc (abs_linesReadFromHitran): Backport patch by Jana for HITRAN 2016 file support from arts 2.2. 2019-01-31 Richard Larsson * arts-2-3-1209 * src/linerecord.h: Changed interface so already internal variables don't have to be passed. Also added a zero Zeeman effect init * src/m_zeeman.cc: Added zeeman_linerecord_precalcCreateWithZeroSplitting as a way to initialize Zeeman effects without having to care about quantum numbers other than J. Also added zeeman_linerecord_precalcPrintMissing as a way to print what is missed by zeeman_linerecord_precalcModifyFromData. * src/methods.cc: See above * src/workspace.cc: Clarified some variable sizes * src/zeeman.cc,h: Did some restructuring while debugging. Turns out, constant angles were not converted to radians as expected so the results were strange. Not that you should be using constant values, but nevertheless... * src/zeemandata.cc,h: See above. Also made a struct a class to easier access the interesting elements (to reduce code clutter in zeeman.cc) 2019-01-31 Oliver Lemke * arts-2-3-1208 * src/linefunctions.cc (Linefunctions::apply_cutoff): Bug fix. MapToEigen was called on a temporary Vector which led to f_grid_cutoff referencing invalid frequency values. f_grid_cutoff was almost always zero or close to zero on Linux. Due to differences in memory management, the values of the temporary happened to be overwritten on Linux immediately but not on OSX. Thus explaining the difference of 10% in the test case for the LTE/NLTE new method between the two systems. * controlfiles/artscomponents/nlte/TestNLTE_LTE_new_method.xml, controlfiles/artscomponents/nlte/TestNLTE_NLTE_new_method.xml: Updated with "correct" values. 2019-01-30 Oliver Lemke * arts-2-3-1207 * controlfiles/artscomponents/nlte/TestNLTE.arts: Add error messages to CompareRelative to give an indication which test has failed. 2019-01-24 Patrick Eriksson * arts-2-3-1206 * src/m_ppath.cc (sensor_losGeometricFromSensorPosToOtherPositions): New WSM. * src/geodetic.cc (pos2refell_r): Fixed bad spelling in header. 2019-01-24 Richard Larsson * arts-2-3-1205 WARNING: Breaks controlfiles. FIX: There is no fix. You have to switch to uvw retrieval instead of angular retrieval. * *: Removes eta and theta from jacobian calculations for the magnetic field. 2019-01-23 Richard Larsson * arts-2-3-1204 WARNING: Breaks controlfiles using *AddConstantVMR FIX: Switch to normal *AddSpecies and set g1, g2, g3 to 1-long vectors to reproduce previous behavior * src/m_basic_types.cc: Added *Set-methods for ArrayOf- and (not) QuantumIdentifer. * src/m_jacobian,retrieval.cc: Removed ConstantVMR as Patrick has point out it is not necessary since the normal function handles this case so long as g1-g2-g3 is 1-long. While this clutters controlfiles, the change keeps ARTS internal sane. * src/methods.cc: Added comments to complement Patrick's update for methods I have defined for Jacobian calculations. * src/quantum.h: Added ---implicit--- conversion from String to QuantumIdentifier. I don't think this will cause any problems since QuantumIdentifier is basically more advanced than String. * src/zeeman.cc: Changed so the magnitude of the magnetic field is computed by std::hypot (to guarantee that w/H is 1 for H=[0,0,w]). Also found the expressions of the other internal functions too complicated and re-ran my sympy-scripts to reduce their apparent complexity. * src/zeemandata.cc,h: Changed to return const references as input is really const. 2019-01-23 Patrick Eriksson * arts-2-3-1203 * src/methods.cc: Improved documentation of jacobianAdd methods. Added text describing how many x-elements that are added, and the order between the new elements. 2019-01-22 Patrick Eriksson * arts-2-3-1202 * src/methods.cc: I had misspelled the GOUT in transmittanceFromIy_aux. The corrected name is *transmittance*. 2019-01-21 Richard Larsson * arts-2-3-1201 WARNING: Breaks runs that does not initialize the magnetic field tensors while using the x-functions. FIX: Use Touch on mag_u_field, mag_v_field, and mag_w_field to make presently working controlfiles (and typhon scripts) work identical to how they were before this update * src/m_oem.cc,methods.cc: Adding magnetic field to the x-functions. The normal fields are copies from the wind functions, but I also added "strength", since I think it is a better retrieval target than the fields. 2019-01-21 Richard Larsson * arts-2-3-1200 Ps. It seemsn the nlte-test does indeed speed-up as it should, but that my IDE is buggy presently. Ignore the comment I made about this for 2-3-1197. * src/linerecord.h: Added helper to get at Zeeman polarization * src/zeeman.cc,h: Changed interface to zeemandata to reduce calls to polarization computing functions * src/zeemandata.cc,h: Changed so the polarization state is computed only once instead of for every line. Shaves about 10% off of normal computations. Also removed some wrongly interpreted reach-end-of-file warnings where gcc got confused by throwing at the end of the files (in what I hope other compilers will not recognize as unreachable code and warn for other reasons) 2019-01-20 Patrick Eriksson * arts-2-3-1199 * src/m_surface.cc (transmittanceFromIy_aux): New WSM. * src/m_transmitter.cc (iyTransmissionStandard,iyTransmissionStandardOld): * src/m_rte.cc (iyEmissionStandard,iyEmissionStandardOld): * src/m_cloudradar.cc (iyActiveSingleScat,iyActiveSingleScat2): Changed setting of iy_aux for variables following the pattern of optical depth. Before all columns were filled with identical values, but this gives wrong results when mapped to y_aux if stokes_dim > 1. Now just the first column is set, and the others are filled with zeros. This should give correct results in y_aux. 2019-01-16 Richard Larsson * arts-2-3-1198 * src/absorption.cc: Eigen debug flags under debug-build mode apparently throws an error here instead of referencing nothing, as it does on release-mode. This update should fix Hudson 2019-01-16 Richard Larsson * arts-2-3-1197 * src/absorption.cc: Made xsec_species2 parallel. Still buggy. Reduces time of execution of TestNLTE.arts (the test with the most lines using xsec_species2) from 6 sec single thread down to 2 sec for -n6, but increases time instead for -n8 up to 9 sec. I have no idea what is going on here, but the code is much faster when it actually works (and I have not managed to induce an error). The parallelization is achieved by creating a summing-variable that is reset every level (this might be subotimal, but it works) 2019-01-16 Richard Larsson * arts-2-3-1196 * controlfiles/artscomponents/cia/tests/dpropmat.xml: * controlfiles/artscomponents/lineshapes/testdata/test-doppler/dpropmat.xml: In this update, some 1e-297 values are 0, and other values close to 1e-297 are changed, so the test failed, requiring a change. Also, the cia deriv test case seems particularly sensitive to changes for some reasons... * src/absorption.cc,h,src/m_abs.cc: Changed interface to xse_species2 by removing verbosity, which was not used anyways. Also reacting to changes in Linefunction-namespace * src/m_linemixing.cc,src/m_zeeman.cc,src/zeeman.cc,h: Reacting to changes in Linefunction-namespace * src/linefunctions.cc,h: Changed so there is a data-variable input to some of the functions to have as a compute-variable. Changed also so many functions are operating on Eigen-variables directly to make the functions easier to read. Changed also so that the N and dN variables have to be set to use the function so that less strange tests have to be performed. Changed also so dF and dN have frequency grids on the row because that's supposed to be better for Eigen (it removes the need for strange .transform()) >>>>>>> .r11225 2019-01-10 Richard Larsson * arts-2-3-1195 BREAKS CONTROLFILES USING EXPERIMENTAL VARIABLE REASONS: xsec_speedup_switch is removed because it did not work HOWTO FIX: Remove setting xsec_speedup_switch in your controlfile * *.arts: Removed xsec_speedup_switch * src/methods.cc,src/workspace.cc: Removed xsec_speedup_switch * src/absorption.cc,h: Changed interface to xsec_species2. Removed "speedup"-code that was not working. Changed so Linefunction-namespace takes Eigen-variables instead of ARTS-variables * src/linefunctions.cc,h: Changed so the namespace takes Eigen-variables instead of ARTS where it was convenient. Also discovered bug where N was not reset, causing TestNLTE.arts to produce bad output. This is fixed but since there are still differences between old and new code for vibrational NLTE levels, I still don't know why. The updated code is not optimized for the change, so only small speed-gains are to be had now. Note that some errors might remain, especially as relates to the fact that ".transpose()" has to be used at times for F to fit into dF... * controlfiles/artscomponents/nlte/TestNLTE_*LTE_new_method.xml: Updated as I discovered the bug above... * src/m_abs.cc: Updated to fit for xsec_speedup_switch and xsec_species2. * src/m_linemixing.cc: Updated to fit with new Linefunction-namespace signatures * src/m_radiation_field.cc: Updated to fit with new Linefunction-namespace signatures * src/propagationmatrix.cc,h: Removed adding polarization function as it seemed better to just use Eigen's outer-products * src/m_ppath.cc: Added helper function to move sensor to a different altitude while retaining the original line-of-sight. Meant for ground-based sensors, and the method is incredibly crude (LOS-strictness is required for Zeeman effect) * src/zeeman*.cc,h: Updated to use new Linefunction-namespace signatures. Also updated to produce polarization vectors that can be used via outer products to generate the PropagationMatrix and StokesVector data block. 2018-12-21 Simon Pfreundschuh * arts-2-3-1194 * src/oem.h: Avoid overflow error in computation of string-length. 2018-12-21 Richard Larsson * arts-2-3-1193 * src/m_cloudradar.cc: Now outputs diy_dpath, but wheter trying to use this will cause a break or failure, I have not tested. I also applied some minor aesthetics because gcc complained. * src/transmission.cc,h: Changed around how transmission calculations are done. Also had to add a reversed forward calculation to fit with the naming. There are still a few gotchas about. Mainly, I think the Reflect matrix can be reduced to a single loop. 2018-12-20 Patrick Eriksson * arts-2-3-1192 * src/m_ppath.cc (AddZaAa, DiffZaAa): New. * src/rte.cc (iyb_calc_body): mad_daa replaced with add_za_aa, which fixes a second bug for 3D calculations using an azimuth > 0 in mblock_dlos_grid. * src/ppath.cc (rotationmat3D): I had assumed that vrot always ends up to have norm = 1, but that's not true. This resulted in a bug for 3D calculations using an azimuth > 0 in mblock_dlos_grid. (map_daa): Replaced by add_za_aa. (add_za_aa, diff_za_aa): New functions. 2018-12-20 Richard Larsson * arts-2-3-1191 * src/m_cloudradar.cc: Fixed an error in directions in the second implementation of single scattering. Likely, this means there exists an error still in either the forward or backwards accumulated transmissions * src/transmissionmatrix.cc: Changed order so signal starts at 0 and is reflected at all points following it. Before, the code assumed opposite order, which did not work the same as the original code. Now the two versions does to same for forward calculations. Likely, there still exists an error in the derivatives because this update does not test them correctly... 2018-12-19 Patrick Eriksson * arts-2-3-1190 * src/m_surface.cc (SurfaceTessem): Disturbance when calculating derivative with respect to salinity was way too high. (SurfaceFastem): New. 2018-12-19 Richard Larsson * arts-2-3-1189 * src/test_propagationmatrix.cc: Forgot to update the below... 2018-12-19 Richard Larsson * arts-2-3-1188 * src/linefunctiondata.cc,h: Update moving a class variable out of the class itself and giving it a real typedef... * src/linefunctions.cc,h: Update changing a few names to make the set_lineshape functions easier to use. * src/m_linemixing.cc: Update as per above 2018-12-18 Richard Larsson * arts-2-3-1187 * src/m_cloudradar.cc: Un-commenting iyActiveSingleScat2- function for testing purposes. Fixed a bug were "+ np" was instead of "+ ip". Also fixed a bug where the zero-value was ignored. I am still not sure I understand the zero-value, especially as I think it by default has to be input to a radar function and not computed somehow internally. The code now clears the first two tests in TestIyActive.arts but not the last test. I have no idea why... * src/methods.cc: iyActiveSingleScat2 added as test-function 2018-12-17 Patrick Eriksson * arts-2-3-1186 * controlfiles/CMakeLists.txt: Added test below as fast. * controlfiles/artscomponents/radar/TestIyActive.arts: New. * src/m_basic_types.cc (NumericFromVector): New WSM. You can now e.g. do: NumericFromVector( a_numeric, a_vector, "max" ) 2018-12-17 Richard Larsson * arts-2-3-1185 * controlfiles/*: Fixing names. Also remove old catalog parameter test that I did not remember adding. The new one is more complete. * src/m_jacobian.cc: jacobianAddLineFunctionDataParameter(s) changed to jacobianAddShapeCatalogParameter(s), and jacobianAddCatalogParameter(s) changed to jacobianAddBasicCatalogParameter(s). * src/m_retrieval.cc: As above * src/methods.cc: As above, but also clarifying documentation. 2018-12-17 Richard Larsson * arts-2-3-1184 * controlfiles/*: Added test for spectroscopy derivatives using HTP-lineshape. Since the tests under controlfiles/artscomponents/ lineshapes work, this should confirm that the spectroscopy parameters work. NOTE: It also confirms my statements about the current HTP implementation requiring some updates for W(Z1)-W(Z2) ~= 0. There is a failure to compute these values, resulting in NaN-results when the center of the line is included in the calculations. I therefore remove these values for now before I have time to return to the issue for some real application. Test file: controlfiles/artscomponents/wfuns/TestSpectroscopy.arts Test input: arts-xml-data; controlfiles/testdata/tropical; controlfiles/artscomponents/wfuns/testdata/ Test results: controlfiles/artscomponents/wfuns/testdata/comparedata/* Test plots: controlfiles/artscomponents/wfuns/testdata/plots.py * src/m_atmosphere.cc,methods.cc: Added z_surfaceConstantAltitude. * src/m_checked.cc: Modified atmfields_checkedCalc to only check included species (I hope, the interface for the AuxData is very unclear for finding species and isotopologue names). 2018-12-15 Richard Larsson * arts-2-3-1183 * src/absorption.cc,linerecord.h,m_linemixing.cc: * test_propagationmatrix.cc: updated LineFunctionData::Output and interface to it. * src/linefunctiondata.cc.h: Changed Output from tuple to a simple struct. Also fixed error in how eta-derivative was computed for HTP. Also added some break;s because my compiler was complaining about non-existing fallthroughs. * src/jacobian.cc,h: Added some helpers for keeping track of spectroscopic derivatives. * src/linefunctions.cc,h: Rewrote the HTP implemenation to make it readable. Removed some "features" in the process, i.e., limits, because I am unsure how to trigger these features in a reliable way to test the implementation. The code should produce garbage at extreme distances from the line center now. The commit also fixes so that all spectroscopic parameters are supported by the Jacobian calculations, and so that internal VMR computations are supported. Note that these DO see strange problems even closer to the line center as they rely on differences of similar numbers... I think I need an algorithm to compute W(Z1)-W(Z2) more reliable when Z1 and Z2 are similar in size... * controlfiles/*: Added SDVP and full HTP tests. Changed from using old implementation of ARTSCAT5 to explicit implementation of the tags in the example lines in the lineshapes-subfolder (note, that these are not real values but a test of the functionality.) I updated the tests and the plotting routine as well, so that there were quite a few files that had to be touched. The test results have not changed much, but there were tests that were not performed before that looked like they were being performed, making for a few extra files of zeroes. I have tried to remove these now and decided to update the plotting-file because it helps understand the test results. 2018-12-15 Patrick Eriksson * arts-2-3-1182 * controlfiles/artscomponents/antenna/TestAntenna2D.arts: Decided to add testing of *y_geo*, which was a good decision. That revealed several bugs. * src/methods.cc: Added description of how *y_geo* is set inside yCalc. * src/m_rte.cc (yCalc_mblock_loop_body): Determination of y_geo changed. Now this is done based on max value in each row of senesor response. Old scheme did simply not work. * src/sensor.cc (antenna2d_basic): Two bugs found and fixed. 2018-12-13 Patrick Eriksson * arts-2-3-1181 * controlfiles/CMakeLists.txt: Forgot that TestAntenna2D.arts makes use of FASTEM. 2018-12-13 Patrick Eriksson * arts-2-3-1180 * controlfiles/CMakeLists.txt: Added TestAntenna2D.arts as fast. * controlfiles/artscomponents/antenna/TestAntenna2D.arts: New. * src/m_sensor.cc (mblock_dlos_gridUniformCircular): Finished. * src/m_sensor.cc (mblock_dlos_gridUniformRectangular): New WSM. 2018-12-13 Patrick Eriksson * arts-2-3-1179 * src/m_sensor.cc (mblock_dlos_gridUniformCircular): Under development. 2018-12-13 Patrick Eriksson * arts-2-3-1178 * src/methods.cc: Updated text for sensor_responseAntenna. * src/m_sensor.cc (sensor_responseAntenna): Small changes of input checks. * src/sensor.cc (antenna2d_basic): Function now complete, but not yet fully tested. 2018-12-12 Patrick Eriksson * arts-2-3-1177 * src/m_sensor.cc (sensor_responseAntenna): Some adoptions towards finally handling 2D antenna patterns. * src/sensor.cc (antenna1d_matrix): Some rearrangement to avoid some reinterpolation of antenna pattern. (antenna2d_basic): Started on a simple handling of 2D antenna patterns. Not ready! 2018-12-10 Simon Pfreundschuh * arts-2-3-1176 * 3rdparts/invlib/src/invlib/optimization/levenberg_marquardt.cpp - Removed reference to undefined variables. 2018-12-10 Simon Pfreundschuh * arts-2-3-1176 * src/m_oem.cc(OEM): - Enabled calculation of gain matrix for retrievals that reach iteration or LM-gamma limit. * 3rdparts/invlib/src/invlib/optimization/levenberg_marquardt.cpp - Slightly modified iteration behavior, requiring a higher, relative cost reduction. 2018-12-07 Oliver Lemke * arts-2-3-1175 * src/complex.h, src/propagationmatrix.h, src/transmissionmatrix.h: Remove constexpr from member functions for ConstComplexVectorView, ConstComplexMatrixView, PropagationMatrix, TransmissionMatrix, RadiationVector. None of these functions can ever be fully evaluated at compile time because their input values depend on runtime values such as stokes_dim, number of pressure levels, number of frequencies. While newer compilers seem to just ignore the constexpr keyword in those cases, gcc 4 fails if constexpr is used inside these non-literal classes. 2018-12-06 Richard Larsson * arts-2-3-1174 * src/complex.cc: Removed some of the constexpr stuff that uses assert() and &. Seems I did not learn constexpr correctly, since my version of gcc compiled what Hudson's gcc compiler does not... I tested with clang and it also complains, so this must be a my-version-gcc error? Now clang here compiles, so it should work? 2018-12-06 Richard Larsson * arts-2-3-1173 * src/complex.cc,h, src/linefunctiondata.cc: * src/propagationmatrix.h: Changed some const functions to constexpr functions trying to learn how this keyword works * src/m_cloudradar.cc: made ghost version, iyActiveSingleScat2, that is trying to change iyActiveSingleScat to use my Eigen code path for RT. Not tested, since there is no test for even iyActiveSingleScat as far as I can see... * src/m_fos.cc, src/m_transmitter.cc, src/m_rte.cc: Separated cumulative transmission calculations from partial transmission calculations. Because one of the experimental single scatter solver requires the reflected cumulative transmission, so there would be a lot of duplicate code without this separation. * src/transmissionmatrix.h,cc: Some code to control iyActiveSingleScat2. 2018-12-04 Simon Pfreundschuh * arts-2-3-1172 * src/make_auto_md.cc(main): Appended nullptr to getaway array, which can be used by the API for external callbacks when activated. * src/interactive_workspace.[h, cc]: Added container for callbacks as well as array to store them inside the interactive workspace. * src/arts_api.[h, cc]: Added method to insert callbacks into angendas. 2018-12-03 Richard Larsson * arts-2-3-1171 * controlfiles/artscomponents/cia/*: Updated output that depended on the Jupiter data. * src/linefunctions.cc: Minimal changes to use std:: more places and an update to the temperature doppler deriv. * src/m_oem.cc: Placeholder code for magnetic field retrieval inclusion. Just copy-pasted from wind since they behave exactly the same in how they are passed by the RTE code. * src/m_retrieval.cc: the same * src/transmissionmatrix.cc,h: An attempt to adapt the code for active transmitters. This is not straightforward for me since I am not sure what parts of the derivatives you wish to ignore. Presently has two implementations, Commutative and Full. Only for single back-scatter. Should probably "typedef MuellerMatrix TransmissionMatrix" to make the names of Z and dZ better. The scatter solver is not at all available to use and is not even tested well. I leave this code here since Patrick wanted something to change iyActiveSingleScat. I cannot follow that code so I am not sure how to finish the implementation... 2018-11-29 Patrick Eriksson * arts-2-3-1170 * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Comparison to reference data was unnecessarily strict. Also switched to use relative comparison. iyHybrid2 now passes this test. 2018-11-29 Richard Larsson * arts-2-3-1169 * controlfiles/artscomponents/wfuns/TestTjacStokes4_transmission.arts: Switch to Standard from NonStandard * src/m_fos.cc: Made a iyHybrid2 solver as old NonStandard. This clears one test but fails at another. * src/m_rte.cc: Made NonStandard→Standard and Standard→StandardOld * src/m_transmitter.cc: Made NonStandard→Standard and Standard→StandardOld * src/methods.cc: Removed NonStandard's and added iyHybrid2 * src/rte.cc: Removed one of the t_nlte-things remaining. Need to go over everything and remove these names sometime * src/transmissionmatrix.cc,h: Removed unused interfaces that was used when testing this out. 2018-11-29 Patrick Eriksson * arts-2-3-1168 * controlfiles/artscomponents/wfuns/TestTjacStokes4_transmission.arts: New test. So far uses iyTransmissionNonStandard. Fails for iyTransmissionStandard, likely due ignored HSE. * controlfiles/CMakeLists.txt: Added TestTjacStokes4_transmission.arts as slow. * controlfiles/artscomponents/transmission/TestTransmission.arts: Now done with stokes_dim=4. * controlfiles/artscomponents/transmission/TestTransmissionWithScat.arts: The test from TestTransmission.arts was repeated. That part removed. Also switched to stokes_dim=4. 2018-11-28 Richard Larsson * arts-2-3-1167 * src/transmissionmatrix.cc: Giving the same strange case treatment for stokes_dim 4 as for stokes_dim 3. Should make this code better. Still possible that some special cases exists where the code does not work... 2018-11-27 Richard Larsson * arts-2-3-1166 * src/transmissionmatrix.cc,h: Changes to mainly stokes_dim 2 and 3 and the beginning of updating stokes_dim 4 after a weird bug. I will try to have this fixed shortly, but I don't think it is very important for real calculations since the bug exists in the old code as well... (The problem is that the input can and will give imaginary values for which the expression is valid but not all of these input can produce good output. So it is mostly important to have this fixed if at anytime the refractive index will be computed as part of the line shape. Presently, we just throw away the refractive index and keeps only the attenuation and the phase velocity.) * src/linefunctions.cc: Bug where mirrored lines where removed not added discovered while trying to remove the extra allocations for cutoff. Not successful to remove the latter the code is otherwise in the same shape. 2018-11-27 Oliver Lemke * arts-2-3-1165 * src/species_data.cc (define_basic_species_data): Set HITRAN tag for H2O-262 which has been recently added to HITRANonline. Also updated abundance with value from HITRAN. 2018-11-22 Simon Pfreundschuh * arts-2-3-1164 * src/m_psd.cc(psdD14): - Ensure that psd data is 0 when iwc is zero. * src/methods.cc(psdD14): - Fixed typos in definition of psdD14 WSV. 2018-11-21 Richard Larsson * arts-2-3-1163 Makes NonStandard comply with Patrick's new test by stomping out some bugs. * controlfiles/artscomponents/wfuns/TestTjacStokes1to4.arts: Corrected and extraction * src/transmissionmatrix.cc,h: Removed some unwanted functions. Corrected a matrix that was [[a, -b], [a, -b]] but should have been [[a, -b], [-b, a]]. Applied my corrections for iyEmissionStandard's transmission matrix derivatives from Monday's commit to iyEmissionNonStandard's transmission matrix derivatives. I still think that both the stokes_dim 2 and 3 code will fail at some point, e.g., when the rotation is larger than the absorption. Corrected a copy-paste typo for stokes_dim 4 where dT1 was assigned to also when dT2 was clearly the variable being computed; this left dT2 as the default identity matrix causing huge discrepancies between standard and non-standard outputs. Changed some class-functions to be more readable... 2018-11-21 Patrick Eriksson * arts-2-3-1162 * controlfiles/CMakeLists.txt: Hudson complained. He's picky! The new tests require FASTEM (to get a polarisation signutre across the Stokes vector). Now placed inside if ENABLE_FASTEM. 2018-11-21 Patrick Eriksson * arts-2-3-1161 * More work on adding some test involving temperature jacobians. * controlfiles/artscomponents/wfuns/TestTjacStokes1.arts: Slight polishing. Main thing is comparing analytical and perturbation calculations, with and without HSE. * controlfiles/artscomponents/wfuns/TestTjacStokes4.arts: New. Added as slow. This test looks at the temperature Jacobian with Zeeman, thus 3D and Stokes=4.Comapres analytical and perturbation calculations with HSE=on. Jacobian of each Stokes element compared seperately. * controlfiles/artscomponents/wfuns/TestTjacStokes1to4.arts: New. Added as fast. This test aims at checking consistency between Stokes 1, 2, 3 and 4. All polarisation comes from surface. * controlfiles/CMakeLists.txt: Two new tests added. 2018-11-20 Patrick Eriksson * arts-2-3-1160 * controlfiles/artscomponents/wfuns/TestTjacStokes1.arts: Extended witn comparison to 3D with length 1 lat and lon retrieval grids. Added also a reference for y. * src/m_jacobian.cc (jacobianCalcTemperaturePerturbations) (jacobianCalcAbsSpeciesPerturbations): Noticed that these methods do not handle retrieval grids of length 1. Not fixed, but now there is at least an error warning the user. 2018-11-20 Richard Larsson * arts-2-3-1159 * src/m_rte.cc: Added enum-control * src/m_transmitter.cc: Added iyTransmissionNonStandard analogous to iyEmissionNonStandard. Fast tests are passed with some numerical drifts by changing agenda.arts * src/methods.cc: As above. * src/transmissionmatrix.cc,h: Changed update_radiation_vector to require a 'solver' enum value. This to stop input that is not important to play a roll but still maintain mostly the same interface to not scatter (pun not intended) RTE solvers across the src-tree. Also added special derivative solvers. 2018-11-19 Patrick Eriksson * arts-2-3-1158 * src/m_rte.cc (iyEmissionStandard): Removed some obselete, inactive code. * controlfiles/artscomponents/wfuns/TestTjacStokes1.arts: New test cfile. * controlfiles/CMakeLists.txt: Added test above as fast. 2018-11-19 Richard Larsson * arts-2-3-1157 * src/m_rte.cc: Activated Patrick's HSE code for iyEmissionNonStandard. Also found bug pointed out by Patrick where the final layer transmission matrix was used instead of the final total transmission matrix for reflections causing huge discrepancies between this and iyEmissionStandard for reflected radiation * src/rte.cc: get_stepwise_transmission_matrix made cleaner * src/transmissionmatrix.cc,h: Activated HSE codepath 2018-11-19 Patrick Eriksson * arts-2-3-1156 * src/m_rte.cc (iyEmissionStandard): Worked on the bookkeeping around temperature jacobian. Now HSE on/off is extracted and used. Changed to other expression for dr/dT. All this passed an off-line comparison to perturbation calculations (will be elaborated and added as a ARTS test), as well as TestWfuns. 2018-11-19 Richard Larsson * arts-2-3-1155 * src/transmissionmatrix.cc,src/propagationmatrix.cc: fixed small bug found while testing the distance-derivatives. Previous code had not done the chain rule right for the distance derivatives, only keeping one of the two levels. I have also found a bug for stokes_dim 2 and 3 derivatives. I will go over these bugs more later since these two cases are not common enough to be part of the fast tests... Also, I have changed the order of the input to the derivatives transmission matrix because it was not the same as for other variables * src/test_propagationmatrix.cc: Testing the above. 2018-11-17 Richard Larsson * arts-2-3-1154 Added deactivated HSE guesswork derivatives calculations. I don't trust these at all because I cannot test them properly without implementing derivatives in ppath. They are currently only active by a very obvious flag in m_rte.cc that needs to manually be set to another value. There is no way to run without HSE derivatives if this flag is true so it is just around because Patrick wanted something to test. For this flag to be removed, a runtime_error in the iy-checking method that asserts we have HSE in said agenda, and a method to set the Index that indicates the temperature derivative to something negative when HSE is not active while running with temperature derivatives. * src/m_rte.cc: Made a branch of transmission calculations that should be removed once people are happy with the HSE state. Note that I did not bother at all to check whether the signs are OK. If the temperature is increased for the level in front of you when you look down, the sign should be negative on lstep, but if you are looking up and the level above you gets warmer, the change in lstep is positive. So the two levels carry different signs. * rte.cc,h: Activate inactive code inside the transmission matrix calculations. Note that this is different from before the switch of 983 because previous versions made a much rougher estimtion, and didn't take the effects of the two different levels into account. The code carries the "guesswork"-label because for whatever reason we want to do this without simply outputting the true local derivatives from the ppath-calculations, so that we wouldn't need to make these guesses. The implemented method reduces to AUG for nadir-looking only. I don't believe in AUG definition because it just ignores the limb. It should get increasingly worse the closer to limb local zenith angles. 2018-11-16 Richard Larsson * arts-2-3-1153 Another small speedup for LBL internals. The heaptrack test now indicates there is just one large issue remaining in the codepaths I am mostly using: the cutoff-calls in Linefunctionsdata is using temporary variables. I tried fixing it but it takes more effort than an hour of coding allowed, so the problem remains even with this commit. For some tests this results in a few million calls to temporary allocations. * src/absorption.cc,h: Changed "const Vector&" that was actually a "ConstVectorView" to the latter. Allocates a lot less memory for LBL calculations since the reallocation happened for every single line at every single level * src/linefunctiondata.cc: Removed vector allocation of line parameter derivatives because it is slower than just calling the functions directly. * src/linefunctions.cc: Implements the above change. * src/linerecord.h: Interface to the above. * src/rte.cc, src/transmissionmatrix.cc: Added a comment where the changes needs to go to have dppath_dx in the transmission matrix derivatives. The goal was to add HSE here but I have no good HSE tests because the method is pre-processed on the input data. So perturbations won't work. Putting the perturbations on an even higher level and just restarting all calculations will not work either, because that changes more than just local values. The only way to make the test work is to have dzfield_dT/ dppath_dx as a variable, but that requires changes I don't have time for. I cannot test it, so I cannot implement it. 2018-11-15 stuart.fox * arts-2-3-1152 * src/continua.cc,h;src/partition_function_data.cc;src/species_data.cc;controlfiles/continua.arts: Added MT-CKD v3.2.0 H2O self and foreign continua based on AER Fortran code. Implementation by Emma Turner. 2018-11-14 Richard Larsson * arts-2-3-1151 Found a neat linux-tool, heaptrack, and tested it on TestOEM.arts. Turns out my code made a few million calls to the heap allocator because I was using MatrixXd. These are now removed, so that the RTE is stack only (at least as far as I can see in heaptrack) except for the initial allocation of the TransmissionMatrix-es and RadiationVector-s. The total number of temporary allocations for TestOEM.arts is thus down from iyEmissionStandard's 4 million mostly single words (reported as 0 to 8 byte in heaptrack) to previous iyEmissionNonStandard 3.5 million with half as many words as before, to the now updated iyEmissionNonStandard 80 thousand allocations of almost no single word (most in the 17 to 32 byte range). General: I strongly recommend trying heaptrack on some controlfiles that are slow for unknown reasons to try and see if there are parts of the code that can be improved. The tool is very simple, just call: heaptrack arts controlfile.arts and it will even give the command for graphically displaying the memory allocations at the end of the run. * src/transmissionmatrix.cc,h: removed generic MatrixXd calls because they allocate on the go. Replaced these by direct MatrixNd and VectorNd variables because these don't go outside local scope (no allocate to heap call) The time save is ~10% compared to previous TestOEM.arts with iyEmissionNonStandard. Again, I repeat that the rest of this code is not well-optimized, it is just that the Eigen-vectors are significantly faster than ARTS-vectors for these small-sized matrices. 2018-11-14 Richard Larsson * arts-2-3-1150 Adding XML IO for TransmissionMatrix and RadiationVector. No external variables of these types exist, but this should help make that easier. Note that while the Arrays are implemented I have not tested them yet. The base-classes works as they should for binary and z-/ascii formats ReadXML/WriteXML. Print does as well. The warning for when there is an error in reading is however wrong; a missing value gives the warning: "Check syntax of XML file. A possible cause is that the file contains NaN or Inf values." I have opted to not fix this because it might break the warnings for other classes reading when their data input is bad... * src/groups.cc: Added TransmissionMatrix and RadiationVector and their arrays. * src/make_auto_md_cc.cc: Added "<< "#include \"transmissionmatrix.h\"\n"" * src/make_auto_md_h.cc: Added "<< "#include \"transmissionmatrix.h\"\n"" * src/make_auto_workspace_h.cc: Added "<< "#include \"transmissionmatrix.h\"\n"" * src/transmissionmatrix.h,cc: Added some initializing calls and operator=(self) and ways to output the size of the data * src/xml_io_array_types.cc: Added new reading/writing of Arrays of base classes. These are currently not tested. * src/xml_io_basic_types.cc: Added base classes reading/writing. These are tested and works except for the strange error above when the data is poor. * src/xml_io_instantiation.h: Added TransmissionMatrix and RadiationVector and their arrays. * src/xml_io_types.h: Added TransmissionMatrix and RadiationVector and their arrays. 2018-11-13 Patrick Eriksson * arts-2-3-1149 * src/m_disort.cc (DisortCalc, DisortCalcWithARTSSurface): Did consider the versions used when DISORT is disabled, but got it wrong. 2018-11-13 Patrick Eriksson * arts-2-3-1148 * It shall now be possible to activate DISORT's delta-m scalling. * src/m_disort.cc (DisortCalc, DisortCalcWithARTSSurface): Added GIN do_deltam. * src/disort.cc (run_disort,run_disort2): Added input argument do_deltam. This now controls if deltam is set to true or false. 2018-11-12 Richard Larsson * arts-2-3-1147 * src/m_rte.cc: Minor formatting change * src/transmissionmatrix.cc,h: Added reading/writing to stream for the new classes. Should help with the interface to XML reading/writing if this becomes a thing. Also removed some code left behind while testing this, and updated some function calls to be more explicit. 2018-11-08 Richard Larsson * arts-2-3-1146 Fixed up an old prototype for using Eigen for RTE. The implementation is very ugly, but it speeds up some things. For instance, TestOEM.arts is a factor 2 faster on my computer using the new iyEmissionNonStandard method over the standard method. I haven't done proper tests to speed up the minutia inside the new classes, so there might still be gains to have... Other test functions are not as much speedier, and ; some are even slower than before, and I have not checked during which conditions the OEM stuff is actually faster. The new iyEmissionNonStandard is only tested by changing agenda.arts from iyEmissionStandard to iyEmissionNonStandard. All fast tests works at present. * src/transmissionmatrix.cc,h, src/CMakeLists.txt: Implements both the TransmissionMatrix and the RadiationVector internal classes. These classes are responsible for all RTE calculations. I think it would be good to have them as the external classes as well, since it would entail less copying of data, but they are still only internal. * src/absorption.cc: Fix bug when doing derivatives with NLTE first activated then deactivated again. * src/jacobian.h: Added helper function to RetrievalQuantity: IsTemperature() * src/linescaling.cc: Also fix of bug when NLTE is first active then deactivated. * src/m_rte.cc,src/methods.cc: Implements iyEmissionNonStandard. This is a copy of iyEmissionStandard but with the RTE internals changed to use the TransmissionMatrix and RadiationVector classes. Even though it is called NonStandard, it still copies all the relevant data back to ARTS outputs. The latter operation might be the cause of some delay, and might be improved by either not doing the copying, or using something fancy to map the data properly back to the ARTS outputs. My main reason to call it NonStandard is that it is not as well tested as Standard, so while it should be doing the same things as Standard, it has yet to carry that guarantee * src/rte.cc: Fixed error in comment. 2018-10-26 Richard Larsson * arts-2-3-1144 Since there is a publication on the matter (https://doi.org/10.1051/0004-6361/201833566) by Takayoshi Yamada etal, I should take some time to write proper fast tests for the NLTE stuff so that the debacle where some tests are allowed to fail for months because they are in the slow repository doesn't repeat. I also discovered some issues with the older NLTE computations that should be fixed. Note that these older NLTE computations have never been validated properly (i.e., numerically) against other code. (There was a graphical comparison with many lines at one point, but we never got into the details of single line comparisons.) As the saying goes, squash one bug and two new will be found. Presently, the older NLTE computations using the new and the old lineshape calculators do not agree. They're are off by quite large amounts in their source function computations (up to 150% in the test). Also, there is another error with xsec_species2 that affects mutlicore simulations when the source is calculated (not xsec so far). The former bug I cannot figure out because the codes are doing the same things and the xsec computations are off by less than a percent. The latter I do not even know how to begin to debug alone. So multicore is shutoff for now and at least one of the two tests should be updated/removed in the future so xsec_species and xsec_species2 agrees... * controlfiles/CMakeLists.txt: Added TestPopulationDensityNLTE_lineshape.arts as a fast test of Taka's NLTE method. I also made the unvalidated NLTE fast by reducing the number of frequencies. * controlfiles/artscomponents/lineshapes/testdata/doppler-line.xml: Set Einstein coefficient to low value to let the NLTE equations work. * controlfiles/artscomponents/nlte/TestNLTE_*_method.xml: New test targets. These are using AddLines2 and AddLines. Note that AddLines2 is validated against external code in for population density NLTE, but that neither method is validated for Vibrational Temperature NLTE. It is important to identify this issue to adjust the code, but I cannot find the differences after looking it over for a day... * controlfiles/artscomponents/nlte/TestPopulationDensityNLTE_lineshape.arts: New test for lineshape of NLTE line using same setup as Doppler-test in lineshapes but activating NLTE. plots.py draws the results. These calculations are somewhat validated in https://doi.org/10.1051/0004-6361/201833566. This uses * controlfiles/artscomponents/nlte/testdata/*: Added new test data for TestPopulationDensityNLTE_lineshape.arts * src/absorption.cc: Lots of small changes trying to debug why xsec_species2 cannot be run in parallel. * src/complex.h: Added way to get the real and imag numbers directly by reference. * src.linefunctions.cc,h: is_line_mixing_DF_parameter was used too often. apply_linestrength_scaling_vibrational_nlte is added and set_nonlte_source_and_apply_absorption_scaling removed. Changed switch-statement to match this. * src/m_abs.cc: Some minor changes trying to identify the initialization but * src/m_jacobian.cc: removed mode from jacobianAddNLTE and friend * m_linerecord.cc: nlteSetByQuantumIdentifiers did not need several of its inputs as they were just tests that are not required to run later code unless in (i)yCalc mode. These are removed. Also added some helpers to manipulate all lines. * src/propagationmatrix.cc: removed unused code and all #pragmas. Also initialize StokesVector so its internal tensor is all 0s. 2018-10-19 Simon Pfreundschuh * arts-2-3-1143 * src/m_basic_types.cc(DiagonalMatrix): Added missing initialization for off-diagonal elements. 2018-10-18 Oliver Lemke * arts-2-3-1142 * controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios. {Jupiter,Mars,Venus}.y_reference.xml, controlfiles/artscomponents/cia/TestRTwithCIA.iy_reference.xml: Updated reference files after discussion with Richard. The slight numerical differences are caused by recent changes in ARTS and are ok. All tests in 'make check-all' work again now. 2018-10-17 Oliver Lemke * arts-2-3-1141 * controlfiles/artscomponents/nlte/TestNLTE_NLTE_ref.xml: Updated. The test failed since arts-2-3-983. Quote from email discussion with Richard: --- The differences for TestNLTE should be unimportant. The test result should be updated. The differences come from how the averaging of the results are computed. In the old way, the source function of a level was essentially computed by three parameters so that 0.5*(B[1] + B[0]) + (0.5*NLTE[1] + 0.5*NLTE[0]) / (0.5*K[1] + 0.5*K[0]) The new way is instead to compute the addition slightly different by converting everything to physical units before so that 0.5*(K[0] B[0] + NLTE[0]) / K[0] + 0.5*(K[1] B[1] + NLTE[1]) / K[1], (where you should note that K is just the same in this case, with scattering, the term inside the paranthesis is different from the division term.) The drifts are about 1% at most between the output, so I think the new results are fine. --- 2018-10-17 Oliver Lemke * arts-2-3-1140 * CMakeLists.txt: Disable assertions for 'Native' build type to bring it on par with 'Release' mode. 2018-10-12 Oliver Lemke * arts-2-3-1139 * NOTE: Please only use 'std::isnan()' and 'std::isinf()' instead of 'isnan()' and 'isinf()' in your code!!! * 3rdparty/Eigen: Update to Eigen from 3.2.7 to 3.3.5. This version is C++17 compatible. * src/matpack.h: Remove defines for isnan and isinf. Only clean solution is to use std::isnan and std::isinf explicitly. Otherwise there always remains a possibility for conflicts between the legacy functions and the "new" ones from the std namespace. * src/absorption.cc, src/absorption.h, src/check_input.cc, src/cia.cc, src/cloudbox.cc, src/doit.cc, src/geodetic.cc, src/m_abs_lookup.cc, src/m_basic_types.cc, src/m_doit.cc, src/m_microphysics.cc, src/m_montecarlo.cc, src/m_oem.cc, src/m_optproperties.cc, src/m_ppath.cc, src/m_psd.cc, src/m_rte.cc, src/matpack.h, src/mc_NotUsed.cc, src/microphysics.cc, src/optproperties.cc, src/ppath_NotUsed.cc, src/psd.cc, src/xml_io_array_types.cc: Replace isnan and isinf by std::isnan and std::isinf. 2018-10-12 Oliver Lemke * arts-2-3-1138 * src/CMakeLists.txt: Silence invlib warning spam by using -Wno-conversion for m_oem.cc compilation. * src/complex.cc: Remove unused variables RAD2DEG and joker. * src/matpackII.cc (Sparse::diagonal): Remove unused variable eigen_diag. * src/m_rt4.cc: Move definition of pfct_threshold inside ifdef ENABLE_RT4 to avoid warning when compiling without Fortran modules. 2018-10-11 Oliver Lemke * arts-2-3-1137 * controlfiles/artscomponents/nlte/TestNLTE.arts: Change reference variable names from test to y_nlte_ref and y_lte_ref to be able to see from the error message which Compare fails. 2018-10-11 Oliver Lemke * arts-2-3-1136 * src/arts.cc (arts_exit_with_error_message): If the verbosity level for the report file is set higher than the screen output verbosity, display a link to the report file in the error message. * cmake/modules/ArtsTestcases.cmake: Change screen output level from 2 to 0. Reduces output clutter for failed test cases. Outputs only the relevant error message, not the whole ARTS log. The detailed log can be found in the report file if needed. * src/m_atmosphere.cc (AtmFieldsAndParticleBulkPropFieldFromCompact): Remove unused species_name variable. 2018-10-10 Manfred Brath * arts-2-3-1135 * src/m_atmosphere.cc, src/methods.cc: Implemented AtmFieldsAndParticleBulkPropFieldFromCompact. 2018-10-09 Richard Larsson * arts-2-3-1134 Fixed, for the added test-case, the CIA derivatives for species VMR (works when combined with line VMR) Warning, might still not work for isotopologues and there was some other functions touching species_match that I am uncertain of if they as intended (the HITRAN-Xsec functions) because the function itself did not work as intended in CIA * controlfiles/CMakeLists.txt: Added simple CIA derivatives test. * controlfiles/artscomponents/cia/*: Test files added * src/abs_species_tags.h: Added (SpeciesTag::BathSpecies) for accessing the bathing species * src/jacobian.cc,h: Added new (species_match) and (species_iso_match) for easier identifications of species * src/linerecord.cc: Reading was broken as the token was never updated for LF-tag * src/m_abs.cc,src/m_cia.cc: (abs_coefCalcFromXsec), (abs_xsec_per_speciesAddCIA) updated VMR interface * src/quantum.cc: Updated (operator<<) to work for no isotopologue 2018-10-09 Oliver Lemke * arts-2-3-1133 * src/jacobian.cc (do_vmr_jacobian): Use explicit constructor call instead of make_tuple to work around a compiler error with Apple Clang related to [1]. [1] https://bugs.llvm.org/show_bug.cgi?id=20855 2018-10-08 Richard Larsson * arts-2-3-1132 Trigger test system.... 2018-10-08 Richard Larsson * arts-2-3-1131 * controlfiles/artscomponents/lineshapes/TestFakeHTP.arts: Fix for error. Writing over the testfile is not a good idea... 2018-10-08 Richard Larsson * arts-2-3-1130 * doc/uguide/absorption.tex: Updated with fixmes for figures in error. Also removed legacy line mixing example. 2018-10-08 Richard Larsson * arts-2-3-1129 * controlfiles/artscomponents/*.xml: Updated because of addition of internal VMR derivatives for Voigt and Lorentz (Doppler should be fine already; because HTP is not working it throws an error now). * controlfiles/artscomponents/lineshapes/TestFakeHTP.arts: Removed internal derivatives calculations option for VMR since it does not work. * controlfiles/artscomponents/zeeman/plots.py: convenient plt.show() * controlfiles/artscomponents/lineshapes/plots.py: Added warning that HTP code is still not in working condition * src/jacobian.cc,h: Added convenience function for VMR * src/linefunctiondata.cc,h: Output typedef as part of class instead of obnoxious tuple. (GetVMRDerivs) fixed because of missing AIR compensation. Might be lingering errors in other derivatives (the unused T0 derivatives), because of code not taking this into account there. Might also have errors in parameter-space parameters because of the same reason since normalization means we are pushing air out of a level due to there being more of "self" or any species. * src/linefunctions.cc: (set_lorentz,set_voigt,apply_linemixing_scaling) updated to do proper internal computations. (set_htp) updated to throw an error if proper calculations are requested. (set_cross_section_for_single_line) updated to pass VMR derivatives on request * src/linerecord.h: Added GetShapeParams_dVMR. Also updated so LineFunctionData::Output is used instead of the tuple. * src/m_linerecord.cc: Removed lingering cout-statement left by mistake in previous commit... 2018-10-04 Richard Larsson * arts-2-3-1128 * src/m_abs.cc: Fixing error in how mirroring works so that mirrored lines are marked as manually mirrored in (abs_lines_per_speciesAddMirrorLines). * src/linefunctions.cc,linerecord.h: Added Manual tag to MirroringTypes. * src/disort.cc,src/quantum_parser_hitran.cc: Added DEBUG_ONLY to suppress errors in a couple of places * doc/uguide/absorption_theory.tex: Added description of new line shape calculator. The old way has the legacy tag added * doc/uguide/absorption.tex: Added abs_xsec_per_speciesAddLines2 to the list. Need to still update figures... 2018-09-29 Patrick Eriksson * arts-2-3-1127 * src/m_oem.cc (avkCalc): Fixed and improved error message. * src/m_checked.cc (sensor_checkedCalc): Also *f_grid* is now examined, that's strictly increasing. (nlteOff): Moved to m_nlte.cc. * src/m_nlte.cc (nlteOff): Moved to m_checked.cc. 2018-09-28 Richard Larsson * arts-2-3-1126 Change in internal pressure broadening routines. Previous versions had strict formats on relationships between temperature, coefficient of broadening, exponent of broadening, and pressure shift. This version has not. Instead, it takes the approach that we now have to define the relationship more loosly by temperature relationships. To be internally consistent, this incurs a penalty for old computations that is up to 50% in new use case. However, what spurred this implementation was that the old computations make an inherent assumption that turns out to not fit with lab-folks model that the exponent for pressure shift has to be 1.5*N+0.25 for N being the exponent of the pressure broadening. This assumption works, a cursory read tells me, for water in air but it is not clear it works for other combinations of species. As a consequence of this re-haul, all catalog parameters relating to line mixing and pressure broadening has been revamped. The new pressure broadening routine can handle any species that can be put in abs_species, but it only operates, in essence, on the Index that identifies the main species of the tag. So it is best to simply write just the species instead of a fancy full tag or some isotopologue. * controlfiles/CMakeLists.txt: Removed linemixingrecord.cc,h and its variable from use in controlfiles. This was a temporary solution that got superseded by ARTSCAT5. No one should be using it. If you did, downgrade ARTS, save the line catalog you had before as ARTSCAT5, and use the ARTSCAT5 you just saved in the future. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Deleted. Also deleted possibility of changing between ARTSCATs other than to ARTSCAT5. The new pressurebroadening routine makes this too messy, and ARTSCAT5 is the best representation of how we use these variables internally. Therefore, the others are not useful but as legacy catalogs. * controlfiles/artscomponents/lineshapes/*.{arts,py}: Updated to use new derivatives routine. As the plots show, the internal derivatives still work except for VMR, since there are no internal derivatives for VMR. * controlfiles/artscomponents/lineshapes/testdata/*: All updated/deleted because the internal derivatives have changed. * controlfiles/artscomponents/wfuns/*: Updated for the same reasons * controlfiles/artscomponents/zeeman/*: Updated because the internal VMR derivatives were not good in the last version (only worked on pressure broadening+shift, not line mixing and other parameters) Therefore, it was better to not do any line shape VMR derivatives at this point. This means we still are limited to an error in VMR jacobian proportional to the VMR of the species itself. * src/absorption.cc,h: (find_broad_spec_locations) removed. (xsec_species*) updated because there is no use of (find_broad_spec_locations) anymore. (xsec_species_line_mixing_wrapper) lm_p_lim is temporarily removed (possible to readd in case it becomes necessary, but bad spectra is not a good reason, because the variable should not be used then anyways...) (xsec_species_line_mixing_wrapper) also updated to not allow line parameter derivatives anymore. The main reason LineFunctions exist as a namespace is because the old method was complicated, and this made it worse. Use LineFunctions-approach instead if you are interested in those derivatives. * src/groups.cc; src/linemixingrecord.cc,h; src/m_basic_types.h; src/make_auto_md_h.cc; src/make_auto_workspace_h.cc; src/xml_io_array_types.cc; src/xml_io_compound_types.cc; src/xml_io_instantiation.h; src/xml_io_types.h; src/workspace.cc: Removed *LineMixingRecord * src/jacobian.cc,h: Moved around and changed logic around line shape derivatives. HasSameInternalsAs added as RetrievalQuantity internal logic. Ignores external logic, such as grids. * src/linefunctiondata.cc,h: Updated to cover all legacy applications and to have easy interfaces to things like the jacobian computations * src/linefunctions.cc,h: updated because (broad_spec_locations) is no longer a thing. Also removes line mixing if you select a Doppler line shape and other things that were possible but not very good. Also updated (set_doppler) because the old version seemed buggy. Also updated all line shapes to be aware of new line shape param derivatives. Also replaced (apply_pressurebroadening_jacobian_scaling) and (apply_linemixing_jacobian_scaling) by just (apply_linefunctiondata_jacobian_scaling). Also removed my experimental (SingleLevelLineData) class because it was not used anywhere and it should not be necessary anymore. * src/linemixingdata.cc;src/pressurebroadeningdata.cc: Commented out failing, now unused code * src/linerecord.cc: Removed functions exclusive to old ARTSCATs and all ways to convert between the catalogs. Also using mlinefunctiondata. * src/linerecord.h: Sets version to 5 in case initiated normally. removed old pressure broadening and line mixing data. Replaced by line function data class in all still relevant interfaces. * src/m_abs.cc: (abs_linesArtscat4FromArtscat3) removed. Changed name of (abs_linesArtscat5FromArtscat34) to (abs_linesNewestArtscatFromLegacyCatalog) * src/m_jacobian.cc: Added(jacobianAddLineFunctionDataParameter*) changed old catalog parameter to only have line center and line strength. * src/m_linemixing.cc: Removed LineMixingRecord. Also changed interface commands to pressure broadening. * src/m_linerecord.cc: (abs_linesReplaceParameterWithLinesParameter) deals in line function data class now. (abs_lines*ParameterForMatchingLines) split to (abs_lines*BaseParameterForMatchingLines) and (abs_lines*LineFunctionDataParameterForMatchingLines) * src/m_radiation_field.cc: Changed because find_broad_spec_locations is not a thing anymore * src/m_zeeman.cc: Removes line mixing pressure limit * src/methods.cc: Changed as described above and below * src/nlte.cc,h: Removed buggy unused method because of interface change. This tried to compute collision relaxation from pressure broadening but it does not work in old or present form... * src/partial_derivatives.cc: Removed old line parameters. * src/zeeman.cc,h: Changed because find_broad_spec_locations is not a thing anymore. Also removed unused (xsec_species_line_mixing_wrapper_with_zeeman) 2018-09-28 Oliver Lemke * arts-2-3-1125 * CMakeLists.txt: Add option ENABLE_CXX17 for testing code and compiler compatibility with the C++17 standard. Note that this for _testing_ only! The version of the Eigen library included in ARTS is currently not C++17 compatible due to its use of deprecated functionality std::binder1st and std::binder2nd. * README: Add note about NO_FFTW and ENABLE_CXX17. 2018-09-27 Oliver Lemke * arts-2-3-1124 * src/xml_io_compound_types.cc: Fix checks for temperature fit input data of XsecRecord. Bug reported by Hanna Dunke. * src/species_data.cc, src/partition_function_data.cc: Add CFC113. 2018-09-25 Oliver Lemke * arts-2-3-1123 * controlfiles/artscomponents/nlte/testRotationalConvergence.arts: Fix names water_psat* -> water_p_eq*. Fixes failing test reported by Patrick and Karina McCusker. 2018-09-24 Patrick Eriksson * arts-2-3-1122 * If you do retrievals inside ARTS, you need to update your control files. x2artsStandard is replaced with x2artsAtmAndSurf. If you retrieve any varaible associated with the sensor, you now also need to call x2artsSensor and to define sensor_response_agenda. You migth also need to adjust call of jacobianAddFreqShift (now uses less input arguments). For further details, see TestOEM.arts. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: * controlfiles/artscomponents/wfuns/TestWfuns.arts: Updated call of jacobianAddFreqShift and jacobianAddFreqStretch. * controlfiles/artscomponents/oem/TestOEM.arts: Updated to changes made, and now also shows how baseline and frequency switch retrievals are made. * src/m_oem.cc (x2artsSensor): Now also handles frequency shift and stretch. To handle this, sensor_response_agenda is now a required input. (x2artsStandard): Removed. * src/agendas.cc (define_agenda_data): Changed description and in/out for sensor_response_agenda. It was once intended to be used in another way, now defined to fit retrievals. 2018-09-23 Patrick Eriksson * arts-2-3-1121 * Some cleaning ... * src/m_disort.cc (DisortCalc, DisortCalcWithARTSSurface): Adopted call of run_disort2. * src/disort.cc (run_disort2): Removed *pfct_method* as input. Was not used. Fixed compiler warning. * src/m_retrieval.cc (retrievalAddFreqShift,retrievalAddFreqStretch): * src/m_jacobian.cc (jacobianAddFreqShift, jacobianAddFreqStretch) (jacobianCalcFreqShift,jacobianCalcFreqStretch): Changed to NOT allow frequency shifts and stretchs that varies with sensor_time. Possible to calculate the Jacoboan for time varying shifts, but not possible to apply it in non-linear inversions inside ARTS, as *sensor_response* is assumed valid for all measuement blocks. Old code left in file. * src/m_oem.cc (OEM_checks): Size consistency between y and Se was wrong. Se was compared to itself! Added y as input, and size check now works. 2018-09-22 Patrick Eriksson * arts-2-3-1120 * Some work towards handling retrieval of sensor variables. * src/m_oem.cc (xaStandard): Added setting of xa for frequency fit variables. (x2artsAtmAndSurf,x2artsSensor,x2artsSpectroscopy): New methods. 2018-09-19 Richard Larsson * arts-2-3-1119 * src/CMakeLists.txt: Added src/linefunctiondata.cc,h to separate the new pressure broadening and line mixing interface from the old * src/linefunctiondata.cc,h: Moved namesake class here from src/pressurebroadeningdata.cc,h. Also added a translation function from old pressurebroadeningdata and linemixingdata to new linefunctiondata * src/m_cloudradar.cc: Small compile warning corrected. Someone over-indented some error code, probably by a copy-paste miss that automatically indented something to the wrong level. This causes the warning (paraphrased): Your if-statement guarding does not include statement on same indentation level. * src/pressurebroadeningdata.cc,h: Removed old interface * src/quantum.cc,h: Made it easier to get the name from a quantum identifier 2018-09-19 Oliver Lemke * arts-2-3-1118 * src/m_microphysics.cc (pndFromPsd): Add same runtime error as for pndFromPsdBasic. 2018-09-19 Oliver Lemke * arts-2-3-1117 * src/m_microphysics.cc (pndFromPsdBasic): Throw runtime error if psd_size_grid contains duplicate values. Avoids assertion in bin_quadweights caused by user input. Reported by Freddy. 2018-09-18 Richard Larsson * arts-2-3-1116 Update to internal pressure broadening interface * src/absorption.cc, jacobian.{cc,h}, src/linefunctions.cc, src/linemixing.cc, src/linerecord.cc, src/m_linemixing.cc, src/m_linerecord.cc, src/nlte.cc, : Updated for change in pressure and line mixing interface. * src/linerecord.h: Where the interface now resides * src/m_nlte.cc, methods.cc: Added helper function to get quantum identifiers from lines * src/pressurebroadeningdata.cc,h: Still tinkering with new pressure/line mixing routine. Today's changes helps * src/quantum.cc,h: Helpers for the nlte helper function 2018-09-18 Oliver Lemke * arts-2-3-1115 * src/hitran_xsec.cc (XsecRecord::Extract): Don't try to apply temperature fit for species that lack data for it. Fixes bug reported by Hanna Dunke. * src/xml_io_compound_types.cc (xml_read_from_stream): Add input sanity checks for XsecRecord. 2018-09-13 Patrick Eriksson * arts-2-3-1114 * src/m_cloudradar.cc (iyActiveSingleScat): The method now considers scat_data_checked. 2018-09-10 Simon Pfreundschuh * arts-2-3-1113 * src/m_rte.cc(iyEmissionStandard): Call to get_stepwise_blackbody_radiation ignored jacobian_do flag leading to an out of bounds access in dB_dT. This has been fixed. 2018-09-10 Simon Pfreundschuh * arts-2-3-1112 * src/m_retrieval.cc(covmat1D): Fixed bugs in covmat1D report by Jonas Hagen as well as some others found in the process. * controlfiles/artscomponents/retrieval/* Added controlfile and reference files to test covmat1D. 2018-09-06 Simon Pfreundschuh * arts-2-3-1111 * src/arts_api.cc (get_covariance_matrix_block): Fixed bug leading to always returning the first block in the matrix. 2018-09-05 Patrick Eriksson * arts-2-3-1110 * src/geodetic.cc (cart2poslos): More tweaks to handle numerical problems. Changed "Check that not lon changed with 180 deg". The old version did not resolve changes of 180 and 360. 2018-09-04 Patrick Eriksson * arts-2-3-1109 * src/geodetic.cc (cart2poslos): Removed a consistency check I added some years ago. Now stumbled upon a case that did not show consistency with the alternative way to set za. In this case the alternative way clearly gave wrong result, and it seems that the code change I did works better than the old (now alternative) way. So removed the check. 2018-09-04 Patrick Eriksson * arts-2-3-1108 * controlfiles/general/general.arts: lat_true and lon_true are now set to be empty. * src/ppath.cc (ppath_start_stepping): Commented out first checks for 3D. They were meant to provide a more clear error message, but they can result in fails for actually OK set-ups at high latitudes. * src/m_checked.cc (atmgeom_checkedCalc): The method now also checks lat_true and lon_true. 2018-09-03 Simon Pfreundschuh * arts-2-3-1107 * src/m_disort.cc(DisortCalcWithARTSSurface): Adapted function placeholder to new signature of DisortCalcWithARTSSurface. 2018-09-03 Simon Pfreundschuh * arts-2-3-1106 * 3rdparty/disort/LINPAK.f: Renamed functions with the same name as other BLAS function to avoid clashes suspected to lead to weird bugs when using ARTS through python. * src/disort.cc(check_disort_input): Updated error message on inhomogeneous scat data grids to mention interpolation option for pfct_method which supports them. * src/m_disort.cc(DisortCalcWithARTSSurface): Updated DisortCalcWithARTSSurface to also support the new extraction scheme for scattering properties. * src/methods(DisortCalcWithARTSSurface): Updated entry for DisortCalcWithARTSSurface. 2018-09-03 Oliver Lemke * arts-2-3-1105 * src/partition_function_data.cc, src/species_data.cc: Add cross section species CCl4, C2F6, CHF3, HFC32, HFC143a. 2018-09-03 Oliver Lemke * arts-2-3-1105 * src/partition_function_data.cc, src/species_data.cc: Add cross section species CCl4, C2F6, CHF3, HFC32, HFC143a. 2018-08-31 Oliver Lemke * arts-2-3-1104 * src/hitran_xsec.cc (convolve): Fix non-FFTW build. 2018-08-31 Oliver Lemke * arts-2-3-1103 * src/hitran_xsec.{cc,h}, src/m_hitran_xsec.cc, src/methods.cc, Apply temperature correction. Add option apply_tfit to abs_xsec_per_speciesAddHitranXsec to disable temperature correction for testing purposes. * src/xml_io_compound_types.cc: Add support for temperature fit data in xml file. * controlfiles/artscomponents/hitran-xsec/CFC11.xml.gz: Updated. * .travis.yml: Give builds names. 2018-08-30 Oliver Lemke * arts-2-3-1102 * .travis.yml: Add Travis CI config. 2018-08-26 Simon Pfreundschuh * arts-2-3-1101 * m_jacobian.cc(jacobianClose): - Removed check requiring sensor_pos and sensor_response to be set even though they are not used by the function. * m_retrieval.cc(retrievalDefClose): - Updated call to jacobianClose * methods.cc(jacobianClose): - Updated entry for jacobianClose 2018-08-25 Simon Pfreundschuh * arts-2-3-1100 * arts_cpi.cc(set_variable_value): - Set variable to be empty when variable pointer is 0. * interactive_workspace.[h, cc](initialize_variable): - Added function to (re)initialize variables 2018-08-23 Patrick Eriksson * arts-2-3-1099 * src/m_rte.cc (iyEmissionStandard, yCalc): Switched from using FOR_ANALYTICAL_JACOBIANS_DO to using FOR_ANALYTICAL_JACOBIANS_DO2 when setting j_analytical_do. Before this change surface jacobians came out as all zeros if there was no atmospheric quantity retrieved. Now it seems surface-only retrievals should work. 2018-08-23 Simon Pfreundschuh * arts-2-3-1098 * m_rte.cc(yCalcAppend): - Add surface quantities to check for equality of retrieval quantities. 2018-08-21 Oliver Lemke * arts-2-3-1097 * controlfiles/instruments/mviri/{TestMVIRI.arts, TestMVIRI.ybatch_MET2_6e8_fastREFERENCE.xml.gz}, controlfiles/instruments/seviri/{TestSEVIRI.arts, TestSEVIRI.ybatch_MET9_6e9_fastREFERENCE.xml.gz}, Remove sensorOff from controlfiles. Update reference files. Added a clear note at the top of the file that these calculations are untested. 2018-08-14 Richard Larsson * arts-2-3-1096 Fixing some annoying bugs * src/m_checked.cc: removed a removed method from missing methods warning * src/rational.cc: isUndefined is no caught inside toIndex() Should instead this be considered a developer bug and the error be thrown elsewhere? * src/zeemandata.cc: Now actively checks for Hund-case being set for standard initialization... 2018-08-14 Richard Larsson * arts-2-3-1095 * src/linerecord.cc: Removed warning as it is fixed now * src/m_wigner.cc,methods.cc: Added methods to set only wigner 3 symbols * src/wigner_functions.cc,h: Added checks to see if the library is in the state we expect it to be in. This is a very non-ARTS way of doing things so that ReadXML does not break. These checks are good to use even for others that call and use the wigner-library (only line mixing so far) * src/zeemandata.cc: Now runs one of said check 2018-08-13 Oliver Lemke * arts-2-3-1094 * src/continua.cc (XINT_FUN): Introduce a range check inside the interpolation function to finally fix out-of-bounds access to the values table. Bug reported by Hanna and Freddy. While the XINT_FUN for ConstVectorView input generated an assertion in those cases, the implementation for Numeric[] input could have returned invalid values. Now both functions return 0 for those cases. 2018-08-12 Simon Pfreundschuh * arts-2-3-1093 * src/m_rte.cc(yCalcAppend): - Fixed handling of the jacobian of scattering species in yCalcAppend * src/m_retrieval.cc(covmat1D): - Added error message if function name is unknown - Fixed matrix type to match that of the type parameter. * src/interactive_workspace.[h, cc]: - Added function to set values of sparse matrices directly through API. * src/covariance_matrix.[h, cc]: - Exposed function to access block vector of covariance matrix. * src/arts_api.[h, cc]: - Added support for setting of sparse matrices through the API - Added support for retrieving covariance matrices through the API 2018-08-08 Oliver Lemke * arts-2-3-1092 * src/m_wigner.cc (Wigner6Init): Fixed compile error due to missing comma after parameter. 2018-08-08 Richard Larsson * arts-2-3-1091 * 3rdparty/wigner/fastwigxj/src/fastwigxj.c: removed exiting from a function that did not need it * doc/uguide/absorption.tex: updated name of method * src/linemixing.cc,h: Added OpenMP support and switched around how Wigner-calculations are done. Speedup is 3X on four threads. * src/linerecord.cc: just added a warning comment. Presently, ARTS will crash completely if you do not run Wigner6Init before reading a catalog with Zeeman-effect data... Problem: the Wigner code calls exit(1) and I do not know how to catch this * src/m_linemixing.cc: Also creates the temporary arrays for Wigner and keeps track of sizes * src/m_wigner.cc: Added OpenMP symbols. Also changed so that the temporary tables are not initiated. The latter is done because there is a need to initiate these temporary objects for every thread. If it was possible to do all that once, I would have it done here and then just remove them in the remove file. I am not sure how these temporary objects work, though, so that is not possible. * src/m_zeeman.cc: Fix of strange previous design of the overwriting program... * src/methods.cc: TestLineMixing needs the wigner symbol sizes * src/wigner_functions.cc,h: Changed so that the same function call is used regardless of whether or not the DO_FAST_WIGNER variable is set or not inside all functions. Also beginning to add O2 ECS symbol. * src/zeemandata.cc,h: Created an init function to keep the code simpler, and the init function now creates a temporary array of the correct size 2018-08-08 Oliver Lemke * arts-2-3-1090 * 3rdparty/wigner/fastwigxj/Makefile: Merge updated Makefile with pthread support. 2018-08-06 Richard Larsson * arts-2-3-1089 Updates of fast-wigner calculations by H. Johansson, should now support multithreading, though this has not been adapted in ARTS-code yet. The rest are just small code dumps for some ongoing work on line mixing calculations. * 3rdparty/relmat/module_linemixing.F90: Fix to hard-coded temperature dependency * src/CMakeLists.txt: Added a linemixing.cc file * src/abs_species_tags.cc,h: Added SpeciesMass, IsSpecies, and IsIsotopologue to SpeciesTag-class for easier use without having to access the species-mapping itself (use these on own risk, because the ARTS species- mapping is riskful to use for these purposes unless you are absolutely certain what you can have available) * src/complex.h: comments update from the copy-paste. * src/linefunctions.cc,h: Update so function takes reference instead of copies * src/linemixing.cc,h: Added. Contains an experimental re-implementation of the simplest case of relmat. Not for real use yet... * src/m_linemixing.cc: TestLineMixing to test the above * src/methods.cc: as above * src/rational.cc,h: Added toInt() because Wigner-code needs integers * src/wigner_functions.cc,h: made co2_ecs_wigner_symbol public 2018-07-17 Oliver Lemke * arts-2-3-1088 * src/pressurebroadeningdata.cc (operator<<): Fix compilation with clang. Not sure if clang is right or wrong here, but this version works in all compilers. lfd.LineMixingType::Interp -> LineFunctionData::LineMixingType::Interp 2018-07-16 Richard Larsson * arts-2-3-1087 * src/abs_species_tags.cc,h: Added SpeciesNameMain functionality to print the name of the main species * src/linefunctions.cc: Shortened some code * src/linerecord.h: removed unused linerecord_binary_data_size * src/pressurebroadeningdata.{cc,h}: Added a yet not completed class I suggest we replace the internal pressure and line mixing routines with in the future. There are too many temperature functions for different line shape paramaters out in the wild that the rigid system we presently have in place will be difficult to maintain. The new method currently lacks the following features: m_linerecord.cc integration, partial derivatives, and control-file level error checking. The first two are easy to fix but might end up breaking some controlfiles because the new way is parameterized in a stronger way. The last one cannot be fixed before this is default, either as artscat-6 or another artscat-5 tag replacing both the LM and PB tags of today. * src/test_propagationmatrix.cc: Demonstrates parts of the new line shape routine in test_linefunctionsdata. * src/zeemandata.{h,cc}: Returns random values to make my compiler stop complaining even for functions where all the possible enum values are already defined in the switch-statement... 2018-07-13 Oliver Lemke * arts-2-3-1086 * controlfiles/artscomponents/moltau/TestMolTau.arts: Add test for WriteMolTau. Provided by Claudia Emde. * controlfiles/CMakeLists.txt: Run TestMolTau if NetCDF support is enabled. * controlfiles/artscomponents/absorption/TestAbs.arts: Remove commented out call to abs_coefCalcFromXsec. * src/m_abs.cc (WriteMolTau): Fix typo. 2018-07-05 Richard Larsson * arts-2-3-1085 Some small changes... * src/m_cloudbox.cc: cloudboxOff sets scat_species to zero-size. Generally, there are too many variables that requires touching to make normal code work. * src/m_planets.cc: Added refellipsoidEuropa * src/pressurebroadening{h,cc}: Update to water broadening test case. Also some playground code for a possible reimplementation (depending on time and necessity), to make the code easier to follow/change. It seems temperature dependency varies for the different variables, so a reimplementation might be necessary to keep the code readable in the future (especially if new line parameters become necessary for other planets than Earth) 2018-06-27 Simon Pfreundschuh * arts-2-3-1084 * src/m_microphysics.cc(pnd_fieldCalcFromParticleBulkProps): - Function computed incorrect size of pnd_field for 3D atmospheres. This has been fixed. 2018-06-25 Oliver Lemke * arts-2-3-1084 * src/{absorption.cc, agenda_class.cc, cia.cc, file.cc, gas_abs_lookup.cc, legendre.cc, linerecord.cc, m_abs.cc, m_abs_lookup.cc, m_agenda.cc, m_atmosphere.cc, m_basic_types.cc, m_batch.cc, m_cia.cc, m_cloudbox.cc, m_doit.cc, m_jacobian.cc, m_linemixing.cc, m_montecarlo.cc, m_radiation_field.cc, m_rte.cc, m_sensor.cc, m_surface.cc, m_xml.h, main.cc, make_auto_md_cc.cc, make_auto_md_h.cc, make_auto_workspace_h.cc, nc_io.cc, parser.cc, rational.cc, rt4.cc, rte.cc, test_geomag_calc.cc, test_legendre.cc, test_matpack.cc, test_quantum.cc, test_sparse.cc, test_xml.cc, tmatrix.cc, xml_io.cc, xml_io_array_types.cc, xml_io_compound_types.cc}: It is recommended practice to catch exceptions by constant reference. Adapted all catch clauses to that. Fixes loads of warning when compiling with GCC 8.1. * ChangeLog: Fix tab/space formatting in previous commit. 2018-06-25 Manfred Brath * arts-2-3-1083 * src/microphysics.cc (psd_SB06): Corrected the derivative of the particle size distribution. * src/m_fluxes.cc (AngularGridsSetFluxCalc, heating_ratesFromIrradiance, irradiance_fieldFromRadiance, RadiationFieldSpectralIntegrate, spectral_irradiance_fieldFromiyField), src/CMakeLists.txt: Implemented functions that are needed for the calculation of radiation fluxes (irradiance) and heating rates. * src/math_funcs.{cc,h}(calculate_weights_linear): Implemented function to calculate integration weights for the angular integration that is needed for the fluxes and heating rates functionality. * src/methods.cc (AngularGridsSetFluxCalc, heating_ratesFromIrradiance, irradiance_fieldFromRadiance, RadiationFieldSpectralIntegrate, spectral_irradiance_fieldFromiyField): Added entries for newly implemented workspace methods. * src/workspace.cc: Introduced heating_rates, irradiance_field, radiance_field, spectral_irradiance_field, specific_heat_capacity, specific_heat_capacity, and za_grid_weights. * controlfiles/artscomponents/heatingrates (TestHeatingRates.arts, TestHeatingRates.abs_lookup.xml*, TestHeatingRates.heating_ratesREFERENCE.xml), controlfiles/CMakeLists.txt: Added testcase for heating rates and fluxes functionality. 2018-06-22 Richard Larsson * arts-2-3-1082 * src/pressurebroadeningdata.cc,h: Forgot to add air to the test. I also needed reading ability... 2018-06-21 Richard Larsson * arts-2-3-1081 * src/absorption.cc,nlte.cc: Changed so pressure broadening takes both T and T0 * src/linefunctions.cc: Changed so pressure broadening takes both T and T0. Added two pressure broadening options for testing * src/m_linerecord.cc, method.cc: Added three ways to set line shape paramters for the xsec_species2 method * src/pressurebroadeningdata.cc,h: Addning now testing pressure broadening form. 2018-06-19 Richard Larsson * arts-2-3-1080 * src/m_zeeman.cc: Added output for zeeman_linerecord_precalcModifyFromData * src/zeeman.cc: Changed so cutoff 'should' work * src/nlte.cc: removed compiler warning * src/quantum.cc,h: added parity properly * src/xml_io_array_types.cc: Fixed bug in quantum identifier reading where the variable was not properly reset so old numbers remained in a variable. 2018-06-17 Simon Pfreundschuh * arts-2-3-1079 Added check for uninitialized variables for calls through the C interface. * src/interactive_workspace.cc (execute_workspace_method): Added check. 2018-06-154 Richard Larsson * arts-2-3-1078 Updated to fixed Zeeman calculations. Note that this intentionally breaks controlfiles. Also note that Zeeman is now using the line functions namespace, so cutoff and such must be defined in the line record * src/jacobian.cc: Modified helper functions * src/methods.cc: Changed name of propmat_clearskyAddZeemanFromPreCalc to propmat_clearskyAddZeeman * src/m_zeeman.cc: Chnaged to use new method * src/propagationmatrix.cc,h: AddPolarized takes a Complex instead of a Numeric now * src/zeeman.cc,h: Updated zeeman_on_the_fly. It now works for all jacobians. Compare with xsec_species_line_mixing_wrapper_with_zeeman for complexity 2018-06-14 Richard Larsson * arts-2-3-1077 Second part of updating Zeeman calculations. Contains the method of how the error became apparent... Still no update to the actual computations. (Sorry for multiple partial updates not leading anywhere; I found the bug while travelling but I had to sit down by my desk for a few hours to find the cause) * src/jacobian.cc,h: introduced is_magnetic_magnitude_parameter to contain all variables that needs the magnitude in jacobian. This waste a few cycles presently but will be necessary by next committ * src/linefunctions.cc: Use is_magnetic_magnitude_parameter * src/zeeman.cc,h: Added future replacement function for Zeeman internals and removed unused parameters 2018-06-14 Richard Larsson * arts-2-3-1076 Starting to fix a small bug in the Zeeman calculations. It seems the eta angle was wrong for when theta angle was close to 90 degrees. This affects very special linear polarization calculations Luckily, none of the use-cases I have had for this has used the geometry in question, and the effect only redistributed some strength from 45 to main axis polarization. Note that this code only adds the necessary code to fix the problem and does not finalize the switch to the new angles. Expect the other update shortly. * src/quantum.h: Adding parity quantum number * src/zeeman.{cc,h}: Added separate implementations returning angles and derivatives 2018-06-14 Patrick Eriksson * arts-2-3-1075 * Spring cleaning of water equilibrium variables and functions. * controlfiles/general/general.arts: * src/rte.h: * src/m_cloudradar.cc (iyActiveSingleScat): * src/m_fos.cc (iyHybrid): * src/m_nlte.cc (nlte_fieldForSingleSpeciesNonOverlappingLines): * src/m_oem.cc (x2artsStandard, xaStandard): * src/m_radiation_field.cc (radiation_fieldCalcFromiyCalc) (radiation_fieldCalcForSingleSpeciesNonOverlappingLines) (doit_i_fieldClearskyPlaneParallel): * src/m_rte.cc (iyEmissionStandard): * src/m_transmitter.cc (iyTransmissionStandard): * src/rte.cc (rtmethods_jacobian_finalisation): * src/methods.cc: * src/agendas.cc: * src/workspace.cc: * src/m_physics.cc (water_p_eq_fieldMK05): Renaming of variables, methods and agenda. Changed from namimg using "psat" to "p_eq". That is, water_psat is now water_p_eq etc. * src/continua.cc (WVSatPressureLiquidWater): Removed, for several reasons: (1) Not used. (2) theta = 373.16 / t; that looks wrong and is inconsistent with comment (saying 300/t). No time for checking what is correct. (3) This is not a very well known parameterisation. (WVSatPressureIce): Also removed, as neither used. Here theta = 273.16 / t;! 2018-06-11 Patrick Eriksson * arts-2-3-1074 * src/continua.cc (xsec_continuum_tag): Changes for liquidcloud-MPM93 and liquidcloud-ELL07. For both models changed the valid temperature range to 210 - 373 K. Comment 1: We allow unphysical values elsewhere in ARTS, so a lower limit of 233K seemed too strict in comparison. At least -42C is possible. And a limit of 233K causes problems when working with e.g. ERA5. In the upper end, I set the limit at 100C (this was already the case for ELL07). Comment 2: Would be good with a clear strategy for how to set limits. Shall we have limits at all? 2018-06-07 Simon Pfreundschuh * arts-2-3-1073 * src/m_psd.cc: - Throw error when *Dm* PSD input is zero or very small. * src/methods.cc: - Updated description of psdD14. 2018-06-05 Simon Pfreundschuh * arts-2-3-1072 * src/arts_api[h, cc]: - Fix bug accidentally introduced in last commit. 2018-06-05 Simon Pfreundschuh * arts-2-3-1071 * src/arts_api[h, cc]: - Added agenda_append method to emulate include statements inside agenda definition. - Fixed handling of agendas in agenda_insert_set * src/interactive_workspace.cc: - Fixed setter function for WSVs of group agenda. 2018-06-02 Patrick Eriksson * arts-2-3-1070 * Bug fix! Contribution to Q was wrong for all surface set-ups involving surfaceFlatRvRh. This includes e.g. TESSEM. * src/m_surface.cc (surfaceFlatRvRh): surface_emission(iv,1) had wrong sign. My mistake. Found by Simon. * src/geodetic.cc (poslos2cart): Deactived assert( abs( lon ) <= 360 ); As lon is cyclic and code works even for higher lons. * src/ppath.cc (ppath_start_stepping): ppath.pos(0,2) was set incoreectly for 3D empty path. 2018-06-01 Richard Larsson * arts-2-3-1069 Change in Zeeman calculations to save some memory. Will break controlfiles using Zeeman and old computational method. * controlfiles/*: The linemixing tests are now covered by the lineshapes tests so I removed them. The Zeeman tests now need to initialize wigner functionality to work. This greatly simplifies the code * src/absorption.cc: Changed interface to reach the new Zeeman calculations * src/linefunctions.cc: as absorption.cc and changed name of faddeeva functions to voigt so people more easily find these * src/linerecord.cc: Updated reading/writing of Zeeman line information * src/m_linemixing.cc: updated interface to linefunctions * src/m_radiation_field.cc: as above * src/m_zeeman.cc: Added zeeman_linerecord_precalcModifyFromData to modify the Zeeman data by external data easily. Removed the standard Zeeman calculations routine because ther were anyways useless (only adding some overhead to make slower calculations). Also demands Wigner6Init to have been run. FIXMEs remaining: The linerecord generator should change to be able to have precalc data in the normal line data upon generation and 6j is technically not required since only the 3j symobol is used. * src/methods.cc: as above * src/quantum.cc: Fix bug in energy level matchings * src/test_propagationmatrix.cc: fix interface to linefunctinos * src/zeeman.cc: updated to use zeemandata files. makes code cleaner. FIXME remaining: move to use linefunctions * src/zeemandata.cc: Updated to store all relevant data for Zeeman effect. FIXME remaining: move polarization and related derivatives into this class to make program flow easier. 2018-05-31 Richard Larsson * arts-2-3-1068 * CMakeLists.txt: Forgot to remove some testcode... 2018-05-31 Richard Larsson * arts-2-3-1067 * controlfiles/*: Updating Zeeman checks for an upcoming change internally necessary for saving memory. Matches the lineshapes tests (I will add jacobian testing to these eventually) 2018-05-31 Oliver Lemke * arts-2-3-1066 * src/linefunctions.cc (Linefunctions::SingleLevelLineData::htp_dz1dt, Linefunctions::SingleLevelLineData::htp_dBdt): Use float literal instead of int when multiplying with a complex number. Fixes compilation with Intel compiler which can otherwise not decide whether it should cast the int to float or double. 2018-05-30 Richard Larsson * arts-2-3-1065 Testing to update numbers using non-native setup (If this does work, there is something wrong with my computer for Native build settings since Native build settings works for Oliver.) 2018-05-30 Richard Larsson * arts-2-3-1064 Forgot controlfiles 2018-05-30 Richard Larsson * arts-2-3-1063 * controlfiles/*: Added more lineshape tests so there is hopefully less bitrot in future. Also lowered relateive differences expected for the derivatives because it failed at different compiler settings * src/linefunctions.cc: Same fix for Lorentz, Doppler, HTP as for Voigt in a previous commit. Also changed so VMR is considered a line parameter because it behaves exactly as pressure broadening. This reduces errors in partial derivatives from ~VMR to near numerical noise. There is likely still some error remaining in this treatment because there are still some systematic errors, though these are much smaller than before... * src/linescaling.cc: Fixed error in dstimulated_relative_emission_dF0 which reduced errors for central line frequencies derivatives by a lot * src/pressurebroadeningdata.cc: Made VMR part of the pressure braodening derivatives. Presently only for species broadening themselves, so, e.g., O2 derivatives will not show up in H2O spectra. This means of course that the derivatives are incorrect... * src/quantum.cc: Fix bug where the ALL tag was passed as failure even though it works in the a > b comparisons (where > here means that b is a partial representation of a) 2018-05-29 Oliver Lemke * arts-2-3-1062 * src/legendre.{h,cc} (gsl_integration_glfixed_table_alloc): Add function from the GSL to compute Gauss-Legendre abscissae and weights necessary for an n-point fixed order integration scheme. The function has been adapted to use ARTS datatypes. * src/test_legendre.cc (test_gsl_int): Test g_i_g_t_a. * license/GPLv3: Put GPLv3 here. 2018-05-28 Simon Pfreundschuh * arts-2-3-1061 * src/m_retrieval.cc (retrievalDefInit): - Added flag to disable call to jacobianInit(...). * src/methods.cc (retrievalDefInit): - Updated method description. 2018-05-27 Patrick Eriksson * arts-2-3-1060 * src/m_fos.cc (iyHybrid): Fixed inconsistency around iy_aux_vars, reported by Simon. The handled options are now "Radiative background" and "Optical depth". Switched to optical depth to be consistent with iyEmissionStandard, and as the original plan. 2018-05-24 Simon Pfreundschuh * arts-2-3-1059 * src/m_rte.h (yCalcAppend): - Fixed handling of scattering species in the Jacobian. * src/m_cloudradar.cc (yCalcActive): - Fixed dimension of y_geo 2018-05-24 Oliver Lemke * arts-2-3-1058 * src/linefunctions.h (SingleLevelLineData): Remove namespace from friend declaration. Compiler assumes same namespace anyway. If the namespace is given explicitly the function must be declared beforehand, not after. Fixes compilation failure with Clang. Reported by Lukas. * src/absorption.cc (xsec_species2): Use a vector variable in ternary operator instead of a temporary object. Fixes runtime error in TestVoigt when compiling with Clang. 2018-05-23 Richard Larsson * arts-2-3-1057 Error rundown in the new lineshapes for Voigt ready. Also found inherent issue in current derivatives for VMR. VMR derivatives are today introducing an error of 1/(1-vmr) on the line shape itself. This was true for semi-analytic test cases as well but not for perturbed. The fix is to implement VMR derivatives for pressure broadening for the self-broadening component of a line. I will get on this at some point, but we mostly retrieve trace gases these days so the error is only important for more prevalent species... * controlfiles/*: Added test to fast for Voigt lineshape. Note that you cannot run the python plotting-script before you have the latest version of typhon (which I will commit around the same time as this commit) * src/absorption.cc: Fixed size of derivatives * src/jacobian.{cc,h}: Fixed *equivlent_propmattype_indexes* and the first-index calls to not point at wrong things... would not work if external derivatives were mixed in amongst the normal derivatives with old update... * src/linefunctions.cc: Moved line mixing derivatives around and separated the frequency derivatives of line mixing from the strength components because the old way was bad. Also scattered "#pragma omp simd" all over the place because 1) I do not understand the intel documentation on this function, and 2) there is a bunch of low level code that is doing exactly the same thing for each frequency so it should be possible to do these things in simd, though I see no differences in speed with these in place and I do not know if this is because the compiler cannot understand that it is supposed to do the same thing for each frequency... * src/linemixingdata.{cc,h}: Added some functions to change values * src/linescaling.{cc,h}: Fix bug in *dstimulated_relative_emission_dF0* * src/m_abs.cc: Fixed size error in derivative matrix in xsec init. Also renamed nlte-variables to fit workspace update * src/m_basic_types.cc: Added some more CompareRelative types * src/m_extract.h: Added extract for QuantumIdentifier * src/m_jacobian.cc: Fixed error in setting LM frequency shift derivatives... * src/m_linerecord.cc: Added a few more changeable variables to *abs_linesChangeParameterForMatchingLines* * src/methods.cc: Changed description and scope of *CompareRelative* to not throw an error for zero-values despite these being relatively bad. The function is only meant to compare input so if one vector is all zeroes, the test will now succeed, so be carful! I need this because I have many zero-crossings in the derivatives and special input (like having a f_grid point exactly on a non-shifted line center) can cause zero-values to appear naturally. * src/pressurebroadeningdata.{cc,h}: Updated to give proper derivatives for pressure (I had real-and-imaginary-and-sign errors in the past version) * src/propagationmatrix.h: Added initialization from Tensor4 * src/xml_io_compound_types.cc: Changed writing/reading of PropagationMatrix and StokesVector to be cleaner and fit with the current implementation rather than with the original commit... 2018-05-23 Patrick Eriksson * arts-2-3-1056 * src/m_surface.cc (surfaceTelsem): Added GIN options r_min and r_max. 2018-05-23 Simon Pfreundschuh * arts-2-3-1056 * src/m_oem.cc (xaStandard, x2artsStandards): - Fixed problem with calculation of jacobian range for affine transformations. * src/m_retrieval (covmat_sxAddBlock): - Added error handling for case when there are already more diagonal block in the covariance matrix than there are retrieval quantities. 2018-05-23 Simon Pfreundschuh * arts-2-3-1055 * src/methods.cc (covmat_sxSet): - Fixed bug in definition of *covmat_sxSet* reported by Dave 2018-05-23 Simon Pfreundschuh * arts-2-3-1054 * src/m_surface.cc (surfaceTelsem): - Added functionality for nearest neighbor interpolation, which can be enabled through the *d_max* GIN * src/methods.cc (surfaceTelsem): - Updated documentation of surfaceTelsem 2018-05-22 Simon Pfreundschuh * arts-2-3-1053 * src/rt4.cc (run_rt4) - Fixed arguments to par_optpropCalc call which caused Tensor out of bounds access when number of streams was increased. 2018-05-22 Simon Pfreundschuh * arts-2-3-1052 * geodetic.[h, cc] (cycle_lat_lon): - Added function the wraps lat/lon coordinates into ranges [-90.0, 90.0] and [0.0, 360.0] * m_telsem.cc (telsemStandalone): - Added functionality for nearest neighbor interpolation * methods.cc (telsemStandalong): - Updated documentation of telsemStandalone * telsem.[h, cc] (calc_cellnumber_nearest_neighbor): - Added function that calculates cellnumber of nearest cell in atlas w.r.t. to L1 norm. 2018-05-20 Patrick Eriksson * arts-2-3-1051 * src/m_surface.cc (surfaceFastem): Removed specular_los as input. Now calculated internally. * src/m_ppath.cc (geo_posEndOfPpath) (geo_posLowestAltitudeOfPpath, geo_posWherePpathPassesZref): * src/m_rte.cc (yCalc): * src/rte.cc (iyb_calc): Adopte to new definition of geo_pos. * src/workspace.cc: Changed definition of geo_pos. It is now a vector of length 5. y_geo adopted. 2018-05-18 Richard Larsson * arts-2-3-1050 * src/CMakeLists.txt: Added way for test_propagationmatrix to see global data. * src/linegunctions.{cc,h}: Fixed bug with id * arts-2-3-1049 With this commit we can compute proper nlte_field inside ARTS with both LI and MALI methods. This is thanks to Takayoshi Yamada's contributions! (We hope to have a paper out soonish which will contain a full description of the implemented theory) * controlfiles/*: Added test for NLTE-field computations. Notice the old NLTE test fails so I will spend some time later debugging (this failure is also there with the version before this). Also added ppvar_trans_partial to hold trans_partial for output * src/workspace.cc: Added nlte_collision_identifiers as ArrayOfQuantumIdentity for finding which line is which in nlte_collision_coefficients, which is also added to contain temperature coefficients for collisional effects such that the statistical equilibrium matrix can be computed. * src/absorption.cc: Removed verbosity input to pressure broadening. This was way to verbose such that no information could be gained from screen output. I believe the verbosity levels need a proper review to remove or change new behavior (e.g., the fact that Agenda-calls are so common at lower levels now that them printing to out2 hides all important information) * src/jacobian.cc,h: Consolidated NLTE jacobian types in name * src/linefunctions.cc,h: See the two above. Also added some copy-paste code for a class that should compute all line parameters beforehand. I think this way will allow proper parallelization of line xsec code, but this might be at the cost of memory. If used for single line at a time it is still fine, and then the code will make the line functions clearer because, e.g., HTP code has a lot of pathing for frequency parameters, making it a bit complicated in normal use * src/linerecord.h: Added helper call to get the effective g-factor for Zeeman * src/m_basic_types.cc: Added CompareRelative for Tensor4 * src/m_fos.cc: Added dummy variable to call to iyEmissionStandard * src/m_jacobian.cc: See "src/jacobian.cc,h" above. * src/m_nlte.cc: Added nlte_collision_factorsCalcFromCoeffs, which should be a proper method in the future when an nlte agenda has been defined. Also use this in nlte_fieldForSingleSpeciesNonOverlappingLines instead of older code because its units were way off. Also set iteration limits to tell the code to either stop or be happy it reached sufficient convergence * src/m_radiation_field.cc: non-LTE requires local transmission ratios and not global once, which were implemented after previous mistaken attempts/communication by myself. This is required by multilevel approximations of lambda iteration method. * src/m_rte.cc: Added ppvar_trans_partial as output to iyEmissionStandard * src/methods.cc: Changed defaults and inputs to a few functions * src/nlte.cc,h: Fix of the SEE matrix solvers. Now LI and MALI both works in ARTS (solong as collisional coefficients are provided. Future updates to make this more advanced will have to implement ways to get more date into these SEE matrices as demand for more advanced computations are needed) * src/partial_dertivatives.cc: See "src/jacobian.cc,h" above. * src/pressurebroadeningdata.cc,h: See "src/absorption.cc" above. * src/test_propagationmatrix.cc: See "src/absorption.cc" above. 2018-05-15 Simon Pfreundschuh * arts-2-3-1048 * arts_api.[h, cc] (get_variable_value, set_variable_value) - Expanded methods to also handle tensors of dimensions 5, 6, 7 * interactive_workspace.[h, cc] (set_tensor[5,6,7]_variable) - Added methods for settings tensors of dimensions 5, 6, 7 2018-05-14 Simon Pfreundschuh * arts-2-3-1047 This is breaking OEM controlfiles. inversion_iterate_agenda now needs to make use of *inversion_iteration_counter*. Quickfix: Add Ingore(inversion_iteration_counter) to your defintion of inversion_iteration_agenda. * agendas.cc (inversion_iterate_agenda): - Added inversion_iteration_counter to input arguments. * workspace.cc (inversion_iteration_counter): - Fixed spelling * agenda_wrapper.h - Added counter to hold iteration step. * matpackII.[cc, h] (diagonal): - Added function to extract diagonal from sparse matrices. * covariance_matrix.[cc, h]: - Added function to extract diagonal from covariance matrices. * test_covariance_matrix.cc (test_diagonal): - Added test to check extraction of diagonal * m_retrieval.cc (covmat_sxExtractSqrtDiagonal): - Added function to extract square root of diagonal of covmat_sx. * methods.cc (covmat_sxExtractSqrtDiagonal): - Added entry for covmat_sxExtractSqrtDiagonal * controlfiles/artscomponents/oem/TestOEM.arts - Adapted definition of inversion_iterate_agenda * controlfiles/artscomponents/agendas/TestAgendaExecute.arts - Adapted definition of inversion_iterate_agenda and added initialization of *inverstion_iteration_counter* 2018-05-06 Jana Mendrok * arts-2-3-1046 * src/optproperties.[cc,h] (FouComp_1ScatElem): Finished this one. Not tested or applied anywhere yet. 2018-05-04 Oliver Lemke * arts-2-3-1045 * src/absorption.cc (xsec_species2): Cache non-changing views in loop for a 40% speedup in the non-binary part. 2018-05-03 Richard Larsson * arts-2-3-1044 * src/absorption.cc: Changed interface for binary-speedup calculations. Still needs some more work to check errors * src/linefunctions.{cc,h}: Moved away from the arrays for derivatives, allowing all functions to drop the range input. Also changed binary-speedup to act outside of the main line functionality * src/linerecord.{cc,h}: Changed binary speedup parameters * src/matpackI.{cc,h}: Added ostream output for Range to help debugging.. 2018-05-02 Patrick Eriksson * arts-2-3-1043 * TODO: Let's use this file to make notes about Todo-s until we have decided what ticket system to use. And maybe we need this file anyhow, to keep track of things that either of larger scope or don't yet have a clear owner. Added two points. * src/rte.cc (ext2trans): The code from Landi Degl'Innocenti and Landolfi (2004) is now used only for stokes_dim==2. Did not work for stokes_dim==3, as reported by Jana. 2018-05-01 Jana Mendrok * arts-2-3-1042 * src/optproperties.[cc,h] (ssd_tinterp_parameters): Outsourced identical code from *1ScatElem for temp interpolation preparation. (opt_prop_1ScatElem, pha_mat_1ScatElem): Use ssd_tinterp_parameters function. (pha_mat_1ScatElem): Revised PTYPE_AZIMUTH_RND branch, simplifying stokes_dim optimized code. (FouComp_1ScatElem): Work in progress. Separate method for extracting Fourier series components per scat element from scat_data. No sense in first extracting pha_mat, then deriving fourier component(s) from that either degrading or blowing up data. Instead derive it directly from scat_data's pha_mat_data. So far only up to stokes_dim=2 and 0th Fourier component as required for RT4. * src/rt4.cc (run_rt4_new): Work in progress (so far moslty a working copy of run_rt4) for RT4 using unified scattering data scheme throughout. 2018-04-27 Jana Mendrok * arts-2-3-1041 * src/optproperties.cc (pha_mat_1ScatElem): Some minor polishing on top of arts-2-3-1029 changes, which already fixed the main issues. * controlfiles/artscomponents/disort/TestDISORT.arts: Use new optprop scheme in test case. 2018-04-27 Oliver Lemke * arts-2-3-1040 * cmake/modules/FindFFTW.cmake: Fix docs. 2018-04-26 Oliver Lemke * arts-2-3-1039 * CMakeLists.txt: Always enable Hitran Xsec code even if the FFTW library is not available. * src/m_hitran_xsec.cc (abs_xsec_per_speciesAddHitranXsec): Output a very clear warning to out0 that computation will extremely slow without FFTW. Remove implementation of abs_xsec_per_speciesAddHitranXsec that throws a runtime-error if FFTW library is not available. * src/main.cc (main): Adapt output of information about Hitran Xsec support. * controlfiles/artscomponents/hitran-xsec/TestHitranXsec.arts: Reduce number of pressure levels. 2018-04-26 Oliver Lemke * arts-2-3-1038 * src/absorption.cc (xsec_species): Removed debug output for Theresa Lang. Instead, provided her a patch that writes the information directly to a file. 2018-04-24 Oliver Lemke * arts-2-3-1037 * controlfiles/CMakeLists.txt: Only run TestWfunsHybCloudy if RT4 is available. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Consistent naming for reference files. * controlfiles/artscomponents/wfuns/JHyb_O2_analyticalREFERENCE.xml.gz, controlfiles/artscomponents/wfuns/JHyb_O3_analyticalREFERENCE.xml.gz, controlfiles/artscomponents/wfuns/JHyb_OtherREFERENCE.xml.gz, controlfiles/artscomponents/wfuns/JHyb_T_analyticalREFERENCE.xml.gz, controlfiles/artscomponents/wfuns/JHyb_WindsREFERENCE.xml.gz, controlfiles/artscomponents/wfuns/yHyb_O3_analyticalREFERENCE.xml.gz: Generated reference files. 2018-04-23 Richard Larsson * arts-2-3-1036 Fix of error I unknowingly introduced with last commit * src/absorption.cc: Added line check for LM params. * src/jacobian.{cc,h}: Added single equivalent index function * src/rte.{cc,h}: This fixes two broken slow tests but arts.ctlfile.slow.artscomponents.wfuns.TestWfunsHybCloudy still fails with the error: "This version of ARTS was compiled without RT4 support." * src/m_*.cc: Removed the position variable which was the cause of the errors 2018-04-23 Patrick Eriksson * arts-2-3-1035 * src/m_cloudradar.cc (iyActiveSingleScat): Added weighting with inverse of local trans_partial in calculation of Jacobian transmission part. This part is approximate, for efficiency reasons. Now hopefully a bit less approximate. 2018-04-20 Richard Larsson * arts-2-3-1034 Removed PropmatPartialsData class. Also removed mspecies, misotopologue, and mquantum_numbers from LineRecord to replace them with a QuantumIdentifier so that each line can return references to their ID rather than having to recreate a new ID every time * files: Many small changes were required for the above changes. At least the "make check" commands seems slightly faster 2018-04-20 Oliver Lemke * arts-2-3-1033 * src/m_hitran_xsec.cc (abs_xsec_per_speciesAddHitranXsec): Take into account recent Jacobian changes. 2018-04-20 Patrick Eriksson * arts-2-3-1032 * src/m_jacobian.cc (PrivateTesting1,PrivateTesting2): Missed to comment these methods. For the moment my personal sandbox for testing out some retrieval tricks. Some small changes. 2018-04-19 Patrick Eriksson * arts-2-3-1031 * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): * src/m_fos.cc (iyHybrid): * src/m_cloudradar.cc (iyActiveSingleScat): * src/rte.cc (rtmethods_jacobian_init): Adoption due to change in get_pointers_for_analytical_jacobians. * src/jacobian.cc (get_pointers_for_analytical_jacobians): Now considering cloudbox_on when setting scat_species_i. * src/m_rt4.cc (RT4Calc): Moved message for if( !cloudbox_on ) from OUT0 to OUT1. * src/m_microphysics.cc (pnd_fieldCalcFromParticleBulkProps): Now does absolutely nothing if cloudbox_on = 0. * src/workspace.cc: Introduced inversion_iteratation_counter. 2018-04-18 Richard Larsson * arts-2-3-1030 * src/jacobian.{cc,h}: Copy-pasted out functions required to remove PropmatPartialsData class. * src/m_jacobian.cc: Added quantum-id tag to for_species_tag false statements. This to keep single tag for internal and external vmr derivatives (the internals will only look for the species and not at the tag at this point because that is how it is implemented). Also, I am now setting JacPropMatType for relevant analytical expressions. * src/m_nlte.cc: Added scaling function. This because it is needed to work with certain nonlte scenarios. Could have placed this in abs_vmrs, however using pressure for anything is nonsense in other nonlte scenarios so this variable will likely have to be adopted to provide true nd values at some point in this evolving code... * src/m_atmosphere.cc: Changed so self-consistent partition functions can be used instead of only external partition functions. Required for some cases. This makes the forward calculations for LTE wrong, however, because it carries implicit assumptions on the number densities not following strictly p/kT... 2018-04-18 Patrick Eriksson * arts-2-3-1029 * src/optproperties.cc (pha_mat_1ScatElem): I got some weird results and managed to track down the problem to this function. Made some small changes to get my case to work. Will check with Jana before doing remaining changes. Note: Scattering simulation with stokes_dim > 1 can be wrong to unfixed issues in this function. 2018-04-17 Richard Larsson * arts-2-3-1028 Reviewing RetrievalQuantity and PropmatPartialsData, as they serve the same purpose. PropmatPartialsData has grown out-of-control and is difficult to understand. The main purpose of it has been to 1) check if the derivative is possible inside the functions themselves (e.g., "supportsCIA()"), 2) to keep the size of the internal derivatives (i.e., "mreal_nelem"), 3) keep track of variables that have to be precomputed (e.g., temperature derivates for line broadening), and 4) to simplify computations where repetition is not needed, (e.g., "mfirst_pressure"). All these 4 can be achieved with different external methods to the class however, so its existence should not be necesseray. (It would have required a lot more work to not have this class from the beginning when I started making the change to more analytical Jacobian computations, but now that these are de facto default, it just adds complexity to the problem to keep this calss around. This commit is moving and renaming some things to fit make it easier to remove PropmatPartialsData. Presently the functionality is identical as to how it were before but this will change. (I will send some questions to the dev-mailing list so please leave comments there.) * files: Renaming, naming, removing, and moving variable definitions. No change in functionality 2018-04-17 Patrick Eriksson * arts-2-3-1027 * src/m_fos.cc (iyHybrid): Just removed inactive code. * src/rte.cc (get_stepwise_scattersky_source): Did not work for stokes_dim > 1. Fixed, and some testing done. * src/m_rte.cc (iyCalc,yCalc): Just added some \n in error message. 2018-04-17 Richard Larsson * arts-2-3-1026 * 3rdparty/relmat/arts_interface.F90: Now takes the dipoles returned to ARTS main for computing Rosenkranz parameters *3rdparty/relmat/module_linemixing.F90: (LM_2ord) and (LM_Rosen) now removes the doubles pressure terms to fit with Smith 1981 * src/linerecord.h: GetMirroringType → SetMirroringType * src/m_linemixing.cc: Added test functions for computing Rosenkranz parameters external from relmat. * m_nlte.cc: Changed to use Patrick's plane parallel geometry so that testing can happen faster * src/m_radiation_field.cc: Changed to use Patrick's plane parallel geometry for testing purposes. To use different geometry can happen later * src/methods.cc: Changed interface to rotational nlte functions to simplify them for testing * src/nlte.cc: Updated LI SEE matrix definition following Taka's advice. Still needs more testing * controlfiles/CMakeLists.txt: Turned off relmat test because the old numbers are likely wrong. (After some testing the produced line mixing coefficients scaled wrongly with pressure) I will reactivate this test once I have more time to get into all the details. (I think the present version is correct) 2018-04-16 Patrick Eriksson * arts-2-3-1025 * The ELL07 and MPM models for liquid absorption now accept that the values outside the accepted temperature range is < 1e-10, and not exactly zero. This needed to make retrievals practically possible. * src/continua.cc (ELL07WaterDropletAbs, MPM93IceCrystalAbs) (ELL07WaterDropletAbs, xsec_continuum_tag): See above. Also improved error messages. * src/methods.cc: Corrected text for jacobianSetFuncTransformation 2018-04-14 Patrick Eriksson * arts-2-3-1024 * Tested iyHybrid. Fixed a small problem for Jacobians. * src/m_fos.cc (iyHybrid): Just removed code that was behind comments. * src/rte.cc (get_stepwise_scattersky_source_old): Removed. (get_stepwise_scattersky_source): dSp_dx[iq] was not filled with zeros when needed. * src/m_ppath.cc (ppathPlaneParallel): Upper cloudbox boundary at top of the atmosphere and sensor in space was not handled correectly. 2018-04-13 Patrick Eriksson * arts-2-3-1023 * src/m_fos.cc (iyHybrid): Added check that ppath is calculated with cloudbox deactivated. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: * controlfiles/artscomponents/hybridscat/TestHybrid.arts: * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Adopted to change below. * src/m_ppath.cc (ppathCalc): Removed GIN ignore_cloudbox. Not needed. Same functionality is obtained by just calling the method with cloudbox_on=0. 2018-04-11 Oliver Lemke * arts-2-3-1022 * src/absorption.cc (xsec_species): Only generate extra info output if it will be visible. 2018-04-12 Patrick Eriksson * arts-2-3-1021 * The lower limit for log, log10 and atanh transformations can now be tuned. * src/jacobian.cc (transform_x_back, transform_jacobian,transform_x): Code adopted to z_min and z_max. * src/m_jacobian.cc (jacobianSetFuncTransformation): Improved error message if selected transformation function is invalid. There is now two GIN, z_min and z_max. * src/jacobian.h (RetrievalQuantity): Opened up for multiple tfunc_parameters. 2018-04-12 Patrick Eriksson * arts-2-3-1020 * Core functionality for surface retrievals should now be in place. In addition, retrievals with an upper bound is now possible, with the atanh option. As for log and log10 the lower bound is 0. Seems to work, but if it is of practical use is to be proven. * src/m_oem.cc (x2artsStandard): x was still used for pointing off-set and baseline fit. Now using x_t. Added handling of surface_prop_data. (xaStandard): Added handling of surface_prop_data. (get_gp_atmsurf_to_rq,get_gp_rq_to_atmgrids): New functions. * src/special_interp.cc (regrid_atmsurf_by_gp): New function. * src/surface.cc (surface_props_check,surface_props_interp,dsurface_check): Now placed in this file. * src/m_surface.cc (dsurface_locate): Removed (SurfaceTessem): Using find_first instead of dsurface_locate. * src/jacobian.cc (check_retrieval_grids): A dummy grid is now set for atmosphere_dim==1. * src/m_retrieval.cc (retrievalAddSurfaceQuantity): New. * src/jacobian.cc (transform_x): Added checks for log, log10 and atanh that x is inside OK range. For example, the log option requires that x>0. (transform_x_back, transform_jacobian,transform_x): tfunc_parameter now applied for atanh. * src/m_jacobian.cc (jacobianSetFuncTransformation): Added GIN to set tfunc_parameter. * src/jacobian.h (RetrievalQuantity): Added tfunc_parameter as private variable. 2018-04-11 Patrick Eriksson * arts-2-3-1019 * src/jacobian.cc (transform_x_back, transform_jacobian) (transform_x): * src/m_jacobian.cc (jacobianSetFuncTransformation): Start on adding atanh as retrieval transformation. 2018-04-11 Patrick Eriksson * arts-2-3-1018 * src/m_oem.cc (xaStandard): The tripple-loopes involving i1, i2 and i3 were wrong. Problem was that <= was used instead of <. 2018-04-10 Patrick Eriksson * arts-2-3-1017 * Introduced water_psat_agenda. * src/m_nlte.cc (nlte_fieldForSingleSpeciesNonOverlappingLines): Adopted call of radiation_fieldCalcForRotationalNLTE. * src/m_radiation_field.cc (radiation_fieldCalcForRotationalNLTE): Adopted call of radiation_fieldCalcFromiyCalc. * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel): (radiation_fieldCalcFromiyCalc): Adopted call of iyEmissionStandard. * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): * src/m_fos.cc (iyHybrid): * src/m_cloudradar.cc (iyActiveSingleScat): Adopted call of rtmethods_jacobian_finalisation. * src/rte.cc (rtmethods_jacobian_finalisation): * src/m_oem.cc (x2artsStandard, xaStandard): Now using water_psat_agenda. * src/rte.cc (psat_water): Removed this temporary solution. * src/m_physics.cc (water_psat_fieldMK05): New WSM. * src/workspace.cc: Introduced water_psat_field. * src/agendas.cc: Introduced water_psat_agenda. 2018-04-10 Stefan Buehler * arts-2-3-1016 * src/absorption.cc (xsec_species): Added writeout of line strength information to out3 for Theresa Lang. This should be commented out again after Theresa no longer needs it. Just search for Theresa, her name is in the comment above the code. 2018-04-10 Patrick Eriksson * arts-2-3-1015 * src/m_surface.cc (iySurfaceRtpropCalc): Should now also work for 2D and 3D, but not tested. * src/jacobian.cc (diy_from_pos_to_rgrids): New function. * src/rte.cc (rtmethods_jacobian_init): Size diy_dx also for surface variables by using FOR_ANALYTICAL_JACOBIANS_DO2. 2018-04-10 Patrick Eriksson * arts-2-3-1014 * src/rte.cc (iyb_calc_body, iyb_calc) (rtmethods_unit_conversion): * src/m_rte.cc (yCalc_mblock_loop_body): Changed from using FOR_ANALYTICAL_JACOBIANS_DO to using FOR_ANALYTICAL_JACOBIANS_DO2. * src/jacobian.h (FOR_ANALYTICAL_JACOBIANS_DO2): New macro. * src/m_surface.cc (iySurfaceRtpropCalc): Added dsurface_names, dsurface_rmatrix_dx and dsurface_emission_dx as input. Added code for calculating surface Jacobian. So fra only 1D works. * src/m_fos.cc (iyHybrid): * src/m_rte.cc (iyEmissionStandard): Adopted call of get_iy_of_background. * src/rte.cc (get_iy_of_background): Added jacobian_quantities and iy_agenda_call1 as input variables. dsurface_names now set based on jacobian_quantities. (iy_transmission_mult): A new version of the function, operating on iy. 2018-04-10 Oliver Lemke * arts-2-3-1013 * src/make_auto_md_h.cc: Properly mark in/out WSV as such in doxygen documentation. Reported by Richard. 2018-04-09 Patrick Eriksson * arts-2-3-1012 * src/jacobian.cc (check_retrieval_grids): Made version for surface variables. * src/m_jacobian.cc (jacobianAddSurfaceVariable): New. 2018-04-09 Richard Larsson * arts-2-3-1011 * src/CMakeLists.txt: Added on datarecord for linerecord and removed another. * src/absorption.{cc,h}, src/linefunctions.{cc,h}, src/m_abs.cc: * src/m_zeeman.cc, src/methods.cc, src/workspace.cc: Removed Zeeman splitting vector * src/linerecord.{cc,h}: Removed obsolete partition function by linerecord and added a Zeeman effect record. Writing and reading still needs testing. It should write and store the splitting and polarization expected of the line. This should allow to input external g-factors directly via the linerecord * src/linerecord_partitionfunctiondata.{cc,h}: deleted * src/zeeman.{cc,h}, (added) src/zeemandata.{cc,h}: Changed interface so that the splitting is known by the line. Moved many tests into the new ZeemanEffectData class. 2018-04-09 Patrick Eriksson * arts-2-3-1010 Another small step towards surface Jacobians. Main change is that iy_surface_agenda has some new in- and output. You fix this most easily by adding a call of SurfaceDummy in this way: AgendaSet( iy_surface_agenda ){ SurfaceDummy iySurfaceRtpropAgenda } The defintion of iy_surface_agenda in agendas.arts is updated and included this change, so most likely you don't need to do anything. * src/m_nlte.cc (nlte_fieldForSingleSpeciesNonOverlappingLines): * src/m_radiation_field.cc (radiation_fieldCalcForRotationalNLTE): Adopted call of radiation_fieldCalcFromiyCalc. * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel) (radiation_fieldCalcFromiyCalc) * src/m_fos.cc (iyHybrid): Adopted call of iyEmissionStandard. * src/m_fos.cc (iyHybrid): * src/m_rte.cc (iyEmissionStandard): Adopted call of get_iy_of_background. * src/rte.cc (get_iy_of_background): Started to add handling of surface_props_data and associated variables. * controlfiles/general/general.arts: surface_props_data and surface_props_names now set to be empty. * controlfiles/general/agendas.arts: Added call of SurfaceDummy to iy_surface_agenda__UseSurfaceRtprop. * src/m_surface.cc (SurfaceDummy): New. * src/agendas.cc: For iy_surface_agenda added dsurface_rmatrix_dx and dsurface_emission_dx as in/output, and surface_props_data and dsurface_names as input. 2018-04-04 Jana Mendrok * arts-2-3-1009 Major redo of optical property (incl phase mat) extraction and preparation for Disort. Some further optimizations to come... * src/disort.[cc,h] (get_gasoptprop, get_paroptprop, get_dtauc_ssalb): Separated dtauc_ssalbCalc(2) into these in order to have ext/abs_par directly accessible and avoid their recalc in phase function calculation. * src/disort.[cc,h] (get_angs, get_parZ, get_pfct, get_pmom): New methods applying unified phase matrix extraction scheme. To replace phase_functionCalc(2) and pmomCalc(2). * src/m_disort.cc, methods.cc (DisortCalc), disort.[cc,h] (run_disort2): Adapted interface allowing user to control angular resolution of bulk phase function (from which the legendre polynomials are calculated then). * src/optproperties.cc (pha_mat_labCalc): Layout fixes. 2018-04-03 Richard Larsson * arts-2-3-1008 * controlfiles/artscomponents/linemixing/TestRelmat.arts: Added call to wigner6init. * src/m_wigner.cc: Added a few wigner functions that has to be used to initialize memory mapping. These only work in single core for now before there is a good way to write to the table in sycn on multi-core (I do not know how to do this) * src/m_linemixing.cc: Minor changes... * src/wigner_functions.cc, src/wigner_functions.h: All calls need external initialization. No check is made so it is up to devs to make sure this have happened in the calls to whatever method is being used... * src/{workspace,methods}.cc: Added a variable to keep track that the wigner memory is initialized. 2018-04-02 Patrick Eriksson * arts-2-3-1007 * src/m_jacobian.cc (jacobianAddAbsSpecies) (jacobianAddConstantVMRAbsSpecies, jacobianAddScatSpecies) (jacobianAddTemperature, jacobianAddWind, jacobianAddMagField) (jacobianAddCatalogParameter, jacobianAddSpecialSpecies): Now adding jacobianCalcDoNothing. (jacobianCalcDoNothing): Replaces the methods below. (jacobianCalcWindAnalytical): (jacobianCalcMagFieldAnalytical): (jacobianCalcTemperatureAnalytical): (jacobianCalcAbsSpeciesAnalytical) (jacobianCalcScatSpeciesAnalytical): Removed 2018-04-01 Patrick Eriksson * arts-2-3-1006 * A small start towards surface Jacobians. * src/m_surface.cc (SurfaceTessem): New version of surfaceTessem, adopted to new variables. * src/workspace.cc: Added surface_props_data, surface_props_names, dsurface_names, dsurface_rmatrix_dx and dsurface_emission_dx. * src/special_interp.cc (rte_pos2gridpos): Added a version of the function for surfaces. 2018-04-01 Richard Larsson * arts-2-3-1005 * src/m_linemixing.cc: Bug fix for non-fortan compiling 2018-03-29 Jana Mendrok * arts-2-3-1004 * src/rte.[cc,h] (get_stepwise_scattersky_source): New version applying unified phase matrix extraction scheme. Old version for now moved into get_stepwise_scattersky_source_old. New version calculates scattered field in prop direction directly, instead of by linear interpolation of fields for two propagation polar angles included in the input field as required by the old, DOIT-type pha_mat extraction method. This changes test results by up to 0.1K, but should be the more accurate solution. * src/m_fos.cc, methods.cc (iyHybrid): Adapt interface to new get_stepwise_scattersky_source. Allow user to select temperature interpolation order. * src/m_cloudradar.cc (iyActiveSingleScat): Bugfix. Consider case with multiple freq in f_grid, but only single freq in scat_data. * controlfiles/artscomponents/hybridscat/yREFERENCE.xml: New reference results reflecting changes in get_stepwise_scattersky_source. 2018-03-29 Richard Larsson * arts-2-3-1003 * 3rdparty/relmat/arts_interface.F90: Fix bug in relative temperatures. Made the outputs of population densities and reduced dipole behave as expected for both methods. * src/CMakeLists.txt: Added a species_info.{cc,h} because I tend to need so many small things that are practically constants for molecules, so it helps to put these in clear files for overview * src/species_info.{cc,h}: Contains some Zeeman constants and some reduced dipole computations required to find the sign of a dipole. Only tested for CO2 * src/zeeman.{cc,h}: moved some constants * src/m_linemixing.cc: Changed so the full inversions are performed when the order of line mixing is negative. Also performs ordered line mixing when pressure is below lm_p_lim to speed these up a bit. Also added two control parameters to the input of the function with reasonable limits. These changes are mostly tested but I will only know if they are good after running through a test over the weekend... the important part of the code is somewhat slow now since it requires 140 inversions of matrices sized 80x80 to 300x300 per atmospheric level per frequency to compute the absorption coefficients... 2018-03-28 Jana Mendrok * arts-2-3-1002 * src/montecarlo.[cc,h] (Sample_los): Replaced phase matrix extraction with new system. * src/m_montecarlo.cc, methods.cc (MCGeneral): Adapted Sample_los call. Allow user to select temperature interpolation order. * src/m_rte.cc, methods.cc (iyMC): Adapted MCGeneral call. Allow user to select temperature interpolation order. 2018-03-28 Jana Mendrok * arts-2-3-1001 * src/m_cloudradar.cc (iyActiveSingleScat), src/m_montecarlo.cc (MCRadar), methods.cc: Replaced phase matrix extraction with new system. Allow user to select temperature interpolation order. * src/optproperties.cc: Minor spell fix. 2018-03-28 Patrick Eriksson * arts-2-3-1000 * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel): iy_main_agenda given to iyEmissionStandard etc. is now defined inside the method. 2018-03-28 Oliver Lemke * arts-2-3-999 * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel): Parallelize zenith angle loop. 2018-03-27 Patrick Eriksson * arts-2-3-998 * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel): Now also returns transmission data. 2018-03-27 Patrick Eriksson * arts-2-3-997 * src/m_radiation_field.cc (doit_i_fieldClearskyPlaneParallel): New method. Seems to work, but some details should be fixed. * src/m_ppath.cc (ppathPlaneParallel): Decreased forbiiden za-range to 89.9-90.1. * src/m_rte.cc (ppvar_optical_depthFromPpvar_trans_cumulat): New WSM. * src/m_fos.cc (iyHybrid): * src/m_radiation_field.cc (radiation_fieldCalcFromiyCalc): Adopted call of iyEmissionStandard. * src/m_cloudradar.cc (iyActiveSingleScat): * src/m_fos.cc (iyHybrid): * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): ppvar_trans_cumulat is now an output variable. * src/workspace.cc Added ppvar_trans_cumulat and ppvar_optical_depth. 2018-03-25 Jana Mendrok * arts-2-3-996 * src/m_optproperties.cc, methods.cc (TestScatDataInterp): Added section testing pha_mat extraction using new unified system. Made compare capability better selectable and updated doc. Added diff threshold of compare as user parameter. * src/optproperties.cc (pha_mat1ScatElem): Bugfixes in az-rand branch triggered by TestScatDataInterp. * src/optproperties.h (pha_mat_1ScatElem, pha_matNScatElems): Added missed default for t_interp_order. 2018-03-24 Jana Mendrok * arts-2-3-995 * src/optproperties.[cc,h] (pha_matBulk, pha_matScatSpecBulk, pha_matNScatElems, pha_mat1ScatElem): Implemented suite of new/replacement methods for consistent phamat extraction over the scattering solvers. (scat_angle, interpolate_scat_angle, pha_matTransform): Moved scattering angle calculation out of interpolate_scat_angle into separate function for re-usability. * src/xml_io_compound_types.cc (xml_read_from_stream for SingleScatteringData), src/disort.cc (check_disort_input), src/rt4.cc (check_rt4_input, par_optpropCalc, sca_optpropCalc): Removed some leftover references to old ptype enums (p10/20/30) in error messages, variable names and comments. * doc/uguide/clouds.tex: Minor fixes. 2018-03-22 Simon Pfreundschuh * arts-2-3-994 * src/m_psd.cc psdD14: Added WSM to compute DARDAR normalized PSD. * src/methods.cc psdD14: Added entry for new WSM * src/math_funcs.[h,cc] delanoe_shape_with_derivative: Added function to compute shape for DARDAR PSD. 2018-03-20 Oliver Lemke * arts-2-3-993 * src/xml_io_compound_types.cc, src/m_jacobian.cc: Fix spelling of pertubation -> perturbation. This fixes the spelling in the 'name' attribute in tags of the lookup table (name="TemperaturePerturbations", name="NonlinearSpeciesVmrPerturbations"), but does not break backwards compatibility currently, since the names are not needed when reading the file. * controlfiles/artscomponents/doitbatch/abs_lookupBatch.xml, controlfiles/artscomponents/montecarlo/gas_abs_lookup.xml, controlfiles/testdata/testdoit_gas_abs_lookup.xml: Updated. 2018-03-19 Patrick Eriksson * arts-2-3-992 * src/methods.cc: Extended description of jacobianSetAffineTransformation and jacobianSetFuncTransformation, to clarify that transformations are applied by jacobianAdjustAndTransform. 2018-03-18 Patrick Eriksson * arts-2-3-991 * src/m_cloudradar.cc (iyActiveSingleScat): Added GIN to ignore transmission in Jacobian calculations. Saves about 30% in calculation time. Also added code to actually include the transmission in the Jacobian. Obtain good fit with perturbations but there could still be some smaller indexing issues. 2018-03-16 Richard Larsson * arts-2-3-990 Still missing: update to NLTE computations required... * controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_GHz.arts: removed unused variable so the test now succeeds. * doc/uguide/absorption.tex: Removed reference to removed variable and slightly updated the text, adding some errata that has been pointed out in the Zeeman paper. This part will likely be updated in the future again as an ongoing review at Chalmers shows whether the changes give reliable results or not... 2018-03-16 Patrick Eriksson * arts-2-3-989 * src/sensor.cc (stokes2pol): Old version now completely removed. New version gives short and more clear code in calling function. * src/sensor.cc (met_mm_polarisation_hmatrix, stokes2pol): * src/m_sensor.cc (sensor_responsePolarisation): * src/m_transmitter.cc (iy_transmitterMultiplePol) (iy_transmitterSinglePol): Now using the new version of stokes2pol. * src/m_cloudradar.cc (iyActiveSingleScat): Another bug for particle extinction as aux variable. 2018-03-15 Patrick Eriksson * arts-2-3-988 * src/m_cloudradar.cc (iyActiveSingleScat): Fixed a bug for iy_aux when f_grid had more than element. (yActive): Now using new version of stokes_pol. This allowed to replace some loops with matrix-vector multiplication. * src/sensor.cc (stokes2pol): A new version of this function. This version has a proper checking that stokes_dim is sufficient for selected polarization. * src/methods.cc: Fixes in description of iy_transmitterSinglePol and iy_transmitterMultiplePol. * src/workspace.cc: Improved text for instrument_pol. 2018-03-15 Patrick Eriksson * arts-2-3-987 * src/m_cloudradar.cc (iyActiveSingleScat): Added the option pext_scaling. Implemented handling of these iy_aux_vars: Radiative background, Backscattering, Optical depth and Particle extinction. (yActive): Added mapping of iy_ayx to y_aux. 2018-03-15 Oliver Lemke * arts-2-3-986 * src/interactive_workspace.cc (InteractiveWorkspace::execute_workspace_method): Output method name in the API the same way the ARTS executable does. 2018-03-14 Oliver Lemke * arts-2-3-985 * src/m_abs.cc (abs_xsec_per_speciesAddLines2): Function was accidentally defined inside the else part of ifdef ENABLE_NETCDF. Which means compilation broke if netcdf was enabled. 2018-03-13 Patrick Eriksson * arts-2-3-984 * Cleaning! Compared to last commit, hopefully no impact at all. Just removed code that is inactive, mainly since last commit but found some very old stuff as well. * src/rte.cc: About 10 functions removed. * src/jacobian.cc: * src/m_jacobian.cc: * src/m_cloudradar.cc: * src/m_rte.cc: * src/m_transmitter.cc: 1-2 functions removed. 2018-03-13 Patrick Eriksson * arts-2-3-983 * With this commit the new set of iy-methods are "activated". That is, e.g. what has been iyEmissionStandard2 for some time is now iyEmissionStandard. Soem specific changes listed below, while bug fixes and adoptions not commented. For a high-level description, see email to arts-dev and arts-users. * src/m_rte.cc (iy_auxFillParticleVariables): Removed. Can not be performed with new version of iy_aux. * src/workspace.cc: iy_aux is now a ArrayOfMatrix. * doc/uguide/faraday.tex: * doc/uguide/transmission.tex: Commented out parts refering to iyRadioLink. * doc/uguide/rte.tex: Removed paragraph around iy\_auxFillParticleVariables. 2018-03-13 Richard Larsson * arts-2-3-982 * src-propagationmatrix.h: Added a check to see if the propagation matrix is only rotating at a given position * src/rte.cc: Set source and their jacobian to zero when there is a layer of pure rotation * src/zeeman.cc: N=0 lines were failing after last update. Fixed and moved all tests inside the g-functions to handle these issues in the future. (Perhaps next step is to treat these zeroes better since they give the so-called zero-frequency transitions of O2?) 2018-03-11 Patrick Eriksson * arts-2-3-981 * src/m_cloudradar.cc (yActive2): Now also handling dBZe. (iyActiveSingleScat2): Work on Jacobian part. * src/rte.cc (rtmethods_jacobian_init): Added input argument is_active, with false as default, to handle a small difference when called from yActive. * src/m_cloudradar.cc (iyActiveSingleScat2): * src/m_transmitter.cc (iyTransmissionStandard2): da_dx[iq] was not sized properly. Added da_dx[iq] = StokesVector(nf,ns); 2018-03-09 Richard Larsson * arts-2-3-980 * src/zeeman.cc: Update to Zeeman calculations after review Mostly adds a new constant, GL, to the central equations that is presently set to 1 wihle waiting for data input. Might update to take nuclear spin into account at a later time 2018-03-07 Patrick Eriksson * arts-2-3-979 * src/m_montecarlo.cc (MCRadar): Now using ze_tref and k2, to mimic iyActive. * src/m_cloudradar.cc (yActive): * src/m_rte.cc (iyIndependentBeamApproximation): Now using error_if_limb_ppath. * src/ppath.cc (error_if_limb_ppath): New function. * src/rte.cc (ze_cfac): New function. * src/m_rte.cc (iyEmissionStandard2): t_nlte change to nlte in variable names. * src/m_cloudradar.cc (yActive2): Started. 2018-03-07 Richard Larsson * arts-2-3-978 Added simple nlte_field-computer. Still a work in progress as there seems to be a large bug with some code that cannot be made to run in parallel, making the code painfully slow. * src/m_radiation_field.cc: Changed main function to directly call iyEmissionStandard2. Also changed transmission_field to fit with iyEmissionStandard2 changed definition. Finally, made it so that the lines are forced to overlap and line shapes are renormalized before integrations. * src/nlte{cc,h},m_nlte.cc: Contains simple function for computing the NLTE-field using lambda iterator (modified approximate or not) based on Taka's formulations. Still not tested because it must be run on single core now due to some bug in the iy-calculations that I cannot find. * src/m_rte.cc: (iyEmissionStandard2) Changed to return background radiation when there is only a single level, and to set the transmission of the undefined layer to unity. 2018-03-01 Richard Larsson * arts-2-3-977 * controlfiles/*: Removed variable no longer used by Zeeman code from workspace entirerly so had to update controlfiles... * src/groups.cc, src/m_basic_types.cc: * src/xml_io_basic_types.{h,cc},src/xml_io_types.h: Added Rational with some basic interaction * src/linerecord.{cc,h}, src/quantum.{cc,h}: * src/m_linemixing.cc, : I wanted to review the quantum number handling in ARTS so I changed the enum to an enum class so I had to look at all the code. Found some bugs... * src/m_linerecord.cc: (abs_linesSetQuantumNumberForAll) helper function for setting constant quantum numbers * src/m_zeeman.cc: Removed isotopologue_quantum * src/zeeman.{cc,h}: Reviewing some paper I found my implementation was lacking. Two bugs were included: 1) Hund case a had switched argument calls to a key-function such that the output would be wrong, and 2) Hund case b would not have worked for Lambda not_eq 0. I changed both these things. Since this meant having to change isotopologue_quantum, I decided instead it was time to remove the file because modern HITRAN provides almost all that is needed from it. The key difference is the Lande relativistic factor, which a small helper function to provide these constants have been added to take care of. So presently the order of arguments in (frequency_change) for Hund::CaseA was fixed to fit with the definition of gs_casea. Their order was rong in previous version introduced a 20% error in the return value... The other thing is having a fuller expression for Hund::CaseB. Unfortunately, this means that the old isotopologue_quantum was bad and that it either had to have an updated format, or the user would have to be able to add the data themselves. So HITRAN reading has been updated. And so has arts-xml-data for O2. Other data is in (get_lande_spin_constant) in these files * src/quantum_parser.h, src/quantum_parser_hitran.{h,cc}: Added more detailed reading/writing of the quantum numbers for O2, ClO, NO, and OH. These functions now sets all variables required for Zeeman effect. The Zeeman effect should therefore be computable for all these though we are working on testing this. Note: I believe HITRAN has bad numbers for some of the isotopologues. Especially, even modern HITRAN provides S=1 for O2-67, which is an impossible number to have for this species. So while the reading works, the actual physics is probably completely wrong... 2018-03-01 Patrick Eriksson * arts-2-3-976 * controlfiles/general/agendas.arts: Added definition of ppath_agenda__PlaneParallel. 2018-03-01 Patrick Eriksson * arts-2-3-975 * src/m_rte.cc (iyIndependentBeamApproximation): The function made use of ppath.r. Changed as ppath.r is Inf is method below is used. Warning: change not tested. * src/m_ppath.cc (ppathPlaneParallel): A complete version. A fair amount of testing done, but loopholes cold still exist. 2018-02-28 Ian Adams * arts-2-3-974 * ChangeLog entry added on behalf of Ian. * src/m_montecarlo.cc, src/montecarlo.cc: Enhancements to MCRadar: Fixes range bin displacement. Adjusts photon scaling. 2018-02-28 Oliver Lemke * arts-2-3-973 * src/interactive_workspace.{cc,h} (InteractiveWorkspace): Add verbosity parameters to constructor. Remove member verbosity_ as it was only used in the constructor. * src/arts_api.{cc,h} (create_workspace): Add verbosity parameters. * src/messages.h (Verbosity): Change type of Verbosity member to constant reference. Avoids lots of copying of Verbosity objects. * src/doit.cc (doit_scat_fieldNormalize): Adapt out level switching since ArtsOut objects cannot be copied anymore due to change in messages.h. 2018-02-26 Patrick Eriksson * arts-2-3-972 * src/m_psd.cc (psdF07): NaNs in PSD were obtained for extremly small values, such as 1e-96. Now all SWC below 1e-15 is considered to be zero. 2018-02-26 Patrick Eriksson * arts-2-3-971 * src/m_ppath.cc (ppathPlaneParallel): Managed to commit with a remaining typo in the code. 2018-02-26 Patrick Eriksson * arts-2-3-970 * src/m_ppath.cc (ppathPlaneParallel): Just started. 2018-02-23 Richard Larsson * arts-2-3-969 * src/gridded_fields.{cc,h}: End of line added to higher order fields when printing. * src/linefunctions.cc: Added Linefunctions::set_lineshape to compute the line shape * src/linescaling.cc: Forgot a minus sign... * src/m_radiation_field.cc: Now also deals with the transmission field required by NLTE computations. Also changed how the integration happens to a separate function, removing some of the optional arguments I introduced before. Again, no one should be using these functions yet as they just serve to prototype necessary input/output for the full nlte-approach * src/{methods,workspace}.cc: Added transmission_field and changed input/output of some of the silly field-computers. There should be just one parameter missing at this point before the output becomes nlte_field instead of these temporaries 2018-02-23 Oliver Lemke * arts-2-3-968 * src/m_basic_types.cc, src/methods.cc: Add convenience method Tensor3ExtractFromTensor4. 2018-02-23 Oliver Lemke * arts-2-3-967 * Preliminary implementation of support for Hitran cross section species. http://hitran.org/xsc/ Since available measurements of cross section data are very sparse (few temperatures/pressures) depending on species, the calculations in ARTS are based on one reference cross section at low pressure for each species. The cross section data is then broadened for the desired pressure by convolution with a Lorentz function. The FWHM of the Lorentz function is determined by an approximation. The coefficients for this approximation are part of the input data and calculated outside ARTS. The code for this will be made available in a separate package. The data for cross section species will be added to arts-xml-data in due time. * CMakeLists.txt, cmake/modules/FindFFTW.cmake, config.h.cmake, src/main.cc: Add FFTW library support. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/hitran-xsec/CFC11.xml.gz, controlfiles/artscomponents/hitran-xsec/TestHitranXsec.arts, controlfiles/artscomponents/hitran-xsec/yREFERENCE.xml, controlfiles/testdata/tropical.CFC11.xml: Add simple cross section species test case. * src/CMakeLists.txt * src/abs_species_tags.{cc,h}, src/m_checked.cc (abs_xsec_agenda_checkedCalc): Add tag TYPE_HITRAN_XSEC. * src/hitran_xsec.{cc,h}: Implementation of class XsecRecord. XsecRecord::Extract does the heavy lifting by using the FFTW library to convolve the cross section data with a Lorentz function to apply the pressure broadening. * src/m_hitran_xsec.cc, src/methods.cc: New WSM abs_xsec_per_speciesAddHitranXsec. Add doc for HXSEC tag type to abs_speciesSet. * src/make_auto_md_h.{cc,h}, src/make_auto_workspace_h.cc * src/species_data.cc, src/partition_function_data.cc: Add HXSEC species CFC11, CFC12, HCFC22, HFC134a. * src/partial_derivatives.h (PropmatPartialsData): Add supportHitranXsec method. * src/workspace.cc: Add WSM hitran_xsec_data. * src/groups.cc: Add ArrayOfXsecRecord. * src/xml_io_array_types.cc, src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add support for new XsecRecord and ArrayOfXsecRecord data types. 2018-02-22 Richard Larsson * arts-2-3-966 * src/m_radiation_field.cc: Removed lingering debug information... 2018-02-22 Richard Larsson * arts-2-3-965 * src/m_atmospheres.cc: Fix for upper levels energy is different... * src/quantum.cc: The 'belongs to' operator< did not work for energy levels before this fix... * src/m_radiation_field.cc: Removed buggy attempt at speeding things up 2018-02-21 Richard Larsson * arts-2-3-964 Adding nlte_field to iy_main_agenda. Necessary for NLTE computations iterating the field. Also, DISORT test failed before this commit with exactly the same error as before. This is therefore unrelated. * src/m_atmospheres.cc: Created nlte_fieldSetLTE to get the ratios for nlte_field to LTE ratios. This still needs some more checking. * src/the-rest: Changes so that iy-calls knows of nlte_field. Only exception is the jacobians for doit, which assume there is LTE. 2018-02-21 Oliver Lemke * arts-2-3-963 * CMakeLists.txt, controlfiles/CMakeLists.txt, doc/CMakeLists.txt, controlfiles/classroom_exercises/, doc/classroom_excercises_solutions/: Remove classroom exercises. They are available in a separate package: https://arts.mi.uni-hamburg.de/svn/rt/arts-lectures/trunk/ 2018-02-21 Oliver Lemke * arts-2-3-962 * tools/bash_completion/completion_arts.sh: Fix expansion of ~ or $HOME in arts exe path. Add new commandline options datapath, docserver, docdaemon. * tools/bash_completion/README: Match text with example. 2018-02-20 Jana Mendrok * arts-2-3-961 * src/rte.cc (get_ppath_partopt): Replaced a leftover instance of opt_propCalc by new optprop extraction scheme. * src/optproperties.cc (opt_prop_1ScatElem, abs_vec_SSD2Stokes): Oops, fixed some crucial bugs revealed by the above (and the TransWithScat test). Why did they go unnoticed so far? :-O * src/workspace.cc, src/methods.cc, src/rte.[cc,h] (get_ppath_partopt), src/m_transmitter.cc (iyTransmissionStandard), src/m_cloudradar.cc (iyActiveSingleScat), src/m_rte.cc (iyEmissionStandard), controlfiles/general/general.arts: Removed use_mean_scat_data (and interface dummies). * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Fixed missed instances of Touch f_grid when using DoitScatteringDataPrepare in doit_mono_agenda and of generally using scat_data in solvers. 2018-02-20 Jana Mendrok * arts-2-3-960 * src/m_checked.cc (cloudbox_checkedCalc, scat_data_checkedCalc): Move all scat_data grid and content checks from cloudbox_checkedCalc to scat_data_checkedCalc. * src/m_doit.cc (DoitCalc): Added scat_data_checked as input and check this flag. * src/m_optproperties.cc: Removed *_RAW definitions. Removed _NEW from definitions acting on scat_data. (pha_mat_sptFromData, opt_prop_sptFromData, scat_data_monoCalc): Reverted to act on scat_data, not scat_data_raw. (DoitScatteringDataPrepare): Changed to assume (and check for) scat_data. Accordingly, replaced scat_data_monoCalc by scat_data_monoExtract. * src/m_jacobian.cc (jacobianDoit): Reverted to act on scat_data, not scat_data_raw. Adapted to DoitCalc and cloudbox_checkedCalc changes. * src/m_cloudbox.cc (ScatElementsSelect): Act on scat_data_raw, not scat_data, consistenly with more common use. (ScatElementsToabs_speciesAdd): Use chk_interpolation_grids directly instead via chk_scat_data_fgrid. * src/cloudbox.[cc,h] (chk_scat_data_fgrid): Removed. Was anyway just calling chk_interpolation_grids nowadays. * src/methods.cc: Adapted to WSM changes above. * controlfiles/artscomponents/doit/doit_setup_pressureoptimization.arts: Adapted to changes above, fixing issues when using scat_dataCalc before ScatSpeciesMerge. * controlfiles/general/agendasDOIT.arts, controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/artscomponents/doit/doit_setup_accelerated.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Touch f_grid when using DoitScatteringDataPrepare in doit_mono_agenda. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Adapted to WSM now using scat_data as default instead of scat_data_raw (and vice versa). * controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts: Cosmetics. * controlfiles/CMakeLists.txt: Revert accidential change from last commit. 2018-02-20 Jana Mendrok * arts-2-3-959 * src/m_rte.cc (iyCalc, yCalc): scat_data_checked added as input and check (only if cloudbox on). * src/m_cloudradar.cc (iyActiveSingleScat), m_fos.cc (iyHybrid), m_rte.cc (iyMC), m_transmitter.cc (iyTransmissionStandard): Remove scat_data_checked as input parameter that is now checked by calling WSMs (i)yCalc instead. * src/m_cloudbox.cc (cloudboxOff): Add scat_data_checked as output parameter. * src/rte.[cc,h] (get_ppath_pmat_and_tmat, get_ppath_partopt, get_ppath_scat_source, get_ppath_scat_source_fixT, get_stepwise_scattersky_source): Remove scat_data_checked as input parameter, now generally assuming f-grid prepared scat_data. * src/m_jacobian.cc (jacobianDoit), m_rte.cc (yCalcAppend), m_radiation_field.cc (radiation_fieldCalcFromiyCalc): Added scat_data_checked as input parameter, now required by (i)yCalc calls. (i)yCalc calls adapted accordingly. * src/m_abs.cc (propmat_clearskyAddParticles[2]), m_montecarlo.cc (MCGeneral, MCRadar): Cosmetics. * src/methods.cc: Adapted to WSM interface changes above. * controlfiles/artscomponents/doit/TestDOIT.arts, TestDOITFromIndividualFields.arts, TestDOITaccelerated.arts, TestDOITprecalcInit.arts, TestDOITpressureoptimization.arts, TestDOITsensorInsideCloudbox.arts, doit_calc.arts, doit_setup.arts, doit_setup_accelerated.arts, doit_setup_pressureoptimization.arts, indivfieldsatmo_setup.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Change to use of scat_data (instead of raw; at least for the test setups this works. might fail for 1-freq-only cases.) Use basic doit_setup for the different Doit-optimnization test cases, just make the additional settings/modifications in their specific setup files. 2018-02-20 Richard Larsson * arts-2-3-958 Adding a silly radiation-field computer in waiting for a better solution. I need a weighted mean intensity value for Taka's NLTE computations. * src/src/m_radiation_field.cc: Now contains the radiation_fieldCalcForRotationalNLTE function. Basically just computes the radiation for a 1D-like atmosphere without storing any information about previous calculations. Quick-and-dirty way to perform the computations. What I need in the end is a normalized line shape multiplied with the radiation field and then summed over frequency so as to get the effective source function for the line. Do not use this function. It will be replaced as soon as there exists a better way to compute the radiation field (on, pressure, zenith, azimuth, frequency). The other changes are merely minor fix-em-ups. 2018-02-19 Jana Mendrok * arts-2-3-957 Continue replacement of particle optical property calculation schemes. * src/disort.[cc,h] (dtauc_ssalbCalc2, run_disort2): Added. Methods for preparing input data and running disort from it using the new optprop extraction scheme. As soon as all the replacements are done (and some more testing), these will replace the old (non-numbered) versions. (dtauc_ssablbCalc): Changed clearsky abs/ext calc to per-layer calc of propmatrix, then average that over layer (instead calc from averaged T,p,vmr). This is more in line with what we do in other solver (e.g. the new path-integration scheme). Resulting BT differences in test case are up to 0.05K. * src/m_disort.cc, methods.cc (DisortCalc): Temporarily added parameter to control which optprop extraction scheme is used (for testing purposes. old scheme branch to be removed, see above, but so far still the default). * controlfiles/artscomponents/disort/yREFERENCE.y.xml: Replaced with new calc reflecting clearsky abs/ext calc changes above. * controlfiles/artscomponents/disort/TestDISORT.arts: Raise compare-to-ref requirement somewhat. Outcommented example call with new optprop extraction scheme. 2018-02-19 Richard Larsson * arts-2-3-956 * src/ling_alg.{h,cc}: Added a simple least square fitting routine. This probably exists somewhere but I needed one for now so please feel free to change this... * src/linemixingdata.h: Made way to set 2ndorder type easier * src/m{_linemixing,ethods}.cc: Added SetLineMixingCoefficinetsFromRelmat. This takes the existing abs_lines_per_band, computes the relaxation matrices, and then sets the coefficients to those in 2nd-order linemixing paradigm. Works reasoanbly well for simple cases (and can showcase why not using full line mixing is such a problematic endeavor for less simple cases). Also removed parallelization attempts in m_linemixing. We need a fix to this to make it work... for now it must be run on a single core. * controlfiles/*: Added simple test for Relmat. Takes about 20 seconds on my maching with -DFASTWIGNER=1 and about 1000 seconds without. So if FASTWIGNER is active, the test is in fast, otherwise it is in slow. Since the error using the slow method is larger than the error with the fast method, the reference file is from running the fast method 2018-02-19 Patrick Eriksson * arts-2-3-955 * src/methods.cc: Documentation of MCGeneral and MCRadar said that mc_seed<0 will result in random initialisation. This was removed 2005 (according to archaeology done by Oliver). 2018-02-18 Patrick Eriksson * arts-2-3-954 * src/m_cloudradar.cc (iyActiveSingleScat2): Started. Work in progress. * src/m_transmitter.cc (iyTransmissionStandard2): Removed scat_data_checked as input WSM. * src/rte.cc (get_ppath_cloudvars): Spelling in a comment 2018-02-17 Patrick Eriksson * arts-2-3-953 * src/m_montecarlo.cc (MCRadar): There was a crash if stokes_dim was < 3 (due to isnan(Ihold[2])). Changed code to handle stokes_dim>2. Now also checked that stokes_dim>=2. 2018-02-16 Simon Pfreundschuh * arts-2-3-952 * src/m_surface.cc: - removed trailing white spaces - added surfaceTelsem method to compute land surface emissivities using TELSEM2 - fixed bug in surfaceFlatRvRh * src/m_telsem.cc: - added telsemSurfaceTypeLandSea WSM to produce a land/sea mask according to TELSEM2 data. - added telsem_atlasReadAscii to read a single atlas. * src/methods.cc: - added surfaceTelsem, telsemSurfaceTypeLandSea, telsem_atlasReadAscii WSMs * src/telsem.[h,cc]: - added some checks to avoid memory errors for invalid inputs 2018-02-15 Oliver Lemke * arts-2-3-951 * 3rdparty/wigner/wigxjpf/CMakeLists.txt: Remove calc_float128.c and c_wrap_float128.c from sources. Not needed because we don't use quadmath. Fixes compilation failure with Clang which doesn't support __float128. 2018-02-15 Richard Larsson * arts-2-3-950 * 3rdparty/wigxjpf: Moved to 3rdparty/wigner/wigxjpf. Also commented out Makefile reference to QUADMATH as the only difference from original as found at: http://fy.chalmers.se/subatom/wigxjpf/ * 3rdparty/wigner/fastwigxj: Added. Also commented out Makefile reference to QUADMATH from original as found at: http://fy.chalmers.se/subatom/fastwigxj/ After work by Håkan T. Johansson of Chalmers, using fastwigxj to compute line mixing speeds up relmat by orders of magnitude. What used to take 40 minutes at 20 cores now takes 4 minutes at a single core. Tha activation of this code-path is still a bit clumsy. To activate it, type "cmake -DFASTWIGNER=X .." in your build with X as a positive integer. X is used internally to generate the two files: 3rparty/wigner/fastwigxj/fasttable.3j and 3rparty/wigner/fastwigxj/fasttable.6j. It also sets a define while building ARTS so that these files are found. Do not make X large as this takes up loads of disk space. The files contain pre-computed hash-maps that finds wigner symbol values. We do not need all wigner symbol values in line mixing because the geometry of the possible transitions is known. Instead, a dynamic map is generated inside ARTS that finds the symbols that have already been computed and use them. If a symbol is not already computed, it returns to use wigxjpf to compute this symbol. Read README in respective wigner/* folder to understant better. Problems: 1) It might only be possible to build this with GCC because native instructions are used. If the code is not built it returns to use wigxjpf with some defines in the code. Can someone with a clang/icc system confirm if it works or not on other compilers? 2) The defines way to select files is not the best but it is much less cumbersome than having the user first personally generate files that are always constant and then finding them. Any suggestion to fix this without adding needless overhead? 3) It does not work with multithreading at this point. I am not sure how to fix this because it needs a smart read-write scheme to the dynamic table inside fastwigxj. 4) Documentation is still lacking as I do not wish to add guides until the setup is deemed to be working. * 3rdparty/relmat/module_maths.F90: Activate the use of fastwigxj if available for both wigner3j and wigner6j. NOTE: the wigner6j old solution is faster but less general. This indicates to me that we should be specific which version to use and perhaps move the wigner6j code to a separate file for specialized cases. The difference in speed is not large, though. wigner3j is incomparably much faster in the present version than in the older code. * src/wigner_functions.{cc,h}: Interface and test code for the faster wigner library. * src/m_linemixing.cc: Also added an interface. I will make the constants inputs with decent defaults at some point in the future. The present numbers works for most singular bands but might need to be increased for fast computations with more bands. 2018-02-12 Simon Pfreundschuh * arts-2-3-949 * src/test_telsem.cc: Explicit in place construction of vector elements of type std::ifstream. 2018-02-12 Simon Pfreundschuh * arts-2-3-948 Testing of TELSEM interface. * src/test_telsem.cc: Test file for in depth comparison to results from FORTRAN module. * src/CMakeLists.txt: Added test executable. * src/telsem.[h, cc]: Some fixes for bugs discovered during testing. 2018-02-09 Jana Mendrok * arts-2-3-947 Continue replacement of particle optical property calculation schemes. * src/m_abs.cc, methods.cc (propmat_clearskyAddParticles2): Added. New-optprop-scheme version of propmat_clearskyAddParticles. * src/m_checked.cc (propmat_clearsky_agenda_checkedCalc): Added propmat_clearskyAddParticles2 in AddParticles validity check. * controlfiles/artscomponents/absorption/TestAbsParticle.arts: Use propmat_clearskyAddParticles2 instead of propmat_clearskyAddParticles. * src/optproperties.cc (opt_prop_ScatSpecBulk, opt_prop_NScatElems, opt_prop_1ScatElem): Cosmetics. 2018-02-07 Richard Larsson * arts-2-3-946 !!WARNING!! Name-change breaking controlfile !!WARNING!! This update changes the workspace variables related to NLTE to remove or append the reference to NLTE temperatures. The reason for this update is that ARTS now supports line strength computations directly from population level distributions. This update became necessary after it became apparent it is impossible to use the vibrational temperature approach to rotational spectra. Since Takayoshi Yamada's code is now in typhon, it is now possible for others to access this code-path knowingly, so updating the naming seems important * controlfiles/*,src/{worspace,methods,agendas}.cc: Changed name * src/m_atmosphere.cc: Changed required name of file to remove "t_" for nlte. Old files called basename+t_nlte.xml should be called basename+nlte.xml in the future. * src/propagationmatrix.{cc,h}: Can now send derivative of distance into function and it should produce transmission derivatives. Supports one Index (implied to be temperature for HSE) * src/test_proagationmatrix.cc: Short test that exists for a simple class I have been looking at for using Eigen more in the transmission calculations. This simple test indicates speed-up of quite a lot, though I am unsure if this is because of Eigen optimizing away a lot of things... more about this in the future if I discover what it really does... Ps. Three controlfiles fail the slow test currently: 8 - arts.slow.doc.uguide.refs 76 - arts.ctlfile.xmldata.artscomponents.doit.TestDOITpressureoptimization 87 - arts.ctlfile.slow.artscomponents.wfuns.TestDoitJacobians These fail because: 8) Many unknown WSM 76) Ptype value (20) is wrong.It must be (... 20 is in the list ...) 87) Ptype value (20) is wrong.It must be (... 20 is in the list ...) Since this is unrelated to my change, I will ignore this but someone should investigate... 2018-01-31 Jana Mendrok * arts-2-3-945 Continue replacement of particle optical property calculation schemes. * src/m_fos.cc (iyHybrid), m_transmitter.cc (iyTransmissionStandard2), rte.[cc,h] (get_stepwise_scattersky_propmat): Revise to use new optprop scheme. * src/optproperties.[cc,h] (opt_prop_1ScatElem, opt_prop_NScatElems, opt_prop_ScatSpecBulk): Introduce t-interpolation tracker. The opt_prop_*ScatElem* extract data over temperature arrays, where individual entries might be invalid for interpolation (e.g. when extracting data over whole cloudbox or even atmosphere at once). At the same time they do not know about pnd, ie whether these T-extracts will actually be used (and that should remain nicely separated like this). Therefore introducing a tracker parameter with one entry per T and scat element indicating whether t-interpol was ok or not. opt_prop_ScatSpecBulk then takes care to check for invalid T-interpols and handles them appropriately. * src/rt4.cc (par_optpropCalc2), montecarlo.cc (cloudy_rt_vars_at_gp), src/m_optproperties.cc (TestScatDataInterp): Update with t-interpolation tracking parameter. * src/montecarlo.cc (opt_propCalc): Bugfix. Don't skip calc for pnd<0 (was needed for jacobians), only for =0. * src/propagationmatrix.h, m_montecarlo.cc: Cosmetics. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: A bit of clean up. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/wfuns/ybatch*REFERNCE_iyHybrid.xml: Added TestWfunsHybCloudy as slow test case and added (new) reference results to compare to in order to avoid getting broken too often. * doc/uguide/scattering.tex, wfuns.tex: More removal of outdated WSM references. 2018-01-29 Richard Larsson * arts-2-3-944 * src/linefunctions.{cc,h}: Updated (apply_linestrength_from_nlte_level_distributions) to take into account partial derivatives with respect to central frequency, ratio of upper and lower state levels, and kinetic temperatures. Not tested yet. * src/quantum.{h,cc}: Added None-case, added method to quickly set energy state identifier, and added methods to create energy state identifier from known transition identifier * src/partial_derivatives.h: Added JQT_population_level_ratio 2018-01-29 Patrick Eriksson * arts-2-3-943 * src/m_transmitter.cc (iyTransmissionStandard2): Post-processing of Jacobian was not updated to use new function. Spotted by Richard. * src/rte.cc (rtmethods_jacobian_finalisation): Small extension of header description. 2018-01-29 Patrick Eriksson * arts-2-3-942 * src/m_transmitter.cc (iyRadioLink): * src/m_fos.cc (iyFOS): Both these WSMs are commented out. That is, they are for the moment not active parts of ARTS. There is just not time for the moment to update these methods to new RT scheme. * controlfiles/general/agendas.arts: * controlfiles/CMakeLists.txt: Commented out things now not working with FOS and RadioLink deactivated. * src/m_transmitter.cc (iyTransmissionStandard2): Now exists as a WSM. Jacobian part not yet OK. * controlfiles/general/agendas.arts: Removed Ignore( iy_id ) from iy_main_agenda__Emission. Removed Ignore( t_nlte_field ) from iy_main_agenda__Transmission. Not needed. 2018-01-26 Patrick Eriksson * arts-2-3-941 * src/m_jacobian.cc (jacobianAddFreqShift): Check of length of f_grid was totally crazy. Pointed out by Richard. 2018-01-26 Richard Larsson * arts-2-3-940 * src/wigner_functions.{cc,h}: Changed to directly include the header-file than to declare the functions again. Also changed ECS calcs to be parallell. * src/propagationmatrix.{h,cc}: Fixed bug that would occur if people were using this MatrixInverse on zenith and azimuth size-other-than-one PropagationMatrices. Spotted by luck... Also added IsZero() to check if a Matrix is zero or not. * README: Added comment about Native build. Sidenote: I was trying to get flto option to compile the code. It does not work. For some small cases it does work (e.g., matpack, artscore) it produces executable tests that are about 15% faster in the small test case I have got. It fails at linking the entire thing together though, warning that some variables are maybe left uninitialized but throwing an error about even the existence of things like griddedfields and tensorviews. It would be nice if this can be fixed because these compiler options really helps the code. (Already using native shaves about 1/4 of the time of something as simple as the "make check" case.) * src/m_linemixing.cc: Changed level of output to 3. 2018-01-25 Richard Larsson * arts-2-3-939 * 3rdpart/relmat/CMakeLists.txt: Added wigner library to relmat so that we can use it as a faster computer of the Wigner symbols * CMakeLists.txt: Added a Native build option that patches both ARTS and Fortran with -march=native and a few other things to make them compile more optimized codes. Not really tested, and it should remain that way. (I.e., not fully supported but it works if it works and then it is faster than not using it...) * src/rational.{cc,h}: Added some logicals and modulus operations * src/test_*: Added and moved and changed some Wigner tests. * src/wigner_functions.{cc,h}: Added a simple ECS relaxation matrix calculator (that only takes the Wigner-bits into account) to the file in order to test how much faster the wigxjpf library is compared to relmat wigner function. Results: 12 seconds versus an estimated 50 seconds. So quite some time can be saved here if we manage to make a proper implementation link to relmat. 2018-01-23 Jana Mendrok * arts-2-3-938 Apply new new scattering particle optical property calculation scheme to MC-related methods. * src/montecarlo.[cc,h] (cloudy_rt_vars_at_gp): Replace old optprop calc scheme (opt_propCalc) by new one. Use scat_data instead of scat_data_mono. For that, pass f_grid and f_index instead of f_mono. (mcPathTraceGeneral, mcPathTraceRadar, get_ppath_transmat): Adapt to changes in cloudy_rt_vars_at_gp, particularly pass through scat_data, f_grid, f_index in place of scat_data_mono and f_mono. (is_anyptype_notTotRan): Renamed due change in ptype internal numbering. Rename applied scat data instance from scat_data_mono to scat_data. And changed to look for AzRand to look for more-complex-than-TotRand * src/m_montecarlo.cc, methods.cc (MCGeneral, MCRadar): Pass scat_data and scat_data_checked instead of scat_data_mono. For now, scat_data_mono is still derived internally as we still need it for the pha_mat calculation routines, which aren't revised yet. * src/m_rte.cc, methods.cc (iyMC): Pass scat_data and scat_data_checked instead of scat_data_raw. Removed scat_data_mono calculation. * src/rt4.cc (run_rt4): Refinements on all-freq-ext/abs-from-outside-freq-loop usage. * src/optproperties.cc (opt_prop_NScatElems): Catch case of single-freq scat_data for multi-freq calc for single-freq extraction. Can't do that for multi-freq extraction (as we don't know about f_grid here). This has to be caught by calling methods (and is also the most efficient (computational and memory wise) way. Added a respective developer-caution note. * src/m_doit.cc, methods.cc (DoitInit): Remove passing and checking of scat_data_raw. Makes no sense here, shouldn't be DoitInit's business. * controlfiles/artscomponents/montecarlo/*.arts: Adapted to changes above. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Repaired. * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Remove definition of doit_i_field_agenda. Not needed anymore. * doc/uguide/scattering.tex: Added references to removed optprop-related WSMs. 2018-01-22 Jana Mendrok * arts-2-3-937 * src/rt4.cc (run_rt4): Calculate ext/abs for all freqs before the freq-loop, except if auto_inc_nstreams (then fall back to in-loop, singe freq calc). Store orig scat_za_grid once, outside any loop. (par_optpropCalc2): Adapt such that multi-freq data can be returned. * src/methods.cc (RT4Calc): Revise doc. Add cautionary notes that output field will only have *nstreams* polar angles, even when run with *auto_inc_nstreams*!=0. 2018-01-22 Richard Larsson * arts-2-3-936 * src/wigner_functions.{cc,h}: Linked to wigxjpf and changed to use their functions. Also added these to the compiled files and moved linking the wigner-library from artscore to matpack... 2018-01-21 Jana Mendrok * arts-2-3-935 * src/m_rt4.cc, methods.cc (RT4Calc), src/rt4.[cc,h] (run_rt4, par_optpropCalc2): Start applying new scattering particle optical property calculation scheme. So far as option to RT4Calc. So far separately per freq point. * src/optproperties.[cc,h] (opt_prop_ScatSpecBulk): Changed pnds type from const MatrixView& to ConstMatrixView due to complaints by par_optpropCalc2. * src/m_basic_types.cc, methods.cc (CompareRelative): Introduced Tensor7 flavour for doit_i_field comparison. * controlfiles/artscomponents/polradtran/TestRT4.arts: Added a RT4Calc using new optprop scheme. Compare to old one. Results are practically identical, new marginally faster. 2018-01-19 Jana Mendrok * arts-2-3-934 Ooops. Parts of ChangeLog missed. * src/m_optproperties.cc, methods.cc (TestScatDataInterp): Deactivated DOIT testing (needs proper adaptation to changes of DoitScatteringDataPrepare in arts-2-3-658). 2018-01-19 Jana Mendrok * arts-2-3-933 * src/optproperties.cc (opt_prop_ScatSpecBulk, opt_prop_NScatElems, opt_prop_1ScatElem): Bugfixes. * src/optproperties.h (opt_prop_NScatElems, opt_prop_1ScatElem): Set defaults for temperature interpolation order (linear). * src/m_optproperties.cc, methods.cc (TestScatDataInterp): Revive this WSM as I need it to test the new system. Fixed bugs and incomplete revision, removed counterproductive input parameters introduced in arts-2-3-658 and arts-2-3-757 (guys... >:-/ bad style!). Added section testing ext/abs extraction using new unified system. 2018-01-18 Richard Larsson * arts-2-3-932 * src/m_linemixing.cc: Added error-coding that prints errors to screen at out1-level. Relmat reports type of error. * 3rdparty/wigxjpf: Attempt to add this library to ARTS because we could use a faster wigner-calculator in relmat. It presently builds and the names are in the library but I am not sure how to access the functions from within ARTS CC files or from within relmat F90 files... * src/wigner_functions.cc: Contains a copy of the example from wigxjpf homepage for wigner 3j symbol but it is not working... 2018-01-18 Teresa Mendaza * arts-2-3-931 Detailed internal comments have been added to all subroutines and functions within relmat-folder. 2018-01-17 Teresa Mendaza * arts-2-3-930 Functionalities of the variable -runE_deb- (an INTEGER used on RELMAT-debugging) were updated. Thus, the following modules: 3rdparty/relmat/arts_interface.F90 3rdparty/relmat/module_common_var.F90 3rdparty/relmat/module_linemixing.F90 3rdparty/relmat/module_molecSp.F90 3rdparty/relmat/module_phsub.F90 are modified. 2018-01-16 Jana Mendrok * arts-2-3-929 More optical property handling related work in progress. * src/optproperties.[cc,h] (opt_prop_Bulk, opt_prop_ScatSpecBulk, opt_prop_NScatElems): Added. Methods to derove ext/mat over all scattering elements and for bulks. * src/array.h: Added typedefs for ArrayOfArrayOfTensor5 and 7. 2018-01-16 Jana Mendrok * arts-2-3-928 More optical property handling related work in progress. * src/optproperties.cc (opt_prop_1ScatElem): Completed this method. 2018-01-16 Jana Mendrok * arts-2-3-927 Work in progress. Implementing functions for consistent optical property handling over the scattering solvers. * src/optproperties.h: Redefined enums associated with ptypes such that they increase with complexity. * src/optproperties.[cc,h] (opt_prop_1ScatElem, ext_mat_SSD2Stokes, abs_vec_SSD2Stokes): New methods for extmat/absvec extraction from single scat elements. To replace opt_propExtract and opt_prop_sptFrom*/ext_matTransform/ abs_vecTransform. * src/montecarlo.cc (opt_propExtract): Spurious comment cleanup. * doc/uguide/clouds.tex: Crucial typo fix. 2018-01-16 Teresa Mendaza * arts-2-3-926 * 3rdparty/relmat/arts_interface.F90: Added a rule tolerance limitation to both LM-methods (Hartmann&Niro and 'the linearization') so the user can control whether his/her calculations meets the perturbation theory condition. 2018-01-16 Richard Larsson * arts-2-3-925 * 3rdparty/relmat/arts_interface.F90: Added a rule tolerance input for diagonalization on fail. Also added logical to check if we should use the adiabatic factor in the new method or not. Without, some physics is ignored but with it, we cannot extend easily to other molecules. Also reverted to calc_QParam instead of calc_QPar_DGELSD because of what seems to be a lapack bug in the latter. * 3rdparty/relmat/module_linemixing.F90: Changed rule2 to accept tolerance level as input instead of having it as a constant. We still do not know what tolerance is acceptable * src/m_linemixing.cc: Changed so tolerance levels and adiabatic-factor inputs are working. For now, these are constants but they might become GIN as the code evolves. Also fixed some strange tabulations caused by my editor not liking the pragmas. These tabulations had caused the code to break when in parallel mode because I had inserted the delete[] statements on the wrong level... There is still some other issue with the parallel code but I do not know what it is... 2018-01-15 Jana Mendrok * arts-2-3-924 * src/m_montecarlo.cc (MCGeneral), src/montecarlo.cc (findZ11max, Sample_los): Simplified code for Z11max finding. This is called just once per LOS, hence efficiency is not crucial. Hence, removed ptype-dependent handling, moved the little remaining code directly into MCGeneral and removed findZ11max function. * CHANGES-2.3: Leftover uncommited change from arts-2-3-900. 2018-01-12 Richard Larsson * arts-2-3-923 * src/m_linemixing.cc: Removed std::cout expression... 2018-01-12 Teresa Mendaza * arts-2-3-922 Some symbols of the FORTRAN 77 grammar have been changed to their FORTRAN 90 counterparts to avoid compilation warnings in relmat. 2018-01-12 Teresa Mendaza * arts-2-3-921 Updated version of relmat. Now it should work for all CO2 bands. 2018-01-12 Richard Larsson * arts-2-3-920 * src/linefunctions.cc: Cleaned up some repetitive code * src/{linemixingdata,pressurebroadeningdata,quantum}.{h,cc}: Changed so enums inherit from Index and added way to set type by Index * src/{m_,}linerecord.{cc,h}: Added a binary writing routine of ARTSCAT5. Reduces time of reading 4.5 million HITRAN2012 lines from 1 minute 40 seconds to 14 seconds on my machine. This is not meant to be a do all solve all routine but a first iteration. It will not be guaranteed to be compatible as ARTSCAT5 evolves so keep those ascii files around when it becomes necessary to regenreate the binary. Also removed a lot of commented away code... * src/propagationmatrix.{cc,h}: Added a lot of '/* FALLTHROUGH */'s to the switch statements to make them complain less in the build log. Still enourmous amount of warnings from invlib and c-api about conversions. Also, someone more familiar with it should check line line 679 in m_jacobian.cc and lines around 590 in montecarlo.cc because it seems to me that they are not doing what they are meant to be doing (strange runtime_error in the former and a lot of ignored but nevertheless executed code in the latter since the output should anyways just be the default of that switch without breaks) 2018-01-10 Richard Larsson * arts-2-3-919 Small exercise to remove a few enums that did not make sense * src/{rte,jacobian,m_{cloudradar,rte,transmitter}}.{cc,h}: Removed all mentions of cases which has semi-analytic in their solutions. That code was no longer possible to activate for over a year. Changed enum to a class to make it easier to read (adding that it made the error throwing clean, and that I even found a bug where some code was working for random reasons...) * src/test_{linalg,propagationmatrix}.cc: Added some code so that the warnings were reduced. Later updated to gcc 7.2.0 and I can no longer find if these codes still throws warnings because things like implicit conversions and implicit fallthroughs creates a lot of junk in the build-log... 2018-01-10 Richard Larsson * arts-2-3-918 Removes integration as a separate entity from the standard iy- functions. The feature remains and is now a bit more heavy on memory, but the code simplification is nice to have * src/rte.{cc,h}: (get_ppath_trans_and_dppath_trans_dx), (get_ppath_pmat_and_tmat), (rtmethods_jacobian_init), and (rtmethods_jacobian_finalisation) had their explicit flags for integration removed (as well as related code) * src/m_transmitter.cc: (iyTransmissionStandard) had the flags and code removed. (iyTransmissionStandard2) was changed to allow for derivatives --- though this is not fully tested yet * src/m_rte.cc: (iyEmissionStandard{,2}) had their integration flags and code removed * src/m_jacobian.cc: removed outcommented code related to integration * src/m_fox.cc: (iyHybrid) had integration code removed * src/m_cloudradar.cc: (iyActiveSingleScat) had integration code removed * src/linefunctions.cc: Added forgotten jacobians speedup code by copying xsec code for each derivative * ChangeLog: Added text about m_abs.cc change in previous commit * src/jacobian.{cc,h}: (get_diydx) now takes a transmission flag to indicate it can ignore source terms. Removed enum names that are no longer relevant. (get_pointers_for_analytical_jacobians) no longer finds integration targets 2018-01-09 Patrick Eriksson * arts-2-3-917 * src/m_oem.cc: * src/jacobian.h: Removed everyting around constraints. * src/m_retrieval.cc: Removed forward declarations of Jacobian WSMs. Should not be needed after Simon's last commit (as far as I understand). Added instead include of auto_md.h. (retrievalConstraintAdd): Removed. (retrievalAddBeamFlux): Removed. * src/methods.cc: Polished descritiption of jacobianSetAffineTransformation. 2018-01-09 Richard Larsson * arts-2-3-916 Speedup is now working via xsec_species2 but only shaves, e.g., 30% of the time despite computing only perhaps 500 out of 524289 points c.f. computing on all points... much time can be saved by having a better interpolator implemented. In particular, a lot of points are being touched more than once which is not as intented. Not tested for multiple lines yet. So still much work to do... * src/absorption.{cc,h}: Removed named functions and moved these to linefunctions.cc. xsec_species2 now just passes the speedup constant along to the inner-most function. * src/linefunctions.{h,cc}: Now contains the speedup framework. I am not allowing cutoff and speedup at the same time because the setup relies on having 2^N+1 data point in f_grid, which means the cutoff cannot be handled very well... The speedup happens inside a do-while call testing that the speedup should be performed and computing the temporary size of the problem. There are a few key calls happening in order: find_boundary_of_binary_range(...): finds the lower and higher boundary of the problem from where there is full interpolation. binary_range(..., false): Finds the partial range that covers the range. In a 9-long f_grid, this would be in order: [0, 8]; [4]; [2, 6]; [1, 3, 5, 7]; speedup_distance_binary_range(...): Finds the distance in Hz that should define if a range is used there or not. speedup_binary_range(...): Reduces the previous ranges to the parts of interest for the particular problem. Say Index 2 and 6 are too close for range [2, 6] above, then these values are only interpolated up (and so will [1, 7] of the next range also be per automatics). Presently using 2^s * C * sqrt(G0^2 + GD^2), where s is an index, C is a constant that has to be set for the line using the "LSM 1 SPD C" logic in the artscat-5 call, G0 is the pressure broadening nad GD the doppler broadening. This is just a first guess and alternatives should perhaps be found. binary_range(..., true): Returns the full range so that the 9-long example returns: [0, 8]; [0, 4, 8]; [0, 2, 4, 8]; interp_up_inside_binary_range(...): Interpolates to a grid denser by a factor 2 than the passed in range. interp_to_boundary_of_binary_range(...): Interpolates from the boundary of the problem all the way to the edges, which are always computed. * src/matpackI_h: Fixed new call based on mextent = -1 representing a joker. This function might be causing quite a lot of slowdown because it is called very often... * src/{workspace,methods}.cc: Added xsec_speedup_switch which activates the code if possible. * src/test_propagationmatrix.cc: A small test of the range functions... * src/m_abs.cc: Added speedup code in (abs_xsec_per_speciesAddLines2) to compute N in 2^N+1 to pass onto later functions 2018-01-02 Simon Pfreundschuh * arts-2-3-915 * CMakeLists.txt: Removed test_telsem.cc which was not yet commited. 2018-01-02 Simon Pfreundschuh * arts-2-3-914 Added covariance_matrix.cc to artscore to avoid compilation of m_retrieval outside of artscore. 2018-01-02 Richard Larsson * arts-2-3-913 Preparing for allowing sparsening grids for line-by-line absorption. Only useful part of this commit is range of ranges, which is probably incredibly inefficient so it should only be used sparsely (pun unavoidable?). This comes from discussions with Oliver and Stefan (where I think we went wrong in wanting 2^N instead of 2^N + 1 grid-points, so the present idea I am working on implements the latter --- otherwise there is no central point and the ranging becomes by ignoring the right-hand. With 2^N + 1 you avoid this and can still perfectly predict the computation sizes) * src/absorption.cc: Added temporarily named functions for the sparsening grids. * src/linerecord.{h,cc}: Added SPD and mspeedup as variables to be used as coefficients in the speedup-calculations. * src/matpackI_h: Added what is probably a poor implementation of range of range. I need this feature in my working python version and I cannot go away from this idea without adding a lot of complexity to the code. I hope the implementation can be improved some. 2018-01-01 Patrick Eriksson * arts-2-3-912 * src/m_jacobian.cc (jacobianAdjustAndTransform): Empty jacobian was not fully handled correctly (the method must accept this, otherwise can not be part of inversion_iteration_agenda). * src/jacobian.cc (transform_jacobian): Bug fix regarding scaling associated with log and log10. * src/m_jacobian.cc (jacobianSetFuncTransformation): Added option "none". 2018-01-01 Patrick Eriksson * arts-2-3-911 * jacobian_indices no longer exists as a WSM. Removed it, as after the introduction of affine tranformations, the Jacobian can have two sizes. Instead of introducing a seocnd WSM, it seemed easier and less confusing to remove the WSV and instead calculate the indices where needed. * controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts: * src/m_retrieval.cc (retrievalDefInit, retrievalDefClose): * src/m_jacobian.cc (jacobianCalcAbsSpeciesPerturbations) (jacobianCalcFreqShift, jacobianCalcFreqStretch) (jacobianCalcPointingZaInterp, jacobianCalcPointingZaRecalc) (jacobianCalcPolyfit, jacobianInit, jacobianOff, jacobianClose): * src/m_oem.cc (x2artsStandard, xClip, xaStandard, OEM_MPI): * src/m_cloudradar.cc (iyActiveSingleScat, yActive): * controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts: * src/m_transmitter.cc (iyTransmissionStandard,iyTransmissionStandard2): * src/m_rte.cc (iyEmissionStandard,iyEmissionStandard2, yCalc) (yCalcAppend): * src/m_fos.cc (iyHybrid): * src/rte.cc (rtmethods_jacobian_init): Adoptionsin various ways. * src/workspace.cc: Removed jacobian_indices. 2017-12-31 Patrick Eriksson * arts-2-3-910 * controlfiles/artscomponents/oem/TestOEM.arts: Missed to switch to jacobianAdjustAndTransform. 2017-12-31 Patrick Eriksson * arts-2-3-909 * Summary: Functional transformations (log and log10) added as a general feature. Revised the treatment of affine transformations, to handle both transformation types in parallel. Started work to remove jacobian_indices as WSV. See arts -d jacobianSetFuncTransformation for an overview of retrieval units and transformations. * Warning: Basically no testing done, and if you use OEM probably best to not update right now. * src/rt4.cc (sca_optpropCalc): Commented out very verbose cout statement * src/m_oem.cc: * src/m_retrieval.cc: Various adoptions to changes below. * src/m_jacobian.cc (jacobianSetAffineTransformation): Renamed transformationAdd. (jacobianSetFuncTransformation): New WSM. (jacobianClose): Now not adding jacobianTransform (jacobianAdjustAndTransform): Replacing jacobianTransform and jacobianAdjustAfterIteration. (jacobianAdjustAfterIteration): Bug fix, rows and columns in jacobian were mixed up when applying adjustment. Renamed. (jacobianTransform): Merged with method above. * src/methods.cc: Set "vmr" as default for unit in abs_speciesAdd2 and jacobianAddAbsSpecies. Note that, for some unknown reason, "rel" was set as default for jacobianAddAbsSpecies. Changed to "vmr", as ARTS native unit should throughout be the default. * src/workspace.cc: Some extension of description of *diy_dx*. * src/jacobian.h (RetrievalQuantity): Added functionality for transformation functions. Some smaller changes for affine transformations. * src/jacobian.cc (jac_ranges_indices): New function. (transform_jacobian, transform_x,transform_x_back): Adopted, and extended to also handle function transformations. (get_jacobian_indices, transform_jacobian_indices): Removed, replaced with jac_ranges_indices. 2017-12-29 Patrick Eriksson * arts-2-3-908 * Summary: Work on abs species retrieval units. Internal conversion of Jacobian now done outside of core code. Added units "rh" and "q" (only allowed for H2O), but "logrel" is now not supported. Restriction for T-jacobian removed. * Warning: Not much testing done. Jacobians look reasonable. Extension in OEM not tested at all. * src/m_oem.cc (xaStandard,x2artsStandard): Added handling of "rh" and "q". Also cleaned up code, particularly removed duplication of code parts. Conversion expressions now more clealry explained by comments. * src/rte.cc (rtmethods_jacobian_finalisation): Added handling of abs species retrieval unit conversion, including rh and q. For "rh", saturation pressure is so far hard-coded to be calculated with the internal functions WVSatPressureLiquidWater and WVSatPressureIce, called for >=0C and <0C, respectively. If we start to use RH as retrieval unit, we should introduce an agenda for calculating the saturation pressure. Added also associated correction of T-jacobian. This is needed as the temperature Jacobian with fixed VMR is not the same as the one with fixed RH. Temperature Jacobian can now be mixed with all abs species units. (adapt_stepwise_partial_derivatives): Hard-coded unit to "vmr" here, as a temporarily solution. * src/m_jacobian.cc (jacobianAddAbsSpecies): Mode can now also be "rh" and "q" if species starts with H2O. Option "logrel" removed. Built-in doc updated. (jacobianAddTemperature): Removed constrain that no abs species with "nd" had been added. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Updated agenda definitions including iyHybrid. 2017-12-21 Richard Larsson * arts-2-3-907 * src/linefunctions.{cc,h}: Updated to remove duplicate ranges after Oliver merged Range and ComplexRange. Also moved some code around to prepare for tries at speeding up the lbl calculations 2017-12-21 Richard Larsson * arts-2-3-906 * src/m_linerecord.cc: Fixed bug reported by Oliver about precedence of operators. "not X < 0" is not "not (X < 0)" 2017-12-19 Oliver Lemke * arts-2-3-905 * src/complex.{cc,h}, src/absorption.cc, src/linefunctions.{cc,h}, src/matpackI.h, src/test_complex.cc: Remove ComplexRange class and replace all occurrences with the matpack Range class. Reduces code duplication. 2017-12-19 Oliver Lemke * arts-2-3-904 * CMakeLists.txt, src/CMakeLists.txt, config.h.cmake, src/gui/*, src/main.cc, src/parameters.cc: Remove obsolete gui testing code. 2017-12-18 Richard Larsson * arts-2-3-903 Bug reported by Oliver and now fixed: *AtFrequency functions renamed to *AtPosition. Still a potential error with switched indexing in code protected by fortran-flags... (not enough ram here to activate these...) 2017-12-18 Richard Larsson * arts-2-3-902 * src/propagationmatrix.{cc,h}: Update of PropagationMatrix and StokesVector so that their internal dimensions is Tensor4. Should always default to 0th element whenever an Index is not given. Updated names of functions to reflect this change (resulting in some other files being touched as well.) Other files touched: src/doit.cc src/m_abs.cc src/m_abs_lookup.cc src/m_linerecord.cc src/m_rte.cc src/montecarlo.cc src/rte.cc src/test_propagationmatrix.cc src/xml_io_compound_types.cc Also removed the function begining on the HSE partial derivatives since it would not work in that form. If we assume T := exp(-K(x)r(x)) we need the full derivative: -K(x)dr(x) - dK(x)r(x) as input. So we must know how the path changes alread when we are doing the propagation matrix computations. If instead we assume --- as the present code does --- that T := exp(-K(x)r(x')), then we can perform the derivatives, though this will undoubtedly introduce errors in the temperature derivatives being computed... (though only for polarized radiation) I think HSE needs to be part of ppath computations instead. Then we no longer have to square our circles. One big problem here though is that there are fields that do not depend on pressure (e.g., the magnetic field), so ppath will have to also offer a way to adopt such fields to the newely computed z_field... 2017-12-15 Jana Mendrok * arts-2-3-900 Descoped opt_prop_part_agenda and replaced by WSM opt_prop_bulkCalc. BREAKS controlfiles defining opt_prop_part_agenda. * src/doit.[cc,h] (doit_fieldsCalc): Removed opt_prop_part_agenda call and from parameter list. * src/m_doit.cc (doit_i_fieldUpdate*), src/doit.[cc,h] (doit_scat_fieldNormalize): Removed opt_prop_part_agenda from parameter list, adapted cloud_fieldsCalc calls. * src/m_optproperties.cc (TestScatDataInterp): Replaced ext_matInit, abs_vecInit, ext_matAddPart, abs_vecAddPart with opt_prop_bulkCalc. (ext_matInit, abs_vecInit, ext_matAddPart, abs_vecAddPart): Removed. * src/methods.cc: Adapted to parameter list changes above. * src/agendas.cc, src/workspace.cc: Remove definition and mentions of opt_prop_part_agenda. * controlfiles/artscomponents/doit/doit_setup.arts, doit_setup_accelerated.arts, doit_setup_newscatdata.arts, doit_setup_pressureoptimization.arts, controlfiles/general/agendasDOIT.arts: Remove use of opt_prop_part_agenda. 2017-12-13 Alex Bobryshev * arts-2-3-900 * controlfiles/instruments/metmm/sensor_descriptions/sensor_saphir.arts, sensor_hatpro.arts, sensor_mwhs2.arts: Added controlfile to simulate MWHS-2 instrument onboard chinese FY-3 satellite, also ground-based radiometer HATPRO (Greenland Summit). These two files and SAPHIR-setup now contain information where I got the viewing angles. 2017-12-11 Jana Mendrok * arts-2-3-899 * src/m_optproperties.cc (scat_dataReduceT): Consistency checks added. (scat_dataCheck): Adapt to work (or at least give proper error/warning) when applied on T-reduced scat_data. * src/m_checked.cc (scat_data_checkedCalc): Mixed up error messages disentangled. Remove redundant check for identical T-dimensions in ext and abs. * src/m_disort.cc (DisortCalc*), src/disort.cc, src/disort.h, src/m_rt4.cc (RT4Calc*): Descoped non-isotropic incoming radiation option (in RT4 it was never functional). * src/methods.cc: Adapted to changes above. 2017-12-11 Simon Pfreundschuh * arts-2-3-898 * src/arts_api.[h, cc]: Added methods to push and pop paths to the include path and data path vectors. Removed set_parameters method. 2017-12-04 Richard Larsson * arts-2-3-897 Many files changed because of a rename. Some by minor updates. Main point of this update: ARTS can now do rotational NLTE using the new line-computer. This is based on simply applying an emission constant as C n2 A21 and absorption as c (n1 B12 - n2 B21) with a few devils in the details to fit with the older vibrational NLTE implementation Last note: I had a version of this with updated numbers for some of the constants in constants.cc, however it fails the tests. Since these constants have been updated due to more accurate measurements of the speed of light, it is a bit funny that our tests require higher accuracies than is expected for the Planck and Boltzmann constants... I might commit an update for this at some point in the future * src/linerecord.h: Added population type tag to identify population level computations. Needed to avoid inputting full partition function for rotational spectra on a line-by-line basis. The old method ByLTE is standard. The ByVibrationalTemperature method is for vibrational NLTE (like Earth CO2) where you do not need to input the partition function because you assume only higher energy levels are perturbed. This was the status of NLTE in ARTS before the present commit. The new thing is to input relative ratio distributions to directly compute the NLTE effects. * src/m_linerecord.cc: Changed nlteSetByQuantumIdentifiers to set population type by GIN. Defaults to old version. * src/linefunctions.cc: Changed name from lineshapesdata. Added function to compute line strength from level distribution and Einstein coefficient based on work by Takayoshi Yamada. There will be typhon code made available to get the ratios necessary to use this code at some point in the future. For now, the ARTS code outputs almost exactly the same as the python code for limited tests of viewing geometries. We are presently writing a short paper detailing this implementation and some test cases with NLTE spectra. * src/propagationmatrix.cc: Working on (compute_transmission_matrix_distance_derivatives) as a way to get the distance derivatives needed for HSE. * src/pressurebroadeningdata.{cc,h}: Added a test-case for HTP that is extremely simplistic. Also updated errors to clearly show which function is failing (a failure at this level is the programmer's fault so it is nice to see which function you messed up...) Also updated to use switch-statements more consistently since this helps with warnings while compiling. Also changed so temperature derivatives output all the HTP variables so that the HTP implementation can be used with jacobian (even though there is still only experimental support for HTP while waiting for more data to be available from elsewhere, the code is fairly close to working in the full ARTS-context now...) * src/methods.cc: Removed unused method and added Ganymede ellipsoid (only the sphere) 2017-12-04 Oliver Lemke * arts-2-3-896 * src/lineshapesdata.cc (Linefunctions::set_htp): Replace several 2s with 2.0s to help the Intel compiler to make up its mind which operator* to use (float or double) instead of failing. 2017-12-01 Oliver Lemke * arts-2-3-895 * src/telsem.h: Add include to fix compilation with clang. Add missing throw before std::runtime_error in several places. 2017-11-27 Simon Pfreundschuh * arts-2-3-894 * src/telsem.[cc, h]: (TelsemAtlas) Made TelsemAtlas a class and added methods to perform coordinate lookup as well as angular and frequency interpolation. * src/m_telsem.cc (telsemStandalone, telsemAtlasLoopkup): Added WSMs to evaluate Telsem emissivity model and lookup SSMI emissivities from the atlas. * src/methods.cc: Added entries for new WSMs. Added ArrayOfTelsemAtlas to supergeneric classes of extract method. * src/xml_io_compound_types.cc Adapted io routines for telsem atlases. * controlfile/artscomponents/telsem/TestTelsem.arts Added a simple test for lookup and interpolation. 2017-11-27 Patrick Eriksson * arts-2-3-893 * src/m_transmitter.cc (iyTransmissionStandard2): A start ... * src/m_rte.cc (iyEmissionStandard2): * src/m_fos.cc (iyHybrid): Just changes in comments. 2017-11-24 Jana Mendrok * arts-2-3-892 * src/m_optproperties.cc, methods.cc (scat_dataReduceT): Added. Work in progress. (scat_dataCalc): Do check for single-entry, but identical f-grids directly here. * src/check_input.[cc,h] (chk_interpolation_grids): Allow order=0. Make work for case when old_grod.nelem==1 and order=0. Moved check for single-entry, but identical grids grids out again. * src/interpolation_poly.cc (interpweights,interp): Fixed itw dimension documentation. * src/m_psd.cc (psdW16), doc/uguide/interpolation.tex: Typos fixed. 2017-11-23 Patrick Eriksson * arts-2-3-891 * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Updated. * src/m_fos.cc (iyHybrid2): Removed. * src/m_fos.cc (iyHybrid): Seems to work! 2017-11-23 Patrick Eriksson * arts-2-3-890 * src/m_fos.cc (iyHybrid): Adopted to change in rtmethods_unit_conversion. * src/m_rte.cc (iyEmissionStandard2): Adopted to change in rtmethods_unit_conversion. * src/rte.cc (rtmethods_unit_conversion): Now also handling ppvar_iy. 2017-11-23 Oliver Lemke * arts-2-3-889 * src/matpackI.cc, src/matpackIII.cc, src/matpackIV.cc, src/matpackV.cc, src/matpackVI.cc, src/matpackVII.cc: Fix bug in move assignment operators. Against my previous assumption, the Range objects of the rvalue reference need to be zeroed out. There are cases when the rvalue object is reused after being moved. For example when inserting into an array, the move assignment is used to make space for the new element (but only if the Array has enough reserved space, otherwise the copy constructor is used to copy every element over to a newly allocated Array). The new element is then assigned to the free spot. If the move assignment doesn't zero out the Range object, this can lead to a NULL pointer access if the new element happens to have the same size as the element that was previously in this position. The moved elements data pointer got set to NULL by the move constructor, but is not reallocated on assignment if the size of the new element is the same (Range member). This bug caused a segfault in TestDOITpressureoptimization when ARTS was compiled with Clang. * src/m_doit.cc (OptimizeDoitPressureGrid): Use std::move to add newLayer to scat_data_local. 2017-11-23 Patrick Eriksson * arts-2-3-888 * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Fixed so there is no parser errors. Deactivated Compare-s, as things are under development. * src/m_ppath.cc (ppathCalc): Added GIN ignore_cloudbox, to simplify things around usage of iyHybrid. * src/m_fos.cc (iyHybrid): doit_i_field is now an input argument. iy_aux and ppvar tested. 2017-11-23 Patrick Eriksson * arts-2-3-887 * src/m_fos.cc (iyHybrid): Added handling of iy_aux. Some smaller polishing. Tests done. * src/m_rte.cc (iyEmissionStandard2): Adopted to change below, and removed scat_species as input. * src/rte.cc (rtmethods_jacobian_init): Check of dpnd_field_dx moved here. 2017-11-22 Jana Mendrok * arts-2-3-886 * src/m_checked.cc, methods.cc (scat_data_checkedCalc): Add check of scatt element single-value f_grid against WS f_grid (shouldn't be too far off, e.g. we shouldn't be able to use a single freq point for all ICI channels). * src/check_input.[cc,h] (chk_interpolation_grids): Added check that order>0. Added special case handling of n_old==n_new==1. * src/m_optproperties.cc (scat_dataCalc): Add ability to rerun scat_dataCalc on data that has already been freq-reduced, i.e. skip freq interpolation if nf_old==nf_new==1 and f_old==f_new. Fix (so far irrelevant) bug in T-dimension looping. * src/workspace.cc: Spell fix. 2017-11-22 Patrick Eriksson * arts-2-3-885 * src/rte.cc (rtmethods_jacobian_init): Removed outdated error. * src/m_fos.cc (iyHybrid): This is now the most updated version of the method. A merged version between iyHybrid2 and iyEmissionStandard2. Revison not totally finished. * src/workspace.cc: Introduced ppvar_pnd. * src/m_rte.cc (iyEmissionStandard2): Added handling of ppath_iy. * src/workspace.cc: Introduced ppvar_iy. 2017-11-22 Jana Mendrok * arts-2-3-884 * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Remove do_only_x=1 setting from ScatSpeciesSizeMassInfo calls since we now use the scat_species_a/b in the psd* WSMs for checking correct setup. 2017-11-22 Patrick Eriksson * arts-2-3-883 * src/rte.cc (rtmethods_jacobian_finalisation): diy_dpath was declared as const even though its content is modified in the function. Fixes the issue I have reported to Richard. 2017-11-22 Oliver Lemke * arts-2-3-882 * AUTHORS: Updated email addresses and contributors list. 2017-11-21 Jana Mendrok * arts-2-3-881 * src/rte.cc (get_stepwise_scattersky_source): Initialize dSp_dx with 0 for non-pnd-affected Jac species. Fixes the wrong-H2O-Jacs when number freqs is >3 (so, not a dimensioning but an initialization bug). * AUTHORS: Moved myself up to "Authors of important components" and updated my email. 2017-11-21 Patrick Eriksson * arts-2-3-880 * src/m_psd.cc (psd_rwc_common, psdMH97): More detailed error message if a or b is wrong. The bad value now printed. 2017-11-21 Oliver Lemke * arts-2-3-879 * src/gas_abs_lookup.cc (find_new_grid_in_old_grid): Replaced fixed tolerance of 1 Hz in comparison by a tolerance that uses a DBL_EPSILON times the frequency value being compared. This should prevent two neighboring frequencies being so close together in the old grid that one of them is selected twice for the new grid (leading to a not increasing assertion). Assertion in abs_lookupAdapt reported by Jana. 2017-11-20 Patrick Eriksson * arts-2-3-878 * src/m_rte.cc (iyEmissionStandard2): Now supports iy_aux_vars, but there is now just two options: "Transmission" and "Radiative background". * src/workspace.cc: Introduced iy_aux2. Will replace iy_aux, that will become an ArrayOfMatrix. 2017-11-20 Patrick Eriksson * arts-2-3-877 * src/m_rte.cc (iyEmissionStandard2): Work to avoid resizing of variables, and to make use of the new feature that joker works for empty dimensions. * src/rte.cc: (rtmethods_jacobian_init): Some restructuring to avoid resizing of variables. (get_ppath_atmvars): Now always set to have size (nnlte,np). Before if-statement and could be set to have size (0,0). 2017-11-20 Patrick Eriksson * arts-2-3-876 * src/m_rte.cc (iyEmissionStandard2): Seems to work for iy. * src/rte.cc (rtmethods_jacobian_init): New. 2017-11-20 Oliver Lemke * arts-2-3-875 * src/matpackI.cc (Range::Range): Slightly adapt assertion in Range constructor to allow selecting empty dimensions with a joker. * src/test_matpack.cc: Add test47 to verify the above change. 2017-11-20 Patrick Eriksson * arts-2-3-874 * src/workspace.cc: Introduced ppvar_p, ppvar_t, ppvar_t_nlte, ppvar_vmr, ppvar_wind, ppvar_mag, ppvar_f. * src/m_rte.cc (iyEmissionStandard2): A bit more ... 2017-11-19 Patrick Eriksson * arts-2-3-873 * src/m_rte.cc (iyEmissionStandard2): Started. * src/rte.cc (rtmethods_jacobian_finalisation) (rtmethods_unit_conversion): New. 2017-11-17 Oliver Lemke * arts-2-3-872 * src/methods_aux.cc (MdRecord::MdRecord): Throw runtime errors if GIN and GOUT share a parameter with the same name or one of them contains duplicate parameter names. * ChangeLog: Fix terminology in previous commit. copy-construct -> conversion-construct. 2017-11-17 Oliver Lemke * arts-2-3-871 * src/m_fos.cc (iyHybrid2): Fix runtime error when compiling with clang. If one of the 2nd and 3rd operands of the ternary operator is a non-const View type, the other one cannot be a temporary (which is an rvalue). Since both operands need to be converted to the same type, the compiler then tries to conversion-construct a non-const View from an rvalue (const) object, which is not allowed . E.g.: ppath_t_nlte.nrows()?ppath_t_nlte(joker, ip):Vector(0) ppath_t_nlte returns a VectorView. Since VectorView is the first common base class between VectorView and Vector, the compiler tries to conversion-construct a VectorView from Vector(0). Because Vector(0) is const in this case as it is a temporary, conversion fails. This can be avoided by explicitly converting the Vector(0) to a ConstVectorView: ppath_t_nlte.nrows()?ppath_t_nlte(joker, ip):ConstVectorView(Vector(0)) Now the first common base class between the two operands is ConstVectorView and thus the first operand is used to conversion- construct a ConstVectorView from a VectorView which is allowed. For detailed information about the ternary operator's behaviour see the "Conditional operator" section at http://en.cppreference.com/w/cpp/language/operator_other Especially 3): ... if E2 and E3 have different types, at least one of which is a [...] class type, [...], then an attempt is made to form an implicit conversion sequence ignoring member access, [...] from each of the operands to the target type determined by the other operand, [...] Can't really tell whether clang's implementation or gcc's decision to conversion-construct a ConstVectorView in both cases follows the C++ standard more correctly. * src/methods.cc (surfaceTessem): Remove spurious backslash. 2017-11-12 Simon Pfreundschuh * arts-2-3-870 * src/tessem.cc: (tessem_prop_nn): Changed frequency and salinity units to SI units. * src/m_surface.cc: (surfaceTessem): Moved frequency conversion down to tessem_prop_nn * controlfiles/artscomponents/tessem/TestTessem.arts: Updated tests to new units. Also set salinity to non-zero value to check unit. Or were those fixed values from some external reference? 2017-11-12 Simon Pfreundschuh * arts-2-3-869 * 3rdparty/invlib/src/invlib/*: invlib update * src/m_oem.cc: (OEM): Return right error code when maximum gamma is reached. * src/methods.cc: (OEM) Minimal fix for documentation. 2017-11-12 Patrick Eriksson * arts-2-3-868 * doc/uguide/rte_theory.tex: A small extension of surface part, to reflect new strategy on how to set R when r_v and r_h are given. * doc/uguide/clouds_theory.tex: The name of WSM psdMgdMassMeanParticleMass was incoorect. * controlfiles/general/agendas_surface.arts: Removed Ignore(rtp_los) from agendas dealing with rtp_los. * src/workspace.cc: Introduced surface_rv_rh. * src/m_surface.cc: (surfaceTessem): Added some checks, including a limitation to 5 to 900 GHz (somewhat wider than the specified range of 10 to 700 GHz). Output arguments now created by making use of surfaceFlatRvRh. Reflectivities now forced to be inside [0,1]. (FastemStandAlone): Now an error if frequency is above 250 GHz. Now also an errror if surface_skin_t < 260. Before this limit was 200 K. (iySurfaceFastem): Now using specular_losCalcNoTopography and a number input arguments could be removed. Lower-right diagonal of surface_rmatrix now filled. (specular_losCalc): Now using specular_losCalcNoTopography if atmosphere_dim == 1 || ignore_surface_slope. (surfaceFlatRvRh): New WSM. (specular_losCalcNoTopography): New WSM. (surfaceBlackbody): Added rtp_pos and rtp_los as input, and added checks of these variables. (surfaceSemiSpecularBy3beams,surfaceSplitSpecularTo3beams): Added check of rtp_pos and rtp_los. (surfaceLambertianSimple): Added rtp_pos as input, and added check of rtp_pos and rtp_los. (surfaceFlatReflectivity,surfaceFlatScalarReflectivity): Added rtp_pos and rtp_los as input, and added check of rtp_pos, rtp_los and specular_los. (surfaceFlatRefractiveIndex): Added rtp_pos as input, and added check of rtp_pos, rtp_los and specular_los. * src/check_input.cc (chk_rte_los): Changed the error message to be more general. Before it was assume that rte_los was checked, while the method can be used for any los-vector. 2017-11-09 Simon Pfreundschuh * arts-2-3-867 * src/arts_api.[h, cc] Add method that prints formatted method documentation to string buffer. 2017-11-09 Oliver Lemke * arts-2-3-866 * src/sourcetext.{h,cc} (SourceText): Add ability to mark the current position in controlfile for later use. This helps to output the correct line number in error messages for certain cases. * src/parser.cc (ArtsParser::parse_method): Set mark before reading the method name. * src/parser.cc (ArtsParser::parse_method_args): Use the marked position in error reporting for method calls without parenthesis. Fixes trac ticket #155 reported by Simon. 2017-11-08 Oliver Lemke * arts-2-3-865 * doc/uguide/development.tex: Update arts-dev list address. 2017-11-08 Oliver Lemke * arts-2-3-864 * README: Updated ARTS URL. Reported by Jana. 2017-11-06 Jana Mendrok * arts-2-3-863 * src/optproperties.cc (ext_matTransform): Bug fix in PTYPE_AZIMUTH_RND higher stokes dim propmat handling. * src/rt4.cc (sca_optpropCalc): Bug fixes in azimuthal weight calculation and application. * src/m_microphysics.cc, methods.cc: Typos fixed. 2017-11-06 Simon Pfreundschuh API BREAKING! This may break your controlfiles if you are using OEM. * arts-2-3-862 * src/covariance_matrix.[h,cc]: - Refactored CovarianceMatrix class and updated documentation to some extent. * src/m_basic_types.cc: - Added WSM to create dense and sparse diagonal matrices from vectors. * src/m_retrieval.cc: - Made covmat_seSet, covmat_seAddBlock, covmatSeAddInverseBlock, covmat_sxSet, covmat_sxAdd, covmat_sxAddInverseBlock supergeneric. - Made covmat1D, covmat1DMarkov and covmatDiagonal supergeneric. - Removed covmat_se from arguments to retrievalDefClose * src/test_covariance_matrix.cc: - Extended tests to cover also workspace methods. * controlfiles/artscomponents/oem/TestOEM.arts: - Adapted controlfile 2017-11-06 Richard Larsson * arts-2-3-861 * src/lineshapesdata.cc: Now the HTP function work as expected, derivatives and all, for Voigt-like input. The forward calculations emulate the original paper with a lot of if-then-else-then statements, making it a bit difficult to read the code without having the original paper to read. I will try to fix this but there are many asymptotes so the multiple-choice pathing might be the only way to get this done. 2017-11-05 Patrick Eriksson * arts-2-3-860 * src/m_psd.cc (psdA12): New WSM. * src/psd.cc (psd_rain_A12): New function. * src/math_funcs.cc (mgd_with_derivatives): Renamed the old mgd. (mgd): A version with derivatives. * src/psd.cc: * src/psd.h: New files. And moved psd_cloudice_MH97, psd_rain_W16 and psd_snow_F07 to these files. * src/m_psd.cc (psd_mono_common): Common code for mono-type PSDs. (psdMono, psdMonoMass): Now using common function. (psdW16): Now using commin code. (psd_rwc_common): Common code for PSDs taking just RWC as input. * src/CMakeLists.txt: Added m_psd.cc and psd.cc. * src/m_psd.cc: Started this file, and put all new PSD WSMs here. * src/m_psd.cc (psd_mgd_mass_and_something): A common function, that handles all psdMgdMassSomething WSMs. Saved at least 500 lines of code, and should made it easier to add new "Something". (psdMgdMassNtot): Now finished and tested. (psdMgdXxx): Repeated basic test of all these MGD PSDs. That is, checked in matlab that PSD generated matches the input, and checked derivatives by doing perturbations. * doc/uguide/clouds_theory.tex: Had missed one term in chain rule for mass derivative in Ntot-version. Some polishing of Ntot part. 2017-11-03 Patrick Eriksson * arts-2-3-859 * src/m_microphysics.cc (psdMgdMassNtot): New WSM. Derivative part not yet ready. Left for another day. * doc/uguide/clouds_theory.tex: Derived equations for psdMgdMassNtot. * src/m_oem.cc (vmr_fieldClip, particle_bulkprop_fieldClip): New WSMs. 2017-11-03 Patrick Eriksson * arts-2-3-858 * src/m_basic_types.h (IndexSetToLast): New generic WSM. Very similar to nelemGet, but needed due to the very stupid idea of some programming languages to use zero-based indexing! The idea is to simplify the setting of index variables, to ensure consistency between different parts of a cfile. A small example: retrievalAddScatSpecies( species = "IWC", ... ) IndexCreate( i_iwc ) IndexSetToLast( i_iwc, jacobian_quantities ) ... xClip( ijq = i_iwc, limit_low=1e-9 ) 2017-11-03 Simon Pfreundschuh * arts-2-3-857 * src/m_surface.cc (surfaceTessem): Fixed computation of Q component and related coefficients. 2017-11-03 Patrick Eriksson * arts-2-3-856 * src/m_oem.cc (xClip): New WSM. (Tensor4Clip): New, but not yet activated. * src/m_microphysics.cc (psdXXX): Corrected error message. 2017-11-02 Simon Pfreundschuh * arts-2-3-855 * src/m_surface.cc: Added WSM to calculate surface emisison and reflexivity using TESSEM. * src/methods.cc: Added md_data entry for new WSM. 2017-11-02 Richard Larsson * arts-2-3-854 * src/jacobian.cc: Added an OK for having 1-long grids and same vector as retrieval coordinates in the grid-tests. * src/linemixingdata.{cc,h}: Added a SetInternalDerivatives function to make it to set partial derivatives vector * src/linescaling{h,cc}: Bug fix for dstimulated_relative_emission_dT. Missed the actual temperature dependency in my copy-paste creation of this prior... * src/lineshapesdata.{cc,h}: Fixed so that Voigt, Doppler, Lorentz, all types of mirroring, cutoff, all types of normalization, and line mixing partial derivatives works for temperature, frequency/wind, all pressure broadening parameters, all rescaling line mixing parameters. Need to still test that this all works in NLTE, in Zeeman, and for frequency-shifting line mixing parameters. Also need to work on HTP to get a good overview of how to make its derivatives work (main problem: there exists 3 types of div-zero conditions that has to be covered to compute the line shape depending on input. One of those div-zero conditions is Voigt-like, another is far-wing Lorentz-like, and the third is Doppler-like. Forward simulations of these are easy but I find that partial derivatives are difficult to implement cleanly because of this.) 2017-11-02 Patrick Eriksson * arts-2-3-853 * doc/uguide/clouds_theory.tex: Comments on parameter limits added. * src/m_microphysics.cc (psdMgdMassMeanParticleMass): The method was wrongly name. It deals with mean mass, not mean size. (psdMgdXxxx): Introduced parameter limits, to avoid numerical issues. Limits specified in built-in doc. 2017-11-02 Oliver Lemke * arts-2-3-852 * controlfiles/instruments/hirs/TestHIRS_fast.arts, controlfiles/instruments/hirs/TestHIRS_reference.arts: Merge HIRS test cases into two stand-alone files after discussion with Stefan. The files were split up into too many, confusing small control files. The reference file currently fails in sensor_responseBackend (same error as the original before merging). Needs further investigation. * controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/hirs/hirs_fast.arts, controlfiles/instruments/hirs/hirs_general.arts, controlfiles/instruments/hirs/hirs_hitran.arts, controlfiles/instruments/hirs/hirs_reference.arts, controlfiles/instruments/hirs/hirs_sensor_common.arts, controlfiles/instruments/hirs/hirs_sensor_fast.arts, controlfiles/instruments/hirs/hirs_sensor_reference.arts, controlfiles/instruments/hirs/hirs_spectroscopy.arts: Removed. * controlfiles/CMakeLists.txt: Add TestHIRS_reference to nocheck category. 2017-11-01 Patrick Eriksson * arts-2-3-851 * doc/uguide/references.bib: Added two references, used in PSD chapter. * doc/uguide/clouds_theory.tex: A restart of this chapter. It is now dedicated to PSDs. So far containing the math behind the MGD PSDs. * doc/uguide/CMakeLists.txt: clouds_theory.tex was missing. * src/m_microphysics.cc (psdMgdMassMeanParticleSize): New WSM. (psdMH97, psdW16): Now takes scat_species_a and scat_species_b as input, and the values are checked to be reasonable. Corrected header text. (psdMgdMass,psdMgdMassXmean,psdMgdMassXmedian): Cosmetic changes, to make the code more consistent with the documentation. (psdF07): scat_species_a and scat_species_b now always checked. Corrected header text. 2017-10-30 Richard Larsson * arts-2-3-850 * src/absorption.cc: Added some comments and changed the range (it did not work when cutoff-range was inside range) * src/linerecord.cc: Added some comments and fixed reading routine error * src/lineshapesdata.{cc,h}: Added lots of comments and split frequency-shift by pressure and line mixing up. Also added one of the limits of HTP and changed function names to be more descriptive. * src/m_abs.cc: 'fixed' an error found using the C API (nlteOff had to be called, but some variables have values regardless. It seems to me that we need to have all variables initialized at start for the C API assertions to stop happening?) * src/m_linemixing.cc: Updated with name change * src/test_propagationmatrix.cc: A few more tests to make sure the implementation is as intended... 2017-10-20 Richard Larsson * arts-2-3-849 The implementation of new lineshape routine should essentially be working now but will need some more testing. Radiation calculations can be made to fit with tests but optical depths are not passing the same tests. I Also need to test that it is as easy as I think to add new methods * src/absorption.cc: Adopted for cutoff * src/linerecord.{cc,h}: Test implementation of method to input cutoff, line mirroring, specific line shape, and line normalization via ARTSCAT-5. * src/ linehshapesdata.{cc,h}: Adopted for the above. Clears all y-tests while switching to *AddLines2 if changed to the correct behavior manually (i.e., setting VVH- normalization or cutoff frequency). Fails iy-aux optical depth tests though for unknown reasons. 2017-10-20 Patrick Eriksson * arts-2-3-848 * src/m_microphysics.cc (psdXXXXXX): Switched to use NaN instead of Inf for flagging non-fixed parameters. Clarified that -999 identifies dependent parameters. 2017-10-20 Oliver Lemke * arts-2-3-847 * src/m_telsem.cc, src/telsem.{h,cc}, src/methods.cc, src/CMakeLists.txt: Add reading routine telsem_atlasesReadAscii for TELSEM 2 SSMI atlas data. To actually use the data in ARTS further work is needed. Esp. the fortran routines equare and calc_cellnum (to determine the cellnum inside the atlas from a given lat/lon) from mod_mwatlas_M2.f90 and the actual emissivity extraction need to be implemented. * src/groups.cc: Add ArrayOfTelsemAtlas and TelsemAtlas group. * src/workspace.cc: Add telsem_atlases WSV. * src/xml_io_array_types.cc, src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add read/write support for [ArrayOf]TelsemAtlas. * src/make_auto_md_h.cc, src/make_auto_workspace_h.cc: Include telsem.h. 2017-10-20 Patrick Eriksson * arts-2-3-846 * src/m_microphysics.cc (psdMgdMassXmedian): A slight renaming. Seems to work now. But only n0 and la allowed as dependent vars. (psdMgdMassXmean): New. As psdMgdMassXmedian but takes mean size as input instead of the median one. (psdMgdMass, psdMgdMassXmedian): Changed internal nomenclature, from implied to dependent parameter(s). Corrected error messages. 2017-10-19 Patrick Eriksson * arts-2-3-845 * src/m_microphysics.cc (psdMono, psdMonoMass): New WSMs, handling mono-dispersive PSD cases. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Updated to removal of pnd_size_gridFromScatMeta. * src/m_microphysics.cc (psdMgdMass): Added checks that input argument to gamma is > 0. (psdMgdMassDmedian): More work, but not yet ready. (psdF07): Now using scat_species_a and scat_species_b. (ScatSpeciesSizeMassInfo): Introduced GIN do_only_x. Now also default values for x_fit_start (0) and x_fit_end (1e9). (pnd_size_gridFromScatMeta, MassSizeParamsFromScatMeta): Removed. Use ScatSpeciesSizeMassInfo instead. * src/math_funcs.cc (mgd): We can not just return with n0=0 as derivatives could still be of interest. 2017-10-19 Patrick Eriksson * arts-2-3-844 * src/m_microphysics.cc (psdMgd): Updated to be as similar to psdMgdMass as possible. (psdMgdMass): Seems to work, but so far only n0 and lambda can be implied parameters.. 2017-10-18 Richard Larsson * arts-2-3-843 * controlfiles/general/agendas.arts: Found bad Zeeman agenda (much slower than it should be). Might break some controlfiles that rely on this... * src/absorption.{cc,h}: Added xsec_species2. Need to add line-record information to replace normalization, cutoff, mirroring, and anything else special that we might wanna do. * src/linemixingdata.{cc,h}: Just updating defaults * src/linescaling.cc: minimal changes * src/lineshapedata.{cc,h}: Will be renamed linefunctions.{cc,h} soon. Added a full lineshape+linestrength calculator that should take all present partial derivatives into account. (Not remotely near fully tested) * src/m_abs.cc: abs_xsec_per_speciesAddLines2. Passes most tests when replacing abs_xsec_per_speciesAddLines but two tests that relies on cutoff fails. The new method is 10% slower through 'make check', though it is not parallelized yet so this might go away. Found a strange bug where our Complex class is not compatible with openmp #pragma omp atomic It relies heavily on complex number multiplication so setting fcx-fortran-rules helps compensate some speed loss in a Fortran- compatible but IEEE-incompatible way * src/m_atmosphere.cc: Error comment change * src/m_checked.cc: Accepts either normal or 2 for the line- adding function. * src/ methods.cc: Added name 2017-10-18 Patrick Eriksson * arts-2-3-842 * src/m_microphysics.cc (psdMgdMass): Some lines added. * src/math_funcs.cc (mgd): A bit more documentation. 2017-10-18 Patrick Eriksson * arts-2-3-841 * src/m_microphysics.cc (psdMgdMass): Extended, but still work in progress. * src/m_microphysics.cc (ScatSpeciesSizeMassInfo): A generalised combo of pnd_size_gridFromScatMeta and MassSizeParamsFromScatMeta. * src/microphysics.cc (derive_scat_species_a_and_b): A generalisation of MassSizeParamsFromScatMeta. * src/workspace.cc: Introduced scat_species_a, scat_species_b and scat_species_x. 2017-10-18 Oliver Lemke * arts-2-3-840 * CMakeLists.txt: Explicitly call enable_language for C and CXX. Otherwise latest CLion version doesn't search for C++ standard library header files. 2017-10-16 Simon Pfreundschuh * arts-2-3-839 * src/arts_api.cc (agenda_insert_set): Fixed implementation so that values of type Numeric are handled correctly. Thanks to Richard for reporting this bug. 2017-10-16 Oliver Lemke * arts-2-3-838 * src/matpackI.h (Iterator1D): Add operator== and operator- when compiled with libstdc++ to make Iterator1D compatible with stl functions such as std::any_of. Reported by Richard. * src/test_matpack.cc (test46): Add test for std::any_of. 2017-10-16 Oliver Lemke * arts-2-3-837 * src/parser.cc (ArtsParser::parse_method_args): Also consider output arguments. 2017-10-16 Oliver Lemke * arts-2-3-836 * src/parser.cc (ArtsParser::parse_method_args): Improve error message for wrong or duplicate named arguments. Reported by Patrick. 2017-10-16 Simon Pfreundschuh * arts-2-3-835 * src/oem.h (ArtsLog::step): Change name of variable to avoid shadowing of function name. * src/m_oem.cc(OEM): Fix naming of covariance matrices and damping matrix of LM method. * src/covariance_matrix.[h,cc] (get_inverse): Added function to extract inverse from covariance matrix. * 3rdparty/invlib/src/invlib/interfaces/arts_wrapper.h: Fixed conversion to dense matrix. 2017-10-15 Stefan Buehler * arts-2-3-834 * src/absorption.cc (xsec_single_line): Stuart Fox has reported the bug that for mirror lines (negative F0) the shift was in the wrong direction. Added an if statement that makes sure that the shift goes in the other direction for negative frequency mirror lines, so that they really end up at the negative of the frequency of the original line. 2017-10-13 Jana Mendrok * arts-2-3-833 * src/rte.cc (get_stepwise_scattersky_source): Bugfix in setting up pnd input for pha_mat_sptFromScat_data. Fixes bug reported by Patrick (hopefully...). * src/m_optproperties.cc ([opt_prop,pha_mat]_sptFrom*): Identical temperature-range-exceed error messages are raised by all the methods. For easier debugging, add info by which (non-WS-)method it was raised. 2017-10-13 Patrick Eriksson * arts-2-3-832 * src/m_microphysics.cc (psdMgdMass): A small start. (psdMgd): Non-fixed parameters are now flagged by Inf, instead of NaN. * src/math_funcs.cc (gamma_func, lgamma_func): Removed. std::tgamma and std::lgamma are now at hand. (mgd): Moved from microphysics.cc. 2017-10-12 Patrick Eriksson * arts-2-3-831 * src/m_microphysics.cc (psdF07, psdMH97, psdW16): To calculate dpsd_data_dx, the perturbation of IWC/RWC is now always 1e-9. That was found to work better in tests. * src/m_jacobian.cc (jacobianAddFreqShift): It is now checked that length of f_grid is > 1, which is a required by the code. 2017-10-11 Oliver Lemke * arts-2-3-830 * src/agenda_record.cc (operator<<): Inputs and outputs were not printed for ArrayOfAgenda. Fixes bug reported by Patrick. 2017-10-11 Simon Pfreundschuh * arts-2-3-829 * src/arts_api.[h.cc] (get_version, VersionStruct): Added function and struct to return ARTS version number. 2017-10-10 Jana Mendrok * arts-2-3-828 * src/m_fos.cc (iyHybrid2): Put derivative variable manipulation behind jacobian_do/j_analytical_do barriers. This as perturbation jacobian calcs will call the iy_main_agenda with jacobian_do flag, but unmodified jacobian_quantities settings (i.e. we can not rely on the contents or size of jacobian_quantities only). Should work now for all kinds of jacobian species. * src/rte.[cc,h] (get_stepwise_scattersky_propmat, get_stepwise_scattersky_source, get_stepwise_effective_source): Pass jacobian_do and put derivative manipulation behind barriers. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Work in progress. Set back to use cheval data shipped with arts. 2017-10-09 Jana Mendrok * arts-2-3-827 * src/rte.cc (get_stepwise_clearsky_propmat, get_stepwise_effective_source): Fixing issues that commit arts-2-3-823 brought up (its break of TestWfunsHybClear test case went unnoticed :-/) by further active initializations of variables and by replacing the not-applicable-anymore IsEmpty by an explicit check for analytical jacobians (the macro doesn't work here, though). * src/m_microphysics (pnd_fieldCalcFromParticleBulkProps): Fixed to allow pnds and dpnd_dx to be non-zero at the cloudbox limits when cloudbox limits at BOA and/or TOA. Fixes the issue of 0-tied Jacobians at BOA in iyHybrid2. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Work in progress, testing further Jac species. 2017-10-08 Patrick Eriksson * arts-2-3-826 * src/methods.cc (define_md_data_raw): Extended doc for psdMgd. 2017-10-08 Patrick Eriksson * arts-2-3-825 * src/m_microphysics.cc (psdMgd): A general treatment of MGD for the case when the native paraneters are used (i.e. n0, mu, la and ga). (psdExpN0Lambda): Removed. * src/m_microphysics.cc (psdMH97,psdF07, psdW16): Now using an even more genral macro for initial part of function. * src/microphysics.cc (psd_general_MGD): Revised and extended. Can now also return the derivative with respect to n0, mu, la and ga. 2017-10-08 Patrick Eriksson * arts-2-3-824 * src/m_microphysics.cc (psdMgd1free, psdExpN0Lambda): Started to play around with how to implement MGD PSDs in a relatively general manner. But so far just test coding. * src/m_microphysics.cc (psdMH97,psdF07, psdW16): Removed demand that input must have a specific name. Start of methods now handled by a common macro. Added check of t_min vs t_max. 2017-10-06 Jana Mendrok * arts-2-3-823 * src/m_fos.cc (iyHybrid2), rte.cc (get_stepwise_clearsky_propmat): Some further proper initializations. Cleanup. * src/partial_derivatives.h: Added missing extern const declaration for SCATSPECIES_MAINTAG (needed now in get_stepwise_clearsky_propmat and all other jacobian tags seem to be drawn from there). * src/m_jacobian.cc (jacobianDoit, jacobianDoitAddSpecies): Consider cloudbox-at-TOA case. Bugfix jacobian sizing for cloudbox-not-at-surface case. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Work in progress, trying to get comparable setups for iyHybrid and JacobianDoit jacobians. * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Fixed bug introduced in arts-2-3-820. 2017-10-06 Simon Pfreundschuh * arts-2-3-822 - Dummy change to trigger Hudson build. 2017-10-06 Simon Pfreundschuh * arts-2-3-821 * oem.h(ArtsLog): - Fixed verbosity of output for zero verbosity. * m_oem.cc(OEM): - Fixed computation of start cost for *oem_diagnostics*. * m_retrieval.cc(retrievalErrorsExtract): - Added method to extract errors from error covariance matrices. * methods.cc(retrievalErrorsExtract): - Added WSM to extract errors from error covariance matrices. * workspace.cc(retrieval_eo, retrieval_ss): - Added WSVs for retrieval error due to measurement noise (retrieval_eo) and limited resolution of observation system (retrieval_ss) * controlfile/artscomponents/oem/TestOEM.arts: - Added retrievalErrorsExtract WSM to controlfile. 2017-10-05 Jana Mendrok * arts-2-3-820 * src/m_fos.cc (iyHybrid2): Initialize jacobian containers properly. Makes plenty of the former issues go away. Removed the IsEmpty checks accordingly. * src/rte.[cc,h] (get_stepwise_scattersky_propmat, get_stepwise_scattersky_source): Use FOR_ANALYTICAL_JACOBIANS_DO instead of blindly looping over jacobian dimension. * src/m_append.h, methods.cc (Append): Added Tensor3-to-Tensor4 append flavour. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Write out instrumental jacobians. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Switch on instrumental jacobians and test vs. TestWfuns.arts results. * controlfiles/artscomponents/wfuns/TestWfunsHybCloudy.arts: Added. Work in progress. * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Minor clean up. 2017-10-05 Richard Larsson * arts-2-3-819 * src/arts_api.cc, src/interactive_workspace.{cc,h}: Added Tensor4 2017-10-05 Richard Larsson * arts-2-3-818 * src/m_fos.cc: Change trying to debug error reported by Jana (I cannot reproduce the error, but these changes should make it more robust) 2017-10-04 Patrick Eriksson * arts-2-3-817 * src/microphysics.cc (psd_rain_W16): Bug fix. The factor 100 was applied on lambda too early, and then gave an incorrect N0. * src/m_cloudradar.cc (iyActiveSingleScat): Retrieval of e.g. both rain and ice diod not work as scattering properties were extracted quite blindly and temperature interpolation problems occured. Scattering properties now only extracted were actually needed. * src/m_oem.cc (xaStandard): Corrected error string associated with particle_bulkprop_field. 2017-10-04 Richard Larsson * arts-2-3-816 * src/m_fox.cc: Should now work with sensor jacobians * src/jacobian.cc: Updated some comments 2017-10-03 Simon Pfreundschuh * arts-2-3-815 * src/m_oem.cc (x2artsStandard, xaStandard): - Added conversion for wind components * src/methods.cc (x2artsStandard, xaStandard): - Added wind fields to arguments * src/special_interp.cc(regrid_atmfield_by_gp): - Fixed if statement for 3D atmosphere 2017-10-03 Jana Mendrok * arts-2-3-814 * src/rt4.cc (sca_optpropCalc): Revision for more consistent handling of scattering matrix (from single T-gridpoint) with extinction and absorption data (from T-interpolation). Preservation of bulk-Z norm needs to be checked vs. gridpoint-T ext/abs (regards the structure of the phase function), but output bulk-Z for RT4 solution needs to be normalized to bulk-scatt coeff consistent with ext/abs extracted for use in RT4 solution (regards the scattering coefficient). ATTENTION: This needs to be taken care of also when implementing T-grid reduction for scat_data. Seems to be a bad idea to allow K and a on different T-grids than Z (or we need to use unity-normalized Z. or keep track of which T is used for Z when reduced to single T-point). * src/m_fos.cc(iyHybrid2), src/m_cloudradar.cc (iyActiveSingleScat): Pass scat_species for getting scat jacobian pointers. Safety check for jacobian_quantities and dpnd_field_dx consistency (dpnd_field_dx needs filled array elements for scat jacobian, empty elements for non-scat jacobians). * src/m_checked.cc (cloudbox_checkedCalc): Made scat_data check non-scat_species safe. * src/optproperties.cc (pha_mat_labCalc, interpolate_scat_angle): Minor stuff. * controlfiles/general/general.arts: Initialize dpnd_field_dx. * controlfiles/artscomponents/hybridscat/TestHybrid.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: Remove now redundant dpnd_field_dx initialization. 2017-10-03 Simon Pfreundschuh * arts-2-3-813 * src/m_oem.cc (x2artsStandard) - Removed trailing whitespaces * src/m_retrieval.cc (retrievalDefClose) - Removed size check between covmat_se and sensor_response. * controlfiles/artscomponents/oem/TestOEM.arts - Fixed order of retrieval definition and cloudbox_checkedCalc 2017-10-02 Patrick Eriksson * arts-2-3-812 BREAKS CONTROLFILES using iy_surface/surface_rtprop__sub_agenda. * The system for surface types is now changed to make use of the ArrayOfAgenda mechanism. * src/m_surface.cc (surface_rtpropCallAgendaX) (iySurfaceCallAgendaX): New methods, replace the sub_agenda methods. * src/workspace.cc: * src/agendas.cc: iy_surface_sub_agenda0-5 and surface_rtprop_sub_agenda_0-5 replaced with iy_surface_agenda_array and surface_rtprop_agenda_array, respectively. 2017-09-29 Jana Mendrok * arts-2-3-811 BREAKS CONTROLFILES. * src/m_fos.cc(iyHybrid2), src/rte.[cc,h] (get_stepwise_scattersky_propmat, get_stepwise_scattersky_source): Moved cloudy-level-check outside the scattersky methods, ie only call them for cloudy levels. This also circumvents previous issues with un-updated cloud contributions. Add explicit check for dpnd_field_dx consistency with jacobian_quantities. * src/m_cloudbox.cc(cloudboxOff, pnd_fieldCalcFrompnd_field_raw, pnd_fieldZero, pnd_fieldCalcFromscat_speciesFields): Output dpnd_field_dx, sized consistently with jacobian_quantities. * src/m_checked.cc (cloudbox_checkedCalc): Don't check particle_bulkprop_field. But do check dpnd_field_dx, for consistency with jacobian_quantities (ie we now need to make the jacobian definitions before this). * src/methods.cc: Adapted for changes above. * src/m_jacobian.cc (JacobianDoit): Adapted for changes above. (jacobianDoitAddSpecies): Do not require cloudbox_checked anymore. * src/m_microphysics.cc (pnd_fieldCalcFromParticleBulkProps): Check particle_bulkprop_field and particle_bulkprop_names here (instead of in cloudbox_checkedCalc). Generalized zero-outside-of-cloudbox check of particle_bulkprop_field. * src/rt4.cc (sca_optpropCalc): Bugfix in handling 1freq-reduced scat_data. * CHANGES-2.3: Document jacobians-before-cloudbox requirement. * controlfiles/CMakeLists.txt: Added TestWfunsHybClear to test suite. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Switched on all analytical abs species and wind cases incl Compares to TestWfuns results. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Separated instrument jacobians from wind jacobians for better comparability with TestWfunsHybClear (that can't handle instrument yet). * controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/artscomponents/absorption/TestIsoRatios.arts, controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts, controlfiles/artscomponents/cia/TestRTwithCIA.arts, controlfiles/artscomponents/clearsky/TestClearSky.arts, controlfiles/artscomponents/clearsky/TestClearSky2.arts, controlfiles/artscomponents/clearsky/TestClearSkyTips.arts, controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/artscomponents/doit/doit_setup_accelerated.arts, controlfiles/artscomponents/doit/doit_setup_pressureoptimization.arts, controlfiles/artscomponents/faraday/TestFaradayRotation.arts, controlfiles/artscomponents/groundbased/TestFgrid.arts, controlfiles/artscomponents/groundbased/TestWinds.arts, controlfiles/artscomponents/helpers/TestHSE.arts, controlfiles/artscomponents/linemixing/TestLineMixing.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeemanPreCalc_50_to_70_GHz.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_GHz.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts, controlfiles/artscomponents/nlte/TestNLTE.arts, controlfiles/artscomponents/oem/TestOEM.arts, controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts, controlfiles/artscomponents/ppath/TestPpath1D.arts, controlfiles/artscomponents/ppath/TestPpath2D.arts, controlfiles/artscomponents/ppath/TestPpath3D.arts, controlfiles/artscomponents/ppath/TestRefractPlanets.arts, controlfiles/artscomponents/radiolink/TestRadioLink.arts, controlfiles/artscomponents/radiolink/TestRadioLink2.arts, controlfiles/artscomponents/radiolink/TestRadioOccultation.arts, controlfiles/artscomponents/regrid/TestRegridFields.arts, controlfiles/artscomponents/stokesrot/TestSensorPol.arts, controlfiles/artscomponents/stokesrot/TestStokesRotation.arts, controlfiles/artscomponents/transmission/TestTransmission.arts, controlfiles/artscomponents/transmission/TestTransmissionWithScat.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts, controlfiles/artscomponents/zeeman/TestZeeman.arts, controlfiles/artscomponents/zeeman/TestZeemanPreCalc.arts, controlfiles/classroom_exercises/exe2_rtcalc/rtcalc.arts, controlfiles/classroom_exercises/exe3_jacobian/jacobian.arts, controlfiles/classroom_exercises/exe4_olr/olr.arts, controlfiles/instruments/odinsmr/TestOdinSMR.arts, controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts, controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts, controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_1D_cloudy.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoVenus_fullRT_1D_cloudy.arts, controlfiles/planetary_toolbox/includes/common/Basics_1D-scalar-clearsky-radiance.arts, controlfiles/planetary_toolbox/includes/common/Basics_1D-scalar-nosensor-clearsky-radiance.arts: Moved jacobian settings to before cloudbox settings. 2017-09-28 Richard Larsson * arts-2-3-810 clearsky jacobians are now working for iyhybrid2 (so long as the input system is correct, which remains to be tested for things other than rel VMR). There is still some friction between definitions in clearsky and scattersky variables that needs working out (size mismatches) * src/jacobian.cc: Simplified expressions. Also, has to add to diy2 not diy1... this explains the factor 2 error! * src/rte.cc: (get_stepwise_effective_source) simplified expressions. (get_stepwise_scattersky_propmat) fixed setting derivaitves to zero in non-cloudy cases. (get_stepwise_scattersky_source) fixed setting to zero in non-cloudy cases. 2017-09-28 Richard Larsson * arts-2-3-809 * src/m_fos.cc: Needed call to (adapt_stepwise_partial_derivatives) Also updated so that there is a check for stokes_dim since the linalg function "id_mat" does not work for 1-by-1 matrices (sometimes; why?) * src/rte.cc: Updated (get_stepwise_transmission_matrix) to check stokes_dim since id_mat did not work for 1-by-1 matrices (again; why?) 2017-09-27 Manfred Brath * arts-2-3-808 * src/m_microphysics.cc - (psdMY2, dNdD_MY2, dNdD_MY2_M,psdS2M, dNdD_SM2, dNdD_SM2_M): Renamed to psdMY05, dNdD_MY05, dNdD_MY05_M,psdSB06, dNdD_SB06, dNdD_SB06_M, and adjusted the function when needed to handle the new names including changed name-tags. * src/microphysics.{cc,h} (psd_MY2, psd_S2M, pnd_fieldMY2, pnd_fieldS2M): Renamed to psd_MY05, psd_SB06, pnd_fieldMY05, pnd_fieldSB06 and adjusted the function when needed to handle the new names including changed name-tags. * src/methods.cc - (psdS2M, psdMY2): Renamed to psdSB06, psdMY05. - (dNdD_SB06, dNdD_SB06_M,dNdD_MY05, dNdD_MY05_M, pnd_fieldCalcFromscat_speciesFields): Updated built-in doc according to the new names. * src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields): Changed to handle the new names. 2017-09-25 Simon Pfreundschuh * arts-2-3-807 * interactive_workspace.[cc,h]: - Added functions to set WSVs of type Tensor3 through python interface. * arts_api.[cc,h]: - Return error if variable cannot be set through interface. 2017-09-21 Simon Pfreundschuh * arts-2-3-807 Adde functionality needed to set up retrievals of principal components. Also added functionality to enforce constraints on retrieval quantities. * src/jacobian.[h,cc]: - Added get_jacobian_indices function to get indices of transformed retrieval quantities before jacobianClose is calles - Some changes related to change of conventions for transformation matrices - Added members to hold constraints on retrieval quantities - Add nelem member function to get number of grid points from quantity * src/m_jacobian.cc(transformationAdd): - Renamed addTransformation * src/m_oem.cc: - Added function to enforce constraints on VMR quantities - Enforce constraints in x2artsStandard - Fixed application of transformation in x2artsStandard - Removed jacobian_indices arguments from OEM WSMs since only the transformed indices are needed * src/m_retrieval: - Enabled adding of retrieval quantities without corresponding covariance block to *covmat_sx* - Renamed covmatSetDiagonal to covmatDiagonal - Added covmat_sxAddBlock WSM - Adapted retrievalDefClose to take into account transformations - Add retrievalConstraintAdd method to add constraints on RQs * src/methods.cc: - Renamed covmatSetDiagonal to covmatDiagonal - Renamed addTransformation to transformationAdd - Added covmat_sxAddBlock WSM - Added retrievalConstraintAdd WSM * controlfiles/artscomponents/oem/TestOEM.arts - Fixed call to covmatDiagonal 2017-09-21 Jana Mendrok * arts-2-3-806 * controlfiles/artscomponents/wfuns/TestWfuns.arts: Some info print output. Some more xml output as ref for Hyb test case. * controlfiles/artscomponents/wfuns/TestWfunsHybridClear.arts: More subcases switched on (remaining switched-off-ones not working (yet?)). Use TestWfuns y & jacobian output as reference (output not commited, though. Ie run TestWfuns first to create that). 2017-09-21 Oliver Lemke * arts-2-3-805 * Added TESSEM2 implementation. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/tessem/TestTessem.arts, controlfiles/testdata/tessem_sav_net_H.txt, controlfiles/testdata/tessem_sav_net_V.txt: Added TESSEM test case and neural net parameter data. * src/CMakeLists.txt, src/tessem.{cc,h}: C++ port of the original TESSEM2 Fortran code. * src/m_tessem.cc, src/methods.cc: Added workspace methods TessemNNReadAscii and TestTessem. TestTessem should be adapted to serve then as the main interface function to the model. * src/m_general.{cc,h}: Add Print for TessemNN. * src/groups.cc: Add TessemNN type. * src/make_auto_md_h.cc, src/make_auto_workspace_h.cc: Include tessem.h were needed. * src/workspace.cc: Add WSVs tessem_neth and tessem_netv. * src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add dummy routines for TessemNN type. 2017-09-21 Richard Larsson * arts-2-3-804 * src/jacobian.{cc,h}: Changed to level-based system. Dunno why I forgot this is the ARTS way in the original implementation. Still missing HSE derivative since HSE is not based on physics under consideration in any iy-calculator * src/rte.cc: Added some comments for the stepwise functions. Added some extra checks for get_stepwise_effective_source. * src/m_fos.cc: Changed iyHybrid2 to use different checks, use the level definition of jacobian, and to convert path-values to Rodger's values. (Discussion point for future: why can't we let the iy-calculators do the physics and let the y-calculators worry about converting to Rodger's nomenclature? It would make life easier to not mix the two together. Twice in the same commit realizing that this mixing makes life difficult has me wondering...) * src/propagationmatrix.h: Added an IsEmpty() return of bool. Returns true if there are no frequencies defined. Would also want an IsZero() test, but could not get the library working on our vectors. 2017-09-20 Jana Mendrok * arts-2-3-803 * src/m_fos.cc (iyHybrid2): Debugging of derivatives sum up. * src/methods.cc, src/m_doit.cc (doit_i_fieldSetConstPerFreq): Added new WSM to set a freq-dependent, but otherwise constant doit_i_field. (doit_i_field_monoSetConst): Bugfixes & cleanup. * controlfiles/artscomponents/wfuns/TestWfunsHybClear.arts: Added. (Quasi-)clearsky test case for Jacobians from iyHybrid*. Setup equivalent to TestWfuns.arts. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Some (outcommented) write statements to help comparison with WfunsHybrid case. * 3rdparty/polradtran/rt4/radtran4.f: Increased max number of layers in order to allow it to run on wfun test case atm setup. Revert in case this degrades performance noticeably. 2017-09-20 Simon Pfreundschuh Reverted changes to jacobianAddAbsSpecies that caused tests to fail. * arts-2-3-802 * src/jacobian.{cc,h}: Added functions to apply affine transformations to x vector and jacobian. * src/m_jacobian.cc: - Removed tranformation_matrix and offset_vector arguments - Added addTransformation WSM, that can be used to add transformation to quantities. This is a much better solution anyways. * src/m_abs_lookup.{cc,h}: - Reverted changes in call to jacobianAddAbsSpecies * src/m_retrieval.cc: - Reverted changes in call to jacobianAddAbsSpecies and jacobianAddTemperature * src/methods.cc: - Reverted changes to jacobianAddAbsSpecies, jacobianAddTemperature, retrievalAddAbsSpecies - Added addTransformation WSM 2017-09-20 Simon Pfreundschuh * arts-2-3-801 First shot add affine transformations of quantities in Jacobian. * src/jacobian.{cc,h}: Added functions to apply affine transformations to x vector and jacobian. * src/m_jacobian.cc: - Added arguments to add affine transformations to absorption species and temperatures. - Added workspace method to apply transformations to jacobian, which is automatically add to jacobian_agenda if any RQ has a transformation. * src/m_abs_lookup.{cc,h}: Adapted call to jacobianAddAbsSpecies * src/m_oem.cc: - Modified x2artsStandard to include transformation - Modified xaStandard to include inverse transformation * src/m_retrieval.cc: - Adapted calls to jacobianAddAbsSpecies and jacobianAddTemperature * src/methods.cc: - Adapted md_data entries for jacobianAddAbsSpecies, jacobianAddTemperatures, retrievalAddAbsSpecies - Added jacobianTransform WSM 2017-09-20 Richard Larsson * arts-2-3-800 * src/jacobian.{cc,h}: Added solution for new formulation of RTE in iyHybrid2. Still need HSE since this is treated on pseudo-expressions rather than actual dependencies in old path. Needs better integration into RTE. * src/m_fos.{cc,h}: Added temporary solution to Jacobian calculations. Still need a test for this... * rest: Some small fixes 2017-09-19 Jana Mendrok * arts-2-3-799 * ChangeLog: Missed save from prev commit. 2017-09-19 Jana Mendrok * arts-2-3-798 * src/m_fos.cc (iyHybrid2), src/rte.[cc,h] (get_stepwise_scattersky_source): Revised scattering source calculation and added derivatives for it. 2017-09-19 Jana Mendrok * arts-2-3-797 * src/m_fos.cc, src/methods.cc (iyHybrid2), src/rte.[cc,h] (get_stepwise_scattersky_propmat): Revised scatt-sky optical property extraction and added derivatives to this. Removed ppath(d)pnd(_dx) calc from get_stepwise_scattersky_propmat, instead do this outside the level-loop at once using the dedicated function get_ppath_cloudvars. * src/m_fos.cc, src/methods.cc(iyHybrid): Make dpnd_field_dx and input. * src/m_cloudradar.cc, src/m_fos.cc, src/m_transmitter.cc, src/m_rte.cc, src/rte.[cc,h]: Renamed clear2cloudbox to clear2cloudy as it is not only checking/ flagging whether in cloudbox, but even whether any non-zero pnd exist at the level in question. * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Adapt for now required Jacobian input. * CHANGES-2.3: Update with (some of) the recent changes. 2017-09-18 Jana Mendrok * arts-2-3-796 ATTENTION: Breaks backward compatability of cloudy-sky controlfiles. Moved "old type" scat_data to scat_data_raw. Sorted out WSM that (primarily, hence per default) act on each of the scat_data*. Break get_ppath_partopt into a part deriving atmospheric particle-related path variables (get_ppath_cloudvars) and one deriving particle optical properties along path (get_ppath_partopt). * src/m_abs.cc (propmat_clearskyAddParticles): Ported to exclusively use new type scat_data. Removed frequency perturbation feature (considering that typical freq perturbs on particle props has negligible effects only). * src/m_checked.cc (cloudbox_checkedCalc): Renamed GIN parameters scat_data_fcheck and scat_data_check_type to more descriptive scat_data_type and scat_data_check_level, respectively. Made (new type) scat_data the default, changed scat_data_type tag for scat_data_raw to "raw". * src/m_cloudbox.cc (cloudboxOff, ScatSpeciesInit): Adapted for scat_data_raw. (ScatElementsPndAndScatAdd, ScatSpeciesPndAndScatAdd, ScatElementsToabs_speciesAdd, ScatSpeciesScatAndMetaRead, ScatSpeciesExtendTemperature): Act on scat_data_raw. (pnd_fieldZero): Adapt such that valid (new type) scat_data is created. * src/m_doit.cc (DoitInit), src/m_jacobian.cc (JacobianDoit), src/m_rte.cc(iyMC), src/m_optproperties.cc (pha_mat_sptFromData, opt_prop_sptFromData, DoitScatteringDataPrepare, scat_data_monoCalc): Use scat_data_raw. * src/m_optproperties.cc: New/revised shortcuts to scat_data and scat_data_raw members. * src/m_optproperties.cc (opt_prop_sptFromScat_data, scat_dataCheck, scat_dataCalc, pha_mat_sptFromScat_data): Adapted shortcuts to scat_data members. * src/m_optproperties.cc (scat_data_monoExtract): Bugfix: Actually use this_f_index in K/Z/a extraction. Minor code optimization. Adapted shortcuts to scat_data members. * src/rte.[cc,h] (get_ppath_partopt, get_ppath_cloudvars): Broke old get_ppath_partopt down into atm and optprop variables parts. * src/m_cloudradar.cc (iyActiveSingleScat), m_fos.cc (fos), src/m_transmitter.cc(iyRadioLink), src/rte.cc (get_ppath_pmat_and_tmat): Adapt for get_ppath_partopt breakup. * src/m_fos.cc (iyHybrid2): Remove ununsed variable declarations. * src/optproperties.[cc,h]: Removed unused scat_data shortcuts. (scat_data_monoExtract): Removed. Semi-duplicate of WSM with same name in m_optproperties.cc. Was not used anywhere anyways (anymore?). * src/cloudbox.cc, src/m_optproperties.cc (opt_prop_sptFromMonoData, pha_mat_sptFromMonoData, ScatSpeciesMerge): Minor stuff like typo fixes, comment and error/info msg updates. * src/m_optproperties.cc (TestScatDataInterp): Outcommented this WSM. Not up-to-date anymore. * src/workspace.cc (scat_data, scat_data_raw): Adapted/extended doc. * src/methods.cc: Adapted for WSM interface changes described above. * controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts, controlfiles/artscomponents/disort/TestDISORT.arts, controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, controlfiles/artscomponents/doit/doit_calc.arts, controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/artscomponents/doit/doit_setup_accelerated.arts, controlfiles/artscomponents/doit/doit_setup_pressureoptimization.arts, controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/hybridscat/TestHybrid.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts, controlfiles/artscomponents/polradtran/TestRT4.arts, controlfiles/artscomponents/transmission/TestTransmissionWithScat.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_FOS_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_MC_1D.arts, controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Adapted to scat_data/scat_data_raw related WSM interface changes above. 2017-09-17 Simon Pfreundschuh * arts-2-3-795 * src/arts_api.[h/cc](add_variable): Added name argument so that names of newly created variables can be also used by the ARTS runtime. * src/interactive_workspace.[h/cc](add_variable): Added name argument so that names of newly created variables can be also used by the ARTS runtime. 2017-09-15 Manfred Brath * arts-2-3-794 * src/m_checked.cc (cloudbox_checkedCalc): Changed the check for particle_bulkprop_field. If the lower cloudbox limit is set to the lowest atmospheric level, then the check will not give an error if the particle_bulkprop_field has non-zero value at the lower cloudbox boundary. * src/math_funcs.cc (mod_gamma_dist): Changed the error message * src/methods.cc (psdS2M, psdMY2): Written built-in doc * src/m_microphysics.cc: (psdS2M, psdMY2): Added new two moment scheme distributions. Particle size distribution values are tested. The new scheme will give except for the differences due to rescalling the same pndfields as pnd_fieldS2M/MY2. The partial derivatives need further testing, but so far they seem to be working. (dNdD_SM2, dNdD_SM2_M, dNdD_MY2, dNdD_MY2_M) Changed to handle the new calls of psd_S2M, psd_MY2. (pnd_fieldCalcFromParticleBulkProps): Changed the check for particle_bulkprop_field. If the lower cloudbox limit is set to the lowest atmospheric level, then the check will not give an error if the particle_bulkprop_field has non-zero value at the lower cloudbox boundary. * src/microphysics.{h,cc} (psd_MY2, psd_S2M): Changed to handle a grid of sizes at once and changed the tags defining the hydrometeor) scheme. * src/microphysics.cc (pnd_fieldS2M, pnd_fieldMY2): Changed to handle the new calls of psd_S2M, psd_MY2. 2017-09-15 Simon Pfreundschuh * arts-2-3-793 * src/m_rte.cc (yCalc): Fixed order of parameters atmgeom_checked and atmfields_check to be the same as in methods.cc. 2017-09-14 Simon Pfreundschuh * arts-2-3-792 * src/methods.cc (PFromZSimple): Added md_data entry for PFromZSimple. 2017-09-11 Simon Pfreundschuh * arts-2-3-791 * src/m_retrieval.cc (ZFromPSimple): Moved pressure check out of loop to avoid inconsistent state in case of error. * src/m_retrieval.cc (PFromZSimple): Ported PFromZSimple method from atmlab. 2017-09-05 Jana Mendrok * arts-2-3-790 * src/methods.cc (iyHybrid2): Fixed interface definition. 2017-09-05 Jana Mendrok * arts-2-3-789 More work toward using pre-interpolated scat_data throughout. * controlfiles/general/general.arts: Inititalize scat_data_checked. Will go away again once all solvers are converted. * src/m_cloudbox.cc (ScatSpeciesInit): Inititalize/reset scat_data_checked. * src/rte.[cc,h]: (throughout): Sorted out references to get_ppath_ext (either get_ppath_partopt or get_ppath_pmat_and_tmat). (get_ppath_ext): Renamed to get_ppath_partopt (as it does NOT provide "clearsky" ppath_ext but particle abs and ext). Use scat_data_checked to decide which type scat_data is at hand. (get_ppath_pmat_and_tmat): Adapted to get_ppath_ext/get_ppath_partopt renaming and interface change. (get_ppath_scat_source, get_ppath_scat_source_fixT): Adapted to exclusively use pre-interpolated scat_data. * src/m_fos.cc (iyHybrid): Revised for use of pre-interpolated scat_data. Removed use_mean_scat_data option. * src/m_optproperties.cc (scat_data_monoExtract): Added, probably tentative. Extracts scat_data_mono from pre-interpolated scat_data (instead of performing an interpolation as scat_data_monoCalc does). * src/m_cloudradar.cc (iyActiveSingleScat), src/m_fos.cc (iyFOS, fos), src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): Use scat_data_checked. At the moment needed as input to get_ppath_partopt and get_ppath_pmat_and_tmat to distinguish whether we it's pre-interpolated scat_data or not that are at hand (for those WSMs they are typically not yet). * src/m_rte.cc (iyEmissionStandard): Dummy scat_data_checked in get_ppath_pmat_and_tmat call. * src/methods.cc: Adapted to WSM additions/interface changes above. 2017-09-03 Jana Mendrok * arts-2-3-788 * src/m_microphysics.cc (psdMH97,psdF07,psdW16): Partly revert of arts-2-3-787 - move check of s/i/rwc back to beginning of level-loop, before the t-range check. this as we loop over full cloudbox here, and of course the cloudbox can contain levels with t that are outside the valid t-range of a hydrometeor. as long as the wc for this hydrometeor is 0, that's perfectly fine. 2017-09-02 Patrick Eriksson * arts-2-3-787 * Temperature changed from being treated as a formal pnd/psd input variable, to be an auxiliary variable that is always at hand. This means that "Temperature" no longer shall be included in pnd_agenda_input_names. So e.g.: ArrayOfStringSet( pnd_agenda_input_names, [ "IWC", "Temperature" ] ) shall be changed to ArrayOfStringSet( pnd_agenda_input_names, [ "IWC"] ) * src/m_microphysics.cc (psdMH97,psdF07): Temperature now taken from pnd_agenda_input_t. (psdW16): As above and also added t_min, t_max and picky. * src/agendas.cc (define_agenda_data): Removed jacobian as input to inversion_iterate_agenda. Not needed after Simon's improvement of x2artsStandard. And added pnd_agenda_input_t as input to pnd_agenda_array. * src/workspace.cc (define_wsv_data): Introduced pnd_agenda_input_t. 2017-09-01 Richard Larsson * arts-2-3-786 * src/m_fos.cc: Added a iyHybrid2 that is splitting up the call to the *and_tmat functionality and also changing the averaging over levels. (Make average of all the source term on a level rather than the individual elements.) * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Added new method to test * src/rte.{cc, h}: Added scattering source for single level. Makes a lot of unecessary calls because of a failed check which is still being investigated... 2017-09-01 Oliver Lemke * arts-2-3-785 * cmake/modules/ArtsTestcases.cmake: Explicitly pass include path to ignore the environment variable ARTS_INCLUDE_PATH. Otherwise the test can break depending on the user's environment. Remove special cases for cmake 2.6 which we don't support anymore. 2017-09-01 Jana Mendrok * arts-2-3-784 * src/m_fos.cc (iyHybrid): Removed a leftover debugging write out. * src/m_rt4.cc (RT4Calc): Set dummy surface_skin_t when initializing. * src/cloudbox.cc (check_pndsum): Downgrade outlevel to 3. * controlfiles/artscomponents/hybridscat/TestHybrid.arts: Set iy_main_agenda for yCalc using RT4 explicitly here (not rely on setting from an INCLUDE). 2017-08-31 Simon Pfreundschuh * arts-2-3-783 There are only two hard things in Computer Science: cache invalidation and REnaming things. * controlfiles/artscomponents/oem/TestOEM.arts: Updated function names changed in previous commit. 2017-08-31 Simon Pfreundschuh * arts-2-3-782 There are only two hard things in Computer Science: cache invalidation and naming things. * src/m_oem.cc: Changed abbreviation ml to lm in variables related to Levenberg-Marquardt method. * src/m_retrieval.cc: Renamed Covmat1D to covmat1D, Covmat1DMarkov to covmat1DMarkov, covmat_blockSetDiagonal to covmatSetDiagonal to get some consistency somewhere. * src/methods.cc: Updated method and argument names. * src/workspace.cc: Updated name of lm_ga_history WSV 2017-08-31 Richard Larsson * arts-2-3-781 * src/rte.{cc,h}: Added some stepwise functions to begin splitting of the *pmat_and_tmat giant function. * src/propagationmatrix_h: Added const return of Matrix because of compiler complaints 2017-08-30 Jana Mendrok * arts-2-3-780 * controlfiles/artscomponents/transmission/TestTransmissionWithScat.arts, clearREFERENCE.xml, cloudyREFERENCE.xml, controlfiles/CMakeLists.txt: Added. Transmission test case with scattering particles. Also added to standard checks. 2017-08-30 Jana Mendrok * arts-2-3-779 * controlfiles/CMakeLists.txt: Move TestHybrid into ENABLE_RT4 loop as uses (ie requires) RT4 for the background rad field calc. 2017-08-30 Jana Mendrok * arts-2-3-778 * src/m_fos.cc (iyHybrid): Bugfixed RTE integration part. Seems to work now. * controlfiles/artscomponents/hybridscat/TestHybrid.arts, yREFERENCE.xml, controlfiles/CMakeLists.txt: Added. Test case and reference solution for hybrid scatt solver. Added test case to standard checks. * src/rt4.cc (run_rt4): Re-enable empty-cloudbox capability that accidentially got lost during implementing the auto-increase streams option. * src/rte.cc: Minor spell fix. * src/workspace.cc (pnd_field): Added crossrefs to cloudbox_limits for understanding dimensions. 2017-08-30 Simon Pfreundschuh * arts-2-3-777 * src/jacobian.[h,cc] (calcBaselineFit): - New function to compute baseline fit without jacobian. * src/m_oem.cc (x2artsStandard): - Rewrite calculation of baselines to not require the jacobian * src/m_retrieval.cc: - Rename p2ZSimple to name output first - Make retrievalAddSinefit work * src/methods.cc: - Updated name of ZFromPSimple - Updated input arguments of x2artsStandard * src/covariance_matrix.cc (generate_blocks): - Remove unused counter variable 2017-08-29 Jana Mendrok * arts-2-3-776 * src/m_fos.cc (iyHybrid): Couple of bug fixes. Running through now without core dump, but test results indicate there's more to fix... 2017-08-29 Simon Pfreundschuh * arts-2-3-775 * 3rdparty/invlib/*: - Fixed overload resolution for multiplication - Fixed wrapper for covariance matrices * src/m_oem.cc: - Fixed check of ml_ga_settings - Deactivated log output for CG solver * src/m_retrieval.cc: - Added P2zSimple method - Extended check_and_add_block to make it more generally applicable - Fixed calls to check_and_add_block * src/methods.cc: - Added entry for P2zSimple 2017-08-29 Jana Mendrok * arts-2-3-774 * src/m_fos.cc (iyHybrid): Consider abs vector in emission source term calc. * src/rte.[cc,h] (get_ppath_pmat_and_tmat): Output total particle absorption (pnd_abs_vec). * src/m_cloudradar.cc (iyActiveSingleScat), m_rte.cc (iyEmissionStandard), m_transmitter.cc (iyTransmissionStandard): Adapt to change above in get_ppath_pmat_and_tmat interface. 2017-08-29 Patrick Eriksson * arts-2-3-773 * src/m_fos.cc (iyHybrid): Added some code. Still not ready. 2017-08-28 Jana Mendrok * arts-2-3-772 * ChangeLog: Missed save from prev commit. 2017-08-28 Jana Mendrok * arts-2-3-771 * src/m_microphysics.cc, methods.cc (pndFromPsd): New, extended WSM for psd-to-pnd conversion including some checks that main part of bulk properties is covered by the chosen size grid (and corresponding scat_data). (pndAdjustFromScatMeta): Do not throw error if cloudbox is off (unless jacobians requested), just return. 2017-08-28 Simon Pfreundschuh * arts-2-3-770 * 3rdparty/invlib/*: - Fixed handling of log-output of m-form. * src/methods.cc: - Added Covmat1D and Markov1D workspace method for creation of correlation blocks of the covariance matrix. * src/oem.cc: - Added m-form for linear and gauss-newton methods. * src/m_retrieval.cc: - Some fixed for Covmat1D and Markov1D * src/agenda_wrapper.h: - Fix bug in handling of precomputed Jacobian. 2017-08-26 Simon Pfreundschuh * arts-2-3-769 * src/arts_api.[h,cc]: - Some changes to the passing of input and output parameters of functions calls - Added methods for manipulation of agendas (agenda_add_method, agenda_insert_set, agenda_clear) * src/interactive_workspace.[h,cc]: - Adapted code to changes in arts_api.[h,cc] - Added set method for agenda variables 2017-08-25 Richard Larsson * arts-2-3-768 Work-in-progress. * src/linescaling.cc,h: Split the big function up into smaller parts, having their derivative functions explicit (but mostly only callable by themselves). * src/lineshapesdata.cc,h: Added the NLTE formulations * src/pressurebroadeningdata.cc,h: Added the interface method for lineshapesdata * src/quantum.cc,h: Added some simple matching logic * src/zeeman.cc: Testing function commented out as it does nothing yet. 2017-08-23 Simon Pfreundschuh * arts-2-3-767 * src/matpackII.h: Added getters for pointer to data arrays. * src/arts_c_api.[h,cc]: - Extended VariableValueStruct to support returning Sparse matrix data - Added support for setting and returning ArrayOfIndex - Updated documentation to be consistent with new memory management * src/interactive_workspace.[h,cc]: - Had to abandon workspace local variables since it doesn't work with WSMs that try to access the variable name. Now all new variables are added to the global wsv_data. - Added method to set ArrayOfIndex variables. 2017-08-23 Oliver Lemke * arts-2-3-766 * src/CMakeLists.txt: Force .so ending for the arts_api library. OSX uses .dylib as a default suffix for dynamic libraries. Makes typhon find the library on OSX. * CMakeLists.txt: Output status of C API and info on how to enable it. * README: Add info on enabling C API. 2017-08-22 Simon Pfreundschuh * arts-2-3-765 * src/arts_c_api.[h,cc]: Implemented C API that can be used to build interfaces to other software. * src/workspace_ng.h: Changed private to protected in order to be able to reuse code. * src/interactive_workspace.[h,cc]: Implemented new workspace class to provided features required by C API. * CMakeLists.txt: Added ENABLE_C_API flag to switch on building of C API. * src/CMakeLists.txt: Add target for C API. 2017-08-21 Richard Larsson * arts-2-3-764 * 3rdparty/relmat*: Updated to latest version * controlfiles/artscomponents/wfuns/TestCatalogJacobians.arts: Made the tests relative since they kept failing for random reasons. Now accepts changes on order of 0.001%. This makes -march=native work * src/lineshapesdata.{cc,h}: Fixed some indexing and some compile errors * src/m_basic_types.cc: Added CompareRelative to make relative comparisons 2017-08-18 Simon Pfreundschuh * arts-2-3-756 * 3rdparty/invlib/*: invlib update * controlfiles/artscomponents/oem/TestOEM.arts: Controlfile adapted to new retrieval workflow. * src/CMakeLists.txt: Added new target for covariance matrix code. * src/CovarianceMatrix.*: New CovarianceMatrix class which simplifies handling of block-diagonal matrices and their inverses. * src/groups.cc: Added CovarianceMatrix class to groups. * src/m_oem.*: Adapted OEM to new covariance matrix class. This for now will break MPI version, will fix it or remove depending on needs. * src/m_retrieval.*: Contains the WSMs for the new retrieval workflow. * src/make_auto_md_h.cc: Add covariance_matrix.h to auto_md.h. * src/make_auto_workspace_h.cc: Add covariance_matrix.h to auto_workspace.h 2017-08-14 Richard Larsson * arts-2-3-762 * src/m_linemixing.cc: Fixed jacobian-interface bug when no temperature jacobian... 2017-08-16 Jana Mendrok * arts-2-3-761 * src/methods.cc (Touch, Ignore, iySurfaceFastem), src/workspace.cc (surface_type_mask), src/agendas.cc (surface_rtprop_sub_agenda0): Minor doc substantiations, spell fixes, etc. 2017-08-15 Oliver Lemke * arts-2-3-760 * src/matpack{I,III,IV,V,VI,VII}.cc: Use std::fill_n instead of iterator loop for initialization with a Numeric in assignment operator of the non-view types. This was already done in the initialization constructor. Added here for consistency. Also replaced the iterator loops in the ctor with std::fill_n for better readability. The compiler generates the same code for both. * src/m_cloudbox.cc: (ScatSpeciesScatAndMetaRead): Parallelize the reading of scattering data and meta data files. Gives a significant speedup (factor 2 - 10 depending on cores and filesystem performance) especially when reading lots of particles. Number of concurrent reads is limited to 16 to not put too much strain on the filesystem. Move output from out2 to out3 for less clutter. Use std::move to push local arr_ssd and arr_smd variables to the workspace variables. Avoids unnecessary copy operations. Note that std::move can only be used if the original variable is not needed anymore! (ScatElementsSelect): Use std::move to push local scat_meta_tmp and scat_data_tmp variables to the workspace variables. Avoids unnecessary copy operations. (ScatSpeciesExtendTemperature): Make ssdo a reference to SingleScatteringData to avoid unnecessary copying. Use std::move for assigning local variables T_grid_new and ssdn to avoid unnecessary copies. * src/xml_io.cc (xml_read_from_file): Assemble string before sending it into the output stream to avoid it being split up in multithreaded calls. * src/interpolation_poly.cc (gridpos_poly): Make non-changing interp order variable m const. * src/cloudbox.cc (chk_scat_data): Move output from out2 to out3 for less clutter. 2017-08-14 Oliver Lemke * arts-2-3-759 All checks are working again. * src/rt4.cc: Add fixes for PropagationMatrix changes. Patch supplied by Richard. * src/xml_io_compound_types.cc: Grid writing code for GriddedField3 was accidentally commented out and broke xml files. 2017-08-14 Oliver Lemke * arts-2-3-758 * controlfiles/artscomponents/wfuns/ReferenceJacobianInTestErrorJacobian.xml: Reverted changes to reference file from arts-2-3-757. The test case runs with the original values, but fails with the new values. 2017-08-14 Richard Larsson * arts-2-3-757 This also breaks controlfiles. Those directly using the propagation matrix Introducing new internal class and sub-class PropagationMatrix and StokesVector to handle propagation a bit more efficiently. StokesVector is basically only there to easier convert from one to another. Note: This lacks a lot of optimizations. Only iyemissionstandard is optimized, the rest receives only moderat boosts. In my own work predicting Martian parameter retrieval expectations using loads of RetrievalQuantity, I see around 50% speed increase, so a few tricks could help other code-paths speed-up some as well. * controlfiles/artscomponents/wfuns/ReferenceJacobianInTestErrorJacobian.xml: Changed because this committ altered the numbers (with same magnitude of the change if you do perturbation calculations). * src/CMakeLists.txt: Added files * src/absorption.cc: Fix error found investigating catalog jacobian change * src/disort.cc: Changed to use new classes: dtauc_ssalbCalc * src/doit.{cc,h}: Created temporary function rte_step_doit_replacement to replace rte_step_doit using new classes. Basically the same thing but without the need to create many local copies Changed to use new classes: cloud_fieldsCalc, cloud_RT_no_background, cloud_ppath_update1D_planeparallel * src/groups.cc: Added new classes up to ArrayOfArrayOf* * src/linerecord.cc: Fix for added quantum identifier for match all in match_lines_by_quantum_identifier * src/linerecord.h: Added method for returning line quantum identifier * src/lineshapesdata.{cc,h}: Changed a lot. Still work in progress. Will be namespace and make life easier for adding new methods... * src/m_abs.cc: Changed to use new classes: nlte_sourceFromTemperatureAndSrcCoefPerSpecies, propmat_clearskyAddFromAbsCoefPerSpecies, propmat_clearskyInit, propmat_clearskyAddFaraday, propmat_clearskyAddParticles, propmat_clearskyAddOnTheFly, * src/m_abs_lookup.cc: Changed to use new classes: propmat_clearskyAddFromLookup, propmat_clearsky_fieldCalc * src/m_cia.cc: Found bug in VMR stuff. Still under debug-status... * src/m_cloudradar.cc: Changed to use new classes: iyActiveSingleScat * src/m_doit.cc: Changed to use new classes: OptimizeDoitPressureGrid, * src/m_fos.cc: Changed to use new classes: fos, iyHybrid * src/m_linemixing.cc: Updated interface * src/m_optproperties.cc: Changed to use new classes: opt_prop_sptFromData, opt_prop_sptFromScat_data, opt_prop_bulkCalc, ext_matAddPart, abs_vecAddPart, ext_matAddGas, abs_vecInit, opt_prop_sptFromMonoData, TestScatDataInterp, * src/m_rte.cc: Changed to use new classes: iyEmissionStandard * src/m_transmitter.cc: Changed to use new classes: iyRadioLink, iyTransmissionStandard * src/m_zeeman.cc: Changed to use new classes: propmat_clearskyAddZeeman, propmat_clearskyAddZeemanFromPreCalc * src/make_auto_md_cc.cc,src/make_auto_md_h.cc,src/make_auto_workspace_h.cc: Includes propagationmatrix.h * src/montecarlo.cc: Changed to use new classes: clear_rt_vars_at_gp, cloudy_rt_vars_at_gp * src/optproperties.{cc,h}: Changed to use new classes: abs_vecTransform, ext_matTransform, opt_prop_sum_propmat_clearsky * src/partial_derivatives.{cc,h}: Added species and isotopologue to test. otherwise, species with same quantum numbers but different species/isotopologue's might add together. Also fixed error where only if the catalogue parameters were first in line and there was no perturbation parameters work... * src/propagationmatrix.{cc,h}: Added. Contains implementations of the class including some specific functions needed to operate and manipulate the matrix/vectors Especially key functions include: compute_transmission_matrix_and_derivative, compute_transmission_matrix, get_diydx_replacement * src/quantum.{cc,h}: Added QuantumIdentifier::operator< and QuantumIdentifier::operator> to mean contained in, and contains (left * arts-2-3-756 Continuation of scatt solver adaptation for use of new-type scat_data: RT4 completely revised. THIS BREAKS CONTROLFILES USING RT4Calc* * src/m_rt4.cc (RT4Calc*), rt4.[cc,h] (check_rt4_input, run_rt4, par_optpropCalc, sca_optpropCalc): Use new type scat_data. Removed use of spt_calc_agenda and opt_prop_part_agenda (replaced by opt_prop_sptFromScat_data and opt_prop_bulkCalc) and creation/use of scat_data_mono. * controlfiles/artscomponents/polradtran/TestRT4.arts: Adapted to changes above. Removed definitions of unused agendas. * src/m_optproperties.cc (opt_prop_bulkCalc): Removed unused interface parameter. * src/m_disort.cc (DisortCalc*), disort.[cc,h] (check_disort_input, dtauc_ssalbCalc, phase_functionCalc2, opt_prop_sptFromScat_data): Check scat_data_checked in check_disort_input, not later when used in subroutines. Completely remove use of opt_prop_part_agenda. (DisortCalc*, run_disort): Removed not any longer needed/used interface parameters. * controlfiles/artscomponents/disort/TestDISORT.arts: Removed setting of unused opt_prop_part_agenda. * src/methods.cc (RT4Calc*, DisortCalc*): Adapted to changes above. * src/workspace.cc (instrument_pol): Typo fixed. * src/methods.cc: Added WSMs for new retrieval workflow. * src/test_covariance_matrix.cc: Test for new CovarianceMatrix class. * src/workspace.cc: Added new covmat_sx, covmat_se, covmat_block and covmat_block_inv WSVs. * src/xml_io_compound_types.cc: XML IO for CovarianceMatrix class. * src/xml_io_instantiation: Instantiation for xml io templates. * src/xml_io_types.h: Instantiation for xml io templates. 2017-08-09 Oliver Lemke * arts-2-3-755 * src/array.h: Introduce C++11 move constructor and move assignment operator. * src/matpack{I,III,IV,V,VI,VII}.{cc,h}: Introduce move constructors and move assignment operators for all memory allocating types (all non-views). Since we know that the data of non-view types is stored in one continuous block of memory, std::memcpy is now used instead of iterator loops for data duplication in copy constructors and assignment operators of those types. This can give a significant speed boost depending on the calculation. For a radar calculation from Manfred, which uses ybatchCalc for 600 cases, the memcpy implementation gives almost a factor 2(!) speed up. This is mostly due to the fact that in each iteration ScatSpeciesMerge needs to be called. Since it uses scat_data as In+Out, the agenda engine has to make a full copy of the ArrayOfArrayOfSingleScatteringData for each batch case. Deep copies of SingleScatteringData are very expensive because it contains four Vectors, two Tensor5s and a Tensor7 which makes the performance advantage of using memcpy very noticeable. * src/optproperties.{cc,h} (opt_prop_sum_propmat_clearsky): Last argument was not passed by reference thus causing a Tensor4 copy on every call. * src/rational.h: Remove converting constructor Rational(int). It is redundant because a converting ctor for Index also exists. * src/m_optproperties.cc (opt_prop_sptFromMonoData): Avoid copying of ext_mat_data and abs_vec_data to temporary variable in every iteration for the t_grid.nelem()==1 case. This code is called very often and the copy to a local variable can be completely avoided by moving the ext_matTransform call into the if and else blocks calling it with different arguments for the two cases. * src/m_abs.cc (abs_linesReadFrom*): In all reading routines use std::move when pushing the temporary LineRecord to the abs_lines array. Avoids copying every line. * src/lin_alg.cc (inv, diagonalize): Only create variable n in debug mode. Avoids warning in release mode. * src/xml_io_array_types.cc (xml_read_from_stream): Use std::move in ArrayOfLineRecord reading routine to avoid an unnecessary copying of the LineRecord. * src/m_cloudbox.cc (particle_fieldCleanup): Remove unneeded local variable. If particle_field_in and particle_field_out are not pointing to the same variable, just copy p_f_i to p_f_o. Keeping p_f_i and p_f_o while looping over all elements is not necessary because the loop only operates on a single element at a time. Avoids two unneeded Tensor4 copies if p_f_i and p_f_o are the same WSV or one copy if they're not. 2017-08-09 Oliver Lemke * arts-2-3-754 * src/m_cloudbox.cc (ScatSpeciesScatAndMetaRead): Remove spurious continue and move out2 to better place. 2017-08-09 Oliver Lemke * arts-2-3-753 * src/m_cloudbox.cc (ScatSpeciesScatAndMetaRead): Treat data search path and optional .gz extension properly when looking for file with first naming convention. 2017-08-09 Oliver Lemke * arts-2-3-752 * src/m_cloudbox.cc (ScatSpeciesScatAndMetaRead): Don't silently ignore exceptions from xml_read_stream (e.g. about wrong version of scattering meta data). Don't exceed array boundaries if string splitting fails. 2017-08-07 Manfred Brath * arts-2-3-751 * src/microphysics.{h,cc} (pnd_fieldMY2,psd_MY2), src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields): Added new two moment scheme distributions. * src/m_cloudbox.cc (dNdD_MY2,dNdD_MY2_M), src/methods.cc: Added new WSMs for the new distributions. * src/methods.cc added new distributions to pnd_fieldCalcFromscat_speciesFields * src/microphysics.{h,cc} (psd_S2M): Renamed from WCtopnd_S2M. Corrected upper and lower limit behaviour of distribution. Updated documentation *src/microphysics.cc (pnd_fieldS2M): Updated documentation. 2017-07-13 Oliver Lemke * arts-2-3-750 * src/m_disort.cc (DisortCalcWithARTSSurface): Fix compilation if Disort is disabled. 2017-07-12 Jana Mendrok * arts-2-3-749 Continuation of scatt solver adaptation for use of new-type scat_data * src/m_optproperties.cc: (opt_prop_sptFromScat_data): Separate f-extraction for ext_mat and abs_vec (allowing for different f-dimensioning in these. Cosmetics. (pha_mat_sptFromScat_data): WSM for pha_mat extraction from new-type scat_data. For use in pha_mat_spt_agenda or to replace internal use of pha_mat_spt_From(Mono)Data). (opt_prop_bulkCalc): WSM reproducing the standard (and only one applied?) setup for opt_prop_part_agenda. Can be used within the agenda or in place of the agenda. * src/disort.cc (phase_functionCalc, phase_functionCalc2): Adapted for use of new-type scat_data, particularly in place of scat_data_mono. * controlfiles/artscomponents/disort/TestDISORT.arts: Use new umbrella WSM opt_prop_bulkCalc in opt_prop_part_agenda (in a next step, the agenda call inside the ARTS interface will be replaced instead). * src/m_checked.cc, methods.cc (scat_data_checkedCalc: Some adaptations to current new-type scat_data state and assumptions. Updated built-in doc accordingly (for details see there). * src/m_disort.cc (DisortCalcWithARTSSurface): Bugfix. * src/methods.cc: Updated according to WSM changes above. 2017-07-11 Jana Mendrok * arts-2-3-748 WARNING: This breaks scattering related controlfiles. More work towards pre-prepared scat_data. Specifically, started to modify DISORT interface to (exclusively) use pre-prepared scat_data (equals to replacing several agendas by hard-wired solutions). * src/[m_]disort.[cc,h]: Started to adapt for use of new, pre-interpolated scat_data. * src/m_optproperties.cc (opt_prop_sptFromScat_data): Added. A temporary WSM for use of new scat_data in spt_calc_agenda. * src/optproperties.[cc,h] (scat_data_monoExtract): A (temporary?) method to extract scat_data_mono out of new type (ie already freq interpolated) scat_data, avoiding the interpolation overhead of scat_data_monoCalc. * src/m_checked.cc (cloudbox_checkedCalc): Switch on use of negative pnd keyword. Switch of scat_data f_grid checks for new-type scat_data (they would fail) via user keyword. (scat_data_checkedCalc): Added. A WSM to check correct prep of (new, preinterpolated) scat_data. * src/m_jacobian.cc (jacobianDoit): Adapt for cloudbox_checkedCalc interface changes. * src/workspace.cc (scat_data_checked, scat_data_raw): Added. * controlfiles/artscomponents/disort/TestDISORT.arts: Adapt for new scat_data use. * controlfiles/artscomponents/disort/yREFERENCE.y.xml: Added. An actual Disort-solver created solution as more exact reference allowing to monitor changes in the Disort approach. * src/m_cloudbox.cc (particle_fieldCleanup): Renamed from scat_species_fieldCleanup. * controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts, controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Adapted to scat_speciesCleanup name change. * CHANGES-2.3: Renaming note. * src/[m_]microphysics.[cc,h], [m_]cloudbox.[cc,h], CMakeLists.txt: Separated the size distribution (and other microphysics related) functionality into their own source files. 2017-07-06 Jana Mendrok * arts-2-3-747 * src/m_optproperties.cc (scat_dataCalc): A start towards a pre-scatt-solver prepared scat_data (on RT f_grid or const over f). Work in progress. * CHANGES-2.3: Added note on cloudboxSetAutomatically from previous commit since that broke backward compatibility. 2017-07-06 Jana Mendrok * arts-2-3-746 THIS BREAKS BACKWARD COMPATIBILITY OF CONTROLFILES THAT USE cloudboxSetAutomatically. * src/m_cloudbox.cc, methods.cc (cloudboxSetAutomatically[Generic]): Replaced old, scat_species_XXX_field tailored WSM with generic one. Bug fixes in generic version. * controlfiles/artscomponents/disort/TestDISORT.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/polradtran/TestRT4.arts controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Adapt cloudboxSetAutomatically calls to changes above. * controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_1D_cloudy.arts: Minor rewording in doc. 2017-07-05 Oliver Lemke * arts-2-3-745 * src/make_auto_md_cc.cc (main): Only zero-out the output-only variables if the same WSV is not also passed as a generic input to another parameter in the same WSM call. Can create unwanted side-effects in debug mode as discovered by Jana. Move a large part of the *agenda_execute functions into a separate helper function. Use range-based loops. Reduces the size of auto_md.cc by ~1400 lines. * src/CMakeLists.txt: Small indentation fix. 2017-07-04 Jana Mendrok * arts-2-3-744 * src/m_cloudbox.cc, methods.cc (cloudboxSetAutomaticallyGeneric): A new instance of cloudboxSetAutomatically (to replace that in future) that handles one Tensor4 particle field at a time, i.e. can be applied for particle_bulkprop_field (and, on the scat_species_XXX_field one after the other). * src/m_checked.cc (cloudbox_checkedCalc): Minor rewording of bulkprop non-zero outside cloudbox error message. Prep for allowing negative pnd (we'll need that for inversions, won't we?). 2017-06-30 Oliver Lemke * arts-2-3-743 * Apply patch provided by Simon P. to fix compilation of OEM with Apple Clang by removing an unneeded constructor that caused trouble. * Changes from patch: * 3rdparty/invlib/src/invlib/algebra/matrix.cpp, 3rdparty/invlib/src/invlib/algebra/solvers.cpp, 3rdparty/invlib/src/invlib/log.h, 3rdparty/invlib/src/invlib/map.cpp, 3rdparty/invlib/src/invlib/optimization/gradient_descent.cpp, src/oem.h: Fixes for several warnings. * oem.h (NormalizingSolver): Removed unneed copy constructor. * Change by me: * CMakeLists.txt: Reenable OEM by default with AppleClang. 2017-06-29 Jana Mendrok * arts-2-3-742 * src/methods.cc, m_cloudbox.cc (pndFromPsdBasic): Removed former version and rename former pndFromPsdBasic2 to this. Added capability to handle unsorted psd/pnd_size_grid (this as they might be extracted from scat_meta, hence in the order of scat_meta with no guarantee that the scat elements in scat_meta are sorted - particularly since sorted order of scat_meta could depend on the actual size parameter chosen). * src/cloudbox.cc (bin_quadweights, pnd_field*): Assert that psd size grids / quadrature ordinates are increasing. 2017-06-29 Jana Mendrok * arts-2-3-741 * src/methods.cc, m_cloudbox.cc, cloudbox.cc (dNdD_MH97, dNdD_F07, dNdD_W16; pnd_fieldMH97, pnd_fieldF07): Ensure meeting requirements of psd_cloudice_MH97, psd_snow_F07, psd_rain_W16 by calling methods. Make (default) setup of dNdD* consistent with pnd_field*. Document settings properly in dNdD* built-in doc. Also document settings in non-WSM in their headers. (MassSizeParamsFromScatMeta): Added ability to limit size range of alpha and beta fit. * doc/uguide/clouds.tex, doit.tex, montecarlo.tex: Updated leftover references to outdated ptype names "horizontally_aligned" and "macroscopically_isotropic". 2017-06-29 Oliver Lemke * arts-2-3-740 * CMakeLists.txt: While OEM works fine with Clang now, Apple Clang is still not cooperating -> disable OEM by default if Apple Clang is used. Error: https://gist.github.com/olemke/a2d5b7621a425a245ee2180d52d6b7a7 2017-06-28 Oliver Lemke * arts-2-3-739 * src/make_vector.{cc,h}, src/CMakeLists.txt: Removed make_vector implementation for same reason as MakeArray. * src/matpackI.{cc,h}: (Vector): Implement list initialization constructor and assignment operator for Vector. (Iterator1D, ConstIterator1d): Define iterator_traits to enable use with std::copy. Needed for list initialization assignment operator. * doc/uguide/matrix_vector.tex, doc/uguide/gridded_fields.tex: Update docs for changes of MakeArray and MakeVector. * src/absorption.cc, src/cloudbox.cc, src/gas_abs_lookup.cc, src/lin_alg.cc, src/m_abs.cc, src/m_abs_lookup.cc, src/m_cloudbox.cc, src/m_general.cc, src/m_montecarlo.cc, src/mc_antenna.cc, src/sensor.cc, src/test_cia.cc, src/test_interpolation.cc, src/test_linalg.cc, src/test_matpack.cc, src/tmatrix.cc: Removed make_array.h include. Replace MakeVector with list initialization. 2017-06-27 Oliver Lemke * arts-2-3-738 * src/make_array.h: Removed. Not needed any longer since C++11 introduced list initialization from a braced-init-list. Some examples (first line old code, second line new code): ArrayOfIndex N; N=MakeArray(1, 1, 3, 3, 5); ArrayOfIndex N{1, 1, 3, 3, 5}; complex_refr_index.set_grid(2, MakeArray("real", "imaginary")); complex_refr_index.set_grid(2, {"real", "imaginary"}); See also: http://en.cppreference.com/w/cpp/language/list_initialization * src/array.h: Add list initialization constructor. * src/abs_species_tags.h, src/absorption.h, src/agenda_record.{cc,h}, src/agendas.cc, src/array.h, src/file.{cc,h}, src/jacobian.h, src/m_abs.cc, src/m_basic_types.cc, src/m_refraction.cc, src/m_sensor.cc, src/m_surface.cc, src/m_tmatrix.cc, src/make_auto_md_cc.cc, src/methods.{cc,h}, src/methods_aux.cc, src/partition_function_data.cc, src/species_data.cc, src/test_gridded_fields.cc, src/test_matpack.cc, src/test_propmat_partials.cc, src/wigner_functions.{h,cc}: Replace MakeArray with list initialization. Removed make_array.h include. Adapted preprocessor macros in several files accordingly. 2017-06-23 Oliver Lemke * arts-2-3-737 * CMakeLists.txt: Do not disable OEM by default when using clang anymore. 2017-06-23 Simon Pfreundschuh * arts-2-3-736 * 3rdparty/invlib/*: invlib update which fixes compile error with llvm libc++ and warnings encountered when building with clang++. 2017-06-22 Jana Mendrok * arts-2-3-735 * src/m_cloudbox.cc (psdMH97, psdF07): Added parametrization-T adjustment limits as user parameters. * src/methods.cc (psdMH97, psdF07, psdW16): Adapted to changes above. Adapted/improved built-in doc. * src/cloudbox.cc (psd_cloudice_MH97, psd_snow_F07): Removed Tc<0 requirement since math is sufficiently stable also for positive T. Removed final isnan check (NaN cases should be avoided before). 2017-06-22 Oliver Lemke * arts-2-3-734 * CMakeLists.txt: The Intel compiler has value-unsafe floating-point optimizations enabled by 'factory-default' which leads to large discrepancies compared to gcc/clang for certain calcucations (esp. Jacobians). To avoid these inaccuracies we now set the option '-fp-model precise' by default. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: Revert changes from previous commit. Not needed anymore with -fp-model precise. 2017-06-22 Oliver Lemke * arts-2-3-733 * cmake/modules/FindBLAS.cmake, cmake/modules/FindLAPACK.cmake: Add modules from cmake master version ded9859. Adds support for OpenBLAS detection without introducing a dependency for ARTS on a newer cmake. * 3rdparty/relmat/module_error.F90: Add missing comma in format description. Fixes compile failure with Intel Fortran. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: Increase BT comparison tolerance from 0.01 to 0.015 to account for numerical differences when using the Intel compiler. 2017-06-21 Jana Mendrok * arts-2-3-732 * m_cloudbox.cc, methods.cc: (pnd_fieldCalcFromscat_speciesFields): Added W16 PSD. Adapted for merged F07 interface. (pndFromPsdBasic2): Added. An extended, more flexible version of pndFromPsdBasic. For testing. Work in progress. (pndAdjustFromScatMeta): Added. Allows to rescale calculated pnd values such that is represents given material content. For testing, to allow *pnd_fieldCalcFromBulkProperties* to reproduce what *pnd_fieldCalcFromscat_speciesFields* used to do. (MassSizeParamsFromScatMeta): Added. WSM to calculatem-D's alpha and beta from the scat_meta info. Code mostly copied from pnd_fieldF07. (psdF07): Added. WSM analogous to psdMH97, but for F07 psd. (psdMH97): Temporarily introduced user parameter to switch off temperature adjustment. (pnd_fieldCalcFromParticleBulkProps): Bugfix in deriving flat indices in case of multiple scat_species. (dNdD_F07): Added. Merged the two F07* WSM and adapted to apply new psd_snow_F07. (dNdD_W16): Bugfix. psd_rain_W16 already returns dNdD for complete size grid; no need to call it per size entry. * cloudbox.cc,h: (pnd_fieldW16): Added. Interface from pnd_fieldCalcFromscat_speciesFields to rain drop size distribution W16 (psd_rain_W16). (pnd_fieldF07): Merged both Field, 2007 methods into one (the only difference are some coefficients that have not even been handled here, but in the further submethods IWCtopnd_F07*). Removed useless "unit conversion factor" as this was anyway hardcoded to 1. Throw error if SWC<0 (in contrast to what the comments claimed, F07 formulas do not provide meaningful results at negative WC (rather NaN in my tests). (pnd_fieldMH97): Don't calculate dveq from mass, but take it from scat_meta. (psd_snow_F07): Renamed from IWCtopnd_F07* and merged both these Field, 2007 core methods. Changed to handle a grid of sizes at once. (bin_integral): Renamed from 'scale_pnd' (as it's more general applicable than just for psd to pnd integration) and separated the node (or bin) weight calculation from the actual integration into it's own method. Generalized doc accordingly. (bin_quadweights): Added. The separated node/bin weight calculation for bin_integral. * controlfiles/artscomponents/doitbatch/TestDOITBatch.ybatch.ref.xml: Updated. Using vol_equ_diameter from scat_meta instead of calculating dveq from mass makes a slightly larger difference than the 0.01K threshold. 2017-06-21 Richard Larsson * arts-2-3-731 * src/lin_alg.cc: Added solution by Philippe Baron on matrix exponent for RT using a Cayley-Hamilton theorem fit to eigenvalues and coefficients. Both explicit and Eigen solutions are available. The Eigen solution is faster despite technically performing more operations and copying in my test cases [by 10%]. Speed-up in simple test of 1,000,000 computations: 24 sec for old method, 0.9 sec for new method. Single core. * src/rte.cc: Updated to use new matrix exponent. Please revert if this breaks anyones test case (and send me the test case). Description of the method can be found in the functions in lin_alg.cc. The Eigen-code should also be fairly straightforward to read Note: there is a lot of copying going on in the trans_mat calculations because we are sending in A=-K*r, where K is a constant. Same for the jacobians, in which case the copying is multiplied by a lot. I wonder if we should redesign the matrix exponent, or at least the interface in rte.cc, to explicitly expect K rather than A=-K*r? 2017-06-19 Oliver Lemke * arts-2-3-730 * CMakeLists.txt: Simplify BLAS/LAPACK detection. Only look for LAPACK, because it itself checks for BLAS anyway. No need checking for both ourselves. Also, remove additional Cblas detection which created more problems than it solved. * src/CMakeLists.txt: Remove BLAS_LIBRARIES variable as blas libraries are listed in LAPACK_LIBRARIES variable. 2017-06-17 Patrick Eriksson * arts-2-3-729 * src/m_cloudradar.cc (iyActiveSingleScat): Added Jacobian for impact of gases on attenuation. 2017-06-17 Patrick Eriksson * arts-2-3-728 * src/m_cloudradar.cc (iyActiveSingleScat): Made a switch to use, get_ppath_pmat_and_tmat that is needed for handling remaining jacobians. Changes below side-effects. But the switch made the calculations nearly double as long. Reason should be checked. * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): * src/m_fos.cc (iyHybrid): Adopted call of get_ppath_pmat_and_tmat. * src/rte.cc (get_ppath_pmat_and_tmat): Added scat_data_single as output argument. 2017-06-16 Richard Larsson * arts-2-3-727 * src/lineshapesdata.h: Updated to fit with line mixing scenario * src/m_linemixing.cc: Using the updated line shape functions better * src/rte.cc: Changed order of two RT loops to be frequency-first so that OpenMP can be applied 2017-06-16 Oliver Lemke * arts-2-3-726 * src/docserver.cc (Docserver::list_agendas): Fix bug introduced in arts-2-3-677. Workspace variables were not listed correctly. Reported by Jana. 2017-06-16 Simon Pfreundschuh * arts-2-3-725 * src/m_oem.cc (oem_template): Fixed passing of ml_ga_settings to invlib. Bug reported by Theresa. * 3rdparty/invlib/*: invlib update. 2017-06-14 Oliver Lemke * arts-2-3-724 * src/parser.cc (parse_matrix): For empty matrices, ncols was set to 1. Fixed and cleaned up code. Bug reported by Patrick. * controlfiles/CMakeLists.txt: Use OEM_SUPPORT variable instead of NO_OEM. 2017-06-14 Patrick Eriksson * arts-2-3-723 * src/workspace.cc: Somne extension of description of the covariance matrices used by OEM. * controlfiles/artscomponents/oem/TestOEM.arts: A small extension to indicate that x, yf, and jacobian can both be empty or pre-calculated. 2017-06-14 Simon Pfreundschuh * arts-2-3-722 * controlfiles/artscomponents/oem/TestOEM.arts: Added missing OEM test. 2017-06-13 Simon Pfreundschuh * arts-2-3-721 * controlfiles/testdata/ozone-line.xml: Moved from groundbased tests to be reused for OEM testing. * controlfiles/artscomponents/groundbased/*.arts: Updated position of ozone line file. * controlfiles/CMakeLists.txt: Added new OEM test. * src/m_oem.cc(oem_checks): Extended oem_checks to properly handle missing or precomputed x, yf, jacobian. 2017-06-13 Patrick Eriksson * arts-2-3-720 * doc/uguide/cloudradar.tex: Slight reorganisation and wrote a basic description of Jacobian calculations. Even stuff not yet implemented! 2017-06-13 Simon Pfreundschuh * arts-2-3-719 * src/m_oem.cc(OEM_checks): Use .empty() member function to test for emptiness of matrices. * src/m_oem.cc: Fixed calculation of covmat_so. Renamed avkCalc, covmat_soCalc for consistency. Added covmat_ssCalc. * src/methods.cc: Updated entries for avkCalc, covmat_soCalc, covmat_ssCalc. * src/workspace.cc: Updated entries for avk, covmat_so, covmat_ss. 2017-06-13 Jana Mendrok * arts-2-3-719 * src/m_cloudradar, m_cloudbox.cc (psdMH97, pnd_fieldCalcFromParticleBulkProps, pndFrompsdBasic, pnd_size_gridFromScatMeta): Moved from m_cloudradar.cc to m_cloudbox.cc * src/m_cloudbox.cc (psdW16): Added pnd_agenda WSM for rain following Wang, 2016. (dNdD_MH97): Throw error when T (in K) is negative. (dNdD_W16): Error message fix. * src/cloudbox.cc (psd_cloudiceMH97): Initialize all sig_* with 0 (as not noisy is the more often used option), then reset only if noisy is chosen. * src/methods.cc (psdW16, psdMH97, dNdD_MH97, dNdD_W16): Written/updated/completed built-in doc. 2017-06-13 Richard Larsson * arts-2-3-718 * src/m_linemixing.cc: Updated for not ignoring that error handling is different now compared to when I started this file... * src/lineshapesdata.h: Some renames, reshuffling, and additions (still beta) 2017-06-13 Oliver Lemke * arts-2-3-717 * CMakeLists.txt: Only disable OEM on macOS with clang. The error on macOS is only a warning with clang on Linux. * src/m_oem.cc (computeSo, computeAVK): Add implementations that throw a runtime error if OEM support is disabled. 2017-06-13 Simon Pfreundschuh * arts-2-3-716 * src/m_oem.cc(oem_template): Renamed covmat_so to covmat_se. * src/m_oem.cc(OEM_checks): Added check to ensure dimensions of Jacobian and yf. * src/m_oem.cc(computeSo): Added workspace method to compute the retrieval covariance matrix. * src/m_oem.cc(computeAVK): Added workspace method to compute the averaging kernel matrix. * src/workspace.cc: Added avk and covmat_so workspace variables. * src/methods.cc: Added documentation for new workspace methods. Fixed missing linebreaks from previous commit. 2017-06-12 Jana Mendrok * arts-2-3-715 * src/m_disort.cc (DisortCalc*), m_doit.cc (DoitCalc), m_rt4.cc (RT4Clac*): Rolled back to only-warning and return to clearsky calc if scatt solvers are called with cloudbox off (as used pre arts-2-3-633). 2017-06-11 Patrick Eriksson * arts-2-3-714 * particle_bulkprop_field and particle_bulkprop_names are now semi-mandatory variables, i.e. they must at least be set to be empty in line with e.g. the wind fields. * src/m_oem.cc (x2artsScatSpecies): Removed. Obselete after changing x2artsStandard. (x2artsStandard): Now handling scattering species. The method now also considers atmfields_checked, atmgeom_checked, cloudbox_on and cloudbox_checked. * src/m_jacobian.cc (jacobianDoit): Adopted call of cloudbox_checkedCalc. * src/m_checked.cc (cloudbox_checkedCalc): Added checks of particle_bulkprop_field and particle_bulkprop_names. * src/m_cloudradar.cc (pnd_fieldCalcFromParticleBulkProps): Added comment, to explain why this method contains a lot of checks. * controlfiles/general/general.arts: particle_bulkprop_field and particle_bulkprop_names added. Set to be empty. 2017-06-09 Richard Larsson * arts-2-3-713 * 3rdparty/relmat/*: Updated to latest version * src/lineshapesdata.{cc,h}: Added LineFunctions helper class because I keep having to rewrite code for special cases. Can handle line shapes, line strengths, line mixing, Zeeman, and their derivatives presently but only used by m_linemixing.cc to simplify those calculations. Some todos to integrate with rest of ARTS if desired (it simplifies computations significantly, or at least makes them readable easier). Lacks cutoff-frequencies and purely real line shapes. Also the generalization to line specific partial derivatives needs to take the quantumidentifiers still. Beta code in other words. * src/complex.h: Added ArrayOfComplex{Vector,Matrix} * src/m_linemixing.cc: Making use on parts of lineshapesdata.{cc,h} to simplify reading. Still left with a lot of old code commented out for easy switching since I am still testing it. * src/partial_derivatives.h: Added some more checks 2017-06-09 Patrick Eriksson * arts-2-3-712 * doc/uguide/cloudradar.tex: Rudimentary update of the chapter. * src/m_cloudradar.cc (iyActiveSingleScat): Now allows that cloudbox_on = 0. But note some calculations will be done even in this case, such as calculation of ppath. And if there is any iy_aux_var, the full method is run. 2017-06-09 Oliver Lemke * arts-2-3-711 * CMakeLists.txt, src/CMakeLists.txt: Add better Threads detection. The pthread library needed by libmicrohttpd was not properly linked on all configurations (clang on Ubuntu 17.04). * src/binio.cc (binostream::float2ieee_single): Remove deprecated 'register' keyword. 2017-06-08 Oliver Lemke * arts-2-3-710 * CMakeLists.txt: Up requirement for cmake to 3.1.0 (released in December 2014). Make C++11 compiler support a requirement. This utilizes the macros CMAKE_CXX_STANDARD, CMAKE_CXX_STANDARD_REQUIRED, CMAKE_CXX_EXTENSIONS available since cmake 3.1.0. Add status output whether OEM is enabled. * src/main.cc (main): Remove C++11 support output from feature list because it is not optional anymore. Changed two loops to test C++11 range-based for loops. * src/m_fos.cc: Include m_xml.h for WriteXML. Fixes unresolved reference with Intel compiler. 2017-06-08 Oliver Lemke * arts-2-3-709 * src/m_abs_lookup.cc (abs_lookupSetupBatch): Error handling was eating the original error message for invalid atmospheres leaving the user with no clue why this atmosphere failed. Bug reported by Alex. 2017-06-07 Jana Mendrok * arts-2-3-708 * src/cloudbox.[cc,h] (psd_rain_W16, psd_general_MGD): Added. PSD core functions for Wang16 raindrop PSD and general modified gamma distribution. Both ported from Matlab code in CloudARTS and Atmlab, respectively. (psd_cloudice_MH97): Rename former IWCtopnd_MH97 / psdFromMH97 once more. * src/m_cloudbox.cc, methods.cc (dNdD_W16): Added. Wrapper WSM for Wang16 rain PSD. (dNdD_MH97): Check for negative IWC. * src/m_cloudbox.cc (psdMH97): IWCtopnd_MH97 / psdFromMH97 rename. 2017-06-07 Jana Mendrok * arts-2-3-707 * src/cloudbox.[cc,h] (psdFromMH97): Fixed last-minute introduced bug *eyeroll*. 2017-06-07 Simon Pfreundschuh * arts-2-3-706 * src/oem.h: Another fix for the isnan problem. 2017-06-07 Jana Mendrok * arts-2-3-705 * src/cloudbox.[cc,h] (psdFromMH97): Revised and renamed old IWCtopnd_MH97. Now takes a Vector of sizes. More rigid behaviour for out-of-bounds input parameters, pushing all responsibility to handle/fix them to calling function. * src/m_cloudbox.cc (dNdD_MH97): Adapted to apply new psdFromMH97 conserving old behaviour. * src/m_cloudradar.cc: Adapted to apply new psdFromMH97. * src/methods.cc: Cosmetical fixes. 2017-06-07 Simon Pfreundschuh * arts-2-3-703 * src/m_oem.cc: Added guards to keep isnan macro out of invlib code. * src/matpack.h: Rolled back using declarations, which cause build error on different configuration. 2017-06-07 Simon Pfreundschuh * arts-2-3-702 * src/oem.h(ArtsLog): Some cosmetical fixes for the logging class. * src/m_oem.cc (oem_template): Implemented some changes discussed with Patrick. Also fixed the length of the ml_ga_history_vector. * 3rdparty/invlib/*: Updated invlib library * src/matpack.h: Replaced Macros by using directives. Same effect, but doesn't break other code that uses the std:: prefix for the isnan and isinf functions. 2017-06-06 Patrick Eriksson * arts-2-3-701 * src/m_oem.cc (x2artsScatSpecies): New WSM. * src/m_cloudradar.cc (pnd_fieldCalcFromParticleBulkProps): Did not work with no jacobian calculations. 2017-06-06 Oliver Lemke * arts-2-3-700 * 3rdparty/polradtran/rt4/radmat.f: Rename daxpy and dswap to rt4_* to avoid name clash with function from external BLAS library. Avoids possible segfaults due to implementation differences. Reported by Patrick and Simon. 2017-06-05 Patrick Eriksson * arts-2-3-699 * First radar jacobian in place. So far just considering the change in back-scattering, effect on attenuation of both gases and particles to be added. [But still happy as I spent 5 hours on bug hunting, finding that all had been correct from start. I just strongly under-estimated the particle attenuation and my test did not work as expected.] * src/m_cloudradar.cc (iyActiveSingleScat): Work around jacobian calculations. * src/m_cloudradar.cc (yActive): Added geo_pos_agenda as input. y_f, y_geo etc. now set. Now alos jacobian quantities processed and the jacobian matrix is compiled. * src/workspace.cc: Updated and polished text for *y_geo*. * src/m_rte.cc (yCalc): Default for y_geo is now NAN, instead of -99999. * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): Initial check of iy_transmission now using .empty. 2017-06-04 Patrick Eriksson * arts-2-3-698 * src/m_cloudradar.cc (iyActiveSingleScat): Renamed iyCloudRadar, as the method is not restriced to neither clouds or radars. (yActive): Renamed iyCloudRadar, for same reason as above. Added jacobian_do as input. Added y_f, y_pol, y_pos, y_los, y_geo and jacobian as output. Started to add handling of these variables. * src/workspace.cc: Improved unit part of *iy*. 2017-06-03 Patrick Eriksson * arts-2-3-697 * src/m_fos.cc (iyHybrid, fos): * src/m_rte.cc (iyEmissionStandard): * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): Adopted calls of the two functions below, by adding even more dummy variables. * src/rte.cc (get_ppath_ext): Added ppath_dpnd_dx as output argument and dpnd_field_dx as input. Added handling of ppath_dpnd_dx. (get_ppath_pmat_and_tmat): Added ppath_dpnd_dx as output argument and dpnd_field_dx as input. 2017-06-03 Patrick Eriksson * arts-2-3-696 * src/m_cloudradar.cc (iyCloudRadar): The reference dielectric factor can now be specied directly, and not just be calculated by MPM93 refractive index. The new feature is needed to mimic e.g. CloudSat data. Extended built-in doc significantly regarding units. (yCloudRadar): Switched to new version. The difference is that binning is done differently. This is now done with integration_bin_by_vecmult, that should be both faster and more accurate. In fact, in my test case I noticed clear deviations when comparing to old bin scheme, when using more wide bins. And it was the old scheme that failed, it e.g. did not conserve the integrated Ze. That is, the previous version did not work properly! I have not tried to find the exact reason. 2017-06-02 Jana Mendrok * arts-2-3-695 * src/rte.[cc,h] (get_ppath_scat_source_fixT): Make separate function for optimized pha_mat_spt extraction without temperature interpolation. * src/m_fos.cc, methods.cc (iyHybrid): Add keyword pfct_method to allow choosing pha_mat_spt temperature adaptation method and calls to respective get_ppath_scat_source* functions. Made median-T-point extraction the default. 2017-06-02 Jana Mendrok * arts-2-3-694 * src/m_optproperties.cc, methods.cc (pha_mat_dataFrom*): Introduced non-T-interpolation option (governed via rtp_temperature variable; see online doc) in order to allow speedier pha_mat extraction (and, specifically, to be able optimize the amount of pha_mat_spt extraction in iyHybrid - perfomring that only once instead of per each ppath grid point). 2017-06-02 Jana Mendrok * arts-2-3-693 * src/rte.cc (get_ppath_scat_source): Remove scaling of scat source per scat element with its pnd, ie outputting scat source one single particle of each element. Removes requirement of separately calculating and storing dppath_scat_source. For jacobians, do NOT skip pha_mat_spt and ppath_scat_source calcs for pnd=0. Bugfix in incoming field p-interpolation. * src/m_fos.cc (iyHybrid): Some code for layer bulk source calculation for applying in scat source in RT solution. * src/rt4.cc: Layout fixes for a couple of error/info messages. 2017-06-02 Patrick Eriksson * arts-2-3-692 * src/m_cloudradar.cc (yCloudRadarNew): New version of yCloudRadar, not yet active. * src/sensor.cc (integration_bin_by_vecmult): Varoius changes, now seems to work. And now also handles decreasing grids. 2017-06-01 Jana Mendrok * arts-2-3-691 * src/m_fos.cc (iyHybrid), rte.[cc,h] (get_ppath_scat_source): Moved all scat source calculation stuff into an individual function. 2017-06-01 Jana Mendrok * arts-2-3-690 * src/m_fos.cc (iyHybrid): Implemented scat source term calculation (not jacobians capable yet). 2017-06-01 Patrick Eriksson * arts-2-3-689 * src/sensor.cc (integration_bin_by_vecmult): New function. So far just coding, no testing done. (sensor_integration_vector2): Removed this function. It was not used in any way. Seems that it was an old version of the function, before normalisation of x_f was introduced. (summation_by_vecmult): (integration_func_by_vecmult): Renaming of two old functions. They before started with sensor_, but they are not limited to sensor calculations. * src/sensor.cc: Changes in sevaral functions due to renaming above. 2017-06-01 Jana Mendrok * arts-2-3-688 * src/rt4.cc: General cleanup from (outcommented and active) couts. (sca_optpropCalc): Bugfix I. Affected calculations with "semi-bad" normed RT4 scattering matrices (ie cases that did pass the error threshold, but were bad enough to trigger a out2 warning message and by that unintentionally skip the renormalization), which easily occured when increasing pfct_threshold to avoid the bad-norm error throwing. :((( Good thing: RT4 results are more stable over nstreams now. Bad thing: complete (re)normalisartion takes time, i.e. calculations take noticeably longer now. Bugfix II. Calculate complete scattering matrix structure when auto_inc_stream limit is hit, but calculation shall be executed (aka robust=1) anyways. * src/m_rt4.cc: Made pfct_threshold an internal global constant (to avoid inconsistent settings in the different RT4Calc* methods). * 3rdparty/polradtran/rt4/radscat4.f, radtran4.f: Remove outcommenting of info message inside CHECK_NORM. instead, outcomment call of it as such (no sense to call it and spend comp time when it has zero effect anyways). Cleaned out some earlier added comments/write statements. * src/m_surface.cc, methods.cc (surface_reflectivityFromSurface_rmatrix): Vector method equivalent to surface_scalar_reflectivityFromSurface_rmatrix. Not in effect so far (as in the end i didn't need it and was not sure whether the approach is correct like this in the general, aka non-scalar, case. 2017-06-01 Patrick Eriksson * arts-2-3-687 * src/m_cloudradar.cc (pnd_size_gridFromScatMeta): Added scat_index as GIN argument. The method should now be complete. 2017-06-01 Oliver Lemke * arts-2-3-686 * src/workspace.cc: New WSV agenda_array_index. * src/agendas.cc: Add agenda_array_index as input to test_agenda_array and pnd_agenda_array. * src/agenda_record.cc: Remove agenda index as last argument in agenda_arrayExecute interface. It is now passed as a normal WSV input for agenda arrays. * src/m_cloudradar.cc: Adapt call to pnd_agenda_arrayExecute. * src/m_general.cc: Adapt call to test_agenda_arrayExecute. * src/m_agenda.cc, src/methods.cc: Add agenda_array_index as input to ArrayOfAgendaExecute. * controlfiles/artscomponents/agendas/TestArrayOfAgenda.arts: Adapt for introduction of new WSV agenda_array_index. * src/make_auto_md_cc.cc: Adapt generated code for changed variable name. 2017-06-01 Patrick Eriksson * arts-2-3-685 * src/m_rte.cc (iyEmissionStandard): * src/m_transmitter.cc (iyTransmissionStandard): * src/m_fos.cc (iyHybrid): Adopted call of get_pointers_for_analytical_jacobians. * src/m_jacobian.cc (jacobianAddScatSpecies): Had missed to set rq.Analytical. * src/jacobian.cc (get_pointers_for_analytical_jacobians): Replaced nscats with scat_species as input argument, and changed identification of scattering species index. 2017-05-31 Patrick Eriksson * arts-2-3-684 * src/m_cloudradar.cc (pnd_size_gridFromScatMeta): New method, to make psd/pnd part even more modular. * src/methods.cc: Added some documentation text, but there are still gaps. * src/workspace.cc: * src/agendas.cc: Wrote documentation text for the variables introduced recently. 2017-05-31 Oliver Lemke * arts-2-3-683 * CMakeLists.txt: Improved detection of anaconda presence. First check for CblasLapack, then LaPack. Fixes linking issue on DKRZ's Mistral supercomputer when compiling with Intel C++. ^^^^^ Please let me know if this change creates problems in LaPack detection for any other configurations. * src/m_general.cc (Print): Timer output for system time was always zero. Thanks to clang-tidy for the info. :-) * src/m_linemixing.cc (calculate_xsec_from_relmat): Use double instead of integer literal to help the Intel compiler to pick the correct overloaded function instead of failing. 2017-05-31 Patrick Eriksson * arts-2-3-682 * src/m_cloudradar.cc (pnd_fieldCalcFromParticleBulkProps): Now making use of the new agenda array feature, and is then hopefully a ready WSM. * src/workspace.cc: * src/agendas.cc: Changed pnd_agenda to pnd_agenda_array. * src/m_cloudradar.cc (psdMH97): Now handles negative IWC, which can happen during iterative inversions. 2017-05-30 Jana Mendrok * arts-2-3-681 * src/rt4.cc,h (run_rt4): When auto-adapting internal stream number, for higher freqs start from where previous freq ended (higher freqs have stronger PFCT peaks need more directions for proper norm conservation). Add robust keyword for auto-adapt case. * src/m_rt4.cc, methods.cc (RT4Calc*): Add robust keyword (for auto_inc_nstreams case). * src/m_fos.cc (iyHybrid): Some unsorted code snippets for scattering source calc. work in progress (not functional, but compilable). 2017-05-30 Oliver Lemke * arts-2-3-680 * controlfiles/artscomponents/agendas/TestArrayOfAgenda.arts: Make test case output a bit more exciting. * src/m_general.cc (TestArrayOfAgenda): Tweak local iy_unit value. 2017-05-30 Oliver Lemke * arts-2-3-679 * src/agenda_record.{h,cc} (write_agenda_wrapper_header): Add is_agenda_array parameter. For ArrayOfAgenda, ...Execute takes the array and the index of the agenda from the array to execute as an additional parameter. * src/agendas.cc, src/methods.cc, src/workspace.cc: Update docs for test_agenda_array and TestArrayOfAgenda. * src/make_auto_md_h.cc: Pass is_agenda_array boolean to write_agenda_wrapper_header. * src/make_auto_md_cc.cc: Pass is_agenda_array boolean to write_agenda_wrapper_header. Do a proper runtime range check in the ...Execute method implementation for ArrayOfAgenda. * src/make_auto_md_h.cc, src/make_auto_md_cc.cc: Remove several trailing white spaces. * src/m_general.cc (TestArrayOfAgenda): Adapt call for test_agenda_arrayExecute. * controlfiles/artscomponents/agendas/TestArrayOfAgenda.arts, controlfiles/CMakeLists.txt: Add simple test case for ArrayOfAgenda. 2017-05-30 Patrick Eriksson * arts-2-3-678 * src/m_cloudradar.cc (pnd_fieldCalcFromParticleBulkProps) (pndFromPsdBasic, psdMH97): Now also handles the dx variables. Seems to works for a simple test case. 2017-05-30 Oliver Lemke * arts-2-3-677 * WORK IN PROGRESS: Implementation of ArrayOfAgenda. * src/agenda_class.h: Add ArrayOfAgenda typedef. * src/agenda_record.cc (AgRecord::AgRecord): Turn assertion into runtime error for better error output in make_auto_md*. * src/workspace.cc, src/agendas.cc: Add test_agenda_array. * src/groups.cc: Add ArrayOfAgenda. * src/wsv_aux.h, src/groups.cc (is_agenda_group_id): Add convenience method. * src/m_agenda.cc, src/methods.cc: Add WSMs ArrayOfAgendaExecute and ArrayOfAgendaAppend. * src/m_general.cc, src/methods.cc: Add WSMs TestArrayOfAgenda. * src/m_append.h, src/methods.cc: Pass WSV names to append. Needed to treat append properly for ArrayOfAgenda. * src/m_basic_types.h: Add nelemGet for ArrayOfAgenda. * src/m_copy.h: Add copy for ArrayOfAgenda. * src/m_general.{h,cc}: Add print for ArrayOfAgenda. * src/m_ignore.h: Add Ignore for ArrayOfAgenda. * src/m_select.h: Add Select for ArrayOfAgenda. * src/m_xml.{h,cc}: Cleanup implementation of ReadXML* and WriteXML* by turning them into template functions and moving the into the header file. Remove MPI handling from WriteXMLIndexed function as it is handled anyway in WriteXML. * src/docserver.cc, src/make_auto_md_h.cc, src/make_auto_md_cc.cc: Use new is_agenda_group_id. * src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add ArrayOfAgenda. Throws a runtime error because Agenda can't be saved/loaded. 2017-05-30 Patrick Eriksson * arts-2-3-676 * src/m_cloudradar.cc (pndFromPsdBasic): Extended. (psdMH97): Fixed some non-resolved issues. (pnd_fieldCalcFromParticleBulkProps): New WSM. * src/workspace.cc: Introduced pnd_agendas_input_names. * src/m_jacobian.cc (jacobianAddScatSpecies): Scattering species now selected by name, and not index. 2017-05-30 Oliver Lemke * arts-2-3-675 * src/xml_io_array_types.cc: Use correct type name in tag attribute for ArrayOfString. 2017-05-30 Oliver Lemke * arts-2-3-674 * src/groups.cc, src/mystring.h, src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Implemented WSV group type ArrayOfArrayOfString. 2017-05-29 Patrick Eriksson * arts-2-3-673 * Some change of plans, revision started. * src/m_cloudradar.cc (psdMH97): Rewritten to handle new set of WSVs, treating multiple points. * src/workspace.cc: Modified or having new names are dpnd_data_dx, dpnd_data_dx_names, particle_bulkprop_field, pnd_agenda_input, pnd_agenda_input_names, pnd_data dpsd_data_dx, psd_data and dpnd_field_dx. 2017-05-29 Oliver Lemke * arts-2-3-672 * CMakelists.txt: Correctly disable OEM if C++11 is unavailable. 2017-05-29 Jana Mendrok * arts-2-3-671 * src/rt4.cc,h, m_rt4.cc (run_rt4): Debugging. * src/methods.cc (DisortCalcwithARTSSurface, RT4Calc): Spelling fixes in doc. * controlfiles/planetary_toolbox/demos/common/DemoMarsClouds1D.arts: Long-done doc corrections. 2017-05-29 Patrick Eriksson * arts-2-3-670 * Continued work on the stuff started in my last commits. * src/workspace.cc: Added also particle_bulkprop and particle_bulkprop_names. 2017-05-28 Patrick Eriksson * arts-2-3-669 * src/m_cloudradar.cc (pndFromPSD, psdMH97): Started. * Added some variables for moving towards tests of scattering jacobians. So far just handling one scattering species, and temporary naming and no documentation text written. pnd_agenda is now defined to cover one point, but it should be consider to instead let it cover multiple points to decrease the overhead due to repeated checks. * src/agendas.cc: Added pnd_agenda. * src/workspace.cc: Added dpnd_dx, dpsd_dx, pnd_agenda, pnd, pnd_input, pnd_input_names, psd and psd_grid. 2017-05-26 Patrick Eriksson * arts-2-3-668 * More work on scattering jacobians. * src/m_rte.cc (iyEmissionStandard): Introduced new variables and adopted call of get_pointers_for_analytical_jacobians. * src/jacobian.cc (get_pointers_for_analytical_jacobians): Added scat_species_i and nscats as functiuon arguments. * src/m_transmitter.cc (iyRadioLink): * src/m_fos.cc (fos): t_nlte_field_dumme renamed to t_nlte_field_empty, and clearly init to be empty. Introduced new variables and adopted call of get_pointers_for_analytical_jacobians. * src/m_jacobian.cc (jacobianAddScatSpecies) (jacobianCalcScatSpeciesAnalytical): New methods. So far just coding, no testing at all. 2017-05-26 Richard Larsson * arts-2-3-667 * src/m_linemixing.cc: Updated to perform calculations with ordered line mixing output from RELMAT. This avoids some complications that are probably numerical in nature that we encounter with the full approach... * src/methods.cc: Updated interface to the line mixing code * 3rdparty/relmat/*: Using Teresa's latest version 2017-05-25 Patrick Eriksson * arts-2-3-666 * BUG fix!!! The transmission in iyCloudRadar was incorrect. No error if cloudbox covered complete atmosphere, otherwise simulated backscattering was somewhat too high. * src/m_cloudradar.cc (iyCloudRadar): tr_rev was only updated inside the cloudbox. This effectively resulted in an under-estimation of gas attenuation in one of the directions. Also, removed use_mean_scatdata as input and more coding to prepare for jacobians. (pnd_field_from_ppdata): Start on function to fill pnd_field using agendas to be added. 2017-05-24 Jana Mendrok * arts-2-3-665 * src/m_rt4.cc, methods.cc (RT4Calc*), src/rt4.cc,h (run_rt4): First complete version with internal automatic increase of nstreams if requested and needed. Not tested yet. Nothing broken in non-increase version, it seems (phew). 2017-05-24 Jana Mendrok * arts-2-3-664 WORK IN PROGRESS. Towards a more robust RT4. Can break controlfiles. * src/m_rt4.cc, methods.cc (RT4Calc*), src/rt4.cc,h (run_rt4, sca_optpropCalc): After misuse by experts, removed pfct_threshold as user parameter, but hardcoded to a value that proofed to make sense. Instead, allow internal automatic increase of number of streams in order to have the scattering matrix being able to properly reproduce the expected norm. Done individually per frequency. 2017-05-24 Patrick Eriksson * arts-2-3-663 * src/m_cloudradar.cc (iyCloudRadar): A small first step towards supporting Jacobians. * src/montecarlo.cc (pha_mat_singleCalcScatElement) (pha_mat_singleCalc): The old pha_mat_singleCalc was seperated into two functions, to make it possible to also obtain the phase function for each scattering element without duplication of code. 2017-05-23 Patrick Eriksson * arts-2-3-662 * src/m_fos.cc (iyHybrid): A bit more ... * src/m_rte.cc (iyEmissionStandard): * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): Just formatting changes. 2017-05-23 Patrick Eriksson * arts-2-3-661 * src/m_fos.cc (iyHybrid): Some small steps forward ... 2017-05-23 Oliver Lemke * arts-2-3-660 * CMakeLists.txt, config.h.cmake, src/CMakeLists.txt, src/m_oem.cc, src/main.cc: Separate C++11 support from OEM support. Before, C++11 support had to be forcibly disabled for clang because invlib doesn't compile with it. Now, only OEM, not C++11, is disabled by default if clang is used. It can be reenabled for testing with clang with -DENABLE_OEM=1 . * CMakeLists.txt, README: Add support for ccache (-DENABLE_CCACHE=1). https://ccache.samba.org/ * src/array.h: Add std:: before fill calls. 2017-05-23 Patrick Eriksson * arts-2-3-659 * src/m_fos.cc (iyHybrid): Just a start on testing out a hybrid scattering solver. * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): Just changes in comments and indentation. * src/agendas.cc: Added doit_i_field_agenda. 2017-05-16 Jakob Doerr * arts-2-3-658 * src/m_doit.cc (OptimizeDoitPressureGrid, doit_scat_fieldCalc, doit_scat_fieldCalcLimb), m_optproperties.cc (DoitScatteringDataPrepare, TestScatDataInterp): Pulled the temperature interpolation of the phase matrix out of the interation loop in DOIT. The interpolation of the phase matrix is now done in DoitScatteringDataPrepare, so before the loop. Before it was interpolated in doit_scat_fieldCalc and doit_scat_fieldCalcLimb. This saves a lot of time for DOIT. The phase matrix is now stored in a new WS variable, pha_mat_doit. * src/methods.cc: Changed the methods according to the change above * src/workspace.cc: Added new WS variable pha_mat_doit 2017-04-27 Gerrit Holl * arts-2-3-657 * controlfiles/instruments/hirs/METOPB_HIRS.backend_channel_response.xml, controlfiles/instruments/hirs/METOPB_HIRS.f_backend.xml: Added Metop-B SRFs. Thanks Viju and Timo. 2017-04-23 Richard Larsson * arts-2-3-656 * 3rdparty/relmat/*: updated to latest version * src/Faddeeva.cc: a bugfix was released in 2015 and is now in ARTS * src/m_linemixing.cc: Fixed error in how I used the joker statements... 2017-04-18 Richard Larsson * arts-2-3-655 Code-dump of various functions I have been using and latest version of Relmat * src/linerecord.cc: ReadFromHitran2004Stream now keeps the einstein coefficient * src/m_atmospheres.cc: added (z_surfaceFromFileAndGrid) and (vmr_fieldSetAllConstant) to easier set some essential variables * src/m_jacobian.cc: fix of error throwing for valid case of VMR jacobians * src/m_linemixing.cc: comment change for future checking * src/m_rte.cc: Fix bug happening for special integrated cases by moving definition of sizes up a level * src/methods.cc: Added metohds above * src/pressurebroadeningdata.cc: fix comment typo * src/rational.cc: "3/1" is now written as "3" --- this is just an aesthetic change as the reading routine already looks for "/" * 3rdparty/relmat/*: Teresa's updated in preparation for O2. It is now using "allocatable" to allocate dynamically instead of statically 2017-03-22 Oliver Lemke * arts-2-3-654 * README: Add information on using callgrind. 2017-03-14 Alex Bobryshev * arts-2-3-653 * controlfiles/instruments/metmm/sensor_descriptions/sensor_atms.arts: Added controlfile to simulate ATMS instrument. * controlfiles/instruments/metmm/TestMetMM.arts: Added comment to stress 0-based indexing in ARTS. 2017-03-07 Jana Mendrok * arts-2-3-652 * src/methods.cc, m_disort.cc (DisortInit, DisortCalc*), disort.[cc,h] (check_disort_input, init_ifield), rt4.[cc,h] (check_disort_input, init_ifield), m_rt4.cc: Removed DisortInit, moved (most) functionality into check_disort_input. Moved init_ifield from rt4.cc to disort.cc (less of a hassle to include disort.h than rt4.h). * controlfiles/artscomponents/disort/TestDISORT.arts: Adapted to above. 2017-03-07 Jana Mendrok * arts-2-3-651 * src/m_doit.cc (iyInterpCloudboxField): Fixed extrapol range check for in-cosine interpolation. Consistently report angles (not cosines) in error message. 2017-03-06 Jana Mendrok * arts-2-3-650 * src/rt4.cc (run_rt4): Update gas absorption from initialized zeros only if there is at least one abs_species (determined via vmr_field extend). Also, only determine scattering properties if there's at least one non-zero pnd_field entry. 2017-03-06 Jana Mendrok * arts-2-3-649 ATTENTION: Breaks backward compatability of RT4-using controlfiles. * src/m_rt4.cc, methods.cc, rt4.[cc,h] (RT4Init, RT4Calc, RT4CalcWithRT4Surface; check_rt4_input, init_ifield): Remove RT4Init (got too error-prone with many generic input variables that needed to be consistent between Init and Calc, and no real use here of having a separate Init WSM). Moved functionality into check_rt4_input and init_ifield instead. 2017-03-06 Jana Mendrok * arts-2-3-648 * src/m_doit.cc, methods.cc (iyInterpCloudboxField): Throw error if angle interpolation order exceeds number of available grid points. Make extrapolfac for za angle poly-interpolation a user parameter, default set to 1.0 which should satisfy all of RT4's quad types. Check that za interpolant within given inter/extrapolation range and throw error otherwise. * src/m_rt4.cc, methods.cc, rt4.[cc,h] (RT4Init, RT4Calc, RT4CalcWithRT4Surface; check_rt4_input): Make adding of zenith/nadir as RT4 user angles optional (together with the extrapolation of angle grid above this should allow for scat_za_grids that are not bound by 0/180degs). 2017-03-05 Patrick Eriksson * arts-2-3-647 * src/m_surface.cc: Added the option ignore_surface_slope. (iySurfaceFastem): Adopted call of specular_losCalc. 2017-03-03 Jana Mendrok * arts-2-3-646 * src/m_doit.cc, methods.cc (iyInterpLinCloudboxField, iyInterpCloudboxField): Renamed iyInterpLinCloudboxField from iyInterpCloudboxField. New iyInterpCloudboxField using free-order polynomials (gridpos_poly) for angle interpolation and offering options for restricting zenith angle interpolation to respective hemisphere. Default reproduces iyInterpLinCloudboxField results. Higher order and options still need to be tested. * src/interpolation_poly.[cc,h] (gridpos_poly_longitudinal, gridpos_poly_cyclic_longitudinal): Added single point interpolation version for longitudinal interpolation. * src/disort.cc (run_disort): Removed leftover cout. * src/interpolation.cc, src/workspace.cc: Spell fixes, clean up. * controlfiles/artscomponents/disort/TestDISORT.arts, controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITaccelerated.arts controlfiles/artscomponents/doit/TestDOITprecalcInit.arts controlfiles/artscomponents/doit/TestDOITpressureoptimization.arts controlfiles/artscomponents/doit/TestDOITsensorInsideCloudbox.arts controlfiles/artscomponents/polradtran/TestRT4.arts controlfiles/general/agendas.arts controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: Adapted for iyInterpCloudboxField changes. 2017-03-01 Oliver Lemke * arts-2-3-645 * doc/uguide/absorption_theory.tex: Clarify unit for errors. %/100 instead of %. Thanks to Domenico Cimini for pointing this out. 2017-03-01 Oliver Lemke * arts-2-3-644 * CMakeLists.txt: Add workaround for possible linker conflicts for libstdc++ and libgomp on Linux if anaconda is in the path. Reported by Richard. 2017-02-23 Jana Mendrok * arts-2-3-643 * src/m_disort.cc, methods.cc (DisortCalc, DisortCalcWithARTSSurface), src/disort.[cc,h] (check_disort_input, run_disort, get_disortsurff_props): As for RT4 in arts-2-3-639, make separate Disort interace WSM for different surface handling approaches. Common functionality moved into subroutines. All surface data prep moved into a subroutines. * controlfiles/artscomponents/disort/TestDISORT.arts: Adapted to changes above. * src/m_rt4.cc, rt4.cc: Minor fixes. 2017-02-23 Richard Larsson * arts-2-3-642 * src/m_linemixing.cc: Fix input to unused function when the relmat variable is active. Again, hope this will fix it. 2017-02-23 Richard Larsson * arts-2-3-641 * src/m_linemixing.cc: Move methods out of if-def for relmat, Hope this fixes the error. 2017-02-23 Richard Larsson * arts-2-3-640 * 3rdparty/relmat/CMakeList.txt: Added OpenMP. * 3rdparty/relmat/*: Now with the linearization method that Teresa has been working on. Also, now with the promise to be silent if not given a debug flag. The same debug flag then reports - by binary - if the program ran into errors or not. For unknown reasons, the new error checking makes RELMAT run one order of magnitude slower. * src/m_linemixing.cc: adapted for the new error handling. Also added two helper functions (SetBandIdentifiersAuto) and (SetRelaxationMatrixCalcType) to help user set the bands to every band and select to use the linearization method or Hartmann-Tran method. * src/quantum{cc,h}: Helper function (SetFromStringForCO2Band) now available to easily set CO2 bands from standard notations for CO2. * src/workspace.cc: made relmat_type_per_band and band_identifiers part of the workspace 2017-02-22 Jana Mendrok * arts-2-3-639 * src/m_rt4.cc, methods.cc (RT4Calc, RT4CalcWithRT4Surface): For cleaner interfaces, separated RT4 interface into two separate WSM, one using surface_rtprop_agenda (RT4Calc), the other using RT4's own surface property handling (RT4CalcWithRT4Surface). * src/rt4.[cc,h] (check_rt4_input, get_quad_angles, run_rt4): Moved common RT4 pre-, post- and processing functionality of both RT4 WSM into subroutines. (get_rt4surf_props): Subroutine to prepare surface properties for RT4-side surface handling. * controlfiles/artscomponents/polradtran/TestRT4.arts: Adapted to changes above. * CHANGES-2.3: Added info on RT4 and Disort. Added info on p30 format change. 2017-02-22 Oliver Lemke * arts-2-3-638 * src/global_data.h: Make SpeciesMap available in global_data namespace. * src/absorption.cc, src/src/species_data.cc: Move definition and initialization of SpeciesMap to species_data.cc. * src/absorption.cc, src/arts.h: Move declaration of define_species_map to arts.h. 2017-02-21 Oliver Lemke * arts-2-3-637 * src/xml_io_compound_types.cc (xml_write_to_stream): Write newline before ptype attribute when saving SingleScatteringData. * src/lin_alg.cc (propmat4x4_to_transmat4x4): C-arrays of non-POD types are not allowed in C++ (even if GCC thinks otherwise). Changed variables to Array<> type to fix compilation errors on compilers other than GCC. 2017-02-20 Jana Mendrok * arts-2-3-636 * controlfiles/testdata/scatData/azi-random_f229-231T214-225r100NP-1ar1_5ice.xml: Converted to version3 SSD, moved into scatData, properly renamed. * controlfiles/artscomponents/montecarlo/p30f229-231T214-225r100NP-1ar1_5ice.xml: Removed, since duplicate of above one. * controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/artscomponents/doit/doit_setup_accelerated.arts, controlfiles/artscomponents/doit/doit_setup_pressureoptimization.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts: Consistently use azimuthal random particle example data. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts, controlfiles/artscomponents/tmatrix/TestTMatrix.azi-random.ssdREFERENCE.xml, controlfiles/artscomponents/tmatrix/TestTMatrix.tot-random.ssdREFERENCE.xml: Converted reference SSP data to version3, properly renamed reference and output data. * controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts, controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts: Replace relative paths which break when the file is copied somewhere else, eg as a template. * controlfiles/artscomponents/doit/doit_setup.arts: Return to 2-scatt.element setup that was accidentially wiped out lately. * controlfiles/testdata/scatData/MieAtmlab_Liquid*,P20FromHong*: Converted to version3 SSD. * src/methods.cc: WSV link fix. 2017-02-20 Richard Larsson * arts-2-3-635 * src/complex.{cc,h}: Added mult for different matrix-matrix-matrix combinations of complex and normal matrices. Also renamed StrideType to ComplexStrideType * src/continua.cc: renamed real and complex to real_t and complex_t because Eigen complains that real and complex overwrites things. I could not see any problems in testing but I have no idea what these copies of C-types are doing since continua.cc is a tad difficult to follow. (I cannot even "meld" it to point at the differences without producing warnings in Chinese...) * src/lin_alg.{cc,h}: Added matrix diagonalize that returns the eigenvalue derivatives is fed the derivatives of the original matrix. I am still trying to get eigenvector derivatives working but I do not understand the normalization of the paper and get errors on the order of 1e15... Also added (matrix_exp_4x4) and (propmat4x4_to_transmat4x4) for explicitly 4x4 matrices after reading Eigen documentation. These are about 3 times as fast as their general equivalence using ARTS types. There might still be data copying issues in these implementations... the improvements are because 4x4 matrices have analytical solutions and because Eigen use processor vectorizations to repeat operations (if I understand this correctly). Also, removed #pragma in my old special_matrix_exp_and_dmatrix_exp_dx_for_rt because it actually made it even slower (with it on, the new code was 10x faster, now it is only 3x for extreme cases). * src/m_linemixing.cc: Added support for temperature and wind partial derivatives in the xsec calculations. This is still considered to be in testing mode as there is just perturbations for temperature before I solve the eigenvector derivatives thing. * src/matpackI.{cc,h}: Is now including Eigen, in an order that did not crash on my system. I hope this works for others. To use Eigen for normal matrices and complex matrices, use MapToEigen* functions. Use MapToEigen4x4 for mapping 4x4 matrices if you know this is the size to improve speed. (Would this help as an option in mult?) * src/partial_derivatives.h: added supportsRelaxationMatrix() to check jacobian requests. Relaxation matrix do not yet support line parameter partials. * src/rte.cc: Added check to see if stokes_dim is 4 to use the speedier calculations. I do not think this has improved the speed of the tests. 2017-02-20 Oliver Lemke * arts-2-3-634 * src/m_basic_types.cc (Compare): Also compare ptype for SSD. 2017-02-17 Jana Mendrok * arts-2-3-633 * src/methods.cc, m_disort.cc (DisortCalc), disort.[cc,h] (surf_albedoCalc): Revised interfacing to Disort surface handling, adding an option to derive albedo as total power reflection coefficient according to the given setting of surface_rtprop_agenda. Done to allow consistent surface setup between different solvers. However, results are rather unsatisfactory for any specular surface (the worse the higher the reflectivity). * src/m_disort.cc (DisortCalc,DisortInit), src/m_doit.cc (DoitCalc,DoitInit), src/m_rt4.cc (RT4Calc,RT4Init): Throw an error when called with cloudbox off, instead of semi-silently going on with a clearsky calculation. When one of them is called, it is safe to assume that an scattering calculation is expected to actually be performed (and not skipped). * src/rt4.cc (surf_optpropCalc): Fixed internal doc. * controlfiles/artscomponents/disort/TestDISORT.arts: Adapted to Disort surface handling changes above. 2017-02-15 Jana Mendrok * arts-2-3-632 * src/m_rt4.cc (RT4Calc): Bugfix in specular surface part. Make this work with f_grid.nelem()>1. (RT4Test): Switch rt4_test back on. * src/rt4.cc (rt4_test): Revised to make consistent again with the modified RT4 fortran interface. * controlfiles/artscomponents/polradtran/TestRT4.arts: Switch performing RT4Test back on. 2017-02-15 Jana Mendrok * arts-2-3-631 Revised RT4 interface such that it can use surface_rtprop_agenda, hence allows (with certain limitations) consistent calculations with ARTS' proprietary scattering solvers DOIT and MC. Currently it is "only" an option to do so, alternatively RT4's own surface handling can be used, where also Fresnel is now possible to be used and a (plain) specular version has been added in analogy to Fresnel and ARTS' plain specular implementation. Keeping the interface to RT4's own surface handling is primarily thought for testing purposes. Keeping this comes with the downside that each method uses different input parameters, which all have to be set within ARTS despite not applying them (WSM Touch is suggested to achieve this). * src/m_rt4.cc (RT4Calc): Complete revision of surface handling as described above. * src/rt4.cc (surf_optpropCalc): Added. Surface reflection matrix and emission vector preparation following surface_rtprop_agenda for use in RT4. (rt4_test): Temporarily commented out call of RT4. Interface need to be adapted to new situation. * src/rt4.h: Added surf_optpropCalc. Adapted radtrano_. Added interface to RT4's planck function. * src/m_append.h: Added implementation for Matrix-to-Tensor3 and Tensor3-toTensor3 appending. Corrected error message for Tensor4-to-Tensor4 appending. * src/methods.cc: Updated RT4Calc and Append according to above. Added more info on TestScatDataInterp. Spell fixes here and there. * src/workspace.cc, m_surface.cc, surface.cc, doit.cc, optproperties.cc: Minor polishing. * 3rdparty/polradtran/rt4/radtran4.f: Modified interface and surface prep calls to handle other than RT4's own Lambertian and Fresnel reflection surfaces. * 3rdparty/polradtran/rt4/radutil4.f[.orig]: Added routines to prepare surface reflection and ground radiance tensors for plain specular reflection and for externally prepared reflection data. Keeping a copy of the original code. * controlfiles/artscomponents/polradtran/TestRT4.arts: Adapt to work with revised RT4 surface handling & to apply surface_rtprop_agenda as default. * controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts: Do correct setting of surface_scalar_reflectivity here, not set here one way and overwrite later, that's just confusing. * controlfiles/artscomponents/disort/TestDISORT.arts: Remove re-setting of surface_scalar_reflectivity. * controlfiles/general/agendas_surface.arts: Add a predefinition for specular surface vector case. Update info on Lambertian surface predefinitions. 2017-02-14 Richard Larsson * arts-2-3-630 * 3rdparty/relmat/CMakeLists.txt: With Oliver's help, parallelizatoin of the line mixing calculations over pressure levels is now possible. * src/m_cloudbox.cc: Changed so that arrays of length 1 also works as the gridded fields when adding particulates to abs species. * src/m_linemixing.cc: Minor changes. There will be more here once I have got a clearer idea of how to deal with the jacobian. As before, this is not ready yet. 2017-02-10 Richard Larsson * arts-2-3-629 Decent cross-sections with 3rdparty/relmat is now a thing. We need some more tests after a second implementation is done. * 3rdpart/relmat/arts_interface.F90: Changed name of interface function to indicate the type of line mixing it is performing. * src/{pressurebroadeningdata,linerecord}.{cc,h}: Finally got around to renaming a few functions. The pressurebroadening structure now has got easy tests of the type for use outside the pressure broadening routines. For now, only air broadening works with relmat so we have to ensure that this is what we've got there. I also commented things a bit more in the pressurebroadening class so people can perhaps follow what the functions do easier. * src/m_linemixing.cc: Now seems to be working. We recommend no one tries this out before we have had more time to test that idea. Remaining work to be sure, especially in how to parallelize this efficiently. 2017-02-09 Richard Larsson * arts-2-3-628 * 3rdparty/relmat/: Updated by Teresa and it is now working mostly as expected, comparing well with other implementations if similar code. * src/{absorption,linemixingdata,methods}.cc}: Changed so negative lm_p_lim now gives extrapol factor for line mixing that is interpolated. THIS MIGHT BREAK CONTROLFILES THAT WERE NOT SUPPOSED TO WORK ANYWAYS. Please set lm_p_lim as a negative value to extrapolate results. Feature requested by Freddy. I strongly recommend against using this. * src/{complex.{cc,h,lin_alg.cc}}: With Oliver's help, there is now proper mapping to Eigen matrices. This means that mult, inv, and diagonalize behave as expected for Complex Matrices and vectors. Note: mult(A, A, A) now works but should be used with care since it creates memory inside Eigen. Use only if you know what you are doing. The old behavior should not increase memory usage by using A.noalias() flag. * src/lineshapes.cc: Made a const static. * src/m_linemixing.cc: Almost got the cross-sections working here. We are only 10-orders of magnitude away from the target! Code is still riddle with output and other debuggin information. Do not use. Work still in progress. 2017-02-08 Jana Mendrok * arts-2-3-627 * controlfiles/artscomponents/absorption/TestAbsParticle.arts: Reorganized such that file-writing and re-reading of scat_data not necessary. Removed setting cloudbox (not needed & just confusing). 2017-02-07 Jana Mendrok * arts-2-3-626 * src/optproperties.cc (ConvertAzimuthallyRandomSingleScatteringData): Bug fixes in p30 version1&2 to version3 conversion routine, namely for za_inc>90deg, data needs to be mirrored not only in za_inc but also za_sca along the 90deg "plane" (tested versus old data) and certain stokes 3 and 4 elements need to be negatized (not yet tested). (abs_vecTransform, ext_matTransform, pha_matTransform): Adapted to use new p30 scat_data format. * src/montecarlo.cc (opt_propExtract, pha_mat_singleExtract): Adapted to use new p30 scat_data format. (findZ11max): For p30 consider all azimuth angles. * src/rt4.cc (sca_optpropCalc): Adapted to use new p30 scat_data format. * src/m_optproperties.cc (TestScatDataInterp): Adapted to use new p30 scat_data format. * src/cloudbox.cc (chk_scat_data): Consider ptype general in azimuth grid check. 2017-02-06 Lukas Kluft * arts-2-3-625 * tools/vim_syntax/update-vim-arts-syntax: Fixed the highlighting of different kind of numbers (brackets and commas "touching" a number are no longer highlighted). 2017-02-06 Richard Larsson * arts-2-3-624 * src/complex{cc,h}: Added standard Eigen matrix maps with Oliver's guidance. To use, call the MapToEigen functions. Be sure of your dimensions when using the vectors. Old version of this did not respect views and therefore produced crazy output. * src/lin_alg.{cc,h}: Updated complex versions of inv and diagonalize to fit with the new inputs. * src/m_linemixing.cc: Trying to fix normalization in the calculations of line mixing via relaxation matrices. Still in progress. Also changed so output from the fortran code can be had to gout variables. Work in progress. * src/methods.cc: Added wmats, d0s and rhos as outputs from the line mixing code. * src/test_complex.cc: Added test for matrix multiplications. 2017-02-05 Jana Mendrok * arts-2-3-623 * src/optproperties.cc (ConvertAzimuthallyRandomSingleScatteringData): Implemented version1&2 to version3 p30 scat_data conversion. * src/tmatrix.cc (calcSingleScatteringDataProperties): Adapted to p30 scat_data format changes: Run scat_data-from-tmatrix setting over full za_inc range. * src/cloudbox.cc (chk_scat_data): Adapt chk_size call to new p30 (az.random) scat_data format definition. Couple of language fixes in docs and error messages throughout the file. * src/xml_io_compound_types.cc (xml_write_to_stream for ssd): Remove p30 write error. * src/montecarlo.cc (opt_propExtract,pha_mat_singleExtract), src/optproperties.cc (abs_vecTransfor,ext_matTransform): Doc info fixes. * controlfiles/CMakeLists.txt: Switch on again previously outcommented checks. * doc/uguide/clouds.tex: Adapted to recent changes in scat_data and ptype. 2017-02-03 Lukas Kluft * arts-2-3-622 * src/m_atmosphere.cc (AtmFieldsFromCompact): Added gridname check. If `check_gridnames` is set to `1` the names of the last three grids are checked (expected values are 'Pressure', 'Latitude' and 'Longitude'). The default is `0`. No check is performed. * src/m_abs_lookup.cc (abs_lookupSetupBatch): Toggle `check_gridnames` to check the gridnames for every `atm_fields_compact` stored in the given `batch_atm_fields_compact`. The default is `0`. No checks are performed. * src/methods.cc: Added description for `check_gridnames`. 2017-02-03 Oliver Lemke * arts-2-3-621 * controlfiles/general/continua.arts: Add continua that are implemented in ARTS but were not listed in the standard include file: H2O-MPM89, H2O-MPM87, H2O-SelfContCKD242, H2O-ForeignContCKD242, H2O-SelfContCKD222, H2O-ForeignContCKD222, H2O-ForeignContATM01, O2-SelfContMPM93, O2-PWR88, O2-MPM92, O2-MPM87, O2-MPM85, N2-SelfContPWR93, N2-DryContATM01, CO2-CKD241. Missing MPM89 reported by Stuart Fox. 2017-02-02 Jana Mendrok * arts-2-3-620 * controlfiles/CMakeLists.txt: Temporarily outcomment temporarily broken test cases (see arts-2-3-618). 2017-02-02 Jana Mendrok * arts-2-3-619 * src/m_rt4.cc, methods.cc (RT4Calc): Removed angular grid indentity check. This was just a copy-paste leftover from DisortCalc. Build-in doc updated accordingly, add info that temp. interpolate of pfct is actually not implemented here (yet?). * src/optproperties.cc, src/workspace.cc: Language fixes in documentation. 2017-02-02 Oliver Lemke * arts-2-3-618 * WORK IN PROGRESS!!! TestMonteCarloDataPrepare, TestRteCalcMC and TestTMatrix are currently failing. * src/cloudbox.cc, src/m_cloudbox.cc, src/m_disort.cc, src/m_optproperties.cc, src/m_rt4.cc, src/m_tmatrix.cc, src/methods.cc, src/montecarlo.cc, src/optproperties.{cc,h}, src/rt4.cc, src/rte.cc, src/tmatrix.{cc,h}, src/xml_io_compound_types.cc: Replacements for new ptype naming: PTYPE_MACROS_ISO -> PTYPE_TOTAL_RND PTYPE_HORIZ_AL -> PTYPE_AZIMUTH_RND 2017-02-02 Oliver Lemke * arts-2-3-617 * WORK IN PROGRESS!!! * Jana and me are currently working on introducing SingleScatteringData version 3. Therefore, temporarily horizontally_aligned data can't be written from ARTS. That means that TestMonteCarloDataPrepare, TestRteCalcMC and TestTMatrix are currently failing. * optproperties.{cc,h}: Copied PTypeFromString to PType2FromString. Adapted PTypeFromString and PTypeToString to SingleScatteringData format 3: "horizontally_aligned" -> "azimuthally_random", "macroscopically_isotropic" -> "totally_random". (ConvertAzimuthallyRandomSingleScatteringData): Added skeleton for conversion of older SingleScatteringData to version 3. * src/xml_io_compound_types.cc: Added reading/writing support for SingleScatteringData version 3. Temporarily throw a runtime error if azimuthally_random data is tried to be written. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Replaced "horizontally_aligned" by "azimuthally_random". 2017-02-01 Alex Bobryshev * arts-2-3-616 * controlfiles/instruments/metmm/TestMetMM.arts: in the comments added the link to the documentation of met_mm_accuracy. 2017-02-01 Patrick Eriksson * arts-2-3-615 * Summary: surface_skin_t is now an output of surface_rtprop_agenda. * controlfiles/general/agendas_surface.arts: Removed all agendas demanding that surface_skin_t is pre-set. That does not work now. Either set value inside the agenda, or copy from another variable. * controlfiles/artscomponents/polradtran/TestRT4.arts: Copied code from TestDISORT.arts to set surface_skin_t. * controlfiles/artscomponents/disort/TestDISORT.arts: Now making use of t_surface in setting of surface_skin_t. * controlfiles/artscomponents/stokesrot/TestSensorPol.arts: Adopted definition of surface_rtprop_agenda. * src/m_surface.cc (surface_rtpropCallSubAgendaX,surfaceSemiSpecularBy3beams): Adopted call of surface_rtprop_agenda by adding surface_skin_t as WSM output. * src/m_surface.cc (iySurfaceRtpropAgenda): * src/m_montecarlo.cc (MCGeneral): * src/doit.cc (cloud_RT_surface): Adopted call of surface_rtprop_agenda by introducing a local variable. * src/m_rt4.cc (RT4Calc): Added surface_skin_t as input. This replaces to take surface temperature from t_field. * src/agendas.cc: Added surface_skin_t as output of surface_rtprop_agenda and its sub-agendas. 2017-02-01 Jana Mendrok * arts-2-3-614 * doc/uguide/surface.tex, rte_theory.tex: Some fixes in surface reflection documentation. * src/doit.cc (cloud_RT_surface): Bugfix in doit_i_field_mono update. * src/m_rt4.cc (RT4Calc): Put FORTRAN routine call (radtrano_) in critical environment (Patrick reports SEGFAULT crash otherwise when arts is run in multi-thread mode. Not sure anymore, though, why the critical environment was there already, but commented out...). * 3rdparty/polradtran/rt4/radtran4.f: Allow larger atm system: increased max number of atm layers to 300. 2017-02-02 Richard Larsson * arts-2-3-613 * src/m_linemixing.cc: Updated pressure from Pascal to atm to fit with relmat input. Bug fix. 2017-02-01 Lukas Kluft * arts-2-3-612 * src/m_gridded_fields.h: Workspace methods related to GriddedFields. Added the WSMs `GriddedFieldGetName` and `ArrayOfGriddedFieldGetNames` to get the names of GriddedFields during an ARTS run. * src/make_auto_md_cc.cc: Added `m_gridded_fields.h` to include list. * src/methods.cc: Added documentation for new workspace methods. 2017-01-31 Richard Larsson * arts-2-3-611 * src/complex.cc: Changed the multiplications to be done by Eigen. Used to be broken code since unknown updates ago. * src/lin_alg.cc: Added dependency on Eigen/Eigenvalues and Eigen/Dense. Updated the complex versions of inv(Ainv, A) and diagonalize(P, W, A). The non-complex has to be friendly with a lot of classes to work as wanted. * src/m_linemixing.cc: Looking at (calculate_xsec_from_W) to make it work with the relaxation matrix now that the linear algebra works. Work in progress... * 3rdpart/relmat/*: Added LAPACK/BLAS to Teresa's compiling options. Should help with future updates. The rest contains some of Teresa's other updates. Work in progress... 2017-01-31 Oliver Lemke * arts-2-3-610 * 3rdparty/Eigen/: Added the remaining files of the Eigen template library (version 3.2.7). Requested by Richard to calculate Eigenvalues. Since we already use parts of the Eigen library (in matpackII.h), it makes most sense to include the whole library for convenience. It is also much easier to use than the low-level LaPack functions. Also added the COPYING.* files from the original source. 2017-01-30 Oliver Lemke * arts-2-3-609 * cmake/scripts/update_doxyfile.cmake, doc/doxygen/Doxyfile.in: Check if dot tool is installed. Set HAVE_DOT accordingly. Fixes flood of messages 'sh: 1: dot: not found' on Linux if dot tool is not installed. Bug reported by Richard. 2017-01-27 Stefan Buehler * arts-2-3-608 * controlfiles/instruments/hirs/TestHIRS.arts: Added path to INCLUDED hirs_fast.arts (from top level include directory), so that the file can be copied to another working directory and run from there. 2017-01-27 Richard Larsson * arts-2-3-607 * 3rdparty/relmat/*: Update of files by Teresa. Removes reading routines and fix input. * ChangeLog: It is 2017 now... fixed that miss. 2017-01-27 Richard Larsson * arts-2-3-606 * 3rdparty/relmat/arts_interface.F90: Added mass parameter to let the code compile. * src/m_linemixing.cc: Updated (abs_xsec_per_speciesAddLineMixedBands) to send more information to the Fortran interface. * src/constants.cc: Added flag for electrons and particulates for the special species jacobian calculations. * src/jacobian.{cc,h}: Added flag for special species in (get_pointers_for_analytical_jacobians). Also changed some wording/enums to make the code easier to follow. * src/m_{rte,transmitter}.cc: Changed so that the new wording is in effect. * src/m_jacobian.cc: Added (jacobianAddConstantVMRAbsSpecies) and (jacobianAddSpecialSpecies) for different additions to jacobian. I was hoping to add independently scaling integrated VMR values but not enough time to solve what this means for the integration. Constant numbers are just a copy of catalog parameter behavior and so they are easy. I might return to this later for the scaling effects I wanted to look at. * src/m_abs.cc: Have (propmat_clearskyAddParticles) return the partial derivaitves needed for the calculations. Updated the rest of the code for new namings. Note that you are not allowed to choose what unit the special absorbers return their derivatives in because neither (propmat_clearskyAddFaraday) nor (propmat_clearskyAddParticles) uses rtp_vmr to contain VMR values. In *Faraday these values are the number densities by default and in *Particles the default is whatever unit was used in the input. * src/rte.{cc,h}: Updated naming. 2017-01-27 Oliver Lemke * arts-2-3-605 * src/m_oem.cc (OEM): Fix dummy function arguments for non-OEM builds. 2017-01-27 Simon Pfreundschuh * arts-2-3-604 * 3rdparty/invlib/*: Updated invlib version to current development status. * src/agenda_wrapper.h: (AgendaWrapper): Avoid recomputation of Jacobian on forward model evaluation. Implemented caching of Jacobian and yf vector provided on creation. * src/methods.cc (OEM): Added oem errors output argument, that is used to store errors encountered during OEM execution. * src/m_oem.cc (oem_template) Added error handling oem computation. Fixed returning of diagnostic values. Fixed storing of gamma factor for the Levenberg-Marquardt method. * src/oem.h (ArtsLog) Added invlib logging class to adapt logging output to Arts requirements. (handle_nested_exception) Generic error handling function, that converts nested exception to a vector of strings. * src/workspace.cc (oem_errors) Added oem_errors WSV. 2017-01-26 Oliver Lemke * arts-2-3-603 * src/agenda_class.cc: (Agenda::set_outputs_to_push_and_dup): Don't take specific inputs and outputs from md_data into account any longer to determine which WSVs are used inside an agenda. Since named parameters have been introduced to the controlfiles, all parameters are treated internally as generic inputs/outputs. A distinction between specific and generic is therefore not needed anymore and leads to unintended behaviour such as: NumericSet(lon, 0) NumericSet(lat, 0) NumericCreate(myg0) AgendaSet( g0_agenda ){ Ignore(lon) Ignore(lat) g0Earth(g0=myg0) } Before this fix, the above code would have run. Because g0Earth lists g0 as a specific output, the agenda engine wrongly assumed that not only myg0, but also g0 is actually produced. However, g0 is of course still uninitialized. Now, the proper error that the agenda must generate g0 as an output is displayed. Bug reported by Patrick. Removed obsolete runtime error that an agenda input-only variable was used as output by a WSM. First, this is supported since some time now. Second, the error was only triggered if the WSV was used as an output before being used as an input variable. Bug reported by Patrick. WSVs that are input and output to a WSM were not correctly added to the agenda's internal inputs list. For AgendaExecute*, the inputs of the executed agenda were not correctly added to the internal inputs list of the calling agenda. (Agenda::is_input): Don't check specific inputs listed in md_data any longer for same reason as explained above. Also check for matches in WSVs that are input+output. Limit additional search for matches in generic inputs of type Agenda to methods AgendaExecute and AgendaExecuteExclusive. (Agenda::is_output): Don't check specific outputs listed in md_data any longer for same reason as explained above. If current method is AgendaExecute* check the output arguments of its agenda for matches. (Agenda::set_outputs_to_push_and_dup): Remove obsolete check that was triggered in some cases if a WSV that is defined as agenda input was used as an output variable by one of the WSMs in the agenda. This is works fine now. * src/m_agenda.cc (AgendaExecute), src/make_auto_md_cc.cc (main): Changed 'agenda checked' assertion to a runtime error. Otherwise the assertion can be triggered by user input using the WSM Touch and then executing the agenda. * src/workspace_ng.h (Workspace::depth): Add method that returns the scoping depth for a WSV. * src/m_general.cc (PrintWorkspace): Add scoping level to output for WSVs. * controlfiles/artscomponents/agendas/TestAgendaExecute.arts: Modified g0_agenda to expose the bug that was fixed in this commit. 2017-01-24 Oliver Lemke * arts-2-3-602 * src/parser.cc (ArtsParser::skip_to_next_argument): Comment sign inside WSM call with named arguments was ignored if the comma was written on the next line. In the example below 'value' was parsed even though it's commented out: MatrixSet(out=m #, value=[1,2,3] ) Bug reported by Richard. 2017-01-23 Oliver Lemke * arts-2-3-601 * src/montecarlo.cc (pha_mat_singleCalc): Found similar bug to previous commit. pnd_vec wasn't using the flattened index. 2017-01-22 Patrick Eriksson * arts-2-3-600 * Fixed serious bug, present if using several scattering elements together with (at least) MC or iyTransmission. * src/montecarlo.cc (opt_propCalc): pnd_vec was indexed with scattering element index only (i_se). That is, the indexing returned to zero when moving to next scattering element. 2017-01-20 Patrick Eriksson * arts-2-3-599 * controlfiles/general/agendas_surface.arts: Added specular_losCalc to all agndes using the Lambertian method, as this is now required. * It is now allowed to have several reflections for one pencil beam calculation. That was unintentionally restricted. For example, you can now have a ppath that is reflected from one side of a valley to the other side. However, there is no limit on the number of reflections and you can possibly end up in an infinite loop. That biggest risk here is the Lambertian function. If this happens, try to use a smaller number of beams. * src/m_surface.cc (surfaceLambertianSimple): Now takes surface_normal as input for safer handling of 2D and 3D. Added some notes about in the built-in doc. * src/m_rte.cc (iyEmissionStandard): Added ppath.np==1 in first if statement. 2017-01-20 Oliver Lemke * arts-2-3-598 * src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields): Throw runtime error if a species in scat_meta is empty. Otherwise an assertion failure is generated later on in the pnd_field* functions (e.g. pnd_fieldS2M). Besides that it doesn't make sense to have an empty species. Reported by Freddy. 2017-01-20 Oliver Lemke * arts-2-3-597 * src/m_checked.cc (cloudbox_checkedCalc): Fix check if scat_data_check_type is 'none' which always evaluated to true. 2017-01-19 Patrick Eriksson * arts-2-3-596 * src/m_cloudbox.cc (pnd_fieldZero): Now considers atmosphere_dim and checks that cloudbox_limits have the correct length. And now also handles 2D. * src/m_rte.cc (iyIndependentBeamApproximation): Now picks up and passes on iy_id. 2017-01-19 Patrick Eriksson * arts-2-3-595 * src/m_disort.cc (DisortCalc): Missed to adopt the dummy declaration of the function. 2017-01-19 Patrick Eriksson * arts-2-3-594 * controlfiles/artscomponents/disort/TestDISORT.arts: surface_skin_t now set, by extract from t_field. * src/m_disort.cc (DisortCalc): Now takes surface_skin_t as input. Replaces using t_field(0,0,0). * src/m_surface.cc (surfaceLambertianSimple): Removed the limitation to 1D. But 2D and 3D are only handled in a simplistic manner. (surface_scalar_reflectivityFromSurface_rmatrix): New WSM. * controlfiles/general/agendas_surface_sub.arts: Removed unnecessary Ignore calls * src/workspace.cc: Small changes in doc of rtp_pos/los. 2017-01-18 Lukas Kluft * arts-2-3-593 * Note: atmosphere_dim must be set before calling abs_lookupSetupBatch! * src/m_abs_lookup.cc (abs_lookupSetupBatch): Perform a full atmfields_checkedCalc() on the given batch_atm_fields_compact. This closes a loophole when only calculating a lookup table. * src/methods.cc (abs_lookupSetupBatch): Updated the documentation to include the performed atmfield check. The more sophisticated checks require atmosphere_dim as an additional input parameter for the method. * controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts, controlfiles/instruments/amsu/TestAMSU_generic.arts, controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/mhs/TestMHS_generic.arts, controlfiles/instruments/mviri/TestMVIRI.arts, controlfiles/instruments/seviri/TestSEVIRI.arts: Removed comments showing outdated abs_lookupSetupBatch syntax. 2017-01-17 Patrick Eriksson * arts-2-3-592 * src/m_oem.cc (inversion_iterate_agendaCall): Removed. This was a fix to the bug just removed. * src/m_surface.cc (FastemStandAlone): Frequency fix implemented here. * src/methods.cc: In all FASTEM methods, set 0.035 as default for salinity. Also for all versions, when calling the core fastem method, any frequency above 350 GHz is replaced with 350 GHz. This as Fastem gives unrealistic values from about 400 GHz. But as before, there is an error from Fastem if going above one 1 THz. 2017-01-17 Oliver Lemke * arts-2-3-591 * src/m_agenda.cc (AgendaExecute): Copy inputs and outputs into new sets to sort them because set_difference does not work with unsorted arrays. Fixes bug in AgendaExecute reported by Patrick. Variables that are defined as input and output of an agenda were wrongly reset to their original value after AgendaExecute. * controlfiles/artscomponents/agendas/TestAgendaExecute.arts: Add check for proper InOut scoping in AgendaExecute. 2017-01-16 Lukas Kluft * arts-2-3-590 * src/m_general.cc, src/methods.cc: Renamed workspace method StringCompose to StringJoin. 2017-01-12 Oliver Lemke * arts-2-3-589 * Added patch provided by Simon Pfreundschuh . * 3rdparty/invlib/src/invlib/algebra.h, 3rdparty/invlib/src/invlib/algebra/matrix.h, 3rdparty/invlib/src/invlib/algebra/matrix_difference.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/matrix_identity.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/matrix_product.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/matrix_sum.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/matrix_transpose.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/precision_matrix.h, 3rdparty/invlib/src/invlib/algebra/preconditioners.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/solvers.{h,cpp}, 3rdparty/invlib/src/invlib/algebra/vector.cpp, 3rdparty/invlib/src/invlib/archetypes/matrix_archetype.{h,cpp}, 3rdparty/invlib/src/invlib/archetypes/vector_archetype.{h,cpp}, 3rdparty/invlib/src/invlib/interfaces/arts_wrapper.{h,cpp}, 3rdparty/invlib/src/invlib/interfaces/eigen.h, 3rdparty/invlib/src/invlib/log.h, 3rdparty/invlib/src/invlib/map.cpp, 3rdparty/invlib/src/invlib/map.h, 3rdparty/invlib/src/invlib/mpi/log.h, 3rdparty/invlib/src/invlib/mpi/mpi_matrix.{h,cpp}, 3rdparty/invlib/src/invlib/mpi/mpi_vector.{h,cpp}, 3rdparty/invlib/src/invlib/mpi/traits.h, 3rdparty/invlib/src/invlib/mpi/utility.h, 3rdparty/invlib/src/invlib/optimization/levenberg_marquardt.h, 3rdparty/invlib/src/invlib/traits.h, CMakeLists.txt, config.h.cmake, src/CMakeLists.txt, src/agenda_wrapper.h, src/agenda_wrapper_mpi.h, src/m_oem.cc, src/m_xml.cc, src/main.cc, src/matpackII.cc, src/matpackII.h, src/methods.cc, src/oem.h, src/oem_mpi.h: Patch with updated version of invlib and OEM with MPI support. * Changes applied after the patch by the committer: * CMakeLists.txt: Fix detection of MPI. * src/CMakeLists.txt: Only add MPI include path and libraries if enabled. * 3rdparty/invlib/src/invlib/mpi/mpi_matrix.cpp, 3rdparty/invlib/src/invlib/mpi/mpi_matrix.h: Change loop variable type from unsigned int to int. Fix type conversion warning from signed to unsigned int. * src/main.cc (main): Display info on OEM MPI support. * src/m_oem.cc (OEM_MPI): Adapt for changes that have been made to OEM since the patch was created: Change xa from output to input because it is now calculated beforehand by x2artsStandard. 2017-01-10 Oliver Lemke * arts-2-3-588 * Added patch provided by Ian Adams * MCRadar: An active radiative transfer model for radar that accounts for multiple scattering has been added. While in many ways based on MCGeneral, MCRadar uses forward Monte Carlo ray tracing to avoid difficulties with defining the transmitted polarization state inherent to reverse Monte Carlo methods. Numerical root finding is implemented to solve for path lengths involving horizontally-aligned hydrometeors. To accompany MCRadar, two workspace variables were created: mc_y_tx, which defines the transmit polarization, and mc_max_scatorder, which limits the scattering order to a prescribed degree (1 == single scattering). There are some differences with how MCRadar functions with respect to MCGeneral and yCloudRadar. MCRadar requires a finite (Gaussian) beam in order to receive energy from multple scattering events. Currently, MCRadar only limits integration by the number of photons, not by runtime or Monte Carlo error. Unlike yCloudRadar, MCRadar expects that range_bins will either contain round-trip times or distances from sensor, as altitude is meaningless for horizontal radar lines of sight. * Antenna Frame and Polarization Basis: The original implementation of the antenna pattern sampling used by MCGeneral did not rotate from the antenna frame into the frame used by ARTS. Instead, antenna zenith and azimuth angles were simply added to the boresight line of sight. Additionally, the antenna polarization basis was not defined, and sampling the antenna pattern resulted in polarization rotations that increased with increasing azimuthal distance from the boresight. The errors in both issues were greatest at nadir and zenith, with no impact for zenith angles of 90 degrees. To address these issues, a reference frame and polarization basis for the antenna boresight was created such that vertical polarization aligns with the plane created by the boresight los vector and the local zenith, i.e., defined by the azimuth angle, and the horizontal polarization is perpendicular to this plane. A rotation matrix is created using the boresight zenith and azimuth angles to rotate from the antenna frame to the local east-north-up (enu) frame, and the columns of the rotation matrix define the axes of the antenna reference frame in enu coordinates. Two randomly sampled angles are then taken in the v-k plane and the h-k plane, and converted to cartesian coordinates to define the sampled los direction in the antenna frame. The sampled los direction is rotated to the enu frame, and the corresponding v and h unit vectors are calculated. Antenna basis rotations are calculated using dot products of the boresight and sampled polarization unit vectors. The polarization bases follow Mishchenko's conventions, referenced to incoming radiation for MCGeneral and outgoing for MCRadar. Due to the polarization rotation, running MCGeneral or MCRadar with stokes_dim < 3 will result in loss of accuracy. * Bug Fixes: * src/m_montecarlo.cc, line 273 (before my changes): local_rte_pos was declared with a size of 2, but should have a size of 3. * src/m_ppath.cc, line 439: The azimuth angle is perturbed, but there was no check on whether the azimuth angle remains in bounds. Upper and lower limits are now checked. * Misc: When run in debug mode, MCRadar occasionally (~0.001%) trips the assertion check on line 540 of m_ppath.cc (in ppathFromRtePos2). The interpolation distance for the index of refraction terms is sometimes calculated to be < 6 microns larger than the ppath segment over which the interpolation is performed. This occurs in both nadir and off-nadir cases. * Changes applied after Ian's patch by committer: * src/mc_antenna.{h,cc}: Moved import of constants from header to cc-file. 2017-01-10 Oliver Lemke * arts-2-3-587 * src/config_global.h: Removed, not needed anymore. * src/arts.h, src/libmicrohttpd/platform.h, src/matpack.h, src/nc_io_compound_types.cc, src/rt4.cc: Include config.h directly instead of global_config.h. 2017-01-10 Oliver Lemke * arts-2-3-586 * src/m_rt4.cc: Fix build if RT4 is disabled by adding the new argument also to dummy RT4Calc function. 2017-01-10 Jana Mendrok * arts-2-3-585 * src/rt4.cc,h (sca_optpropCalc): Modified test for scattering matrix normalization (consistently with scat_dataCheck use albedo deviation). Throw more helpful error message. * src/m_rt4.cc, methods.cc (RT4Calc): Made above mentioned albedo deviation treshold user definable parameter. 2017-01-05 Patrick Eriksson * arts-2-3-584 * src/m_rte.cc (iyIndependentBeamApproximation): Added some more control variables for filling of *atm_fields_compact*. 2017-01-05 Patrick Eriksson * arts-2-3-583 * src/m_montecarlo.cc (MCGeneral): Added chack that sensor_pos/los in fact just have one row (before additional rows were silently ignored). * src/m_rte.cc (iyIndependentBeamApproximation): 1D now handled exactly as 2D and 3D. Added another GIN option. * src/workspace.cc: Polishing of description of iy_id. * src/rte.cc (apply_iy_unit, apply_iy_unit2): Inside these functions the name y_unit was still used. 2017-01-04 Patrick Eriksson * arts-2-3-582 * src/rte.cc (get_iy_of_background): Had commited with a cout. 2017-01-04 Patrick Eriksson * arts-2-3-581 * A basic implementation of iy_id now in place. * controlfiles/general/general.arts: iy_id set to 0. * src/m_radiation_field.cc (radiation_fieldCalcFromiyCalc): * src/m_fos.cc (iyFOS, fos): * src/m_surface.cc (iySurfaceCallSubAgendaX, iySurfaceFastem) (iySurfaceRtpropAgenda, iySurfaceRtpropCalc): * src/rte.cc (get_iy_of_background): * src/m_rte.cc (iyEmissionStandard,iyCalc): * src/m_cloudradar.cc (yCloudRadar): Changes related to iy_id. * src/agendas.cc (define_agenda_data): Added iy_id as input to iy_surface_agenda and all iy_surface_sub_agenda-s. * src/workspace.cc: Removed mblock_aa_grid. Should have been done earlier. 2017-01-03 Patrick Eriksson * arts-2-3-580 * make check-all works again. Not just fixed the problems, also tried to make the contraolfiles a bit more resistant against changes in the rt agendas. * controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts: * controlfiles/planetary_toolbox/demos/passive/DemoScat_MC_1D.arts: * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/transmission/TestTransmission.arts: Replaced some local definitions of iy_main_agenda, iy_sub_agenda and iy_transmission_agenda with prefefined ones from agenda.arts. * controlfiles/general/agendas.arts: Introduced iy_main_agenda__Freqloop, iy_sub_agenda__Emission, iy_sub_agenda__Transmission, iy_sub_agenda__Radiolink, iy_main_agenda__FOSN0 and iy_transmitter_agenda__UnitPolIntensity. 2017-01-03 Patrick Eriksson * arts-2-3-579 * Started on a feature to support storing data inside iy_main_agenda to files with names that can be coupled to corresponding iy calculation. Not finished, got stuck with other things. * controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts: * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/general/agendas.arts: Adopted definitions of modified agendas. Revision not ready! * src/m_surface.cc (iySurfaceRtpropCalc, iySurfaceFastem) (iySurfaceRtpropAgenda): * src/rte.cc (iyb_calc_body, get_iy): * src/m_rte.cc (iyCalc, iyLoopFrequencies): * src/m_cloudradar.cc (yCloudRadar): Adopted calls of modified agendas. * src/agendas.cc: Added iy_id as input to iy_main_agenda and iy_sub_agenda. * src/workspace.cc: Introduced iy_id. * src/m_rte.cc (iyIndependentBeamApproximation): Method slightly renamed. Now at least works for some cases. 2017-01-03 Patrick Eriksson * arts-2-3-578 * src/m_rte.cc (iyIndependentColumnApproximation): Still in progress ... * src/m_optproperties.cc (pha_mat_sptFromData) (pha_mat_sptFromMonoData): Removed out3 printing just reflecting name of WSM. (scat_dataCheck): Commented out printing to out3 that drowned everything else. 2017-01-02 Patrick Eriksson * arts-2-3-577 * controlfiles/artscomponents/transmission/TestTransmission.arts: Adopted setting of iy_sub_agenda. * src/m_rte.cc (iyIndependentColumnApproximation): Just started. (iyLoopFrequencies): Adopted to new required input of iy_sub_agenda. * src/agendas.cc: Fixed typo in description. Added several input WSVs to iy_sub_agenda. * src/special_interp.cc (interp_cloudfield_gp2itw): Some spell fixes in header. 2016-12-18 Patrick Eriksson * arts-2-3-576 * src/m_oem.cc (oem_template): Removed demand nq > 0. * src/m_basic_types.cc (MatrixVectorMultiply): New WSM. 2016-12-17 Patrick Eriksson * arts-2-3-575 * ChangeLog: Correction of last commit. (basline_basis_funcs not introduced) * src/m_oem.cc (OEM): Corrected definition used without CXX11. 2016-12-17 Patrick Eriksson * arts-2-3-574 * Some restructuring of OEM. Not ready, mainly a "backup" commit. This commit brakes old cfiles including OEM. Either don't update or email me for info. Otherwise more later ... * src/m_oem.cc (x2artsStandard): x2arts_std renamed. (xaStandard): Internal function setup_xa now renamed and converted to WSM. (OEM): xa and initial x, jacobian and yf are now input, instead of being calculated internally. That is, these variables shall be prepared before calling OEM. 2016-12-17 Richard Larsson * arts-2-3-573 * src/partial_derivatives.cc: Fixed handling of some of the line parameters. Beginning work to abstract this more easily. * src/absorption.cc: Fix copy-paste mistake * src/lineshapes.cc: Fix copy-paste mistake * src/pressurebroadeningdata.{h,cc}: Fix compilation warning for needless input. * controlfiles/artscomponents/wfuns: Added test for jacobian for line paramters. This also serves to show how it is activated. 2016-12-15 Jakob Doerr * arts-2-3-572 * controlfiles/artscomponents/doit/TestDOITpressureoptimization.arts, controlfiles/artscomponents/doit/doit_setup_pressureoptimization.arts, controlfiles/artscomponents/doit/yREFERENCE_DOITpressureoptimization.xml: Added files to test the pressure optimization in DOIT * ChangeLog: Added CMakeLists.txt to my previous commit 2016-12-13 Jana Mendrok * arts-2-3-571 * src/optproperties.cc (pha_mat_labCalc): Bugfixed non-transformation check on azimuths (reported to yield odd consequences by PE in arts-2-3-569). Properly use ANGTOL_RAD (on angle in radians). 2016-12-13 Jana Mendrok * arts-2-3-570 * src/m_optproperties.cc (scat_dataCheck): Replaced check_type alternative 'none' by 'sane' (since it does not mean nothing is checked, but "only" sanity of K11,a1,Z11 is checked). * src/methods.cc (scat_dataCheck, cloudbox_checkedCalc, jacobianDoit): Adapted built-in doc according to above changes. Adapted jacobianDoit default setting of *check_type*. * src/m_cloudbox.cc (ScatElementsToabs_speciesAdd): Update *check_type* setting in internal call of scat_dataCheck. 2016-12-08 Patrick Eriksson * arts-2-3-569 * src/optproperties.cc (pha_mat_labCalc): Changed check to catch cases where no transformations are needed. Now just considers theta. Discovered that MC calculations converged very very poorly. After testing different arts versions, found that the change of this if-statement was the point where MC started to behave poorly. Right now I don't know if the if-statement was wrong, or if the change made some bug in MC visible. Needs to be investigated, but made this change to resurrect MC to its old behaviour. 2016-12-06 Oliver Lemke * arts-2-3-568 * src/m_optproperties.cc (scat_dataCheck): Cleaner check for check_type argument. Must now be 'ALL' or 'NONE'. * src/mystring.h: New functions toupper and tolower for my_basic_string. * src/m_xml.{h,cc} (WriteXMLIndexed, ReadXMLIndexed), src/xml_io.cc (filename_xml_with_index): New argument digits that gives the desired width of the index. String of numbers with less digits will be padded with zeros. * src/m_jacobian.cc (jacobianDoit): Adapt calls to WriteXMLIndexed. * src/methods.cc: Add 'digits' argument to WriteXMLIndexed and ReadXMLIndexed. Update docs for scat_dataCheck. * src/m_linemixing.cc (abs_xsec_per_speciesAddLineMixedBands): Comment out parameter names in dummy function to avoid compiler warnings. 2016-11-25 Richard Larsson * arts-2-3-567 Update support for LBL catalog parameter derivations. Now with integrations over all levels * src/absorption.cc: Interface for pressure broadening partial derivation updated * src/constants.cc: Updated naming scheme for derivatives seen by the user via methods * src/jacobian.{cc,h}: Added support for full integration via a flag in RetrievalQuantity. (diy_from_path_to_rgrids) returns only a vector if this flag is found. * src/m_jacobian.cc: (jacobianAddCatalogParameter{,s}) now no longer accepts grids as arguements and instead activates the integration flag. Catalog parameters are constant at all points * src/m_rte.cc: (iyEmissionStandard) Updated to integrate when RetrievalQuantity says so * src/m_transmitter.cc: (iyTransmissionStandard) Mimics behavior of iyEmissionStandard when asked to integrate (as far as possible) * src/methods.cc: Updated comments for jacobianAddCatalogParameter{,s}. * src/partial_derivatives.{cc,h}: Updated to calculate pressure shift partial derivatives when available and also to return the exponent derivative for pressure shift. There still remains an error in the central frequency calculations that I have not managed to fix. This affects both "Line Center" and all the "* Pressure Shift" partial derivatives and forms an error that increases the further from the line center you are in a symmetric manner, almost in an identical way for both these cases. I am still looking at this... * src/pressurebroadeningdata.{cc,h}: Added methods to calculate the internal derivatives for pressure shift. Also removed the calculations for Planetary broadening as these were not working due to the rescaling. Will have to think how do do that properly at a later date 2016-11-24 Jakob Doerr * arts-2-3-566 * ChangeLog: Added version number to previous commit * src/m_doit.cc (OptimizeDoitPressureGrid): New method added to DOIT that optimizes the pressure grid for every frequency seperately, based on the single scattering albedo and the scattering optical thickness and interpolates the fields to the new grid. The two corresponding thresholds, sgl_alb_max and tau_scat_max, can be set, but defaults are set. The maximum cloudbox size can be set by cloudbox_size_max. This method should be called inside doit_mono_agenda, right before doit_i_field_monoIterate. It can only be used if ScatSpeciesMerge has been called and if it is called, another method, doit_i_field_monoOptimizeReverse has to be called right after doit_i_field_monoIterate to interpolate doit_i_field mono back to the original size. * src/m_doit.cc (doit_i_field_monoOptimizeReverse): New method that interpolates the doit_i_field from the optimized calculation back to the original size. Should be called if OptimizeDoitPressureGrid has been called. Call should be inside doit_mono_agenda, right after doit_i_field_monoIterate. * src/methods.cc: Defined OptimizeDoitPressureGrid and doit_i_field_monoOptimizeReverse * src/workspace.cc (p_grid_opt): Defined p_grid_orig. It is used in doit_i_field_monoOptimizeReverse and it stores the original pressure grid. * controlfiles/CMakeLists.txt: Added pressure optimization test. Added pressure optimization test to the list (xml-data) 2016-11-15 Jana Mendrok * arts-2-3-565 * controlfiles/artscomponents/polradtran/TestRT4.arts: RT4 test case added. * controlfiles/CMakeLists.txt: Replace implementation test case TestRT4Test.arts by interface test case TestRT4.arts. * src/methods.cc (RT4Calc, RT4Init, DisortCalc): Added RT4 built-in doc. Default setup updated (Double Gauss with 16 streams). Some polishing of DisortCalc doc. * src/rt4.cc (par_optpropCalc,sca_optpropCalc): Method summary corrected. * src/m_optproperties.cc (pha_matCalc): Removed error-prone duplicate code for 1D and 3D (set up atm indices depending on atm_dim instead, then run the same calc loop regardless of atm_dim). * 3rdparty/tmatrix/ampld.arts.f: Check input validity separately for each parameter and provide specific error message. 2016-11-09 Jana Mendrok * arts-2-3-564 * doc/uguide/clouds.tex: Added scat_meta documentation. * src/m_optproperties.cc, methods.cc (TestScatDataInterp): Included full DOIT-like SSD extraction chain. Added & polished user options. * src/optproperties.cc (pha_mat_labCalc): Use tolerance in difference instead of equality for float-to-float comparisons. Added missing parts in interface documentation. * src/m_checked.cc (sensor_checkedCalc): For atm_dim=3 add lower limit check on sensor azimuth. 2016-11-08 Oliver Lemke * arts-2-3-563 * This commit should fix all warnings in GCC 6.2 (except unused parameters in abs_xsec_per_speciesAddLineMixedBands and warnings in 3rd party code). * src/complex.h: Fix indentation of return statements after for loops. * src/lin_alg.cc (special_matrix_exp_and_dmatrix_exp_dx_for_rt, matrix_exp_dmatrix_exp, matrix_exp_dmatrix_exp): Change type of r from Numeric to Index. floor() is used in the calculatoin of r and in all further uses, r is always compared to Index variables anyway. * src/linescaling.cc (partition_function): Fix indentation of break statement. * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): Fix indentation of checks. * src/m_radiation_field.cc (radiation_fieldCalcFromiyCalc): Reindent whole function because indentation was completely messed up. * src/m_sensor.cc (sensor_responseGenericAMSU): Change type of numPBpseudo and numPB from Vector to more appropriate ArrayOfIndex. Inserted explicit conversions to Numeric where needed. * src/m_tmatrix.cc (scat_data_singleTmatrix): Change 0. to 0 in integer comparison. * src/m_xml.h (WriteXML): Reindent one line for better readability. * src/math_funcs.cc (gamma_func): Clean up implementation. * src/ppath.cc (ppath_start_stepping, ppath_calc): Insert explicit type conversions to Numeric or Index where needed. 2016-11-08 Richard Larsson * arts-2-3-562 * src/rte.cc: Turns out the abs() call was incorrect 2016-11-07 Jana Mendrok * arts-2-3-561 * src/optproperties.cc, src/montecarlo.cc: Added coordinate system inconsistency warning at all places preparing/extracting single scattering data of PTYPE_GENERAL particles. 2016-11-07 Jana Mendrok * arts-2-3-560 * Revision of scatterig media descriptions. * doc/uguide/clouds.tex, atmosphere.tex: Revision of scat_data and pnd_field documentation, extention towards internal calculation of both (not yet complete, though). * doc/uguide/rte_theory.tex, doc/uguide/Figs/rte_theory/part_frame.pdf: Moved coordinate system description and figure from AUG to here. * doc/uguide/clouds_theory.tex, arts_theory.tex: Moved general size distribution descriptions here. * doc/uguide/absorption.tex: Updated zeeman paper reference. * doc/uguide/rte_basics.tex, symbol_defs.tex: Minor changes. 2016-11-07 Richard Larsson * arts-2-3-559 * src/{m_,}zeeman.cc: Fix bugs introduced to speed things up * src/pressurebroadeningdata.{cc,h}: Initial support for speed-dependent limit pressurebroadening in ARTSCAT5. Still very much in testing. Seems to work but it is not easy to find data/input. Ask me if you have a use case. * src/rte.{h,cc}: Fix for zero wind-fields. Note that there is an abs()- call that might not be necessary. There should be a normalization to -1/c, so the three components inside the switch needs to normalize to 1 and be positive 2016-11-07 Patrick Eriksson * arts-2-3-558 * src/optproperties.cc (pha_mat_labCalc): Replaced some asserts with a run_time error. Added also check of element (0,0). The idea to replace a few asserts with runtime error is to allow MC calculations to continue if these errors appear, and to give out an error message with information about what to do if an user stumbles upon these errors. 2016-11-06 Jana Mendrok * arts-2-3-557 * src/m_optproperties.cc, methods.cc (TestScatDataInterp): Extented to emulate RT4 ssd extraction (not exactly te same though, as RT4 does not need individial inc/sca direction extraction and allow for in-place comparison of results. Allow user to control WSM behaviour a little more. * src/optproperties.cc (pha_mat_labCalc): Bug fix (delta azimtuh of 180 or 360 deg is forms great circle, not their sum). Effects random oriented particles only. Brings the MC/RT4 like ssd extraction in TestScatDataInterp into agreement. Negligible effect on full RT solution, though. 2016-11-04 Oliver Lemke * arts-2-3-556 * doc/uguide/arts_developer.tex, doc/uguide/arts_theory.tex, doc/uguide/arts_user.tex: Add UHH address for contributor list. 2016-11-01 Oliver Lemke * arts-2-3-555 * montecarlo.cc (pha_mat_singleCalc): Fix indexing bug in inner loop over scattering elements. Caused a crash for cases that did not use ScatSpeciesMerge. * m_optproperties.cc (scat_dataCheck): Remove output of loop variables to out2. They create a huge amount of clutter in the output without giving any useful information. They are still included in the error output if something goes wrong. Demote coefficients output from out2 to out3. This output was too detailed for out2. 2016-10-30 Patrick Eriksson * arts-2-3-554 * src/m_montecarlo.cc (MCGeneral): Path sampling now put inside a try block, to be somewhat more resistent against failures in the path sampling. Warning and error message are displayed at failures. The calculations are halted if there are 5 failures for one radiance calculation. * src/montecarlo.cc (mcPathTraceGeneral): Now waiting until 100000 path points before issuing an error. The old value (25000) can be passed with tau limit and thick clouds. However, introduced a (hard-coded) limit of the step length. Presently set to 10 m. This to avoid pushing the ppath calculations too far, and avoid getting stuck if there is some extremly high extension values. * src/geodetic.cc (cart2poslos): If za is >90 or <90 is now resolved by start za and comparing step length to distance to tangent point. Internal check to dr now gives a runtime error, instead of assert. This required some new input arguments. * src/ppath.h: Added declaration of geompath_l_at_r. * src/ppath.cc (do_gridcell_3d_byltest): Added an assert around ppc. Also, assert for icall is now icall < 10. Was already like this for 2D versions. 2016-10-27 Patrick Eriksson * arts-2-3-553 * src/m_surface.cc (specular_losCalc): Now throws a runtime error if the incoming direction corresponds to hit the surface from below. (surfaceSemiSpecularBy3beams): New WSM. (surfaceSplitSpecularTo3beams): Renamed from surfaceSplitSpecular and built-in doc written. * src/agendas.cc: Defined surface_rtprop_sub_agenda. 2016-10-26 Patrick Eriksson * arts-2-3-552 * src/montecarlo.cc (mcPathTraceGeneral): Crashed if viewing direction was towards space. Now fixed. Or more in detail, now also handles cases where already start-up of ppath flags a radiative background. * src/montecarlo.cc (Sample_los): * src/montecarlo.cc (cloudy_rt_vars_at_gp): Some code replaced by instead calling mirror_los. 2016-10-25 Patrick Eriksson * arts-2-3-551 * src/m_optproperties.cc (TestScatDataInterp): So far just a test of a potential test. 2016-10-21 Patrick Eriksson * arts-2-3-550 * src/m_atmosphere.cc (AtmFieldsExtract1D): New WSM. More or less the reverse of AtmFieldsExpand1D. 2016-10-14 Jana Mendrok * arts-2-3-549 * src/m_optproperties.cc (ScatSpeciesMerge): As we change scat_data here, reset cloudbox_checked to 0 (unchecked). * src/m_jacobian.cc (jacobianDoit): Adapting to change above, run cloudbox_checkedCalc after the Merge calls. Requires the WSM to carry a few more interface parameters. * src/methods.cc: Adapt to above changes. * src/make_array.h: Change to allow longer WSM parameter lists. * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/artscomponents/disort/TestDISORT.arts: Add calls of cloudbox_checkedCalc after ScatSpeciesMerge. 2016-10-14 Patrick Eriksson * arts-2-3-548 * src/m_montecarlo.cc (MCGeneral): MC can now also handle cases where the surface_los have more than 1 angle. * src/m_surface.cc (surfaceSplitSpecular): So far just an undocumented method used to test the new feature above. 2016-10-12 Patrick Eriksson * arts-2-3-547 * This commit introdcues a new MC feature!!! There is now an upper limit on the optical path for each step. Default value, in general.arts, is set to 0.1. All tests done so far indicated same or better results. We will do more tests and later send out an email. Please keep an eye on your MC results until then. * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: Removed a setting of lambertian_nza as this old WSV is removed. * controlfiles/general/general.arts: Added default for mc_taustep_limit. Set it to 0.1. * src/m_montecarlo.cc (MCGeneral): * src/m_rte.cc (iyMC): mc_taustep_limit is now input and passed on. * src/workspace.cc (define_wsv_data): Added mc_taustep_limit. * src/montecarlo.cc (mcPathTraceGeneral): taustep_limit is now an input argument. 2016-10-12 Patrick Eriksson * arts-2-3-546 * src/montecarlo.cc (mcPathTraceGeneral): Made sure that background is set to undefined when recalculating ppath step. Needed when ppath step ends at the surface. 2016-10-11 Patrick Eriksson * arts-2-3-545 * src/montecarlo.cc (mcPathTraceGeneral): My last commit made MC to crash for stokes_dim = 1. Mixed up 0 and 1-based indexing in one place! 2016-10-11 Patrick Eriksson * arts-2-3-544 * src/montecarlo.cc (mcPathTraceGeneral): Code added that allows setting a limit on each path step in terms of optical thickness. Thsi feature is being tested. In this commit tau limit is hard-coded to 100, which maintains the old behaviour except for extreme situations. * controlfiles/general/agendas_surface.arts: Removed za_pos=0.5 from definitions including surfaceLambertianSimple. This is anyhow default for the method. In addition, standard agenda definitions should use method default values, otherwise we have basically two different default settings. * src/methods.cc: For surfaceLambertianSimple, moved lambertian_nza from IN to GIN. The value 9 was selected as default. * src/workspace.cc: Removed lambertian_nza as WSV. Semmed unnecessary to have such a specific variable as WSV. 2016-10-06 Patrick Eriksson * arts-2-3-543 * Some preperations to introduce an additional feature in MC: * src/m_fos.cc (fos, iyFOS): * src/m_montecarlo.cc: * src/montecarlo.cc (mcPathTraceGeneral): * src/rte.cc (defocusing_general_sub, defocusing_general) (defocusing_sat2sat): * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard, iyMC): * src/m_cloudradar.cc (iyCloudRadar): * src/m_doit.cc (doit_i_fieldUpdate1D, doit_i_fieldUpdateSeq1D) (doit_i_fieldUpdateSeq3D): * src/doit.cc (cloud_ppath_update1D, cloud_ppath_update1D_noseq) (cloud_ppath_update3D): * src/ppath.cc (ppath_calc): * src/m_ppath.cc (ppathCalc, ppathFromRtePos2, ppathStepByStep): Adopted to change below. That is, ppath_lmax has been added. * src/agendas.cc (define_agenda_data): Added ppath_lmax as input to both ppath_agenda and ppath_step_agenda, to allow algorithms to include modification of ppath_lmax. 2016-10-05 Oliver Lemke * arts-2-3-542 * src/methods.cc, src/m_atmosphere.cc: (atm_fields_compactAddConstant): Add argument condensibles. When given, the added species' vmr is scaled by the vmr of the condensibles: VMR * (1 - VMR_sum_of_condensibles). Useful when the given VMR assumes dry air. (batch_atm_fields_compactAddConstant): Add argument condesibles and pass it on to atm_fields_compactAddConstant. (batch_atm_fields_compactFromArrayOfMatrix): Remove extra fields from interface. They can be added with batch_atm_fields_compactAddConstant. * CHANGES-2.3: Add info about b_a_f_cFromArrayOfMatrix changes. * ChangeLog: Add version number to previous commit. 2016-09-29 Lukas Kluft * arts-2-3-541 * controlfiles/classroom_exercises/exe3_jacobian/plot_jacobian.m: Removed second positional argument from round() call. It breaks backward compatibility with older MATLAB versions and 0 is the default anyway. 2016-09-28 Oliver Lemke * arts-2-3-540 * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Reduce required accuracy in aligned particle reference comparison to 2e-10 to avoid failure if quad-precision is enabled. 2016-09-27 Jana Mendrok * arts-2-3-539 * src/cloudbox.cc (pnd_fieldF07ML, pnd_fieldF07TR): Don't try m-D regression in case of monodispersions. * src/m_checked.cc (cloudbox_checkedCalc), src/m_optproperties.cc (scat_dataCheck), src/methods.cc: Renamed keyword parameter determining what to check to scat_data_check_type and check_type, respectively. 2016-09-22 Oliver Lemke * arts-2-3-538 * Fix bug in tmatrix quad-precision calculations. avg_tmatrix was using the parameter file from double precision. * 3rdparty/tmatrix/avg_tmatrixq.f: Added. Import parameters from amplq.par.f instead of ampld.par.f. * 3rdparty/tmatrix/CMakeLists.txt: For quad-precision use avg_tmatrixq.f. 2016-09-17 Jana Mendrok * arts-2-3-537 * src/m_rt4.cc (RT4Calc): Non-fortran build bugfix. Debug comments outcommented. 2016-09-17 Jana Mendrok * arts-2-3-537 * src/m_rt4.cc, methods.cc (RT4Calc,RT4Init): Tests showed that RT4 runtime is proportional to 3rd power of number of angles. That means, number of angles, including the quadrature streams plus any extra/user angles, should be kept as low as possible. Therefore, I disallow user-specified angles, ie no scat_za_grid usage. Instead, RT4Calc returns doit_i_field on the quadrature angles (number to be specified by the user) plus 0/180deg if not in quadrature angles already to satisfy ARTS' scat_za_grid requirements. Corresponding scat_za_grid is output of RT4. RT4Init (e.g. sizing of doit_i_field) adapted accordingly. 2016-09-16 Jana Mendrok * arts-2-3-536 * 3rdparty/polradtran/rt4/radtran4.f: Bugfix in quadrature weights setting for extra-angles. Fixes i_field offset issue in calcs with (many) extra-angles. * src/doit.cc (doit_scat_fieldNormalize): Be slighty more verbose about actual applied norm_error_threshold. 2016-09-15 Jana Mendrok * arts-2-3-535 * src/m_rt4.cc, methods.cc (RT4Calc, RT4Init): Introduced usage of 'extra-angles' (ie. angles that are not computational streams). Work in progress. * 3rdparty/polradtran/rt4/radtran4.f: Allow 'extra-angles' for all quadrature methods, not only Gauss-Legendre. Govern 'extra-angle'-use via specified number of extra angles instead of quad-type and zeroed mu_values. * src/m_doit.cc (DOAngularGridsSet): Allow N_za_grid=0. This for having a proper way to set scat_za_grid for RT4 with proprietary streams only. * src/m_doit.cc (DoitInit), src/m_disort.cc (DisortInit): Move check of scat_za_grid size further up for proper error in case of size=0 as introduced above. * src/m_rt4.cc, methods.cc (RT4Test), src/rt4.cc,h (rt4_test): De-hardcode location of test data. * controlfiles/artscomponents/polradtran/TestRT4Test.arts: Better way to specify ref-output location. 2016-09-14 Alex Bobryshev * arts-2-3-534 * controlfiles/instruments/avhrr/ METOPA_AVHRR.backend_channel_response.xml, NOAA15_AVHRR.backend_channel_response.xml, NOAA16_AVHRR.backend_channel_response.xml, NOAA17_AVHRR.backend_channel_response.xml, NOAA18_AVHRR.backend_channel_response.xml, NOAA19_AVHRR.backend_channel_response.xml, Changed the first and the last weights to zero. Before the first and the last weights were negative values. With negative values arts gave an error-message: backend_channel_response.data = [0, >0, >0, 0]. * controlfiles/instruments/avhrr/TestAVHRR.arts: Add two agendas to controlfile: abs_xsec_agenda_checkedCalc propmat_clearsky_agenda_checkedCalc Without these two agendas controlfile didnot work. Now the controlfile works without error-messages. 2016-09-13 Jana Mendrok * arts-2-3-533 * src/disort.cc (phase_functionCalc): Apply a pnd threshold (<1part/galaxy) when deriving phase function from bulk scttering matrix. Obviously too tiny numbers cause numerical issues. Fixes issue reported by Patrick. 2016-09-08 Jana Mendrok * arts-2-3-532 * m_cloudbox.cc (cloudboxSetFullAtm): Bugfix: loop parameter for upper lat/lon edges corrected. 2016-09-08 Jana Mendrok * arts-2-3-531 * src/m_disort.cc, m_cloudbox.cc, methods.cc (cloudboxSetFullAtm): Moved the WSM definition (former cloudboxSetDisort) from m_disort to m_cloudbox. Extended applicability to any atm_dim. * src/constants.cc, m_checked.cc (cloudbox_checkedCalc): Defined minimum distance between cloudbox and alt/lon edges as global constant (to hae them consistent in cloudboxSetFullAtm and cloudbox_checkedCalc. Adapted cloudbox_checkedCalc accordingly. * src/m_rt4.cc (RT4Calc): FIXME note on up/down_rad to doit_i_field assignment using cloudbox_limits[0] (not an issues now, but needs revision when we allow cloudbox_limits[0]!=0). 2016-09-07 Oliver Lemke * arts-2-3-530 * src/main.cc: Display relmat info with '-v'. 2016-09-01 Jana Mendrok * arts-2-3-529 * src/m_rt4.cc (RT4Init): Loophole fix: RT4 has to be run with cloudbox_limits[0]==0. * src/m_disort.cc (DisortInit): Minor modifications. 2016-09-05 Richard Larsson * arts-2-3-528 Non-working commit of relmat-arts interfacing. Will work on this through to relmat and arts interface is clean. Committing code to ease collaboration. * 3rdparty/relmat/*: relmat and files to interfacce with it. See later commits for more details. * 3rdparty/CMakeLists.txt,CMakeLists.txt,config.h.cmake: * src/CMakeLists.txt: ENABLE_RELMAT * src/linemixingdata.cc: Added LM_BYBAND as ignore tag for band calculations. * src/linerecord.{cc,h}: Removed (ReadFromHitranModifiedStream) but added reading for hupper and glower to HITRAN reading. * src/linescaling.{cc,h}: Added (partition_function) as separate function to easier get partition function when other scale factors are not needed. * src/m_linemixing.cc: Changed completely adding (abs_xsec_per_speciesAddLineMixedBands) to interface with relmat. This is still very much work in progress where there will be more updates in the somewhat near-future Currently, trying to use this without changing the code will just result in throwing runtime_error. * src/jacobian.cc: Fix bug when vmr=0 gives jacobian as nan. * other files: Only minor comments updae for problematic cases. 2016-09-02 Oliver Lemke * arts-2-3-527 * doc/uguide/interpolation.tex: Small wording fix. 2016-09-01 Jana Mendrok * arts-2-3-526 * src/methods.cc, controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Changed Z-norm threshold 0.01 -> 0.05 (such that the arts-xml-data scat_data passes and which should still be okayish. more detailed adjustments (what to do with norm deviations) are up to the individual scatt solvers. Reverted threshold-modifying settings in controlfiles. * src/m_disort.cc, methods.cc, controlfiles/artscomponents/disort/TestDISORT.arts: Renamed cloudboxSetDisort to cloudboxSetFullAtm (in line with renaming in ARTS2.2 for removing references to Disort there as well as with the fact that Disort interface does not require anymore whole-atm cloudbox). 2016-08-29 Jana Mendrok * arts-2-3-525 * src/cloudbox.cc (pnd_field*): Added check that produced dNdD vector contains any non-zero values (else all rescaling later won't help to reach the desired mass/number density/flux). Info/error message coding less error-prone through once per subroutine set psdname variable. 2016-08-28 Jana Mendrok * arts-2-3-524 * src/methods.cc: Updated doc of *cloudbox_checkedCalc* and *scat_dataCheck*. 2016-08-28 Jana Mendrok * arts-2-3-523 * src/m_checked.cc (cloudbox_checkedCalc): Added checks of scat_data: Freq coverage checks moved here. Checks of single scattering data validity (no NaN, no neg values in K11, Z11, a10) and Z norm. Except freq coverage, checks are performed by the WSM scat_dataCheck and can be switched off (idea: data, once created, is often re-used. then it's not necessary to check them at each new arts run. instead, a check can be done once using scat_dataCheck.). * src/m_optproperties.cc (scat_dataCheck): Extended to also check for NaNs in single scattering data and for negative values in K11, Z11, and a11. Added Z norm check for horizontally aligned particles. Added keyword allowing Z norm checks to be skipped. * src/m_cloudbox.cc (ScatElementsPndAndScatAdd, ScatSpeciesPndAndScatAdd, ScatSpeciesScatAndMetaRead): Removed freqency coverage check in WSMs that read scat_data/pnd_field for in-cloudbox use (where cloudbox_checkedCalc will be applied). * src/cloudbox.cc,h, xml_io_compound_types.cc: Remove passing scat data file names to chk functions and remove all references to files in output messages. Here, we only process data; files are - if at all, handled by the calling functions. * src/methods.cc: Adapted for WSM interface changes above. * controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Increase sca_mat_threshold in cloudbox_checkedCalc to 5% in order to make these cases pass the now (semi-)mandatory Z norm test. We should actually review and improve the data... 2016-08-26 Oliver Lemke * arts-2-3-522 * doc/uguide/clouds.tex: Small fix for aa-grid size of horizontally-aligned particles. N_za_inc/2+1 -> N_za_sca/2+1. 2016-08-26 Oliver Lemke * arts-2-3-521 * src/m_optproperties.cc (ScatSpeciesMerge): Extended merging to work not only for randomly oriented particles but all particle types. Weighted sum is now calculated for all dimensions of particle's ext_mat_dat, abs_vec_data and pha_mat_data. Horizontally-aligned case provided by Jana now shows numerically identical results with and without ScatSpeciesMerge. 2016-08-25 Jana Mendrok * arts-2-3-520 * src/rt4.cc (sca_optpropCalc): Bug fix in azim. oriented particles branch: actually use particle's own azimuth grid in azimuthal integration, not the user-controlled one created for random orientation particles. Found by Oliver. 2016-08-25 Oliver Lemke * arts-2-3-519 * src/doit.cc (doit_scat_fieldNormalize): If norm_debug=1, add additional output for each pressure level instead of just changing from out2 to out0. 2016-08-24 Jana Mendrok * arts-2-3-518 * src/montecarlo.cc (Sample_los): Bug fix p30 branch: adapt pnd_field/scat_data_mono consistency check to scatt species&elements system (seems nobody used MC with non-random particles for a long time...). 2016-08-24 Jana Mendrok * arts-2-3-517 * src/rt4.cc,h (sca_optpropCalc): Bug fix Fourier component integration. Check and correct Fourier component normalization. * src/m_rt4.cc (RT4Calc): doit_i_field size check. Bug fix filling doit_i_field from RT4 output. * src/m_disort.cc (DisortInit), src/m_rt4.cc (RT4Init): Bug fix. Initialize doit_i_field size with stokes_dim. * src/disort.cc (pmomCalc, pmomCalc2): Made PFCT normalization check messages and thresholds consistent. * 3rdparty/polradtran/rt4/radtran4.f (RADTRANO): Increased max size of RT problem. More informative error output when allowed problem size is exceeded. * 3rdparty/polradtran/rt4/radscat4.f (CHECK_NORM): Outcomment PFCT normalization warning message. We leave that to ARTS. * controlfiles/general/agendas_surface.arts: Added another predefined agenda for lambertian surface. 2016-08-22 Oliver Lemke * arts-2-3-516 * src/m_doit.cc (DoitCalc): Properly catch exceptions in OMP frequency loop. If an exception occurs, it is rethrown after the loop. Fixes bug reported by Jana. 2016-08-15 Jana Mendrok * arts-2-3-515 * src/m_rt4.cc (RT4Calc): non-RT4 build fix. 2016-08-15 Jana Mendrok * arts-2-3-514 * src/m_rt4.cc, methods.cc (RT4Calc), rt4.cc, rt4.h (sca_optpropCalc): Continue on RT4 interface implementation: preparation of scattering matrix data for RT4. * src/disort.cc, disort.h: Cosmetics. * 3rdparty/polradtran/rt4/radmat.f: Avoid redefining blas/lapack functions idamax and dscal. 2016-08-10 Oliver Lemke * arts-2-3-513 * src/m_rt4.cc: (RT4Calc, RT4Test): Throw a runtime error in non-rt4 builds. (RT4Calc): Fix arguments in function declaration for non-rt4 build to match rt4 build. * src/rt4.h: Ignore everything in here for non-rt4 build. Note: Functions should never be _implemented_ in the header file. Could otherwise lead to duplicate symbols error from linker (function ends up in more than one object file). * src/rt4.cc: Ignore everything in here in non-rt4 build. 2016-08-09 Jana Mendrok * arts-2-3-512 * src/rt4.h: Return to previous version. Plus a correction. However, RT4-disbaled build still fails :-/ Oliver? * src/disort.cc: Error message correction. 2016-08-09 Jana Mendrok * arts-2-3-511 * src/rt4.h: Reorganized the ifdef ENABLE_RT4 loops in the hope that hudson likes that better... 2016-08-09 Jana Mendrok * arts-2-3-510 * src/m_rt4.cc, methods.cc (RT4Calc, RT4Init), workspace.cc (rt4_is_initialized): Work in progress: Implementation of RT4 solver interface. * src/rt4.cc, rt4.h: Added. Methods for RT4 input preparation etc. RT4Test contents moved here. * src/CMakeLists.txt: rt4.cc added to library list. * src/disort.cc, m_disort.cc: Cosmetics. 2016-08-08 Lukas Kluft * arts-2-3-509 * controlfiles/instruments/metmm/common_metmm.arts: Removed method calls for absorption lookup tables. * controlfiles/instruments/metmm/TestMetMM.arts: Included method calls for absoprtion lookup tables. Also moved the includes for sensor descriptions closer to the top of the controlfile. 2016-08-03 Jana Mendrok * arts-2-3-508 * controlfiles/CMakeLists.txt: Added RT4 test to (fast) checks. 2016-08-03 Jana Mendrok * arts-2-3-507 * 3rdparty/polradtran/rt4/radtran4.f,radscat4.f,radintg4.f: Adapted RT4 code for use with ARTS. Particularly, don't use files for SSP data input, but pass this down from the calling routine. Changed all internal full-stokes size SSP containers to only have nstokes entries. * 3rdparty/polradtran/rt4/*.f.orig: Keep original RT4 code in addition to ARTS-adapted one. * config.h.cmake, CMakeLists.txt, 3rdparty/CMakeLists.txt, 3rdparty/polradtran/CMakeLists.txt, 3rdparty/polradtran/rt4/CMakeLists.txt, src/CMakeLists.txt,src/main.cc: Modified/added to include RT4 module. * src/m_rt4.cc, rt4.h: Added. So far contains only an interface to the proprietary RT4 testc test case. * src/methods.cc: Added RT4Test. Improvements/corrections of DisortCalc doc. * controlfiles/artscomponents/polradtran/, TestRT4Test.arts, refRT4.xml, testdata/*.xml: Added RT4 test case including (atm & SSP) data needed and reference results (created from original RT4 calc). NOTE: the testdata is not formatted for general use with ARTS, but specific to this test case (ie not supposed to run as is with other ARTS modules like yCalc, DoitCalc etc.) * src/m_jacobian.cc: Minor formulation changes. * src/: Some further ignore patterns (*.mine*, .*sw*) added. 2016-07-07 Oliver Lemke * arts-2-3-506 * src/methods.cc, src/m_basic_types.cc: Add IndexAdd. 2016-07-07 Oliver Lemke * arts-2-3-505 * controlfiles/instruments/mviri, controlfiles/instruments/seviri: Added setup for mviri and seviri from Max Schaper. Adapted original files to work with the latest arts. Added reference files for ybatch results. Use with care, setups need further verification of results. * controlfiles/CMakeLists.txt: Added seviri and mviri as "nocheck" cases. 2016-07-06 Oliver Lemke * arts-2-3-504 * CMakeLists.txt: Added workaround for systems that use the atlas lapack implementation with cblas, e.g. the DKRZ supercomputer mistral. Lapack detection in those cases fails because the default cmake lapack check does not detect the cblas library. * cmake/modules/FindCblasLapack.cmake: Added simple cblas+lapack detection. 2016-07-01 Oliver Lemke * arts-2-3-503 * cmake/modules/FindNetCDF.cmake: Remove unused library dependency on netcdf_c++. 2016-06-24 Oliver Lemke * arts-2-3-502 * src/m_batch.cc (ybatchCalc): Resize all elements of the ybatch* WSVs to 0. Before it could happen that old values are still present if ybatchCalc is called more than once with an ARTS release build. Fixes bug reported by Freddy. 2016-06-16 Jana Mendrok * arts-2-3-501 * src/continua.cc (xsec_continuum_tag): Added frequency and temperature limit checks for liquidcloud ELL07 & MPM93 and rain MPM93 absorption models. * methods.cc (AtmRawRead): Tried to improve documentation, giving some hints for handling of cloud/precip as absorption species. 2016-06-06 Oliver Lemke * arts-2-3-500 * src/xml_io_compound_types.cc (xml_read_from_stream): Better error message if the user tries to read a broken GriddedField file with a wrong tag for *ArrayOfString*. Only occurs if user decides to manually create XML files instead of using proper tools such as atmlab or typhon. :-) 2016-06-03 Richard Larsson * arts-2-3-499 ComplexVector and ComplexMatrix are implemented with similar internal structures as Matrix and Vector. The goal: to simplify calculations of relaxation matrix inversion. Will also help with keeping function calls shorter by not having to copy complx numbers to separate vectors. Also, none of this code has been optimized and is probably slow. * src/blash.h: Added references to zgemm and zgemv * src/lapack.h: Added references to zgeteri and zgetrf. Also added references to dgeev and zgeev. * src/complex.{cc,h}: Implementation of ComplexVector and ComplexMatrix copying Matrix and Vector. This was done just by copy-pasting matpackI code and adding the word "Complex" where approapriate and changing most double/Numeric references to Complex. There is probably a lot of redundant code in here, and also a lot missing. Especially missing is ways to combine Vectors and ComplexVectors in the same mult statements. Should be possible, could be useful, but when it is useful it should be possible to add and check these at the time of need. * src/lin_alg.{cc,h}: inv function for ComplexMatrix is working by relying on Simon's implementation for Matrix. Also added diagonalize functions that return P and W from A in the statement diag(P^-1*A*P)-W == 0. For both Complex and Numeric Also added secondary method to calculate the matrix exponent using the diagonalizations for testing purposes. (This should be faster than the other method for smaller matrices but I think it is less numerically stable? Not sure. So for now only available to ensure that the diagonalizations actually work for simple test cases.) Problem 1: An eigenvalue/vector can be complex even if the original matrix is real. I have not bothered taking this into account, but should probably do so rather than work as presently returning the strange format used by lapack for these cases. If this becomes used that is. By my tests, eigenvalues for the propagation matrix will be complex, so these cannot presently by calculated with this method. (I found somewhere that this is because propmat is the addition of an hermitian and a skew-hermitian matrix, though somehow I cannot find that source again to confirm that my memory is not playing tricks on me...) Problem 2: I am not using any test on the condition of the matrix, so nan and inf outputs are possible and probable if care is not taken. I could switch to the "x" versions of dgeev and zgeev, but I am unsure on what else this will do. * src/matpackI.h: added diagonalize reference. * src/test*: Added some tests of the functions above. 2016-06-03 Jana Mendrok * arts-2-3-498 * src/m_cloudbox.cc (dNdD_MH97), src/cloudbox.[cc,h] (pnd_fieldMH97, IWCtopnd_MH97), src/methods.cc: Allow additional options passed as part of scat_species tags. Add option 'robust' for MH97, which ignores (upper) T-limits (any ambient T>0C gives psd for T=0C). Non-robust remains the default. 2016-06-02 Oliver Lemke * arts-2-3-497 * src/lin_alg.cc (lubacksub): Fix warning in Release build about unused variables. Variables only used in assertions should be enclosed in the DEBUG_ONLY() macro. * src/rational.h: Include math_funcs.h to make fac(Numeric) function known at compile time. Avoids warning about Rational::fac calling itself. 2016-06-01 Oliver Lemke * arts-2-3-496 * src/lin_alg.cc (inv): Fix memory leak. ipiv was allocated but never freed. Reported by Richard. 2016-05-30 Patrick Eriksson * arts-2-3-495 * doc/uguide/rte_theory.tex: Fixed error in Eq 6.50, pointed out by Simon. 2016-05-30 Jakob Dörr * arts-2-3-494 * src/doit.cc (doit_i_field_ngAcceleration): Fixed another bug in the convergence acceleration concerning NaN values. 2016-05-25 Richard Larsson * arts-2-3-493 * src/{m_,}zeeman.cc: Added a zeeman_frequencyshiftconstant_precalc varible and precalc a value per Zeeman split line for the splitting. This reduce redundant calculations that previously repeated at every level. 2016-05-24 Jana Mendrok * arts-2-3-492 * src/disort.cc, disort.h, m_disort.cc, methods.cc: Renamed pfct_method options. Added options for using highest or median T_grid points. Made median the default option. NOTE 1: Renaming breaks backward compatibility. NOTE 2: The default change might (slightly) modify your results if you had run with default option before (equiv. to 'low'). * 3rdparty/disort1.2/DISORT.f.orig, ErrPack.f.orig: (Re)Added original code files. * 3rdparty/polradtran, 3rdparty/polradtran/rt4/*: Added place for polradtran (RT3/4) code and original RT4 code. 2016-05-24 Jakob Dörr * arts-2-3-492 * src/m_doit.cc (doit_i_field_monoIterate): Fixed a bug in the convergence acceleration 2016-05-23 Oliver Lemke * arts-2-3-491 * src/zeeman.cc (create_Zeeman_linerecordarrays): Turned a couple of variables into const references to avoid unnecessary copying. 2016-05-20 Richard Larsson * arts-2-3-490 * src/{quantum.h,zeeman.cc}: Previous commits contained C++11 features. Thanks Oliver for pointing this out and showing me how to fix it. 2016-05-20 Richard Larsson * arts-2-3-489 * src/quantum.h: Changed from "Hund" to "Hund : Index". Relying on Hudson to test if this works because it compiles locally, just as the last commit did? If this fix does not work, then I will declare specific integers in quantum.h instead. 2016-05-20 Richard Larsson * arts-2-3-488 This update requires updating zeeman_constants.xml in arts-xml-data. Found bug in implementation for NO. Should be fixed now following Berdyugina and Solanki's 2002 paper. Note: This only works from a catalog that defines quantum numbers that we can understand. Reading HITRAN presently does not work for NO because the quantum numbers are not well-represented. The rules in the 2004 paper seems to not be work outside some limited frequnecy regions. So this is disabled and you have to set the quantum numbers by hand if you use HITRAN. (Or reenable it in quantum_parser_hitran for testing if your freqeuncy region works as expected. Just remember to disable this before committing any code updates...) * src/m_zeeman.cc: Updated propmat_clearskyAddZeeman to just copy behavior of the preferable propmat_clearskyAddZeemanFromPreCalc, but slower by repetition. Should probably deprecate this instead... Updated the other functions to remove a multitude of if-statements and writing of quantum numbers directly to the Zeeman linerecords. * src/quantum.{cc,h}: Added a flag for hund case and a Lambda as a quantum number. * src/rational.{cc,h}: Updated handling of toIndex() for half-integers. 2/2 failed before but is clearly an integer. * src/zeeman.{cc,h}: Added the error handling of isotopologue_quantum. The change in zeeman_constants.xml showed me there was no error handling whatsoever other than "is it defined?". Removed old frequnecy_change function handler for different Hund cases and moved this functionality in under one function that cares for the Hund-flag in the linerecord. Added an enum for the Auxilliary indexing so that if this has to change again, it is easier. (I am thinking that visible lines having transitions away from the ground-state to the ground-state has to be treated differently, though I do not know how important this actually is...) Changed the quantum number handling so that the case a calculations can be made. Also simplified the loop of J giving M. Turns out that there was a bug in the stored data in zeeman_linerecord_precalc before, so that upper Ms where stored as lower Ms and vice versa, though there was another bug that also handled upper Ms as lower Ms and vice versa compensating for the first bug 1-to-1... it was a mess caused by the J loop being too complicated for me. * doc/uguid/absorption.cc: Changed to point at the precalc methods rather than the old slower method for Zeeman. Also updated its version of isotopologue_quantum. 2016-05-19 Patrick Eriksson * arts-2-3-487 * src/m_atmosphere.cc (vmr_fieldSetConstant): A new small WSM. 2016-05-10 Jana Mendrok * arts-2-3-486 * src/m_disort.cc (DisortCalc): Revert critical region extension from 2-3-454. Can't reproduce the issues that led to the extension while the extension makes proper error catching more complicated. * src/m_checked.cc (cloudbox_checkedCalc): Allow non-zero pnd at upper cloudbox limit if this coincides with top of atmosphere. * src/m_cloudbox.cc (ScatSpeciesScatAndMetaRead): Added *.scat_data.xml/*.scat_meta.xml to allowed scat (meta) data naming patterns. This particularly since this is the default naming pattern when these data are created by ARTS WSMs. * src/m_tmatrix.cc (diameter_maxFromDiameter_volume_equ): Adapted to output consistent with current meta data format (different diameters). Removed tmatrix-specific error check (this method is not limited to tmatrix!). * src/methods.cc (diameter_maxFromDiameter_volume_equ): Doc adapted according to changes above. (scat_data_singleTmatrix): More comfortable default setup of data_aa_grid, which is irrelevant for randomly oriented particles. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts, controlfiles/artscomponents/tmatrix/TestTMatrix.ssd.metaREFERENCE.xml: Adapted to changes above. * controlfiles/instruments/metmm/sensor_descriptions/prepare_metmm.arts: Added. Containing creation of container variable commonly used by the metmm-type sensor setups. Allows to process several sensors in one ARTS run. * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar_downward.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar_upward.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_saphir.arts: Removed container variable creations. Updated header info. 2016-05-10 Oliver Lemke * arts-2-3-485 * src/m_surface.cc: (FastemStandAlone): Changed all assertions for user input to runtime errors. (surfaceFastem): Remove inconsistent checks for salinity and wind_speed. These are passed on directly to FastemStandAlone and are checked there. * src/check_input.{cc,h}: Added three new variations of ckh_if_in_range (_exclude, _exclude_low, exclude_high) to be able to exclude the low, high or both values from the valid range if needed. 2016-05-03 Jakob Dörr * arts-2-3-484 * controlfiles/artscomponents/doit/doit_setup_accelerated.arts: Fixed errors in the test case for the convergence acceleration. 2016-05-01 Simon Pfreundschuh * arts-2-3-483 * src/m_jacobian.cc: Check for empty Jacobian in JacobianAdjustAfterIteration. 2016-04-28 Simon Pfreundschuh * arts-2-3-482 * src/math_funcs.cc: Fixed index order in reshape(...) and flat(...) functions for Tensor3. 2016-04-28 Richard Larsson * arts-2-3-481 * controlfiles/instruments/odinsmr/{odinsmr.arts,yREFERENCE.xml}: Updated the reference vector and returned to 1e-2 test for future updates to pass. 2016-04-27 Richard Larsson * arts-2-3-480 Parts of this is still work in progress, parts are old promises, parts are me finding things that I have done apt for misunderstanding while looking through the code in preparation of my thesis. The work in progress will still experience great changes. * src/absorption.cc: Preparations for line mixing through relaxation matrix. Check in xsec_species_line_mixing_wrapper. Work in progress. * src/lin_alg.cc: (special_matrix_exp_and_dmatrix_exp_dx_for_rt) Made the parallel partial derivation executable in parallel whenever not already in parallel. * src/linemixingdata.h: Preparation for line mixing through relaxation matrix. Setting up Band tags. Work in progress. * src/linerecord.{cc,h}: Preparation for line mixing through relaxation matrix. ReadFromHitranModifiedStream perhaps temporary creation. (Paris group has a modified HITRAN format for some files. This might get merged with main reading of HITRAN by some "if" statement down-the-line. For now separation is easier.) Also, there was a backwards compatibility bug for ARTSCAT4 to 5 that is now corrected. * src/m_abs.cc: Removed lingering implementation comment. * src/m_jacobian.cc: Tries to fix error reporting in species jacobian. * src/m_linemixing.cc: Reading routine abs_lines_per_band in preparation for line mixing through relaxation matrix. Very much work in progress. * src/lineshapes.cc: Added a deprecated function that is called by anyone trying to access Voigt_Kuntz3/4 in accordance with old series of emails that these are deprecated. Also tried to clean-up the HTP line shape. This entire code could be made so much simpler if we had ComplexVector as an ARTS class for Vectors containing "complex" instead of "Numeric". (HTP would now require 8 Vector outputs to handle partial derivation properly, which makes for a very annoying code so I have not made this implementation. If xvector was a ComplexVector, then only two complex vectors would have to be returned to handle all partial derivations since d(F)/dx then could be 2xF-2/sqrt(pi), but because of HTP complexity, two rather than one F must be returned for partial derivations later on. Anyways, I rant because I think it might matter in the future since Voigt data is incompatible with HTP data, so data published as HTP cannot be used in partial derivations if there is no fix in sight.) * src/m_linerecord.cc: Added method to "turn off" lines in abs_lines_per_species in preparation for line mixing through relaxation matrix. To avoid duplicate lines. Work in progress. * src/partial_derivatives.cc: Added a comment warning about non-lte partial derivations. While technically the code is correct there is a missing term in this implementation that could confuse people. So commented a warning for anyone looking at the code in the future. * src/rte.cc: Updated emission stepping for non-lte to make its design cleaner. Also removes four operations per frequency for hopefully slightly faster code execution. * src/pressurebroadeningdata.cc: Updated HTP defaults to be in line with published works. Made a mistake here before. * src/workspace.cc: Added two variables in preparation. Work in progress. * src/methods.cc: Updated lineshape definitions. I have Hartmann-Tran in there now but there is still no way to get proper data to it since very limited publications have been made on it. (So if you have data you want to use with this there is still some minimal work required to input this data. Since there is a temperature dependency issue still under discussion for the shape, different data sources will still have different dependencies, so no general implementation is yet possible.) * controlfiles/instruments/odinsmr/odinsmr.arts: Now uses Voigt_Kuntz6. This makes the file complain that it is not within 1e-2. So I increased the error range. I am hoping someone can confirm if this is still acceptable or possibly update y-reference? 2016-04-27 Simon Pfreundschuh * arts-2-3-481 * src/invlib/*: invlib update. 2016-04-27 Simon Pfreundschuh * arts-2-3-480 * src/m_oem.cc: Corrected forwarding of OEM parameters to invlib routine. * src/m_oem.h: Fixed type of preconditioner. 2016-04-26 Jakob Dörr * arts-2-3-479 * controlfiles/artscomponents/doit/TestDOITaccelerated.arts, controlfiles/artscomponents/doit/doit_setup_accelerated.arts, controlfiles/artscomponents/doit/yREFERENCE_DOITaccelerated.xml: Added controlfiles to test the DOIT with convergence acceleration. * src/doit.cc, src/doit.h: Added an internal method for the convergence acceleration. It computes an accelerated field out of four iteration fields. * src/m_doit.cc: Added the option to enable or disable convergence acceleration in doit_i_field_monoIterate (default is disable) * src/methods.cc: Added an Index "accelerated" to the generic input of doit_i_field_monoIterate to control the convergence acceleration. * controlfiles/CMakeLists.txt: Added accelerated test. 2016-04-25 Simon Pfreundschuh * arts-2-3-478 * src/matpackI.cc: Fixed bug in matrix-vector multiplication. * src/test_matpack.cc: Added test to cover the fixed bug. 2016-04-13 Simon Pfreundschuh * arts-2-3-478 * 3rdparty/invlib/*: invlib update to include new timing functionality. * src/oem.h: Added timing for arithmetic operations. 2016-04-12 Simon Pfreundschuh * arts-2-3-477 * doc/uguide/wfuns.tex: Fixed minor typos. 2016-04-12 Simon Pfreundschuh * arts-2-3-476 * doc/uguide/formalism.tex: Fixed minor typos. * doc/uguide/ppath_theory.tex: Fixed minor typos. 2016-04-10 Simon Pfreundschuh * arts-2-3-475 * 3rdparte/invlib/* Changed FM interface so that Jacobian computation also computes y prediction. * m_oem: Avoid computation of Jacobian when only y is needed. 2016-04-09 Simon Pfreundschuh * arts-2-3-474 * methods.cc: Renamed WSM oem to OEM * m_oem: Renamed oem to OEM. Added conjugate gradient versions for each optimization method. * 3rdparte/invlib/* invlib update. 2016-04-07 Oliver Lemke * arts-2-3-475 * CMakeLists.txt: Put OS X clang on C++11 blacklist for now. Apple Clang as well as vanilla clang (tested 3.6-3.8) currently fail compiling invlib on OS X 10.11.4. 2016-04-06 Simon Pfreundschuh * arts-2-3-474 * 3rdparte/invlib/* invlib update. * m_oem.cc: Optimized invlib forward model interface to avoid unnecessary computation of the Jacobian. 2016-04-06 Oliver Lemke * arts-2-3-473 * CMakeLists.txt, src/CMakeLists.txt: Move all CXX11 detection into one place in toplevel CMakeLists.txt. Set C++11 compiler flags globally (if enabled). Set maximum template depth globally to 1024. Add Intel compiler <16.1(unreleased) to C++11 blacklist. In version 16.0, it does not yet support all necessary C++11 features. * config.h.cmake: Add CXX11_SUPPORT preprocessor definition. * src/main.cc, src/m_oem.cc: Use CXX11_SUPPORT preproc constant. * 3rdparty/Eigen/Core: Temporarily disable deprecated warnings in Functors.h file for binder1st and binder2nd when compiling with C++11 support until Eigen library is fixed. 2016-04-05 Simon Pfreundschuh * arts-2-3-472 * src/CMakeLists.txt Added macro to signal C++11 support. * m_oem.cc Fixed conditional compilation to also work in absence of C++11 support. 2016-04-05 Simon Pfreundschuh * arts-2-3-471 Small fix to Oliver's changes to make C++11 autodetection work. * src/m_oem.cc: Removed conditional compilation macros around x2arts method. * src/m_oem.cc: Forwarded display_progress argument to invlib call. 2016-04-05 Oliver Lemke * arts-2-3-470 * src/main.cc: Display OEM/C++11 status in arts -v output. * src/methods.cc, src/m_oem.cc, src/CMakeLists.txt: Instead of removing the oem WSM completely if C++11 support is not available, replace it with a dummy function that output a runtime error to give the user information what he has to do to enable OEM. This makes OEM consistent with the behaviour of other optional features in ARTS. 2016-04-04 Patrick Eriksson * arts-2-3-469 * src/m_oem.cc (setup_xa): Had missed to add handling of pointing and baseline fits. 2016-04-03 Patrick Eriksson * arts-2-3-468 * src/m_oem.cc (oem_template): Added jacobian.resize(0,0); + comments before first call of inversion_iterate_agenda. * src/agendas.cc: Added jacobian as input to inversion_iterate_agenda. * src/m_jacobian.cc (jacobianCalcPointingZaRecalc): Fixed typo in a comment * src/special_interp.cc (regrid_atmfield_by_gp): itw was given wrong side for 2D and 3D. * src/m_oem.cc (setup_xa): Added handling of logrel for VMR. * src/m_oem.cc (x2arts_std): Added handling of logrel for VMR. Baseline fit and pointing off-set parts were wrong. Thinsg improved, but these parts are not yet tested practically. * src/m_basic_types.cc (VectorExtractFromMatrix) (MatrixExtractFromTensor3): These WSMs are now placed in this file. (VectorReshapeMatrix): New WSM. * src/m_batch.cc (VectorExtractFromMatrix) (MatrixExtractFromTensor3): Moved to other file. 2016-04-02 Patrick Eriksson * arts-2-3-467 * Some additions around oem, but nothing really tested. * src/m_basic_types.cc (VectorAddVector, VectorSubtractVector): New WSMs. * src/m_oem.cc (x2arts_std): Extended to handle baseline fits and pointing off-sets. * src/m_jacobian.cc (jacobianAddPolyfit): Initial error message was wrong. * src/workspace.cc: Added y_baseline. 2016-03-31 Simon Pfreundschuh * arts-2-3-466 * 3rdparty/invlib/src/invlib/optimization/levenberg_marquardt.cpp: Added missing implementation file. 2016-03-30 Simon Pfreundschuh Exchanged old OEM implementation against invlib (github.com/simonpf/invlib) library. Successfully built with g++-5.2 and clang++-3.7. * arts-2-3-465 * 3rdparty/invlib/* Generic implementation of MAP estimators. * CMakeLists.txt: Added check for C++11 support that disables oem functions if C++11 is not supported. * src/CMakeLists.txt: Conditional compilation of m_oem. Added compile flags for m_oem.cc and test_oem.cc. * src/methods.cc: Conditional compilation of m_oem and m_x2arts. * src/oem.h: Completely rewritten. Now only contains type aliases for for invlib generic types. * src/oem.cc: Removed. * src/test_oem.cc: Adapted tests to new OEM implementation. * src/test_oem/test_oem_levenberg_marquardt.m: Fixed atmlab call. 2016-03-28 Simon Pfreundschuh * arts-2-3-464 * src/matpackII.* (insert_vector): Added function to efficiently insert vector of unsorted elements into sparse matrices. * src/xml_io_basic_types.cc (xml_read_from_stream(..., Sparse& , ...)) Changed read function for Sparse to use insert_vector function. 2016-03-27 Simon Pfreundschuh * arts-2-3-463 * src/matpackII.* (transpose_multiply): Added a function to multiply the transpose of a matrix with a vector without the need to explicitly compute the tranpose. * src/test_sparse.cc (test_sparse_multiplication) Added test for new multiplication function. * src/matpackI.h (Vector): Added transpose_multiply to friends declaration. * src/matpackI.cc (mult): Fixed input parameter to dgemv when multiplying a transposed matrix consisting only of one row/column. * src/test_matpack.cc (test_matrix_vector_multiplication) Refined test to catch above corner case. 2016-03-21 Jana Mendrok * arts-2-3-463 * src/m_refraction.cc, methods.cc (complex_refr_indexIceMatzler06): WSM to calculate Matzler06 ice ref index data (eq. to Warren08 microwave data). * src/refraction.[cc,h] (complex_n_ice_matzler06): The actual function to calculate Matzler ref indices. * controlfiles/artscomponents/refice/TestRefice.arts, TestRefice.complex_refr_indexREFERENCE.xml: For microwave use Matzler refindex data, not outdated Warren84. Set harder comparison threshold (old threshold was larger than imag refindex values as such; Warren84 passed as ok for Matzler reference data). * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Replaced refindex model Warren84 by Matzler06 (in comment). Harden comparison threshold to the order magnitude of the actual ssd data (we don't want to test the t- and f-grid settings, but the data itself). * controlfiles/artscomponents/tmatrix/TestTMatrix.aligned.ssdREFERENCE.xml, TestTMatrix.random.ssdREFERENCE.xml: Updated reference data according to changed refindex data. 2016-03-12 Patrick Eriksson * arts-2-3-462 * MC now works with scat data having a single temperature. * src/montecarlo.cc (opt_propExtract,pha_mat_singleExtract): Part for PTYPE_HORIZ_AL now handles also single scat data with a single temperature. * src/m_tmatrix.cc (scat_data_singleTmatrix): Give error if azimuth grid is empty for horisontally aligned, instead of an informative assert. * src/m_montecarlo.cc (MCGeneral): Added checks of scat_data_mono, that data indeed are mono and frequency fits f_grid[f_index]. 2016-03-11 Jana Mendrok * arts-2-3-461 * src/m_optproperties.cc (pha_mat_sptFromDataDOITOpt, pha_mat_sptFromMonoData, opt_prop_sptFromMonoData), src/disort.cc (phase_functionCalc): Added check that scat_data_mono is indeed mono (reduced to one freq point). * src/m_optproperties.cc (pha_mat_sptFromData, opt_prop_sptFromData): Added check that scat_data is indeed freq-dependent data, not scat_data_mono. * src/cloudbox.cc (chk_scat_data_fgrid, chk_scat_data): Sorted out the header info (csd checks for T and ang grids, not csd_fgrid). 2016-03-11 Alex Bobryshev * arts-2-3-460 * controlfiles/instruments/metmm/README: Readme file contains changes for the line parameters of 183-GHz line, as described in Payne et al, 2008, compared to HITRAN-2012. * controlfiles/instruments/metmm/abs_lines_metmm.xml.gz, * controlfiles/instruments/metmm/TestMetMM.arts, * controlfiles/instruments/metmm/ybatchREFERENCE.xml: abs_lines_metmm.xml.gz is a crop from HITRAN-2012 catalogue with modified line parameters of 183-GHz line. I also change the range of line stored in abs_lines_metmm.xml.gz to [0-1000e9 GHz]. Changed the reference file to correspond to the new changes. 2016-03-11 Simon Pfreundschuh * arts-2-3-460 Removed sstream.h file and dependencies. The file was included as a guard for VERY old compilers not supporting the standard headers. However, since streambuf.h is not included in ARTS this cannot have worked, as far as I can see. * config.h.cmake: Removed HAVE_SSTREAM macro. * src/iotraits.h: Removed file. * src/sstream.h: Removed file included from sstream.hh * src/legendre.cc: Removed sstream.h include macro. * src/m_basic_types.h: Removed sstream.h include macro. * src/mc_antenna.cc: Removed sstream.h include macro. * src/mystring.h: Removed sstream.h include macro. * src/montecarlo.cc: Removed sstream.h include macro. * doc/doxygen/Doxyfile.in: Removed sstream.h from REMOVE declaration. 2016-03-11 Simon Pfreundschuh * arts-2-3-459 * src/matpackI.cc (mult): Eliminated corner case when multiplying a transposed matrix with another matrix that has only one column. * src/test_matpack.cc (test_matrix_multiplication): Fixed bug in tests that discarded error. 2016-03-10 Jana Mendrok * arts-2-3-458 * src/m_optproperties.cc (opt_prop_sptFromMonoData): Like the other methods, check T interpolation grid before trying to determine gridpos and interpweights, and give proper error message when fails. Found by Patrick. 2016-03-09 Jana Mendrok * arts-2-3-457 * src/m_optproperties.cc (pha_mat_sptFromData): Fixed T-handling to be consistent with all other pha_mat_spt* and opt_prop_spt* methods, ie skip T-interpolation when only single T given. (opt_prop_sptFromData): Bugfix in derermining number of scatt elems per each species. 2016-03-09 Jana Mendrok * arts-2-3-456 * src/m_disort.cc (DisortCalc): Bugfix of phase_function container sizing (mixed up sizings for old and new versions). 2016-03-09 Oliver Lemke * arts-2-3-455 * src/m_append.h: Allow appending a Matrix or a Vector to an empty Matrix. Feature requested by Jana. 2016-03-08 Jana Mendrok * arts-2-3-454 Added temperature and scat angle grid interpolation of phase matrix for Disort data prep. So far this is experimental, hence implemented as additional option. So far previous state remains the default. * src/disort.cc, disort.h (phase_functionCalc2, pmomCalc2): These methods hold the altyernative phase matrix / phase function handling. phase_functionCalc2 applies scat data interpolation methods developed for DOIT and consistent with extinction/absorption derivation methods applied by dtauc_ssalbCalc, namely spt_calc_agenda, opt_prop_part_agenda, and pha_mat_sptFromMonoData. (dtauc_ssalbCalc): Remove implicit assumption of cloudbox_limits[0]==0 (not a critical issue for now, where we disallow lower cloudbox limit anywhere else but at lowest atm level. but beter to avoid future confusions...). * src/m_disort.cc (DisortCalc): Added T- & data_za_grid-interpolation option for phase matrix as alternative. Removed doit_i_field initialization, instead have it as input initialized by DisortInit. Extend thread-safe region (new phase matrix methods make changes to variables passed into disort, hence not only disort itself but also these modification parts need to be encapsulated.); later on try to reduce this region as far as possible. Moved data_za_grid identity check from DoitInit to here as this requirement depends on which phase matrix handling method is applied. * src/m_optproperties.cc (pha_mat_sptFromData): Bugfix. pha_mat_spt need to be flat scat elem indexed! (pha_mat_sptFromMonoData): Bugfix. Actually use pha_mat_data of different temperature grid points in transformation to lab coord system before temperature interpolation. * src/m_doit.cc (doit_i_fieldSetClearsky): Check that cloudbox_on, else this does not need to be performed at all. Additional cosmetics. * src/methods.cc (DisortCalc, doit_i_fieldSetClearsky): Adapted to changes above. * src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields), src/optproperties.cc (pha_matTransform): Cosmetics. * 3rdparty/disort1.2/DISORT.f: Increased max number of computational levels, giving more room for refined vertical grids. 2016-03-05 Patrick Eriksson * arts-2-3-453 * src/m_abs_lookup.cc (propmat_clearskyAddFromLookup): Revision of extpolfac. This did not work at all. First of all, error checks did not consider extpolfac, the value of 0.5 was hard-coded. Doc was also wrong. Now extpolfac is applied for temperature and VMR. But decided to just allow standard extrapolation for pressure and frequency, to keep things a it safer. Hopefully I got it right and there are checks now for all interpolations (there was no check for frequency part), but please feel free to double-check. * src/m_linerecord.cc (abs_linesReplaceWithLines): Commented out error if replacement_lines is empty. That error check caused me problem as I have a general file with replacement lines, but in some cases I am just interested in lines inside some narrow frequency range having no "replacement". To allow a general script for this, I had to remove the error. 2016-03-04 Alex Bobryshev * arts-2-3-452 * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts controlfiles/instruments/metmm/sensor_descriptions/ sensor_ismar_downward.arts controlfiles/instruments/metmm/sensor_descriptions/ sensor_ismar_upward.arts: Unwanted feature of freq_spacing: default value of met_mm_freq_spacing overwrote the desired met_mm_freq_num for metmm-fast-setup for channels wider than 1e9 GHz. Thus making more than one grid point per passband for fast setup. Fixed: For all files added vector "freq_spacing_tmp". This vector contains default values for "met_mm_freq_spacing" for 4 met_mm_accuracy setups. * controlfiles/instruments/metmm/sensor_descriptions/sensor_saphir.arts Added new sensor setup. Channel definitions taken from https://megha-tropiques.cnes.fr, The PDF-document-name: 2013_01_17_Level-1productdef_ED3rev4 The viewing angles are from h5-file L1A2 v1.07 // group attributes: 2016-03-03 Oliver Lemke * arts-2-3-451 * src/disort.cc, src/m_disort.cc: Put disort fortran calls inside critical regions. Fortran code is in its current state not thread-safe. 2016-02-26 Oliver Lemke * arts-2-3-450 * src/continua.cc: Slightly lower upper boundary N2N2_N2F_ckd_mt_250_v2 from 2710.466309 to 2710.45 for CKD_mt_250_CIAfun_n2 continuum to avoid possible out-of-bounds array access in XINT_FUN. Bug reported by Mareike Burba. 2016-02-24 Oliver Lemke * arts-2-3-449 * src/m_tmatrix.cc (scat_data_singleTmatrix): Add check for horizontally-aligned particles that the azimuth grid starts at 0 and ends at 180. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Change azimuth grid from 0-360 to 0-180 for aligned particles. * controlfiles/artscomponents/tmatrix/TestTMatrix.aligned.ssdREFERENCE.xml: Updated. 2016-02-23 Oliver Lemke * arts-2-3-448 * Known issue: TestTMatrix.arts currently fails due to new check in reading routine of SingleScatteringData. aa grid must end at 180 for horizontally aligned particles, but currently goes up to 360. Solution to be discussed. * src/cloudbox.{cc,h} (chk_scat_data): Split into two functions (c_s_d and chk_scat_data_fgrid). * src/m_cloudbox.cc (ScatElementsPndAndScatAdd, ScatSpeciesPndAndScatAdd, ScatElementsToabs_speciesAdd, ScatSpeciesScatAndMetaRead): Call c_s_d_fgrid instead of c_s_d. * src/xml_io_compound_types.cc: Call check_scat_data in reading routine for SingleScatteringData. 2016-02-22 Oliver Lemke * arts-2-3-447 * 3rdparty/tmatrix/amplq.arts.f, 3rdparty/tmatrix/tmq.arts.f: Modified T-matrix version that makes the quad-precision callable as a subroutine. * 3rdparty/tmatrix/CMakeLists.txt, CMakeLists.txt, config.h.cmake: Add ENABLE_TMATRIX_QUAD option. * README: Add doc for T-matrix quad-precision. * src/main.cc: Display T-matrix precision with -v option. 2016-02-22 Jana Mendrok * arts-2-3-446 * src/m_optproperties.cc (ScatSpeciesMerge): Reset scat_meta and scat_species such that they are consistent with new, "merged" scat_data and pnd_field (they are only filled with dummy info, though. might be improved when desired.). * src/m_jacobian.cc (jacobianDoit), controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Adapt to modifications of ScatSpeciesMerge. * src/m_cloudbox.cc (pnd_fieldZero): Do not overwrite scat_data with dummy data if scat_data is present. (pnd_fieldCalcFromscat_speciesFields): Throw error when trying to calc pnd from already "merged" particle data. * src/m_basic_types.h: Added ArrayOfArrayOfSingleScatteringData and ArrayOfArrayOfScatteringMetaData to nelemGet applicable types. * src/methods.cc (Select, Extract): Made available for ArrayOfArrayOfSingleScatteringData (scat_data). (scat_speciesSet): Updated outdated doc (no size selection here anymore). (ScatSpeciesMerge, pnd_fieldZero, jacobianDoit): Adapted to changes above. 2016-02-19 Jana Mendrok * arts-2-3-445 * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar_downward.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar_upward.arts: Replaced "?" with -1 in ArrayOfIndex variable freq_number setup making these setting functional. Bugfixed met_mm_freq_spacing setting (needs to have nchannels entries). * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts, controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts: Generalized met_mm_freq_spacing setting. * controlfiles/instruments/metmm/TestMetMM.arts: Include files from the common ARTS include paths, not as relative includes (the latter does not work if file/snippets copied to somewhere else or if file included by another file). 2016-02-19 Jana Mendrok * arts-2-3-444 * src/disort.cc (phase_functionCalc): Bugfix: use flat-scat-elem index for pnd_field value extraction. In layer-pfct from level-pfct averaging, made loop over angle the innermost loop avoiding re-decision on averaging approach for each angle. * src/m_disort.cc, src/disort.h: Cosmetics. 2016-02-18 Jana Mendrok * arts-2-3-443 * src/disort.cc (get_cb_inc_field), src/m_disort.cc (DisortCalc), 3rdparty/disort1.2/DISORT.f: A bit of polishing of non-iso TOA inc version: Initialize TOA inc field with NaN. Move check for invalid inc field values into DISORT and reduce check to actually applied angles (skip upwelling angle dummy values). 2016-02-17 Jana Mendrok * arts-2-3-442 * src/m_disort.cc: Bugfix non-Fortran interface of DisortCalc. 2016-02-17 Jana Mendrok * arts-2-3-441 Non-isotropic incoming radiation at DISORT-TOA functional and available option in *DisortCalc*. * src/m_disort.cc (DisortInit): Added. Disort-eqivalent to DoitInit. (DisortCalc): Adapted for possible calc of Disort-TOA non-iso incoming field and passing of cloudbox-only atm layer data to Disort. Removed a bunch of checks now performed by DisortInit as well as variables that were only needed for checks. * src/methods.cc: Updated DisortCalc doc. Added DisortInit. * src/disort.cc, disort.h (get_cb_inc_field): Added. Method that calculates top-of-cloudbox incoming rad at DISORT stream and scat_za_grid angles, to be used as DISORT non-iso TOA rad. (planck2): Removed. When needed, physics_funcs.cc planck is applied (works now that f2c is replaced by direct FORTRAN compilation). * src/disort_DISORT.h: Added qgausn_, DISORT's own gaussian quad angle calc method, to make available in ARTS. * 3rdparty/disort1.2/DISORT.f: Corrected selection of direction-corresponding non-iso TOA rad value for internal and user angle solutions. Corrected array size of input TOA rad array. * controlfiles/artscomponents/disort/TestDISORT.arts: Apply DisortInit. * src/m_doit.cc: Cosmetics. 2016-02-17 Jana Mendrok * arts-2-3-440 * src/workspace.cc (pnd_field): Added note/explanation of scat element correspondence in pnd_field and scat_data. On request of Patrick. 2016-02-17 Oliver Lemke * arts-2-3-439 * src/methods.cc, src/m_general.cc (GetEnvironmentVariable): Throw runtime error if environment variable does not exist. Add option to interpret environment variable as Index. 2016-02-16 Jana Mendrok * arts-2-3-438 * controlfiles/planetary_toolbox/includes/venus/atmo_venus.arts: Typo fix (thanks to Elisa Castelli for pointing out!). 2016-02-16 Oliver Lemke * arts-2-3-437 * 3rdparty/tmatrix/CMakeLists.txt: Only compile quad precision test files with ifort. Fixes broken build with gfortran. 2016-02-12 Jana Mendrok * arts-2-3-436 * src/m_disort.cc (DisortCalc), src/disort.cc, src/disort.h (dtauc_ssalbCalc, phase_functionCalc): Changed to work with a flexible cloudbox. DISORT calculation itself is done over the whole atmosphere, but output is only provided (and further used by ARTS) from within the cloudbox. That improves sphericity issues for slant-looking cases (it's a little slower, though - ARTS clearsky is slower than DISORT clearsky). * controlfiles/artscomponents/disort/TestDISORT.arts: Set to apply cloudboxSetAutomatically (differences to DOIT solution do indeed improve a little more. no-cloud diffs no below 0.1K). * src/m_cloudbox.cc, src/methods.cc (pnd_fieldZero): Bugfix. Do not create pnd_field covering whole atmo, but only the cloudbox. 2016-02-11 Jana Mendrok * arts-2-3-435 Added handling of non-isotropic incoming radiation at TOA in DISORT. Work in progress: ARTS interface and DISORT code done. Data preparation within ARTS pending (regards calculation of angular grid, which needs to correspond to DISORT's internal double-Gauss grid for the specified nstreams, and the incoming clearky rad at these angles (maybe we can use DoitGetIncoming for the latter?) as well as adaptation of DisortCalc to flexible cloudbox sizes). * 3rdparty/disort1.2/DISORT.f: Added option of non-isotropic incoming radiation at TOA (code copied from modified DISORT version by Suzuki & Mendrok as used in and tested with SARTre). * src/m_disort.cc (DisortCalc), src/disort_DISORT.h: Modified Fortran DISORT call interface for above feature. 2016-02-11 Jana Mendrok * arts-2-3-434 * src/m_atmosphere.cc, methods.cc (AtmFieldsFromCompact): Introduce keyword that allows to remove low-pressure atmospheric levels from the atm field data (effectively moving TOA to higher pressure). * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Apply the TOA move feature (has sufficiently small effects on radiance that no new reference data is necessary). 2016-02-11 Oliver Lemke * arts-2-3-433 * 3rdparty/tmatrix/amplq.lp.f, 3rdparty/tmatrix/amplq.par.f, 3rdparty/tmatrix/lpq.f, 3rdparty/tmatrix/tmq.lp.f, 3rdparty/tmatrix/tmq.par.f: Add tmatrix quadprecision sources. * 3rdparty/tmatrix/CMakeLists.txt: Add targets matrix_tmq and tmatrix_amplq to build quadprecision reference calculation executables. * 3rdparty/tmatrix/tmatrix_amplq.ref, 3rdparty/tmatrix/tmatrix_tmq.ref: Reference results. 2016-02-10 Jana Mendrok * arts-2-3-432 * controlfiles/artscomponents/disort/TestDISORT.arts: Complete and functional DISORT test case. Using a copy of doit/TestDOITFromIndividualFields.arts adapted to current DisortCalc restrictions as well as DOIT output as reference. * controlfiles/artscomponents/disort/indivfieldsatmo_setup.arts: Added. Separated case setup from calculation itself (when DisortCalc restrictions on scatt element format is removed, remove this file, too, and use the original one from doit/ folder). * controlfiles/artscomponents/disort/yREFERENCEfromDOIT.y.xml: Added. Reference results (from an equivalent DOIT calc). * controlfiles/artscomponents/disort/scat_data_disort.xml: Removed. Was not used anymore anyways. Use sing scatt data from testdata/, commonly used by several scatt solver tests. * controlfiles/CMakeLists.txt: Switched on DISORT test as regular test case (fast; only if fortran enabled). 2016-02-09 Jana Mendrok * arts-2-3-431 More bugfixing in DISORT related code. Now DisortCalc seems to work properly. * src/disort.cc (phase_functionCalc): Layer averaged (bulk) phase function from averaging of scat. coeff. weighted phase function (i.e. (bulk) scattering function), not plain averaging of phase function itself. Equivalently to layer optical depth and sing. scat. albedo provided by dtauc_ssalbCalc, output phase_function in DISORT-type layer oder (from TOA to BOA). (pmomCalc): Remove layer re-assignments of pmom as phase_fucntion is coming in in already correctly assigned order. This fixed an assignment mismatch for scattering-free layers. * src/m_disort.cc (DisortCalc): Added assert in case of inconsistent pfct and ssalb (pfct can't be 0 when ssalb is non-zero). Removed "Don't use this WSM" warning. Some code cleaning. * src/methods.cc: Updated DisortCalc disclaimer. Spellfixes. * 3rdparty/disort1.2/DISORT.f: Removed unsuppressable header printing (in future govern this by ARTS verbosity level?). 2016-02-08 Richard Larsson * arts-2-3-430 Added along-beam-path flux calculations. This is analytical but only for iyEmissionStandard. * src/constants.cc: Added FLUX_MAINTAG. * src/jacobian.{h,cc}: (get_pointers_for_analytical_jacobians) now shows if flux_i is intended target by finding FLUX_MAINTAG in jacobian_quantities. * src/m_rte.cc: Added for_flux array of index. This sets ppath distance to 1.0 for call to (get_diydx). * src/m_transmitter.cc: Added fake_for_flux array of index. If any is true this code throws a runtime_error. * src/rte.{cc,h}: (get_ppath_pmat_and_tmat) now takes for_flux. This sets dppath_ext_dx to negative ppath_ext, and dppath_nlte_source_dx to zero. Also, (get_ppath_trans_and_dppath_trans_dx) now takes for_flux. This sets the derivative to not multiply by lstep (in the end); no changes were made to (ext2trans_and_ext2dtrans_dx) so here the derivative is divided by ppath.lstep[ip-1]. * src/m{_jacobian,ethods}.cc: Added (jacobianAddBeamFlux). 2016-02-08 Oliver Lemke * arts-2-3-429 * m_disort.cc (DisortCalc): Add new argument to function definition. Fixes build if Fortran is disabled. 2016-02-07 Jana Mendrok * arts-2-3-428 * controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts: Undo accidential setup change (fixes check fail). * doc/uguide/scattering.tex: Update for WSM DoitAngularGridsSet renaming in 2-3-424. 2016-02-07 Jana Mendrok * arts-2-3-427 Some bugfixes in data prep for DISORT calcs. Now nadir-view to BB surface difference to DOIT is below 1K. 50deg off-nadir still off by several K. :-/ * src/disort.cc (dtauc_ssalbCalc): For tau don't only add up gas abs and particle ext, not particle abs. For scatt albedo do add gas abs to particle abs in denominator. * src/m_disort.cc, src/methods.cc (DisortCalc): De-hardcoded number of streams; now promoted to interface parameter. Throw error in case of uneven number of streams (else DISORT itself will). 2016-02-06 Richard Larsson * arts-2-3-426 * src/zeeman.cc (set_magnetic_parameters): Found case of |x|>1 in acos(x). The only way create |x|>1 was through numerical drifts. This means nan-output. Set test to ensure |x|<1, which if broken gives eta=0 degrees. (Having x close to unity means theta is 90 degrees so eta cannot matter.) 2016-02-04 Oliver Lemke * arts-2-3-425 * CMakeLists.txt, CHANGES-2.3, README: Don't enable NetCDF support by default. It's very limited and hardly used. Can be enabled if needed with a cmake option. * src/CMakeLists.txt: Only add NetCDF source files to artscore lib if enabled. * src/methods.cc: Don't mask % with \. * src/m_tmatrix.cc (scat_data_singleTmatrix): Add two explicit casts to Numeric to avoid compiler warning. 2016-02-01 Jana Mendrok * arts-2-3-424 Trying to make ARTS-DISORT work somewhat properly, closing a couple of traps and loopholes, fixing bugs. * src/m_disort.cc (DisortCalc): Replaced surface_emissivity_field with surface_scalar_reflectivity; lat/lon dependence wasn't used anyways, now allowing for frequency dependent surface reflectivity. Bit of restructuring code. Checks for only p20-type particles and identical scattering grids added. Both are implicitly assumed by the code, but weren't checked potentially causing significant errors. Angle grid size check added (see DOAngularGridsSet below), allowing only even numbers (DISORT can not really handle 90deg polar angles, so we should avoid them). Changed from using isotropic incoming rad at TOA to blackbody source cosmic background temp at TOA (both are possible. but setting TOA emisivity to 0 seemed dangerous as it potentially causes the TOA boundary to reflect. though that's not considered in the DISORT version we use so far). Bugfix in assigning DISORT output to doit_i_field levels. * src/disort.cc (phase_functionCalc): Calc scat coef only once for each atm level (DISORT handling only p20, i.e. scat coef independent of polar angle). Bugfix: loop over number of scatt elements of each species. This fixes the non-normalization complaints of pmomCalc. Moved pfct normalization with scat coef outside of sum-over-scatelements loops. Bugfix: layer-averaged pfct shouldn't become 0 when only one of the bounding levels' pfct is 0 (there are actually particles in this layer, which shouldn't be ignored!), hence take average in case of both given, take that one that's non-zero if only one is and only set 0 when both are zero. FIXME: this might have a corresponding unsuitable setting of layer single scatt albedo (and layer optical depth?) - dtauc_ssalbCalc check ToBeDone! (pmomCalc): Throw error if pfct normalization deviates more than 50% (than it's very likely a bug). Relax warning-level accuracy check of pfct normalization (with linear interpolation 1e-4 accuracy is only reached for Rayleigh particles), push warning back to out2 and renormalize pfct to 2. * 3rdparty/disort1.2/DISORT.f: Increased number of processable (output) polar angles 100->1000. Replaced Claudia's fix of planck emission within wavelength range for monochromatic case by separate monochromatic planck emission subroutine (PLK) using current ARTS constants (unfortunately, we can't use the C++ ARTS settings directly, but have to use a copy here in FORTRAN code), fixing unit consistency issues. * 3rdparty/disort1.2/ErrPack.f: More verbose wrong-dimension statements: tell current dimension setting in addition to required one). * src/m_doit.cc (DOAngularGridsSet): Renamed from DoitAngularGridsSet since WSM is also used for creating DISORT output grid. Moved grid size checks from here into solver-specific methods since requirements are solver-specific. Allow single-element azimuth grid as this is not used/required for DISORT. Make empty za_opt_file the default. (DoitInit): Moved check of sufficient angular grid resolution for DOIT here. (doit_i_fieldSetFromPrecalc, doit_i_fieldSetClearsky): Added checks for doit_is_initialized. * src/workspace.cc: Removed surface_emissivity_DISORT. Spell fixes. * src/m_tmatrix.cc (scat_data_singleTmatrix), src/tmatrix.cc (calcSingleScatteringDataProperties): Be more user-friendly: Introduced flag 'robust' for continuous calcs in case of individual fails and 'quiet' to switch on/off T-matrix' own screen output (e.g. for debugging). Defaults remains with quiet T-Matrix and failing all if anything fails. In any case, be more verbose on what failed. * 3rdparty/tmatrix/tmd.par.f: Increase NPN1 parameter, allowing more convergence iterations. * src/m_atmosphere.cc (MagRawRead, WindRawRead): Adapted convention on expected file names (adding 'mag_' and 'wind_' to allow for common basename for all atm data). * src/cloudbox.cc (chk_pndsum): Push back warning to out2, point out scat species concerned. * src/tmatrix.h, src/math_funcs.cc, Cosmetics. * src/methods.cc: Bit of alphabetic re-sorting. Expanded DisortCalc description. Adapt DOAngularGridsSet description. Adapted interfaces according to changes above (DisortCalc, DOAngularGridsSet, doit_i_fieldSetFromPrecalc, doit_i_fieldSetClearsky, scat_data_singleTmatrix). * controlfiles/artscomponents/disort/TestDISORT.arts: More or less complete redo of test case, considering limitations of DISORT and its ARTS implementation (only use type 20 particles, all scat data given on identical angular grids, ...). Similar to doit/TestDOITFromIndividualFields.arts. Work in progress. * controlfiles/artscomponents/doit/doit_calc.arts, doit_setup.arts: Move iy_unit setting from doit_calc to doit_setup. Cosmetics. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts:' Moved setup into separate controlfile for re-use with other cases (e.g. consistent scatt solver comparisons). * controlfiles/artscomponents/doit/indivfieldsatmo_setup.arts: Added. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: Adapted to WSM DOAngularGridsSet renaming. * controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/instruments/metmm/TestMetMM.arts, controlfiles/artscomponents/linemixing/TestLineMixing.arts, controlfiles/artscomponents/zeeman/TestZeeman.arts, controlfiles/artscomponents/zeeman/TestZeemanPreCalc.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeemanPreCalc_50_to_70_GHz.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_GHz.arts: Cosmetics. Spell fixes. 2016-01-27 Oliver Lemke * arts-2-3-423 * controlfiles/artscomponents/disort/scat_data_disort.xml: Convert to UTF-8. 2016-01-26 Oliver Lemke * arts-2-3-422 * src/test_propmat_partials.cc: Replace pow10(p) with pow(10., p). pow10 is a GNU extension and not available on certain operating systems / compilers. 2016-01-22 Jana Mendrok * arts-2-3-421 * src/m_tmatrix.cc (scat_data_singleTmatrix): Replace identity comparisons of numerics with same-within-epsilon comparison. * src/check_input.cc, m_atmosphere.cc, m_tmatrix.cc: Sorted include statements in header for better overview (assuming order doesn't matter for functionality...). 2016-01-21 Jana Mendrok * arts-2-3-420 * src/m_tmatrix.cc (scat_data_singleTmatrix): Slight reorganiosation of code. Added check za_grid to fulfills tmatrix' equidistance requirement for randomly oriented particles. Set aa_grid as empty for randomly oriented particles. * src/tmatrix.cc (calcSingleScatteringDataProperties): Fixed ssd.abs_vec resizing bug. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Added randomly oriented particle test case. * controlfiles/artscomponents/tmatrix/TestTMatrix.random.ssdREFERENCE.xml: Added. Reference data of randomly oriented particle. * controlfiles/artscomponents/tmatrix/TestTMatrix.aligned.ssdREFERENCE.xml: Renamed from TestTMatrix.ssdREFERENCE.xml. * 3rdparty/tmatrix/ampld.arts.f: Spellfixes. Added ARTS (in addition to PyARTS) to header info. 2016-01-21 Richard Larsson * arts-2-3-419 * src/absorption.cc: Fix for workaround. When voigt kuntz6 is the line shape, then phase must be zero or we can end up with 0*nan in a later calculations. Bug found and reported by Lukas. Function affected: (xsec_species_line_mixing_wrapper) * src/jacobian.cc: Added commentary on jacobian solver. * src/rte.cc: Updated comments for species tags. 2016-01-20 Oliver Lemke * arts-2-3-418 * CMakeLists.txt: Add support for Intel Fortran. Ignore warning 1682 with Intel C++ compiler. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/fastem, controlfiles/artscomponents/refice: Add simple fastem and refice test cases. Main purpose is to ensure the Fortran interface is working as expected. Note on refice (Warren84): While fastem and tmatrix results are basically identical between gfortran and Intel compiler, strangely the refice code gives a difference of ~0.04 for the real part (value is around 1.8) in this test case. This needs further investigation because at this point it is not clear which compiler is better or worse. * controlfiles/artscomponents/tmatrix/TestTmatrix.arts: Read reference refractive index from file for consistency check of tmatrix output. Compare SingleScatteringData against reference file. * src/m_refraction.cc (complex_refr_indexIceWarren84): Disable OpenMP in loop (for now) to resolve segfault with Intel Fortran. * src/parameters.cc (get_parameters): Don't crash if an empty "" commandline argument is passed to arts. Fixes bug reported by Lukas. * src/methods.cc, src/m_basic_types.cc: Add Compare functions for SingleScatteringData and Tensor5. 2016-01-20 Jana Mendrok * arts-2-3-417 * src/tmatrix.cc: Removed all wavelength related unit conversions before and after tmatrix fortran code calls as well as all references to microns units. Mishchenko's tmatrix code does NOT require size and/or wavelength in microns, just consistent units of both (i.e., ARTS convention of SI unit m for both is fine). * src/m_tmatrix.cc: Removed m->um conversion when calling calcSingleScatteringDataProperties. Spell fixes: ngds->ndgs, meat->meta. * src/methods.cc (scat_data_singleTmatrix): Renamed ngds to ndgs for consistency with original tmatrix. Added explicit unit info for diameter_volume_equ input parameter. * 3rdparty/tmatrix/ampld.arts.f: Formatting fixed. 2016-01-18 Jana Mendrok * arts-2-3-416 * src/m_cloudbox.cc (ScatSpeciesExtendTemperature): Skip extending when only one T_grid point given. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Examplary apply SSD T-extension for cloud ice (actually doesn't have any affect here as extension is actually skipped due to single T_grid point in input SSD; but still okayish for demonstrating usage. in future would be better to have T-dependent data applied here.). * src/methods.cc (ScatSpeciesExtendTemperature): Documentation added. 2016-01-18 Jana Mendrok * arts-2-3-415 * src/m_cloudbox.cc, methods.cc: Added WSM ScatSpeciesExtendTemperature to extend single scattering data temperature range. Work in progress! Not tested yet. No doc yet. 2016-01-18 Richard Larsson * arts-2-3-414 * src/m_jacobians.cc,methods.cc: Fix for big bug I introduced unwittingly. I had mistakenly assumed that (jacobianAddAbsSpecies) was to calculate atmospheric species and not species tags. Now, the method takes the input parameter for_species_tag to work on species tags as in the past. When this evaluates true, the old behavior is returned. When it evaluates true, then new behavior of looking for atmospheric species takes effect. * src/jacobian.cc: Fix check and throws error when appropriate in (get_pointers_for_analytical_jacobians). * src/m_abs_lookup.cc: (abs_speciesAdd2) called jacobianAddAbsSpecies manually. So it calls it with default behavior as before, for_species_tag=1. 2016-01-18 Oliver Lemke * arts-2-3-413 * src/matpackII.cc (Sparse::list_elements): Remove 'it' as first argument in for loop to avoid statement with no effect warning. * 3rdparty/Eigen/src/Core/products/TriangularSolverMatrix.h (triangular_solve_matrix): Avoid compiler warning by not shadowing a local variable with another. * 3rdparty/Eigen/src/SparseCore/AmbiVector.h, Add explicit casts to size_t and Index to avoid implicit type conversion warnings. * 3rdparty/Eigen/src/SparseCore/SparseView.h (SparseView::SparseView): Fix compiler warnings by not shadowing member variables with function parameters in constructor. 2016-01-18 Patrick Eriksson * arts-2-3-412 * controlfiles/general/agendas.arts: After email from Elisa, revised agenda templates for refractive index of air. Two ones were wrong. Added Ignore(rtp_vmr) to refr_index_air_agenda__GasInfraredEarth. And Ignore(rtp_pressure) and Ignore(rtp_temperature) to refr_index_air_agenda__FreeElectrons. 2016-01-13 Oliver Lemke * arts-2-3-411 * README: Added lapack to prerequisites. * controlfiles/artscomponents/montecarlo/mc_incoming.xml: Removed unused file. 2016-01-13 Oliver Lemke * arts-2-3-410 * src/lin_alg.cc: Replaced accidentally left in test value for memory allocation of 'work' variable with correct value (lwork). 2016-01-12 Simon Pfreundschuh * arts-2-3-409 * src/lin_alg.cc: Fixed memory allocation error handling. 2016-01-12 Simon Pfreundschuh * arts-2-3-408 * src/lin_alg.cc: Added error control for memory allocation and inverse computation. Removed block size query from inv(...) function. * ext/*: Moved Eigen library to 3rdparty folder. * src/CMakeLists.txt: Changed include path for Eigen library. * src/matpackII.cc: Added missing returns in operator *=, /=, +=, -=. 2016-01-12 Richard Larsson * arts-2-3-407 Consolidation of jacobian work. Old analytical methods no longer available in clearsky calculations. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Added unphysical transmission test to this file. Just so the code gets activated. * doc/uguide/references.bib: Added a reference to the matrix derivation that is in use by the jacobian calculations. * doc/uguide/wfuns.tex: Changed text to reflect changes in jacobian. Comments appreciated here. Still do not know what level to put discussions in user guide. For instance, now I refer to the theory guide for several expressions. Expecially, the temperature subsection and non-LTE should probably be improved. It is difficult to just add non-LTE to the text... * src/{absorption.h,lineshapes,cc}: Name change to fit text better. Only one variable. * src/m_jacobian.cc: Removed "from propmat" as an option. This is now the new "analytical". Old analytical no longer possible to activate. * src/m_transmitter.cc: Changed to transmission2 as default. Old transmission removed. * src/methods.cc: Reflects changes above. 2016-01-11 Simon Pfreundschuh * arts-2-3-406 * oem.* Added function for the computation of the averaging kernel. * m_oem.cc Changed type of covmat_sx_inv to sparse. * workspace.cc Changed type of covmat_sx_inv to sparse. 2016-01-08 Patrick Eriksson * arts-2-3-405 * src/workspace.cc: ppath_stepRefractionEuler was corrected to ppath_stepRefractionBasic.And moved covmat_sx_inv to correct place, alphabetically. 2016-01-08 Simon Pfreundschuh * arts-2-3-404 * doc/uguide/matrix_vector.tex: Updated Sparse section. 2016-01-08 Simon Pfreundschuh * arts-2-3-403 * src/CMakeLists.txt: Added OpenMP flag for timer class and removed oem.cc from compilation files. * src/matpackII.*: Renamed identity matrix function to id_mat(...). Implemented operators *=, /=, +=, -= in order to generalize the code written for dense matrices. * src/m_oem.cc: Made the oem(...) function a template and called it oem_template(...) to avoid code duplication. Added wrapper oem(...) that instantiates the template. * src/m_sensor.cc: Adapted call to sparse identity matrix. * src/methods.cc: Added SparseIdentityMatrix function. * src/oem.*: Rewrote oem_cost_y as function template. * src/test_sparse.*: Added tests for operators *=, /=, +=, -=. * src/workspace.cc: Changed types of measurement covariance matrices. 2016-01-08 Lukas Kluft * arts-2-3-402 * src/m_sensor.cc (backend_channel_responseGaussian): fixed indexing. 2016-01-07 Simon Pfreundschuh * arts-2-3-401 * src/CMakeLists.txt: Added OpenMP flag for timer class and removed oem.cc from compilation files. * src/matpackII.*: Added const classifier to Matrix() * src/oem.*: Added templates to interface functions oem_levenberg_marquardt(...) and oem_gauss_newton(...). Adapted NonLinearOEM class. * src/test_oem.cc: Added tests for OEM with sparse matrices. * src/timings.h: Added some comments. 2016-01-06 Simon Pfreundschuh * arts-2-3-400 * src/CMakeLists.txt: Removed gfortran library relic. 2016-01-06 Simon Pfreundschuh * arts-2-3-399 * ext/Eigen/*: Removed unneeded files from library. * src/matpackII.cc: Changed Eigen includes to Core modules. * src/matpackII.cc: Fixed warnings due to implicit conversion of indices. * src/test_sparse.cc: Added missing return statement to test_xml_io(...). 2016-01-06 Simon Pfreundschuh * arts-2-3-398 * ext/Eigen/*: Added Eigen headers used for sparse arithmetic. * src/CMakeLists.txt: Added system include for Eigen and dependencies of test_sparse.cc. * src/matpackI.h: Added dense-sparse and sparse-dense multiplication to friends. * src/matpackI.cc: Fixed corner case bug in matrix multiplication. * src/matpackII.*: Rewrote sparse matrix algebra using Eigen. * src/test_sparse.cc: Added randomized testing for all functions of the Sparse class. * src/test_utils.*: Added utility functions for sparse matrices. * src/xml_io_basic_types.cc: Adapted writing of xml files. * src/m_sensor.cc: Replaced make_I(...) by identity(...). 2016-01-04 Richard Larsson * arts-2-3-397 * src/{{m_,}zeeman.cc,zeeman.h}: Fix for bug with several speceis tags? This should allow "O2-Z-66,O2-Z-68" in the same tag. Before, this was asserted away. 2015-12-18 Richard Larsson * arts-2-3-396 * src/m_rte.cc: Changed to adapt to changes in (get_ppath_pmat_and_tmat). Also removed error for non-LTE jacobian. This should work since a few updates (though testing is still limited). * src/rte.{cc,h}: adapted (get_ppath_pmat_and_tmat) to work with iyTransmissionStandard2. Created (get_ppath_trans2_and_dppath_trans_dx). Also needs more testing. * src/m_transmitter.cc: Uncommented (iyTransmissionStandard2). Added t_nlte_field as input. Adapted pmat and tmat calculations to work with (get_ppath_pmat_and_tmat). * src/methods.cc: Added (iyTransmissionStandard2). This will be removed after some tests confirms it works as (iyTransmissionStandard). 2015-12-17 Patrick Eriksson * arts-2-3-395 * src/m_rte.cc (iyEmissionStandard): Some more comment fixes. * src/m_transmitter.cc (iyTransmissionStandard2): Still work in progress. Presently commented out * src/rte.cc (get_ppath_pmat): (get_ppath_pmat_and_tmat): It said get_ppath_ext in an error message. * src/m_rte.cc (iyEmissionStandard): Small polishing of comments. 2015-12-17 Oliver Lemke * arts-2-3-394 * src/methods.cc, src/m_sensor.cc (backend_channel_responseGaussian): Rename backend_channel_responseGaussianMultiWidth to backend_channel_responseGaussian. * controlfiles/artscomponents/groundbased/TestGbased.arts: Adapt for changed arguments of backend_channel_responseGaussian. Added reference comparison for y1, y2, y3. * controlfiles/artscomponents/groundbased/TestGbased.y[123]REFERENCE.xml: Added reference files. * CHANGES-2.3: Note changed arguments of b_c_rGaussian. * controlfiles/artscomponents/nlte/TestNLTE.arts: Relax comparison criteria from 1e-15 to 1e-12. Test was otherwise failing with clang compiler due to slightly different numerical results. 2015-12-17 Patrick Eriksson * arts-2-3-393 * Now possible to control ndgs of Tmatrix. Default is 2, to match old hard-coded value. For particles with high axial ratio, it could help to increase ndgs. A value around 5 seems to work quite well. * src/m_tmatrix.cc (scat_data_singleTmatrix): * src/tmatrix.cc (tmatrix_random_orientation): (calcSingleScatteringDataProperties): Added ndgs. * src/m_tmatrix.cc (scat_data_singleTmatrix): Corrected spelling in an error message. * src/m_transmitter.cc (iyTransmissionStandard2): Started on new version. Work in progress ... * src/m_rte.cc (iyEmissionStandard): Just some polishing of comments and indentation. 2015-12-16 Richard Larsson * arts-2-3-392 make check-all tests mostly fixed? Memory problem... * src/m_rte.cc: No longer sets ispecies for Jacobian reasons. Still works for iy_aux reasons. * src/rte.cc: No longer care for ispecies in Jacobian part. 2015-12-16 Richard Larsson * arts-2-3-391 * src/m_rte.cc: Simplified get_diydx call to not have any "a?b:c" operations. All analytical types of derivatives are now called under the same if-statement. Moved temperature derivative of blackbody radiation into a separate function. * src/rte.cc: Removed test for setting size of *_dx functions to simplify the code (get_ppath_pmat_and_tmat). The function (get_dppath_blackrad_dt) now calculates the partial derivation of the Plack function with temperature. This is done analytically instead of by perturbation. 2015-12-16 Patrick Eriksson * arts-2-3-390 * src/m_montecarlo.cc (MCGeneral): Adopted to change below. * src/workspace.cc: Changed definition of mc_source_domain. The variable now includes an distinction between gas and particle emission, to allow that the impact of particle absorption easily can be determined. This resulted in that a different order felt more natural, withboundaries first. Surface was before last [2], it is now element [1]. 2015-12-16 Oliver Lemke * arts-2-3-389 * src/m_sensor.cc, src/methods.cc: Added backend_channel_responseGaussianMultiWidth with takes a Vector of widths, half-widths and grid spacings requested by Lukas. Could replace backend_channel_responseGaussian in the future. 2015-12-15 Patrick Eriksson * arts-2-3-388 * Summary: blackbody_radiation_agenda is removed. * doc/uguide/Figs/rte/ycalc_flow.odg: Figure updated. * doc/uguide/transmission.tex (section{Pure transmission calculations}): * doc/uguide/rte_basics.tex (subsection{Emission and absorption vectors}): * doc/uguide/rte.tex (subsection{Blackbody and cosmic background radiation}): Updated according to removal of blackbody_radiation_agenda. * controlfiles/artscomponents/clearsky/TestClearSkyTips.arts: * controlfiles/artscomponents/clearsky/TestClearSky2.arts: * controlfiles/artscomponents/clearsky/TestClearSky.arts: * controlfiles/artscomponents/clearsky/TestBatch.arts: * controlfiles/artscomponents/disort/TestDISORT.arts: * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: * controlfiles/artscomponents/doit/doit_setup.arts: * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/artscomponents/groundbased/TestFgrid.arts: * controlfiles/artscomponents/groundbased/TestWinds.arts: * controlfiles/artscomponents/groundbased/TestGbased.arts: * controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_GHz.arts: * controlfiles/artscomponents/linemixing/TestLineMixingAndZeemanPreCalc_50_to_70_GHz.arts: * controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman.arts: * controlfiles/artscomponents/linemixing/TestLineMixing.arts: * controlfiles/artscomponents/nlte/TestNLTE.arts: * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts: * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: * controlfiles/artscomponents/regrid/TestRegridFields.arts: * controlfiles/artscomponents/stokesrot/TestStokesRotation.arts: * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: * controlfiles/artscomponents/wfuns/TestWfuns.arts: * controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts: * controlfiles/artscomponents/zeeman/TestZeemanPreCalc.arts: * controlfiles/classroom_exercises/exe2_rtcalc/rtcalc.arts: * controlfiles/classroom_exercises/exe4_olr/olr.arts: * controlfiles/classroom_exercises/exe3_jacobian/jacobian.arts: * controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts: * controlfiles/instruments/hirs/TestHIRS.arts: * controlfiles/instruments/ici/TestICI_fast.arts: * controlfiles/instruments/metmm/common_metmm.arts: * controlfiles/instruments/mhs/TestMHS_generic.arts: * controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: * controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios.arts: * controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts: * controlfiles/artscomponents/absorption/TestIsoRatios.arts: * controlfiles/artscomponents/absorption/TestAbsParticle.arts: Removed declaration of blackbody_radiation_agenda. * controlfiles/general/agendas.arts: Removed definition of blackbody_radiation_agenda. * src/m_doit.cc: * src/m_fos.cc: * src/rte.h: * src/rte.cc (get_ppath_blackrad): * src/m_rte.cc (iyEmissionStandard): * src/m_surface.cc: * src/surface.h: * src/surface.cc (surface_specular_R_and_b): Removed everything around blackbody_radiation_agenda. Instead new planck function hard-coded. * controlfiles/CMakeLists.txt: * controlfiles/artscomponents/surface: Removed this folder as this test was based on the fact that blackbody_radiation could be set to T. * src/m_physics.cc (blackbody_radiationPlanck): * src/check_input.cc (chk_if_std_blackbody_agenda): Removed. Now obselete. * src/workspace.cc: Removed blackbody_radiation_agenda and blackbody_radiation. * src/agendas.cc: Removed blackbody_radiation_agenda. * src/m_physics.cc (MatrixPlanck, MatrixCBR): Now using new function below. * src/physics_funcs.cc (planck): New version of the function, handling a vector of frequencies. 2015-12-14 Oliver Lemke * arts-2-3-387 * doc/uguide/common.tex: Add macro \artsserver with ARTS web url. Add macro \artsurl to insert a link to a page on the ARTS web server. Only needs the subpath as input. Add macro \docserver. Makes it easy in the future to switch from the trunk to the stable docserver once ARTS is released. Change \builtindoc macro to use the \artsserver and \docserver macros. Fixes links still pointing to the old docserver URL at www.sat.ltu.se. Thanks Richard for reporting this issue. * doc/uguide/arts_developer.tex, doc/uguide/arts_theory.tex, doc/uguide/arts_user.tex, doc/uguide/clouds.tex, doc/uguide/concept.tex, doc/uguide/development.tex, doc/uguide/scattering.tex: Replace all ARTS web URLs with the \artsurl macro. 2015-12-14 Richard Larsson * arts-2-3-386 * doc/uguide/rte{,_basics}.tex: Added description of how source for NLTE is defined. * doc/uguide/wfuns.tex: Added description of how Jacobian is calculated. * src/{m_jacobian,rte}.cc: Removed limitation on only VMR in "from propmat" after Patrick's update. * src/m_rte.cc: Simplified Jacobian calls. 2015-12-11 Patrick Eriksson * arts-2-3-385 * src/jacobian.cc (dxdvmrscf): New function. Very similar to *vmrunitscf* but returns the scaling factor for derivatives with respect to VMR. 2015-12-11 Richard Larsson * arts-2-3-384 * src/m_rte.cc: Simplified iyEmissionStandard to work with one general jacobian function. Might still want to simplify it more. * src/jacobian.{cc,h}: This function is (get_diydx). It works from flags sent into it. * src/rte.cc: Added some comments to functions I have created/changed. * src/methods.cc: Added comments to jacobianAddWind. 2015-12-10 Patrick Eriksson * arts-2-3-383 * src/m_rte.cc (iyEmissionStandard): Added a table to give an overview of the main internal variables, as the list now is quite long. Als a few cosmetic changes 2015-12-10 Richard Larsson * arts-2-3-382 * src/rte.cc: Did some code review and I found that polarized NLTE was treated inconsistently between (emission_rtstep) and the jacobian calculations. It was assumed that the source term is unpolarized, solving this expression for polarized terms: "iy(iv,i) = tt[i] - t(iv,i,0) * ( bbar[iv] + J_n[i] );" but if J_n is polarized, the correct expression should be "iy(iv,i) = tt[i] + tmp(i,0) * bbar[iv] + J_bar[i];", with id_mat(tmp); tmp-=t(iv,joker,joker); and mult(J_bar, tmp, J_n); This is now changed in (emission_rtstep). 2015-12-07 Richard Larsson * arts-2-3-381 * src/{m_linerecord,methods}.cc: Added abs_linesSetParameterForMatchingLines to set individual line parameters for matching lines. Also added pressure exponents to the list of supported parameters. * src/pressurebroadeningdata.{cc,h}: Added some functions to easier set parameters. 2015-12-04 Richard Larsson * arts-2-3-380 For iyEmissionStandard only now... Made a function (get_ppath_pmat_and_tmat) that replaces the combination of get_ppath_pmat, the wind correction and the transmission matrix calculations. It also takes over calculations of partial derivatives from iyEmissionStandard. This applies not only to the partial derivatives of type "from propmat" but also to "analytical" partial derivatives. Patrick, I need you to check that I am not messing something up here. In particular regarding cases where the parameter is perturbed might behave strange in an unintended manner. This all results in small changes in the behaviour of "analytical" for fully polarized signals (order of magnitude, the change is on a level of 1e-5 in my simple tests.). The tests in wfun still works. * src/jacobian.cc: Changed an error call because it helped me debug. * src/m_rte.cc: get_ppath_pmat and tmat calculations replaced by single function call. Removed all calculations of shifted propagation matrices. One problem remains: temperature derivative of the blackbody radiation is still calculated as before. I think this should be made part of the call to (get_ppath_blackrad) so we can use pure analytical derivatives. The Jacobian calculations are now done on the percalculated internal partial derivatives instead of estimating the internal partial derivative in the code blocks. In essence, this means that the expressions for the fields and for species absorption should be identical, so this should perhaps change to make the code cleaner. Temperature still need some more treatment due to blackbody partial derivative with temperature. (Wind as well, due to blackbody frequency partial derivatives, but we did not care for that so far.) This should perhaps be treated as an "extra" for temperature as I treat NLTE in the Jacobian parts? * src/rte.{cc,h}: Commented some code away since it just wasted cycles. (ext2trans_and_ext2dtrans_dx) In (get_ppath_pmat), I forgot to test if there is nlte in the nlte partial derivative calculations... Added (get_ppath_pmat_and_tmat) as pretty much the same as (get_ppath_pmat) but connecting more parts together. (get_ppath_trans_and_dppath_trans_dx) No longer has to act on ppd since dppath_ext_dx should be full now. Might introduce problems with "perturbation" calculations... 2015-12-02 Oliver Lemke * arts-2-3-379 * src/m_general.cc, src/methods.cc: New WSM GetEnvironmentVariable. It copies the contents of an environment variable to an ARTS String. 2015-12-01 Oliver Lemke * arts-2-3-378 * src/m_abs_lookup.cc (abs_lookupSetupBatch): Add additional check and runtime error if pressure grids in batch_atm_fields_compact are not strictly decreasing. Fixes assertion failure reported by Alex. 2015-12-01 Oliver Lemke * arts-2-3-377 * CMakeLists.txt: Fix warning caused by mismatching endif. 2015-12-01 Simon Pfreundschuh * arts-2-3-376 * CMakeLists.txt: Added LAPACK requirement * src/CMakeLists.txt: Removed gfortran dependence for test_linalg * lin_alg.cc: LAPACK bindings for ludcmp(...), lubacksub(...), and inv(...). 2015-11-30 Richard Larsson * arts-2-3-375 Added NLTE temperatures to Jacobian calculations. Will just throw an error for now. This is fixed when we have moved some or most of the jacobian calculations away from iy* functions. (The code in m_rte.cc is there so we do not miss something in the future. The code has not been thouroughly tested and is not expected to work without some more changes. For instance, Wind does not work now since frequency derivative of the Planck function is never multiplied with the wind/frequency derivative.) * rte.{cc,h}: Now returns dppath_nlte_source_dx from get_ppath_pmat. This serves as the derivative with regards to any parameter for Jn in iy = t*iy + (1-t)* ( B + inv(extbar)*Jn ) from emission_rtstep. * src/m_{cloudradar,fos,transmitter}.cc: Gets dummy nlte variable. * src/{partial_derivatives.{cc,h},constants.cc}: Set NLTE_MAINTAG and fixed some keywording. * src/m_jacobian.cc: Added jacobianAddNLTETemperature. Will fail in m_rte.cc due to now allowing NLTE in calculations with jacobian yet. * m_rte.cc: Changes in iyEmissionStandard. sibi variable now calculated with nlte effects considered. sibi is the term that is multiplied with dt/dx, which means -inv(extbar)*Jn following emission_rtstep. Also in each of the different jacobian calculations, the same term of T0 (1-t) d/dx(inv(extbar)*Jn) is added, where T0 is the cumulative transmission to that point. That is with this equation d/dx(inv(extbar)*Jn)=inv(extbar)(dJn/dx-dextbar/dx inv(extbar)Jn) [note that order matters for matrix multiplications]. The implementation should be identical to the implementation for the B-term as has been done for temperature jacobian since before. I have to add this term to all jacobians since source is a function of more inputs under NLTE. 2015-11-30 Oliver Lemke * arts-2-3-374 * src/oem.cc, src/timings.h: Include arts_omp.h instead of omp.h. Fixes compilation with clang. * src/CMakeLists.txt: Remove forced dependency on gfortran library. 2015-11-28 Simon Pfreundschuh * arts-2-3-373 * src/test_matpack.cc: Added explicit conversion in test42(...) to avoid warning during compilation. Also added missing return statement for test_matrix_vector_multiplication(). 2015-11-28 Simon Pfreundschuh * arts-2-3-372 * src/lin_alg.cc: Added changes that should have been in the previous commit. 2015-11-28 Simon Pfreundschuh * arts-2-3-371 * CMakeLists.txt: Removed LAPACK requirement. * src/lin_alg.*: Reverted ludcmp(...), lubacksub(...), and inv(...) to not use LAPACK since Hudson build failed. 2015-11-28 Simon Pfreundschuh * arts-2-3-370 * CMakeLists.txt: Added LAPACK requirement. * src/blas.h: Added declaration for dgemv_ * src/lapack.h: Header file with LAPACK function declarations. * src/lin_alg.*: Changed ludcmp(...), lubacksub(...), solve(...) and inv(...) to use LAPACK. This involved changing the ludcmp interface to require a reference to a Matrix object to be passed instead of a MatrixView. * src/matpackI.h: Added mult(...), mult_general(...), ludcmp(...), lubacksub(...) and inv(...) to the friends of the ConstMatrixView class * src/matpackI.cc: Changed matrix vector multiplication to use BLAS. * src/oem.*: Added more detailed timings. * src/test_linalg.cc: Added randomized testing for solve(...) and inv(...) * src/test_matpack.cc: Changed name of maximum_err(...) function. * src/test_oem.cc: Changed name of maximum_err(...) function. * src/test_utils.cc: Changed name of maximum_err(...) function to get_maximum_error(...) and added function to create random, positive definite matrices. * src/timings.*: Timings class that holds a set of timers to simplify profiling. 2015-11-26 Richard Larsson * arts-2-3-369 Added "strength" as option for "from propmat" wind jacobians. Agrees with individual components for optiomized observation directions. Speed-up setting missing: There is no reason to recalculate the dpropmat_dx for different frequency alterations. * src/jacobian.cc: Key for this is set similar to how other options (u,v,w) works. * src/m_jacobian.cc: Fixed error handling to allow setting the component. * src/rte.cc: Set how to handle the individual components. 2015-11-20 Richard Larsson * arts-2-3-368 * src/absorption.h: Declares find_broad_spec_locations so it can be used elsewhere. * src/{m_linerecord,methods}.cc: Created (abs_linesChangeParameterForMatchingLines) to easier perturb catalog parameters. Works on basis of QuantumIdentifier. For a simple usecase define and laod from xml a QI such as O2-66 TR UP J 9/1 N 9/1 LO J 10/1 N 9/1 Then calling abs_linesChangeParameterForMatchingLines(QI=QI, parameter_name="Central Frequency",change=20e3) will change the O2-66 9+ line frequency by 20 kHz. Warning: If v1=1 line is part of the catalog, then this matching will fail since it is only a partial match. Setting "loose_matching=1" will succeed, but both v1=0 and v1=1 lines will have their frequency changed in the example above. Other "parameter_name" are available as per online documentation. Also, if a relative rather than absolute change is needed, set "relative=1" in the function argument. The parameter then changes by a factor (1+change). * src/pressurebroadeningdata.{cc,h}: Added methods to perturb internal pressure broadening parameters. 2015-11-20 Richard Larsson * arts-2-3-367 * src/{absorption.cc,partial_derivatives.{cc,h}}: Bug in magnetic calculations when lines are not Zeeman affected. Fixed. * src/{methods,m_atmosphere}.cc: Added simplified method to read magnetic fields and making their grids agree to simulation grids. Did same for wind while at it. (MagRawRead) and (WindRawRead) sets wind and magnetic raw fields from basename folder. (MagFieldsCalc) and (WindFieldsCalc), or (MagFieldsCalcExpand1D) and (WindFieldsCalcExpand1D) can now be used to set the two fields. * src/workspace.cc: Added corresponding *_raw fields to the wind and magnetic fields. 2015-11-20 Oliver Lemke * arts-2-3-366 * src/m_sensor.cc (sensor_responseBackend): The check of backend_channel_response and sensor_response_f_grid only took into account the first channel in f_backend if b_c_r had only one element. * src/sensor.cc (sensor_integration_vector): Reverted back to assertions. 2015-11-19 Oliver Lemke * arts-2-3-365 * src/sensor.cc (sensor_integration_vector): Turn assertions about grid errors into runtime errors because they can be triggered by faulty user input in controlfile. * src/m_sensor.cc (sensor_responseBackend): Catch runtime error from spectrometer_matrix (passed on from sensor_integration_vector) and try to give a hint on what's wrong. 2015-11-19 Richard Larsson * arts-2-3-364 These are the last of the semi-analytical expressions that can now be found from partial derivation of the propagation matrix. * src/{jacobian,m_rte}.cc: Fixed bugs in magnetic field jacobian. * src/m_jacobian.cc: Activated from_propmat magnetic jacobians in (jacobianAddMagField). For now, perturbations are used on u, v and w components. They are very complicated to get right analytically, so some more thinking is needed. I also add analytical expressions for strength, theta, and eta components jacobians. (I tested it and found that squared strength-jacobian mostly of agrees with summed and squared u, v and w jacobians.) * src/methods.cc: Changed so magnetic jacobians take some inputs. * src/zeeman.cc: Changed to perturb for u, v and w magnetic jacobians. Will leave it as a fixme to change these to analytical expressions later. * src/partial_derivatives.{cc,h}: No magnetic calculations in the cc Added bools for easily identifying what magnetic component's derivative is calculated. 2015-11-18 Oliver Lemke * arts-2-3-363 * src/m_sensor.cc (f_gridFromSensorAMSU, f_gridFromSensorHIRS): Use nlinspace instead of linspace. The generated grid might otherwise end up one value short due to numerical inaccuracies. Fixes bug reported by Max Schaper. 2015-11-10 Richard Larsson * arts-2-3-362 * Files added under "controlfiles/*": Adds simple testcase to ensure NLTE code does not break. In slow tests. The atmosphere is not realistic. May move to fast in reduced form once more tested. * src/methods.cc: Fixed bug affecting DebRelease users due to an error of mine from before. Release users were not affected by abs_lines_per_species being passed only as output from (nlteSetByQuantumIdentifiers). * Other files altered under "src/*": Update comments on NLTE part after request by Taka and Jana. 2015-11-10 Oliver Lemke * arts-2-3-361 * src/CMakeLists.txt: Fix compilation on systems without gfortran. Removed hardcoded gfortran library from matpack link libraries. We don't want to have a hard dependency on gfortran. 2015-11-06 Richard Larsson * arts-2-3-360 * src/{{constants,m_jacobians}.cc,partial_derivatives.{h,cc}}: Added support for line mixing partial derivatives. * src/{linemixingdata.{cc,h},absorption.cc}: Added methods to calculate internal partial derivatives as a function of the catalog of choice. * sec/methods.cc: Updated documentation for (jacobianAddCatalogParameter). 2015-11-05 Lukas Kluft * arts-2-3-360 * tools/vim_syntax/update-vim-arts-syntax: Set commenstring variable to properly work with commentary.vim plugin. 2015-11-04 Richard Larsson * arts-2-3-359 * src/{linescaling.{cc,h},partial_derivatives}.cc: I forgot the NLTE implementation for central frequency changes. Now added. ARTS still will throw a fit if Jacobians are used with NLTE activated, but at least now it might work when properly implemented. 2015-11-04 Richard Larsson * arts-2-3-358 * src/methods.cc: Updated description so people know how to activate the variable. 2015-11-04 Richard Larsson * arts-2-3-357 This adds the last major catalog parameter that was missing. Remaining minor parameter is lower state energy level (which I will not add unless directly requested, because I cannot imagine wanting to directly test that parameter). * src/{absorption.{cc,h},lineshapes.cc}: Added internal partial derivative of lineshape with regards to line frequency. * src/{{constants,m_jacobians}.cc,partial_derivatives.{h,cc}}: Added support for line center partial derivatives. * sec/methods.cc: Added support for setting multiple line parameter partial derivatives for multiple lines in one command as (jacobianAddCatalogParameters). * src/linescaling.{h,cc}: Added line strength scaling derivative for reference freqeuncy. 2015-11-03 Simon Pfreundschuh * arts-2-3-356 * src/CMakeLists.txt Removed non-generic Matlab include directory and replaced it by generic one. * src/oem.* Added error codes and timing functions to OEM implementation. * src/test_oem.cc Added testing of Gain matrix for the linear case by comparison with atmlab results. * src/test_oem/test_oem.m Added Gain matrix to output values * src/test_oem/test_oem_gauss_newton.m Added Gain matrix to output values * src/test_oem/test_oem_levenberg_marquardt.m Added Gain matrix to output values 2015-11-02 Richard Larsson * arts-2-3-355 Added support for line catalog parameter partial derivatives in "from propmat". Added parameters are: reference line strength and several types of pressure broadening parameters. These can be activated using (jacobianAddCatalogParameter). I am trying to be generous in throwing my errors when the user tries to activate this for unsupported cases. Note that using a non-catalog calculation (e.g., lookup table or continua), results in a warning presently. I am wondering if this should instead result in a zero term instead? We cannot know if a line is in continuum or lookup as far as I am aware. Some growing concerns: The code is generously wasteful right now. The PropmatPartialsData class is created many times despite being identical each time, and some design decisions I have made could be improved significantly by moving some loops and identifications of partial derivative properties outside of these loops. I would be happy to have some comments on this. * src/absorption.cc: Added very bulky interface to internal line parameter derivatives. This presently wastes a lot of computing cycles. I need a more consistent way of always knowing if a line needs some calculations or not. * src/constants.cc: Following other parameters, I implemented some text strings as constants for identifying if a term is understandable or not. * src/jacobian.h: Finally needing the QuantumIdentifier's, I renamed their interface for clearer reading. * src/{m_jacobian.cc,methods.cc}: Added (jacobianAddCatalogParameter). Most tests should be clear. * src/m_rte.cc: Added interface for knowing that a parameter is another jacobian to iyEmissionStandard. This is a temporary solution as we plan to move a lot of this code soon. * src/partial_derivatives.{cc,h}: Added more inputs to the partial_derivatives functions. This is getting input-heavy. Also added tracking system for catalog parameters. * src/pressurebroadeningdata.{cc,h}: Added one function per output derivative of interest. This right now means that each pressure broadening scheme might require upwards to eight functions for the various outputs. But not all. I have gone with throwing errors generously for now. For instance, Artscat-4 broadening just says that foreign broadening is not a thing in Artscat-4, and it has no replacement for foreign broadening. The same is true for water broadening and the Artscat-3 scheme. * src/quantum.h: Added (operator==) for two quantum identifiers. Needed to ensure that we do not duplicate too many things in the (jacobianAddCatalogParameter). I might think of using it for line matching later on but I need some thinking on this first. (E.g., how should we enforce isoptopes being defined in the catalog matching?) * src/zeeman.cc: Fixed typo. 2015-10-28 Richard Larsson * arts-2-3-354 Added support for "from propmat" for wind. Note that relative errors of orders of magnitude between this method and "analytical" occurs at frequency ranges of small partial derivative values. I think this is an error in the "analytical" approach, since exactness of frequency is really important for these small values. Looking in details of the plots, when the partial derivative is increasing, the "analytical" method shows slightly lower values than "from propmat", and when the partial derivative is decreasing in value, the "analytical" method shows slightly larger values than "from propmat". This is an effect expected for numerical derivatives. Also, this shift is why orders of magntiude large relative errors occurs. At the zero-crossing, it is such that when one of the methods show a zero-value, the other is much larger/smaller. That said, I think the differences between methods are negligble when it comes to inversions. The relative errors are only large for frequency ranges where sensitivity to wind is anyways practically zero, so there is no information avalable anyways. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Added error checking for wind. * src/jacobian.{cc,h}: Fixed bug. Preliminary adding of absolute wind speed to potential wind jacobians. * src/m_jacobian.cc: (jacobianAddWind) This function now takes two additional arguments: "method" and "dfrequency". It sets the runs behavior according the these inputs. * src/m_rte.cc: (iyEmissionStandard) Calculates the frequency to wind derivate ratio. This is done since the f_grid seen by propmat is already altered by wind so internally, in propmat calulations, only the frequency derivative can be calculated. (Right now, there is no optimization for this so if several wind parameters are wanted, then several frequency derivatives are calculated, wasting cycles.) * src/methods.cc: Changed (jacobianAddWind) as above. * src/partial_derivatives.h: Small changes in internal checks which failed before when mixing different methods to create one jacobian. * src/rte.{cc,h}: Added dotprod_with_los_dWd{u,v,w} functions. * src/zeeman.cc: Fix bug where I did not support VMR calculations for Zeeman species. 2015-10-28 Alex Bobryshev * arts-2-3-353 * Updates to the setup for microwave sensors. Modify the 183 GHz line parameters in accordance with HITRAN2012 and Payne 2008. Add the line-mixing flag for O2. Change the cutoff for spectroscopy file to 700 GHz. Divide sensor description for ISMAR into two parts downward and upward looking. Recalculate the ybatchREFERENCE.xml in accordance with spectroscopy changes. * controlfiles/instruments/metmm/TestMetMM.arts: Cutoff for spectroscopy is 700 GHz. Lineshape defined per species, for O2 Fadeeva Algorithm. * controlfiles/instruments/metmm/abs_lines_metmm.xml.gz: cut from HITRAN for range 5-700 GHz * controlfiles/instruments/metmm/sensor_descriptions/ sensor_ismar_downward.arts * controlfiles/instruments/metmm/sensor_descriptions/ sensor_ismar_upwards.arts: Add matrix met_mm_available_accuracies, with selected number of frequencies per channel. 2015-10-26 Simon Pfreundschuh * arts-2-3-352 src/CMakeLists.txt Reverted some accidentally commited local changes. 2015-10-26 Simon Pfreundschuh * arts-2-3-351 * oem.* Changed GaussNewtonOEM class to NonLinearOEM class and added Levenberg-Marquardt method. Refactored the available methods. * m_oem.cc Adapted function calls to changes in OEM interface. * test_oem.cc Adapted tests to changes in OEM interface. * test_utils.* Added function to generate random positive semi-definite matrices. * test_oem/test_oem_levenberg_marquardt Changed matrix nomenclature to Sx for the state space covariance matrix. 2015-10-26 Richard Larsson * arts-2-3-350 While running NLTE code I realized a regression due to some of my changes. This update fixes that. * src/linescaling.cc: Do not allow 0 vibrational temperatures. This can cause 1/0.0, which is not a good situation to be in. Of course, very small vibrational temperatures might still cause numerical issues. * src/absorption.cc: In a recent change, I forgot to initialize the cumulative source term as zero... this is fixed. 2015-10-22 Simon Pfreundschuh * arts-2-3-349 * m_oem.cc Fixed AgendaWrapper to not overwrite Jacobian when only evaluating the forward model. * oem.* Introduced GaussNewtonOEM class for Gauss-Newton OEM. Refactored Gauss-Newton code. * test_oem/test_oem_gauss_newton.m Use normalization in when comparing to Matlab. * test_oem.cc Adapted test to changes in OEM interface. * test_utils.* Added function to add noise to vector. 2015-10-22 Richard Larsson * arts-2-3-348 Fix so that Zeeman temperature derivatives work with "from propmat". There was a very small bug in indexing. * src/partial_derivatives.cc: Changed sign to remove rather than add the phase lineshape derivatives. This is from the notion that w(z=x+iy)=F=Fa+iFb, and multiplying things with iy results in negative values. I am very much unsure where the true minus sign is supposed to be, here or in the lineshape, so that the physically correct number is returned. I choose here. * src/rte.cc: Fixed bug in indexing the Stokes order... this made the partial derivatives of the transmission wrong. * src/test_propmat_partials.cc: Added test for matrix exponent and its derivative. * src/zeeman.cc: Fix so that (dnumber_density_dt) is properly called where needed... 2015-10-22 Jana Mendrok * arts-2-3-347 WARNING: This breaks controlfiles. * src/m_refraction.cc, src/methods.cc: Renamed air refractive index methods for more clarity: refr_index_airThayer -> refr_index_airMicrowavesEarth refr_index_airMWgeneral -> refr_index_airMicrowavesGeneral refr_index_airIR -> refr_index_airInfraredEarth * src/m_refraction.cc (refr_index_airMicrowavesGeneral): Adapted N_ref of H2O to changes in refr_index_airMicrowavesEarth. * doc/uguide/refr_index.tex, doc/uguide/refr_index_theory.tex, doc/uguide/references.bib: Reflect name changes above. Replaced references to Thayer with reference to Bevis or refr_index_airMicrowavesEarth. Added Bevis lit. reference. * controlfiles/general/agendas.arts: Renamed refr_index_air_agenda predefinitions consistently with WSM name changes above. * controlfiles/artscomponents/ppath/TestPpath1D.arts, controlfiles/artscomponents/ppath/TestPpath2D.arts, controlfiles/artscomponents/ppath/TestPpath3D.arts, controlfiles/artscomponents/ppath/TestRefractPlanets.arts, controlfiles/artscomponents/radiolink/TestRadioLink.arts, controlfiles/artscomponents/radiolink/TestRadioLink2.arts, controlfiles/artscomponents/radiolink/TestRadioOccultation.arts, controlfiles/artscomponents/transmission/TestTransmission.arts, controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts, controlfiles/planetary_toolbox/includes/common/ RefractionMWgeneral.arts, makegeometry1D_refracted-air+electrons_geometrictanh.arts, makegeometry1D_refracted-air+electrons_truetanh.arts, makegeometry1D_refracted-air_geometrictanh.arts, makegeometry1D_refracted-air_truetanh.arts, makegeometry3D_refracted-air+electrons_geometrictanh.arts, makegeometry3D_refracted-air+electrons_truetanh.arts, makegeometry3D_refracted-air_geometrictanh.arts, makegeometry3D_refracted-air_truetanh.arts: Adapted to WSM and agenda predefinition name changes. * CHANGES-2.3: Documenting WSM and agenda predefinition name changes. 2015-10-22 Oliver Lemke * arts-2-3-346 * src/m_sensor.cc (f_gridMetMM): Replaced "manual" frequency sorting with more optimized STL sort algorithm after discussion with Patrick. 2015-10-21 Patrick Eriksson * arts-2-3-345 * doc/uguide/refr_index.tex (section{Gases}): Adopted, mainly changed "Thayer" with "Microwaves". * doc/uguide/refr_index_theory.tex: Commented out sub-sections on Thayer and IR parameterisations, as there is nothing new in this text not already said in on-line doc or AUG. * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Pre-defined agenda template now not used, refr_index_air_agenda set with k1, k2, and k3 matching Thayer, as reference values calculated using old refr_index_airThayer. * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/ppath/TestRefractPlanets.arts: * controlfiles/artscomponents/ppath/TestPpath3D.arts: * controlfiles/artscomponents/ppath/TestPpath2D.arts: * controlfiles/artscomponents/ppath/TestPpath1D.arts: * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: Replaced "Thayer" with "Microwaves". * controlfiles/general/agendas.arts: Replaced "Thayer" with "Microwaves" in name of predefined agendas. * src/m_refraction.cc (refr_index_airMicrowaves): New name of method below. And default values changed. On-line doc extended, including a detailed specification of source to default values. a, b and c changed to k1, k2 and k3, to follow standard nomenclature. * src/m_refraction.cc (refr_index_airThayer): Renamed, see above, 2015-10-21 Patrick Eriksson * arts-2-3-344 * src/m_montecarlo.cc (MCGeneral): Filling of mc_points changed. Before there was one count for each point evaluared in MCGeneral, but these are not just source points, also scattering points. mc_points are now just filled at the final source point, i.e. the variable shows the origin point of each "photon". The overall sum of mc_points now equals mc_iteration_count, before it was higher. 2015-10-20 Patrick Eriksson * arts-2-3-343 * src/m_rte.cc (iyMC): Adopted call of MCGeneral. * src/m_montecarlo.cc (MCGeneral): Now also returns mc_scat_order and mc_source_domain. * src/workspace.cc: Added mc_scat_order and mc_source_domain, and corrected the order among the WSV starting with mc_. 2015-10-20 Patrick Eriksson * arts-2-3-342 * src/m_oem.cc (oem): One if-statement checking x_norm was not correct. Cheers Oliver for pointing this out. 2015-10-20 Richard Larsson * arts-2-3-341 Now I consider the internal partial derivatives of temperature in working condition. At least for some uses. There can always be more bugs. Note that the test in TestWfuns still fails at 3.6105e-05 in the comparison as it stands. I am not sure why. I suspect there could be some error lingering for high altitudes. I get 4% differences between my own perturbations and partial derivatives on the line shape when pressure is low (below 1 Pa) at frequencies around sigma from a line. This is of course also where we expect there to be differences if there are any, so now I am unsure if there still is a coding error or not. * src/CMakeLists.txt: Added test for some of the internal partial derivatives. I will likely expand this test in the future when more problems occur. * src/absorption.cc: (GetLineScalingData_dT) Now outputs the derivative of the stimulated emission. Before, this caused relative errors of 1e24 (... from a small value, but it was significant for the results by about 10% of the output missing). * src/linescaling.cc: (GetLineScalingData_dT) changed as above. Also, dQ/dT is now a pseudo output of dQ/dT * 1/Q. This is a design decision I make quite frequently, since it lowers number of operations. Should perhaps fix this to either be a consistent "always" or "never". The advantage of doing this is that I need to multiply dQ/dT with the scaled lineshape at some point, and this scaled lineshape already incorporates Q, whereas I need the value for dQ/dT instead of this Q. * src/lineshapes.cc: Fixed bug included in last code-push. The minus sign change was completely wrong and just compensated for the error with the stimulated emission. * src/test_propmat_partials.cc: Added some tests for T-derivatives. 2015-10-20 Patrick Eriksson * arts-2-3-332 * controlfiles/instruments/metmm/sensor_descriptions/apply_metmm.arts: Now also using f_gridMetMM. * src/m_sensor.cc (f_gridMetMM): Typo made that npassb=4 effectively resulted in napssb=1. (sensor_responseMetMM2): Renamed, see below. (sensor_responseMetMM): Old version now replaced with new "2" version. * src/methods.cc: As above. Added me as author of sensor_responseMetMM, not for these last changes but my old work on mirror_dza and the polarisation sub-function. 2015-10-17 Simon Pfreundschuh * arts-2-3-331 * src/oem.* Added LinearOEM class for more convenient handling of OEM computations, added normalisation for covariance matrices. * src/test_oem.cc Adapted tests to changes in OEM functions. * src/test_oem/test_oem.m Change name of Jacobian matrix to J. 2015-10-16 Richard Larsson * arts-2-3-338 * src/absorption.{cc,h}: Added check for line shape having partials. * src/lineshapes.cc: Changed lineshape_voigt_kuntz6 to give back numerical partial derivatives. I used this in TestWfuns and the changes makes this function agree with faddeeva_algorithm_916 line shape and partial derivatives. Note that for partial derivative calculations, faddeeva_algorithm_916 will be faster since it is only looping frequency once to get partial derivative and lineshape_voigt_kuntz6 is looping frequency three times (recursive calls with perturbed variables). Also changed the helper functions so that both faddeeva_algorithm_916 and lineshape_voigt_kuntz6 get internal partial derivatives from the same source. They both operate on the same principle, so this should be OK. Note that the temperature partial derivatives are still different between the "analytical" and "from propmat" cases, and that I still do not know why. * src/partial_derivatives.cc: Discovered a bug in the temperature part of the code (which did not affect the end results for the previous commit but made the new code act strange). 2015-10-15 Richard Larsson * arts-2-3-337 * src/absorption.cc: Renamed some internal variables for easier reading. * src/linescaling.cc: Added comment on partial partition function design. * src/lineshapes.cc: Added comment and changed signs. The signs here are difficult to get right. * src/m_abs.cc: Another bug in the continua derivatives fixed. With this and the above general shape is similar between wfuns when using on-the-fly calculations. Differences still remains... * src/m_cia.cc: In fixing to not output pseudo cross-section I also removed adding the cross-section when the secondary and first species are not the same. This is now back. * src/partial_derivatives.{cc,h}: Changed some comments and names to make it easier to read. 2015-10-14 Richard Larsson * arts-2-3-336 VMR with "from propmat" and "analytical" now works idtentical for both lookup and on-the fly in Wfun test. Temperature still has issues in this test for on-the-fly. Its shape looks OK but some values are way too large. I repeat, there are plenty of variables in the temperature partial derivative so I will have to go through these to find if something might be wrong... * src/absorption.cc: Reformat of wrapper function to allow calculations even without phase functions if some jacobian quantitites are specified. Still remains to allow calculations with more lineshapes... * src/m_abs.cc: Moved VMR partial derivatives from xsec to coef. Previous version did not return dxsec_dx, but some hybrid that worked once in coef. Fixed continua bug whereby if internal partial derivatives were calculated for more than one continua, then all failed... With this fix, VMR "from propmat" or "analytical" are identical lest we count that CIA is also doing vmr for secondary species. NOTE: The correct VMR partial derivative have to take change in pressure broadening into account but this has not been done in the code. That was also ignored before. I am wondering whether a "fast" and "full" option should be made available at some points... * src/m_cia.cc: Fixed so no psuedo partial derivative is returned. * src/m_rte.cc: Changed interface to look more alike between VMR and temperature. * src/m_zeeman.cc: Had to add test here to allow no phase in absorption.cc for special cases. I am strongly considering dropping support for the non-PreCalc option for calculations of Zeeman effect. It is slower and needs more special treatments than its cousin. To no known gains. * src/partial_derivatives.cc: Removed VMR calculations since these gave psudo xsec partial derivatives. Started debuggin and changing temperature derivatives. * src/partial_derivatives.h: Added one test and refined another. Added knowledge about species to all parameters, so that a flag can be used when there is no species. 2015-10-14 Patrick Eriksson * arts-2-3-335 * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts: Corrected type of met_mm_accuracy in header text. But channels and viewing_angles still listed as expected variables. The header of all these files should be revised. * src/m_sensor.cc (sensor_responseMetMM2): A version of the MetMM method, where the frequency part is precalculated, by e.g. f_gridMetMM. * src/m_basic_types.cc (Compare): Added Compare for Sparse. 2015-10-13 Patrick Eriksson * arts-2-3-334 * src/m_sensor.cc (f_gridMetMM): Sets f_grid and some sensor related variables based on met-mm settings. The output fits with sensor_responseMixerBackendPrecalcWeights. Finished, but not yet hard tested. 2015-10-13 Patrick Eriksson * arts-2-3-333 * ChangeLog: Removed one old conflict marker. 2015-10-13 Oliver Lemke * arts-2-3-332 * CMakeLists.txt: Put variable in quotes to avoid error if it's empty. 2015-10-12 Patrick Eriksson * arts-2-3-331 * src/m_sensor.cc (f_gridMetMM): Started. * src/m_sensor.cc (sensor_responseMixerBackendPrecalcWeights): Now using channel2fgrid_indexes and channel2fgrid_weights, replacing two old GIN arguments with exacly the same functionality. * src/workspace.cc (define_wsv_data): Introduced channel2fgrid_indexes and channel2fgrid_weights. 2015-10-11 Patrick Eriksson * arts-2-3-330 * Warning! If you have any control file including sensor_pol or sensor_pol_array, you need to change that to instrument_pol(_array). There is now a new WSV named sensor_pol. * controlfiles/CMakeLists.txt: Added test below, as fast. * controlfiles/artscomponents/stokesrot/TestSensorPol.arts: New test. * src/m_sensor.cc (yApplySensorPol): New WSM. * CHANGES-2.3: Added renaming of sensor_pol. * src/m_jacobian.cc (jacobianClose): Fixed comment that incorrectly referrred to sensor_pol. * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: * src/m_cloudradar.cc (yCloudRadar): * src/sensor.cc (stokes2pol): * src/m_sensor.cc (sensor_responseAntenna) (sensor_responsePolarisation): * src/m_transmitter.cc (iy_transmitterMultiplePol) (iy_transmitterSinglePol): Changed sensor_pol to instrument_pol. * src/workspace.cc (define_wsv_data): Renamed existing sensor_pol to instrument_pol, and sensor_pol_array to instrument_pol_array. This as the variable now is used for both receivers and transmitters, and this name fits better with a new WSV: Introduced a new sensor_pol. 2015-10-09 Patrick Eriksson * arts-2-3-329 * src/m_sensor.cc (sensor_responseMixerBackendPrecalcWeights): Definition of frequency - channel assocation is defined. Now more general as the old way did not handle double pol channels. 2015-10-08 Patrick Eriksson * arts-2-3-328 * controlfiles/artscomponents/wfuns/TestWfuns.arts: Polishing of comments and accuracy limits. Switched to Faddeeva_Algorithm_916 line shape, to allow test of On-The-Fly. This option seems not to work yet for "from propmat". 2015-10-07 Richard Larsson * arts-2-3-327 WARNING: This breaks your controlfiles. propmat_clearsky_agenda and abs_xsec_agenda now both depends on jacobian_quantities, so it has to be initialized. I believe that there must be some bugs in the code at present, but it is very complicated so I need some tests that are general enough, which is why I submit the code as is. There are many terms involved in the temperature partial derivatives. The new feature is the calculations of partial derivatives within the absorption scheme. This partial derivative scheme interfaces with the Jacobian calculations in iyEmissionStandard. Presently, only Temperature and VMR works, and it can be activated by changing the Jacobian method to "from propmat". The code is in place to allow for all of the present schemes but this remains to be tested before becoming activated. So the descriptions below will also deal with other parameters. There are some limitations: e.g., that VMR is the only allowed setting for Abs Species. Once this has been tested and seems to work I will update the documentation with the additions. Note that some numbers are presently perturbed (e.g., tabulated CIA values). This might be changed in the future by interpolating the partial derivative. Please view this initial release as Testing, and report bugs/missing features/incompatible behavior to me directly so these can be sorted. The intention is to be backwards compatible but not wastefully so. E.g., VMR is the only way to calculate Abs Species presently (though it might be possible to do so in more ways.) About speed: The code is about as fast as before in performing the tests, at least in Release mode. I suspect it might be much slower under Debug mode. Using "from propmat" instead of "analytical" makes a yCalc call in average 10% faster. I suspect the increase in speed is much more noticeable if calculating other fields than temperature, since this is by far the most complicated of the lot. * src/ CMakeLists.txt: Added partial_derivatives.{cc,h} for internal calculations and an internal tracking class. This is likely where most of the bugs and mistakes are located. * src/absorption.{cc,h}: (xsec_single_line) now outputs partial derivatives of the line absorption. So that these are added at the right place when given cutoff, the cutoff range is also output. Since this change facilitated several internal loops, I simplified the code by manually looping over frequnecy rather than using built-in features. All other behavior remains as before. (xsec_species_line_mixing_wrapper) now also acts as a wrapper for partial calculations. Name change? Not yet but soon a must. The reason is that partials also require the line shape to output phase, or at least be able to calculate it internally. Presently, all internal partials are calculated separately from the internal value. I think it would be speedier to do more things on-the-fly, so perhaps this will change later. The bulk of internal partials are calculated after the calls to (xsec_single_line). Old functions: I outright removed unused code for old xsec_species, since this caused headaches with other changes. In header file, I changed the definition of line shape and line normalizations. Normalization functions all now also can return their internal partial derivativeis with respect to temperature, frequency and line frequnecy. There are two options for lineshapes: either they return partials and support deturning internal partial derivatives for temperature, frequency, gamma, magnetic field strength, and line mixing frqeuency shift. More could be added, but I did not bother for now. The other option is that the line shape do not support partials. Warnings should be thrown when you muck about with this and make a mistake. * src/agendas.cc: Added dpropmat_clearsky_dx, dnlte_dx_source, and nlte_dsource_dx as inputs to propmat_clearsky_agenda. Note that two of these remains unused. Also added jacobian_quantities as required input to allow methods to not do wasted calculations by setting this array to size zero. Similar changes are applied to abs_xsec_agenda, but only one NLTE parials output is given, since the other is from Planck function derivative. The workspace variables are called dabs_xsec_per_species_dx and dsrc_xsec_per_species_dx, though they are not "per_species". Name change? * src/{methods,workspace}.cc: Plumbing for other changes. * src/constants.cc: PROPMAT_SUBSUBTAG added as a retrieval string. * src/jacobian.{cc,h}: Force tests of Jacobian type to follow an enum lists of named integeres in (get_pointers_for_analytical_jacobians). This allows chaning types of calculations later on by name rather than by numbers. Default behaviors are also kept for false statements. Minor preparations for doing line parameters Jacobians are added. There is no way to activate this code yet though. * src/lin_alg.cc: Added two speedier ways to calculate the partial derivative of a matrix exponent. This speed is simply achieved by allowing to calculate several partials at once, where these partials are supplied as a Tensor3, with the size of one dimension meaning "number of partial derivatives". One of these methods should probably be moved away from this file at some point since it gets its speed by assuming that there are two sets of partial derivatives for a level matrix, one upper level and one lower level. The intention is that we calculate absorption in a layer from absorption at the surrounding levels, so we have a partial influence on a layer from two levels. In other words, dT(n)/dx(n) and dT(n)/dx(n+1) are not generally nil. * src/{pressurebroadeningdata,line{mixingdata,scaling}}.{cc,h}: Returns partial derivvatives with temperature. * src/lineshapes.cc: Lots of changes. As said, each normalization factor now returns several partial derivatives. Only faddeeva_algorithm_916 of the actual line shapes have been adapted to return partial derivatives. Part of these adaptations might appear overly complicated. The reason is that Hartman-Tran lineshape is somewhat different from the rest, and I want to keep extensions to this lineshape clean. * src/m_abs.cc: All propmat and xsec functions have been changed to either return partial derivatives (most of them) or throw warnings when propmat partial derivaitves are not supported (e.g., Faraday rotation does this for now for angular parameters). Intentionally, all functions create their internal data structure for knowing to do partial derivatives, and these are strictly tested so that the partial derivative type is allowed. Some of the methods get the partial derivatives from perturbations, and these perturbations are known by the internal data. Still some silliness involved here, e.g., Wind cannot be understood inside propmat_clearsky since the variable is external. So Wind partials must be done as frequency partials, and then have the internal partial of frequency to wind applied externally. Another thing I have to fix is to allow more perturbations than one for the fields (now u,v,w must have the same perturbations). * src/m_abs_lookup.cc: lookup partials are calculated by perturbations. * src/m_zeeman.cc: Does partial derivaitves analytically. Only Precalc method will allow magnetic partials in the future, probably. * src/m_rte.cc: Setup simple interface between propmat partial derivatives and present Jacobian scheme. * src/m_cia.cc: Same as above. Note that it assumes that in conversion to coefficients, there is no vmr derivative applied. It therefores returns a doubled value when both species are the same. There is a small comment justifying the equations here. Note that both first and second species VMR matters, so the scaling might look odd. I think this might have been missed by the semi-analytical calculation scheme. Though it might be me doing something wrong. * src/gas_abs_lookup.h: Added function to return species number. * src/physics_funcs.{cc,h}: Added simple partial derivatives for number density and Planck function. * src/rte.{cc,h}: Added (ext2trans_and_ext2dtrans_dx) and (get_ppath_trans_and_dppath_trans_dx) for when propmat_clearsky partials are calculated. Current FIXME: How do I use the speedier Landi Degl'Innocenti and Landolfi (2004) method? (get_ppath_pmat) returns dppath_ex_dx and depends on jacobian_quantities. * src/zeeman.{cc,h}: Changed a lot. Added several polarization rotation matrices partial derivaitves. Also changed input/output for the Zeeman method wrapper. Note that some expressions are direct copies of output from Matlab's symbolic toolbox, so they can be lengthy. * src/partial_derivatives.{h,cc}: Added. Change name? This treats all cases of internal propmat partials for the cross-section. It also has a class, PropmatPartialsData, that is used and understood by other functions that need more than just cross-section partial derivatives data. This class shall, for instance, contain all tests of whether a method is eligble for calculating certain partial derivatives. For instance, abs_lookup and continuum cannot calculate line parameters but they can calculate NLTE (since there is no NLTE in these models). Another example is that Faraday rotation cannot be combined with Zeeman angle changes yet (has to be added manually). (partial_derivatives_lineshape_dependency) is the function that does these calculations. I have a PDF file available that have been shown to some of the developers. The PDF tries to explain each parameter, but it is mostly a collection of mathematical expressions. It is much more extensive than the presently available outputs suggests. * All others: Changed to work around the changes above. Or insignificant changes. 2015-10-07 Oliver Lemke * arts-2-3-326 * src/m_xml.h (WriteXML): Intel Compiler doesn't see the try...catch inside the critical region as one statement. Put {} around as a fix. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Lowered required limit to 1e-16. 1e-18 was well below the typical accuracy of 16 digits for double anyway. Test case was failing with the Intel Compiler. 2015-10-06 Patrick Eriksson * arts-2-3-325 * src/methods.cc: * src/m_jacobian.cc (jacobianAddAbsSpecies): * src/jacobian.cc (vmrunitscf): I had to reintroduce "logrel". Now discovered that Qpack had not been working since May due to commit 2-3-204. To handle rel/logrel solely in Qpack would require a quite complex and demanding solution. So decided to revert this change. 2015-10-06 Patrick Eriksson * arts-2-3-324 * src/m_sensor.cc (sensor_responseMixerBackendPrecalcWeights): Now seems finished. * src/m_basic_types.cc (MatrixCopySparse): New WSM. 2015-10-06 Patrick Eriksson * arts-2-3-323 * controlfiles/instruments/metmm/sensor_descriptions/apply_metmm.arts: Adopted to name change below. * src/m_sensor.cc (sensor_responseBackendMetMM): Renamed. This as the method handles more sensor parts than backend. (sensor_responseMetMM): New name of the WSM. * src/m_sensor.cc (sensor_responseMixerBackendPrecalcWeights): Started. 2015-10-05 Patrick Eriksson * arts-2-3-322 * src/m_oem.cc: * src/oem.cc: Still work in progress. If you are curious, see built-in for oem WSM and oem_diagnostics WSV to get an idea about the plans. 2015-10-05 Patrick Eriksson * arts-2-3-321 * src/oem.cc: * src/m_oem.cc: Work in progress. Adding diagnostics and different features to control calculations and reporting. * src/workspace.cc: Renamed inverse of covariance matrices, to covmat_sx_inv and covmat_so_inv. 2015-10-02 Simon Pfreundschuh * arts-2-3-320 * src/oem.* (oem_gauss_newton, oem_levenberg_marquardt): Adapted interface and corrected computation of fitted state vector and gain matrix. * src/m_oem.cc (oem): Adapted function calls to oem_gauss_newton and oem_levenberg_marquardt. * src/test_oem.cc (test_oem_linear, test_oem_gauss_newton, test_levenberg_marquardt): Adapted function calls to oem_linear_nform, oem_gauss_newton and oem_levenberg_marquardt. 2015-10-01 Patrick Eriksson * arts-2-3-319 * src/oem.cc (oem_linear_nform): Changed order of input, following arts standard. yf now not updated inside the function. x and G now given their size inside function. * src/oem.cc: Changed order of input also for other oem functions. * src/m_oem.cc (oem): Some dummy code removed. Adopted to change of oem intyernal functions. * src/workspace.cc: Added invcovmat_sx and invcovmat_s0. * src/agendas.cc: Removed inversion_agenda_old. 2015-09-24 Oliver Lemke * arts-2-3-318 * doc/arts-splash.gif: Removed. * doc/arts-splash.png: Added. s/System/Simulator/ * doc/index.html.in: Updated. * doc/doxygen/CMakeLists.txt, src/arts.h: Use updated png splash. 2015-09-23 Simon Pfreundschuh * arts-2-3-317 * src/oem.*: Added linearization around given (xa,yf) and removed unnecessary matrix-vector multiplications. * src/m_oem.cc: Adapted AgendaWrapper to new agenda execution function and removed old one. * src/methods.cc Removed old agenda argument. * src/test_oem.cc Adapted oem function calls to changed function interfaces. 2015-09-21 Richard Larsson * arts-2-3-316 * m_atmosphere.cc,methods.cc (atm_fields_compactCreateFromField): Added by request of Maryam to be able to create compact fields from nothing. (Was problematic to do this before, this is just a helper.) 2015-09-19 Simon Pfreundschuh * arts-2-3-315 * src/oem.* Modified OEM functions to accept inverses of covariance matrices, added log output to iterative methods, added computation of gain matrix and returning of fitted measurement vector. * src/test_oem.* Adapted oem function calls to changed function interfaces. *src/m_oem.cc Adapted oem function calls to updated function interfaces. 2015-09-18 Oliver Lemke * arts-2-3-314 * controlfiles/instruments/amsu/amsub_metmm.arts: Fix testcase TestAMSUB_MetMM by adding met_mm_accuracy and setting it to high (2). This folder should be removed once the TestMetMM cases are settled. 2015-09-18 Oliver Lemke * arts-2-3-313 * src/m_agenda.cc (AgendaExecute): Don't scope WSVs that are input _and_ output. 2015-09-18 Patrick Eriksson * arts-2-3-312 * src/m_oem.cc (oem): inversion_iterate_agenda_old used by ml and gn, while li uses inversion_iterate_agenda. * src/agendas.cc: Introduced inversion_iterate_agenda_old as a temporary solution. Changed set of input arguments to inversion_iterate_agenda. 2015-09-18 Oliver Lemke * arts-2-3-311 * src/m_agenda.cc (AgendaExecute): Fix bug in scoping for WSVs that are defined as input of the agenda but changed by WSMs inside it. Their new values wrongly leaked into the caller's scope. Reported by Patrick. * controlfiles/artscomponents/agendas/TestAgendaExecute.arts: Add check for above case. 2015-09-17 Patrick Eriksson * arts-2-3-310 * src/m_oem.cc (oem): Some changes around the gin arguments. Most importantly, introduced yf_linear to trigger that the actual yf is calculated. 2015-09-15 Simon Pfreundschuh * arts-2-3-309 * src/m_oem.cc Added wrapper class for agenda execution and calls to OEM methods. 2015-09-14 Alex Bobryshev * arts-2-3-308 * Setup for microwave sensors (for now it is fully consistent with AMSU-A and AMSU-B sensors. Added switch-variable met_mm_accuracy to select the number of monochromatic calculations to simulate these sensors. * controlfiles/CMakeLists.txt: Add TestMetMM to slow tests. * controlfiles/instruments/metmm/TestMetMM.arts: Main controlfile * controlfiles/instuments/metmm/common_metmm.arts: Common agendas for metmm sensors. * controlfiles/instruments/metmm/abs_lines_metmm.xml.gz: HITRAN2012 5 to 600 GHz for H20, O2, N2 and O3. * controlfiles/instruments/metmm/ybatchREFERENCE.xml: Reference file for AMSU-B outermost viewing angle for all channels based on Garand profiles. * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts: Add matrix met_mm_available_accuracies, with selected number of frequencies per channel. 2015-09-11 Patrick Eriksson * arts-2-3-307 * src/m_oem.cc: Some minor polishing. * src/workspace.cc (define_wsv_data): Fixed spelling for dxdy. 2015-09-10 Simon Pfreundschuh * arts-2-3-306 * src/matpackI.* (ConstMatrixView::diagonal): Added function returning ConstVectorView of matrix diagonal. * src/test_matpack.cc (test_diagonal): Added test function for diagonal() function. 2015-09-10 Patrick Eriksson * arts-2-3-305 * Now things are prepared for "zero order" inversions, i.e. just returning data matching a priori / zero measurement response. Retrieval quantities handled so far are just abs. species and temperature, but all details should be in place, such as allowing length 1 grids. * src/m_oem.cc (oem): Extended. * src/workspace.cc: Added dxdy. * src/m_jacobian.cc (jacobianAdjustAfterIteration): New. 2015-09-10 Patrick Eriksson * arts-2-3-304 * src/m_oem.cc: Work all over the file to make use of new functions listed below. Added temperature as treated retrieval quantity. Length 1 retrieval grids are now handled. * src/methods.cc: Added comment around scope of the hse argument. * src/m_jacobian.cc (jacobianAddAbsSpecies) (jacobianAddTemperature): Changed cross-checks between nd and t retrievals. It is now allowed to mix these two things, as long as temperature is included as retrieval quantity before the species using nd. The code to calculate Jacobians does not cover all details of this mix of retrieval quantities, but this should not have any practical consequences. With the demanded order, things get at least right when mapping a iteration state back to t_field and vmr_field. * src/agendas.cc (define_agenda_data): Added jacobian_do as input to inversion_iterate_agenda. And changed back to have y as output. * src/interpolation.cc (gp4length1grid): This was before an internal help function in jacobian.cc, now polished and moved to this file.. * src/jacobian.cc (jacobian_type_extrapol): This was before an internal help function, now polished and included in jacobian.h. 2015-09-10 Jana Mendrok * arts-2-3-303 * src/cloudbox.cc (IWCtopnd_MH97): Use same T-margin as introduced in atmlab-2-3-116 (I couldn't find a T check in ARTS' MH97 at all :-/ ). Seems more practical than disallowing any T>0C. * src/m_cloudbox.cc (dNdD_*): Fixed a couple of comments. * src/methods.cc, src/workspace.cc: Couplke of spell fixes and previously overlooked adaptations to changed WSM names. 2015-09-10 Patrick Eriksson * arts-2-3-302 * src/math_funcs.cc (reshape): New, exists for Vector to Matrix or Tensor3. * src/m_oem.cc (x2arts_std): Now active, but just a start. (oem): A few more lines. * src/agendas.cc (define_agenda_data): y changed to yf for inversion_iterate_agenda. 2015-09-09 Patrick Eriksson * arts-2-3-301 * src/m_oem.cc (x2arts_std): Start on a new WSM. So far commented out. (get_gp_rq_to_atmgrids): As below, but working in reversed direction. (get_gp_atmgrids_to_rq): New name of a function added in last commit. 2015-09-09 Oliver Lemke * arts-2-3-300 * Backported from arts-2.2. Adapted controlfiles. * controlfiles/classroom_exercises/: Added exercises. Controlfiles, matlab scripts and assignments provided by Theresa Lang. * doc/classroom_excercises_solutions: Added solutions for exercises. Provided by Theresa Lang. * doc/CMakeLists.txt: Added solutions subdir. * controlfiles/CMakeLists.txt: Add exercises as tests. Add custom target mkdir-arts-results as the exercises require an 'results' folder to be present. * cmake/modules/ArtsBuildTexDoc.cmake: Add macro ARTS_ADD_SIMPLE_TEX_DOC. Used to compile exercise solutions. * CMakeLists.txt: Add exercises to check-xmldata. Also add special target check-classroom. Add mkdir-arts-results as a dependency for both targets. 2015-09-09 Oliver Lemke * arts-2-3-299 Warning: You have to adapt your controlfiles if you're using a custom iy_main_agenda that calls iyRadioLink, iyMC or iyLoopFrequencies. -> Add Ignore(diy_dx) to iy_main_agenda * src/agendas.cc, src/methods.cc: Jacobian calculations that relied on recursive calls of the iy_main_agenda didn't work since arts-2-3-279. diy_dx was defined as an output-only variable and only initialized on the first call of iy_main_agenda. In recursive calls the output variable is resetted by the workspace engine and hence empty. Fixed by adding diy_dx as input to all agendas and methods that can call iy_main_agenda recursively: iy_main_agenda, iy_space_agenda, iy_surface_agenda, iy_surface_sub_agenda[0-5]. iyEmissionStandard, iyFOS, iySurfaceCallSubAgendaX, iySurfaceFastem, iySurfaceRtpropAgenda, iySurfaceRtpropCalc, iyTransmissionStandard. * controlfiles/general/agendas.arts: Ignore diy_dx in iy_main_agenda__ScattMC and iy_main_agenda__Radiolink. * controlfiles/artscomponents/transmission/TestTransmission.arts, controlfiles/artscomponents/radiolink/TestRadioOccultation.arts, controlfiles/artscomponents/radiolink/TestRadioLink.arts, controlfiles/artscomponents/radiolink/TestRadioLink2.arts, Ignore diy_dx in iy_main_agenda. * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: Ignore diy_dx in iy_main_agenda and iy_sub_agenda. * controlfiles/artscomponents/surface/TestSurface.arts: Ignore/Touch diy_dx. 2015-09-09 Patrick Eriksson * arts-2-3-298 * src/m_oem.cc (get_gp_for_jq_grids): (setup_xa): Internal help functions. (oem): Started. * src/special_interp.cc (regrid_atmfield_by_gp): New. * src/math_funcs.cc (flat): Mimics matlab's x=X(:). Exists for matrix and Tensor3. * src/m_basic_types.cc (MatrixIdentity): New WSM. * src/agendas.cc (define_agenda_data): Added *inversion_iterate_agenda*, *covmat_so*, *covmat_sx* and *yf* and *xa*. * src/workspace.cc (define_wsv_data): Added *x*. * src/CMakeLists.txt: Added m_oem.cc. * src/m_oem.cc: Started this file. 2015-09-08 Oliver Lemke * arts-2-3-297 * src/sensor.cc (find_effective_channel_boundaries): Add runtime error with (hopefully) helpful error message if no passbands are detected. 2015-09-05 Patrick Eriksson * arts-2-3-296 * doc/uguide/wfuns.tex (subsection{Common practicalities}): Removed comments around logrel, as this option has been removed. (subsubsection{General case}): Added comment making clear that the bulk of the text are just notes for possible future changes. 2015-09-03 Oliver Lemke * arts-2-3-295 * src/global_data.h: Add missing ifdef. * src/optproperties.cc (pha_mat_labCalc): Avoid warning about shadowing a global variable on some compilers by renaming ANGTOL to ANGTOL_RAD. Reported by Richard. 2015-09-31 Richard Larsson * arts-2-3-294 * src/m_linerecord.cc: Added simple explorative setup scripts for f_grid that are based on the lines in the line database. 2015-09-01 Manfred Brath * arts-2-3-299 * src/cloudbox.{h,cc} (pnd_fieldS2M), src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields): Added two moment scheme distributions that uses scat_species_mean_mass_field Removed redundant string variable "psd" * src/m_cloudbox.cc (dNdD_S2M_M), src/methods.cc: Added new WSMs for the new distributions. 2015-09-01 Simon Pfreundschuh * arts-2-3-298 * src/lin_alg.* (solve): Added convenience wrapper for the solution of linear systems. * src/oem.h (Forward Model): Interface class for forward models. * src/oem.cc (oem_gauss_newton): Implemented Gauss-Newton method for non-linear inverse problems. * src/oem.cc (oem_gauss_newtom_n_form): Implemented N-form of the Gauss-Newton method. * src/oem.cc (oem_gauss_newtom_m_form): Implemented M-form of the Gauss-Newton method. * src/oem.cc (oem_levenberg_marquardt): Implemented Levenberg-Marquardt method for non-linear inverse problems. * src/oem_test.cc (test_oem_gauss_newton): Randomized testing of the oem_gauss_newton, oem_gauss_newton_n_form and oem_gauss_newton_m_form functions. * src/oem_test.cc (test_oem_levenberg_marquardt): Randomized testing of the oem_levenberg_marquardt function. * src/test_utils.* (random_fill_matrix_symmetric): Added function to generate random, symmetric matrices. * src/oem_test/forward_model.m: Matlab function to represent a forward model. * src/oem_test/test_oem_gauss_newton.m: Matlab script for testing of the Gauss-Newton method. * src/oem_test/test_oem_levenberg_marquardt.m: Matlab script for testing of the Levenberg-Marquardt method. * src/CMakeLists.txt: Added new Matlab scripts to copy directive. 2015-08-31 Patrick Eriksson * arts-2-3-297 * src/m_transmitter.cc (iyTransmissionStandard): Copied all recent changes and extensions in iyEmissionStandard. That is, this method now supports also mag field retrievals. * src/m_rte.cc (iyEmissionStandard): Just changes to make the code less lengthy. Replaced the Tensor4-s ppath_ext_dwu/v/w with ArrayOfTensor4 ppath_ext_dw. And did the same thing for corresponding mag field variables. This allowed to avoid some if-else, making the code some 40 lines shorter. 2015-08-31 Patrick Eriksson * arts-2-3-296 * src/m_rte.cc (iyEmissionStandard): Just changed value for dm, down to 0.1 muT. 2015-08-31 Oliver Lemke * arts-2-3-295 * src/jacobian.h: Include abs_species_tags.h for ArrayOfArrayOfSpeciesTag. 2015-08-31 Richard Larsson * arts-2-3-294 * src/zeeman.cc: Added test that removed a 0-div-0 error when the magnetic field is set to zero vectors. Bug reported by Patrick to give all NaNs in the propagation matrix (due to angle being NaNs in the Zeeman code). 2015-08-31 Patrick Eriksson * arts-2-3-293 * src/m_atmosphere.cc (AtmosphereSet3D): The method now also sets lat_true and lon_true, to be empty. This matches how the 1D method sets lat_grid and lon_grid to be empty. * src/jacobian.cc (get_pointers_for_analytical_jacobians): * src/m_transmitter.cc (iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard): Continued work magnetic field as jacobian quantity. Should be finished but no proper testing yet. 2015-08-28 Patrick Eriksson * arts-2-3-292 * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: The bandwidth for 664 GHz was incorrectly set to 3 GHz, now corrected to 5 GHz. Error found by Stuart. The below is work in progress, to add magnetic field as jacobian quantity. * src/m_transmitter.cc (iyTransmissionStandard): Just adopted to get_pointers_for_analytical_jacobians. * src/jacobian.cc (get_pointers_for_analytical_jacobians): Added support for mag. fields. * src/m_jacobian.cc (jacobianAddMagField): New. (jacobianAddWind): Corrected an error message. (jacobianCalcMagFieldAnalytical): New. * src/constants.cc: Added MAGFIELD_MAINTAG. 2015-08-27 Patrick Eriksson * arts-2-3-291 * src/m_abs.cc (abs_linesReadFromHitran): A small correction of error message, added 1 to the line << "run 'cmake -DWITH_HITRAN2008=1 ..' and recompile arts"; * A change to make things more flexible in the met mm part. freq_number is now set in the instrument file. It was before hard-coded to 1 GHz in apply_metmm.arts. * controlfiles/instruments/metmm/sensor_descriptions/apply_metmm.arts: See above. * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts: Adopted with met_mm_freq_spacing set to 10 GHz. met_mm_freq_number changed back to 12, to match the files below. Tests indicate that this number is actually needed, for upward looking views, as some bands include ozone lines. While for downward, a value of 2 or 3 could suffice. * controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts: Adopted with met_mm_freq_spacing set to 1 GHz. This maintains the performance for these instruments. 2015-08-27 Oliver Lemke * arts-2-3-290 * src/m_abs.cc (abs_linesReadFromHitran): Don't require the full catalog filename to match hitran2012.par/hitran08.par. Only require that it starts with hitran2012/hitran08 (case insensitive). Change proposed by Patrick to make it easier to read custom catalogs. 2015-08-27 Patrick Eriksson * arts-2-3-289 * arts/controlfiles/instruments/ismar: Removed this folder. The MetMM system should be used for ISMAR, MARSS and DEIMOS. The files were anyhow not up to date and caused some confusion. 2015-08-26 Richard Larsson * arts-2-3-288 * src/methods.cc: Fixed typo. Partition functions do not (yet) have to be checked agains t_nlte_field but rather to t_field. Patrick, thank you for noticing this error. 2015-08-25 Jana Mendrok * arts-2-3-287 * src/continua.cc: Corrected validity range values for MPM93 cloud absorption continua. * src/m_abs_lookup.cc (find_nonlinear_species): Be more specific in setting liquidcloud continua as linear abs species. * src/workspace.cc (iy_unit): Give some examples on the radiative methods meant. 2015-08-24 Oliver Lemke * arts-2-3-286 * src/methods.cc: Add verbosity as input to verbosityInit and verbositySet. Usually, init functions only produce output. Verbosity is a special case because the workspace engine sets a flag in the Verbosity object whether we're inside the main agenda or not. This partial initialization has to be preserved when calling verbosityInit/Set. Problem became visible because of the changes in arts-2-3-279. Bug reported by Patrick. 2015-08-24 Oliver Lemke * arts-2-3-285 * doc/uguide/check_refs.py: Fix the py3k fix. It wasn't working properly on all configurations. 2015-08-24 Oliver Lemke * arts-2-3-284 * controlfiles/general/continua.arts, src/continua.{cc,h}, src/partition_function_data.cc, src/species_data.cc: Added Ellison 07 continuum. Implementation provided by Stuart Fox. 2015-08-21 Patrick Eriksson * arts-2-3-283 * src/m_ppath.cc (geo_posEndOfPpath) (geo_posLowestAltitudeOfPpath, geo_posWherePpathPassesZref): Did not work for 1D. The pseudo-latitude kept inside ppath was incorrectly included. 2015-08-21 Richard Larsson * arts-2-3-282 * src/absorption.cc: Fixed a typo. The rest is just a preparation. No code has been changed, but some functions that we have yet to decide necessary have been added. * src/lin_alg.Pcc,h}: Added matrix_exp_dmatrix_exp as a method for outputting the matrix exponent and its derivative at once. Tested as a temporary replacement for matrix_exp and the results are identical. I have yet to test that the derivative is OK. The function is also based on Pade Approximation. * src/zeeman.{cc,h}: Added partial derivatives with respect to the angles. I am still unsure if there are easier ways to calculate this. E.g., exp(LKL^-1)=Lexp(K)L^-1, and L is the only eta variable, so the partial derivative might be easier than partial derivative of all angles. Nevertheless, the code is unused for now. I just need it to check with matrix_exp_dmatrix_exp that the dmatrix_exp part is doing a decent job. Suggestion: We should agree on a naming scheme for functions and variables that can have a direct partial derivatives with respect to some variable(s). This should of course only happen if we decide to try the analytical route. If so, some clear structure for the multiples of partials required could be useful. 2015-08-21 Oliver Lemke * arts-2-3-281 * controlfiles/planetary_toolbox/includes/jupiter/getatmo_jupiter.arts, controlfiles/planetary_toolbox/includes/mars/getatmo_mars.arts, controlfiles/planetary_toolbox/includes/venus/getatmo_venus.arts: Use different names for temporary files for each planet. Otherwise test cases fail randomly if executed in parallel and one test case overwrites the tmp file of the other. 2015-08-20 Oliver Lemke * arts-2-3-280 * doc/uguide/check_refs.py: Make script Python 3 compatible. 2015-08-20 Oliver Lemke * arts-2-3-279 * src/make_auto_md_cc.cc: Extend clearing of output-only variables before WSM calls from matpack types to all WSV groups. Simplify code by using the default constructor to initialize objects. Numerics are initialized with NaN, Index with -1. This is only done in Debug configurations. Closes trac ticket #129. 2015-08-19 Jana Mendrok * arts-2-3-278 Scattering species size selection removed from scat_species tag. Now solely controlled and done by WSM ScatElementsSelect * src/m_cloudbox.cc, methods.cc (ScatElementsSelect): Modified behaviour/scope of the WSM. Now doing size selection per one scattering species a time, size limits specified directly here, size parameter selectable. * src/workspace.cc, src/cloudbox.[cc,h]: Removed size limit part from scat_species tags and corresponding scat_species parsing method. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Adapted to modified behaviour/scope of ScatElementsSelect and scat_species. 2015-08-19 Jana Mendrok * arts-2-3-277 * src/methods.cc (ScatElementsPndAndScatAdd, ScatElementsToabs_speciesAdd, ScatSpeciesPndAndScatAdd, ScatSpeciesScatAndMetaRead): Added all append-to-WSV as input parameters. * ontrolfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Properly initialize scatt related variables (using ScatSpeciesInit). * workspace.cc (scat_species): Doc bug fix. 2015-08-19 Jana Mendrok * arts-2-3-277 * src/workspace.cc, src/methods.cc, src/m_cloudbox.cc (cloudboxSetAutomatically, pnd_fieldCalcFromscat_speciesFields) src/m_atmosphere.cc (AtmFieldsFromCompact), src/m_jacobian.cc (jacobianDoit): Introduced new scat.species field mean_mass. Handled identically to all other atmospheric scat.species fields. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_1D_cloudy.arts: Adapted to scat_species_mean_mass_field introduction. 2015-08-19 Patrick Eriksson * arts-2-3-276 * src/methods.cc: Polishing of text for refr_index_airThayer. Removed reference to Solheim as it could cause some confusion. Corrected equation, it was aP/T, corrected to a(P-e)/T. 2015-08-18 Jana Mendrok * arts-2-3-275 Renaming of ParticleType* and ScatteringParticle* WSM and change of behaviour of some of these WSM for consistency with scat-species/scat-element scheme. * src/m_cloudbox.cc (ScatSpeciesInit): Renamed from ParticleTypeInit. Merged with scat_speciesInit and scat_metaInit. (ScatSpeciesScatAndMetaRead, ScatElementsSelect): Renamed from ScatteringParticleTypeAndMetaRead and ScatteringParticlesSelect, respectively. (ScatSpeciesPndAndScatAdd): Renamed from ParticleTypeAddAll. Modified to append data as new scattering species. (ScatElementsPndAndScatAdd): Renamed from ParticleTypeAdd. Adapted to handle multiple scattering elements at once (using file lists equivalent to ScatSpeciesScatAndMetaRead). (ScatElementsToabs_speciesAdd): Renamed from ParticleType2abs_speciesAdd. Adapted to handle multiple scattering elements at once (similar to ScatElementsPndAndScatAdd). (scat_speciesInit): Removed. * src/m_cloudproperties.cc (ScatSpeciesMerge): Renamed from ScatteringMergeParticles1D. * src/m_tmatrix.cc (scat_metaInit): Removed. * src/methods.cc, m_jacobians (jacobianDoit): Adaptation according to name/interface/behaviour changes above. * controlfiles/planetary_toolbox/includes/mars/getclouds_mars.arts, controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts, controlfiles/planetary_toolbox/includes/venus/getclouds_venus.arts, controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/artscomponents/disort/TestDISORT.arts: Adapted according to above changes. * doc/uguide/clouds.tex, absorption.tex: Scattering particle related text adapted according to above changes. * CMakeLists.txt: Fixed bug (exclude planettoolbox tag from 'check' tag). 2015-08-17 Jana Mendrok * arts-2-3-274 Modified ParticleTypeAddAll for consistent behaviour with ScatteringParticleTypeAndMetaRead. Adapted test cases for above change as well as for further previous ARTS changes (partition functions: arts-2-3-265, LTE: arts-2-3-225). * src/m_cloudbox.cc, methods.cc (ParticleTypeAddAll): Adapt for consistency with ScatteringParticleTypeAndMetaRead: Pass list of filenames (ArrayOfString) for scat_data input instead of name of file containing the filenames. * controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Adapted to ParticleTypeAddAll changes. * controlfiles/planetary_toolbox/includes/common/make-and-use-absLUT.arts, controlfiles/planetary_toolbox/includes/common/make-and-use-absLUT_1Dfor3D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_[DOIT,FOS,MC]_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_1D_clearsky.arts, controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_1D_cloudy.arts, controlfiles/planetary_toolbox/demos/passive/DemoMars_fullRT_3D_clearsky.arts, controlfiles/planetary_toolbox/demos/passive/DemoVenus_fullRT_1D_clearsky.arts, controlfiles/planetary_toolbox/demos/passive/DemoVenus_fullRT_1D_cloudy.arts, controlfiles/planetary_toolbox/demos/passive/DemoJupiter_fullRT_1D_clearsky.arts, controlfiles/planetary_toolbox/demos/active/earth_tropical_false3d_0to[64,1000]km_lowfreq.arts, controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: Adapted for changes in partition function handling. * controlfiles/planetary_toolbox/includes/common/makeatmo[1,3]D.arts, controlfiles/planetary_toolbox/demos/active/earth_tropical_false3d_0to1000km_lowfreq.arts: Adapted for LTE related changes in atmfield input. * controlfiles/planetary_toolbox/includes/common/createvars.arts, controlfiles/planetary_toolbox/includes/mars/getclouds_mars.arts, controlfiles/planetary_toolbox/includes/venus/getclouds_venus.arts, controlfiles/planetary_toolbox/demos/common/DemoMarsAtmo[1,3]D.arts, controlfiles/planetary_toolbox/demos/common/DemoMarsClouds1D.arts, controlfiles/planetary_toolbox/demos/common/DemoMarsSurface[1,3]D.arts, controlfiles/planetary_toolbox/demos/common/DemoVenusAtmo[1,3]D.arts, controlfiles/planetary_toolbox/demos/common/DemoVenusSurface1D.arts, controlfiles/planetary_toolbox/demos/common/DemoJupiterAtmo[1,3]D.arts: Minor rearrangements of planet toolbox file organisation. Improved header info. * CMakeLists.txt, controlfiles/CMakeLists.txt: Added planet toolbox test cases (else toolbox demos keep breaking undetectedly) and target planettoolbox. * controlfiles/instruments/amsu/amsub_metmm.arts: Fixed broken testcase: apply apply_metmm.arts required by reorganisation in arts-2-3-269. * controlfiles/artscomponents/cia/TestRTwithCIA.arts: Fixed broken testcase: slightly raised error margin. 2015-08-14 Jana Mendrok * arts-2-3-273 * src/m_optproperties.cc (scat_dataCheck): Polished error message, being consistent with current scat_data format. * src/methods.cc (doit_i_fieldSetFromPrecalc): Polishing documentation (no doit_i_field1D_Spectrum existing anymore). 2015-08-13 Richard Larsson * arts-2-3-272 * src/lineshapes.cc: Added mirrored Lorentzian line shape. Useful when you only want a single line or species that is mirrored and not all lines are to be mirrored. (E.g., NH3 in Jupiter atmosphere). * src/m_radiation_field.cc: Fixed logic bugs reported by Oliver. 2015-08-12 Oliver Lemke * arts-2-3-271 * ChangeLog: Fix version number continuity. * src/m_xml.h (WriteXML): Intercept exceptions crossing the critical region border. Fixes bug reported by gerrit in trac ticket #127. * src/xml_io.cc (xml_open_output_file): Catch file.open exceptions more broadly as different compilers throw different types of exception for the same error. 2015-08-11 Patrick Eriksson * arts-2-3-270 * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: Changed met_mm_freq_number to be 7 for all channels. Should be OK in most cases, while 12 should be unnecessary high. * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: Changed order between H and V for 243 and 664 GHz, to follow changed order in L1b file. And new order is better, H before V which is the alphabetical order. 2015-08-11 Patrick Eriksson * arts-2-3-269 * A small restructuring in met-mm. I have separated the definition and the application of the settings. This to make things more modular, e.g. to allow that the basic settings can be extracted without doing any calculations. Instead of INCLUDE "instruments/metmm/sensor_descriptions/sensor_mhs.arts" you must now do INCLUDE "instruments/metmm/sensor_descriptions/sensor_mhs.arts" INCLUDE "instruments/metmm/sensor_descriptions/apply_metmm.arts" * controlfiles/instruments/metmm/sensor_descriptions/apply_metmm.arts: New. * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: This file was not up to date. Not used by anybody!? In addition, added dummy data for 424 and 874 channels as they are in place in the ISMAR L1b datafiles, and then to get same channel index in both places. Adopted to apply_metmm.arts. * controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts: * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts: Modified to fit with apply_metmm.arts. 2015-08-10 Oliver Lemke * arts-2-3-268 * src/workspace.cc: Update docs for verbosity WSM. 2015-07-03 Richard Larsson * arts-2-3-267 Added Hartmann-Tran line shape. Also added radiation_field variable and a method to calculate it. * controlfiles/*: Added "Hartmann-Tran" as a line shape call where both Hui and Faddeeva where already in use for a third test. * src/CMakeLists.txt: Added m_radiation_field.cc. * src/absorption.{cc,h}: Moved sigma calculations outside of xsec_single_line. This so that all line broadening parameters are sent in to xsec_single_line as one block, making it easier to get an overview of the broadening scheme. Also changed layout of call to xsec_single_line so that parameters that are related to one-another are close-by in the call. Added five broadening parameters we did not have before, and renamed deltaf to df_0 and gamma to gamma_0. All broadening parameters are: gamma_0, gamma_2, eta, df_0, df_2, sigma, f_VC, which are the Hartmann-Tran inputs for speed-dependent and collisional broadenings. Note that we presently cannot input these parameters since I have yet to add this as a feature of Artscat5, though adding this should be a trivial task once data is available. Added several code comments to make the code easier to follow. * src/lineshapes.cc: All line shape functions now take 8 Numerics as input. This is so that the Hartmann-Tran line shape can work properly. Note that it is only tested for default inputs, where behaves like faddeeva_algorithm_916. I need to find some test case to ensure that the implementation is correct for the full calculations. * src/m_radiation_field.cc, methods.cc, workspace.cc: Added the radiation field calculations (planned to be used for internal calculations of t_nlte, but the full code is not yet ready). * src/pressurebroadeningdata.{cc,h}: Now returns 7 of the line broadening terms. Behavior is identical to before by setting pressure broadening terms unknown by Voigt to their canceling values. 2015-07-02 Jana Mendrok * arts-2-3-266 * src/continua.cc (MPM93RainExt): Catch vmr/rainrate=0. case (bugfix). Change from mm/h input to kg/m2/s to be consistent with scattering species methods. * src/m_abs_lookup.cc (find_nonlinear_continua): Added liquidcloud as linear species. Disallow icecloud and rain abs_species in lookup table calculations. * src/m_atmosphere.cc, methods.cc (batch_/atm_fields_compactCleanup): Added. scat_species_fieldCleanup equivalent working directly on the compact atmospheres (GF4 and ArrayOfGF4). Useful, when LWC/IWC shall be used with hydrometeor continuum abs_species. * controlfiles/general/agendas_surface.arts: Added skin temperature from t_surface variant for blackbody. * controlfiles/general/agendas.arts, src/rte.cc (emission_rtstep), src/gas_abs_lookup.cc, src/m_jacobian.cc (jacobianDoit), controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Spell fixes and other minor changes. 2015-06-29 Richard Larsson * arts-2-3-265 Warning: This update breaks controlfiles that are using bad partition functions. To keep using bad partition functions, set bad_partition_functions_ok = 1 in atmfield_checkedCalc. By "bad" partition function, I mean a partition function that is only defined for other temperatures than those that t_field contain. The test on partition functions should ideally be in the abs_xsec_agenda_checkedCalc, but we have too many definitions of the temperature fields for various agendas that rtp_temperature and abs_t are not always defined when iy_main_agenda is called, so it is only through iy_main_agenda that the temperature can be tested. The user can thus find themselves having fully calculated abs_lookup but getting a runtime_error when they then try to use this lookup through iy_main_agenda. So there is some waste of time. * These controlfiles were using bad partition functions: controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Jupiter.arts controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Mars.arts controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Venus.arts controlfiles/artscomponents/arts-xml-data/TestAtmScen_Jupiter.arts controlfiles/artscomponents/arts-xml-data/TestAtmScen_Mars.arts controlfiles/artscomponents/arts-xml-data/TestAtmScen_Venus.arts controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts controlfiles/artscomponents/clearsky/TestBatch.arts controlfiles/artscomponents/doitbatch/TestDOITBatch.arts controlfiles/artscomponents/ppath/TestRefractPlanets.arts controlfiles/artscomponents/wfuns/TestDoitJacobians.arts controlfiles/instruments/hirs/TestHIRS.arts In the first ten, I recommend using the TIPS function at some point after updating, so that the scenarios are actually calculating the correct line scaling. The latter five are a few degrees outside the defined temperature limits. * src/absorption.h (SetPartitionFctCoeff): Now also sets a temperature range in built-in so that the interpreter reading the built-in can set the temperature range properly. * src/partition_function_data.cc: Every call to iso() now also sets a temperature range. The temperature range is (150.0, 300.0) for all partition functions. This can of course be updated if anyone shows that the temperature range of some species is greater than suggested. The range was suggested by Jana after some tests she has done. Note that the range cannot be much different, since using TIPS instead of built-in produced errors of 0.01 K as stated in a previous commit. * src/methodds.cc: Plumbing. * src/m_checked.cc (atmfields_checkedCalc): Now takes partition_functions as input. Also takes a flag, bad_partition_functions_ok, for ignoring when partition_functions does not cover the t_field range. The test is simple: first of all, the size of each variable inside partition_functions is checked to see if it complies with its type of data. Then the temparure max of min and min of max of the partition functions are found. Then, if the flag is as per default, we test that min of max and max of min temperatures cover t_field. N.B., that a hard limit of 1 MK is set as the minimum min of max temperature. So if, for whatever reason, higher temperatures are needed, then this limit must be changed. 2015-06-26 Richard Larsson * arts-2-3-264 * src/linescaling.{cc,h}: Now does not calculate partition function if Q(T) or Q(T0) are defined. * src/absorption.cc: Now employs a simple buffer for the partition functions, Only if isotope or line temperatures changes between lines at a pressure level will the partition function be recalculated. 2015-06-26 Oliver Lemke * arts-2-3-263 * src/continua.cc, src/interpolation.cc, src/interpolation_poly.cc, src/m_jacobian.cc, src/m_optproperties.cc, src/ppath.cc, src/sensor.cc: Use the DEBUG_ONLY(...) macro around variable definitions and argument names that are only used in assertions. Avoids unused variable warnings in release build. 2015-06-26 Oliver Lemke * arts-2-3-262 * controlfiles/CMakeLists.txt: Move TIPS clear sky test to xmldata. 2015-06-26 Oliver Lemke * arts-2-3-261 * Comment on Richard previous commit: The slowdown when using TIPS data is due to an assertion in the interpolation routines. It calls is_increasing which has a large impact on performance (long vector checked in every iteration inside xsec_species). With a release build (cd build; cmake -DCMAKE_BUILD_TYPE=Release .), it is only marginally slower than using the builtin coeffs. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/clearsky/TestClearSkyTips.arts: Add test case for TIPS. Move artscomponents/radiolink/TestRadioLink.arts to slow tests. 2015-06-25 Richard Larsson * arts-2-3-260 * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): now properly returns a Tensor6 nlte_source_field. If t_nlte_field.empty() is false the field is one stokes_dim smaller than propmat_clearsky_field. If t_nlte_field.empty() is true, so is nlte_source_field.empty(). * src/workspace.cc, src/methods.cc: Variable creation and function redefinition. 2015-06-25 Richard Larsson * arts-2-3-258 Now the externalized partition functions can be used by everyone. Note that there is probably a bug presently that makes the calculations very slow. I.e., make check with built-in takes one quarter the time as using the gridded data. There might be a copy-bug in either (CalculatePartitionFctFromData) or in the calls to (CalculatePartitionFctFromData) and (CalculatePartitionFctFromCoeff). That or the interpolation is very slow. This is quite a significant update, because with TIPS data instead of built-in data two fast test fail for deviating from the minimal allowed error. These tests are: arts.ctlfile.fast.artscomponents.clearsky.TestClearSky arts.ctlfile.fast.artscomponents.groundbased.TestWinds Clearsky has limit at 0.01 K and is 1% above this. Wind has limit at 0.0001 K but is 1100% above this in the test. So the new partition functions makes about 0.01 K difference to built-in. I did not investigate why yet. Will make check so that the eternal partition function is valid for the provided atmospheric temperature field. By Jana's advice, the check should allow us to forcefully calculate with a bad partition function, and I agree since it gives errors of only 0.01 K for the fast testcases, and we mostly care about larger errors. FIXME remaining: PF tag in Artscat5 (for easy playing with partition functions) does not work for now. * controlfiles/general/general.arts: Calls partition_functionsInitFromBuiltin. If you do not include general.arts, your controlfile will now fail. * src/CMakeLists.txt: Added linescaling.cc to handle scaling calculations. I wanted this part of LineRecord but this seems impossible since SpeciesAuxData is in absorption.h and linerecord.h is a dependency of absorption.h. * src/absorption.{cc,h}: Appended old partition calculation functions to _OldUnused. These should be removed at some point. partition_functions is now passed along to xsec_species and xsec_species_line_mixing_wrapper. GetLineScalingData moved from LineRecord to linescaling.cc so absorption.cc depends on linescaling.h. I also changed xsec_single_line so the numeric isotopic ratio is passed on instead of the SpeciesAuxData variable since I found that part strange. * src/linerecord.{h,cc}: Moved GetLineScalingData from linerecord. * src/linescaling.{cc,h}: New files. To keep line scaling data separated from absorption.cc. * src/m_abs.cc, src/m_zeeman.cc, src/methods.cc, src/zeeman.{cc,h}: All pass partition_functions onto linescaling. 2015-06-25 Oliver Lemke * arts-2-3-257 * More work towards better partition functions handling. Goal is to be able to load them from a file just like isotopologue ratios. Work in progress. * src/workspace.cc: Add WSV partition_functions. * src/methods.cc, m_abs.cc: Add WSM partition_functionsInitFromBuiltin. * src/absorption.{cc,h}: (fillSpeciesAuxDataWithPartitionFunctionsFromSpeciesData): Added. (SpeciesAuxData::AuxType): Change enum prefix from PT_ to AT_. (IsotopologueRecord): Add member functions to get access to coefficients, the corresponding grid and the type. * src/partition_function_data.cc: (define_partition_species_data): Add missing continua SelfContHo66 and ForeignContHo66 to CO2. (next_species): Renamed from spec for clarity. Add doc string. * CMakeLists.txt: Add -Wno-strict-overflow if available. Silences unhelpful warning appearing only on some GCC versions. 2015-06-25 Richard Larsson * arts-2-3-256 * src/absorption.{cc,h}: Added partition function types to enum. No calculations yet. 2015-06-25 Oliver Lemke * arts-2-3-255 * src/absorption.{h,cc}: Move definition of SpeciesAuxTypeNames from .h to .cc file. It's only used internally. Also fixes warning from GCC about unused variable. (SpeciesAuxData::ReadFromStream): Use explicit cast from Index to Numeric in nlinspace to avoid compiler warning. 2015-06-24 Oliver Lemke * arts-2-3-254 * src/absorption.{cc,h} (SpeciesAuxData): Change internal implementation to make it possible to store more complex auxiliary data. Each isotopologue can now be associated with an ArrayOfGriddedField1. Preparation to store partition functions externally. * src/xml_io_compound_types.cc: Adapt the read/write routines for SpeciesAuxData. Format version increased to 2. Old format 1 data can still be read and converted to version 2. * src/zeeman.cc (set_quantum_numbers, set_part_isotopolouge_constants): Adapted for changes in SpeciesAuxData. * src/m_zeeman.cc, src/zeeman.{cc,h} (set_part_isotopologue_constants): Fix typo in function name. 2015-06-23 Jana Mendrok * arts-2-3-253 * src/m_jacobian.cc (jacobianDoitAddSpecies, jacobianDoitClose, jacobianDoit): Set and make use of jacobian_indices. Additionally, jacobian_quantities now also provides the retrieval/perturbation grids consistently with jacobian_quantities in clearsky jacobian case. Avoid clearsky/cloudy jacobian conflicts by throwing error if jacobian_do is 1. (jacobianOff): Added jacobianDoit_do, also set to 0. * src/methods.cc, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Adapted to changes above. * src/workspace.cc, src/check_input.cc, controlfiles/instruments/ici/TestICI_fast.arts, controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts, TestAMSU_generic.arts, controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/mhs/TestMHS_generic.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, TestWfuns.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, TestMonteCarloDataPrepare.arts, TestMonteCarloGeneralGaussian.arts, TestRteCalcMC.arts, controlfiles/artscomponents/faraday/TestFaradayRotation.arts controlfiles/artscomponents/clearsky/TestBatch.arts controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts, TestClouds_Mars.arts, controlfiles/artscomponents/absorption/TestAbs.arts, TestAbsParticle.arts, controlfiles/artscomponents/cia/TestCIA.arts, controlfiles/artscomponents/groundbased/TestGbased.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: Removed spurious leftovers of nlte_checked. 2015-06-23 Richard Larsson * arts-2-3-252 Updated non-LTE formalism in ARTS to fit with Patrick's suggestion to only return the difference between LTE and non-LTE source term. That is, instead of doing dy/ds = - K*y + E*B, we now assume that dy/ds = - K*y + K*B + J_n for the radiative transfer. In this equation, J_n = (E-K)*B, and it is returned from propmat_clearsky_agenda when nlte_do is true. As a consequence of these changes propmat_source_clearsky has been removed from workspace and all functions that previously had to return it so that E would be complete for all absorption cases. (This also saves some time, since, e.g., continua will no longer have to add onto E, since its non-LTE contribution is nil, its J_n contribution is also nil.) One negative consequence of this update is that it also formally changes a behavior of m_rte.cc. Previously, E was pressure level-averaged for a layer in m_rte.cc so that E_bar was (E'+E'')/2, where E_bar is the average and E' and E'' is the E of two adjacent levels. This E_bar was multiplied by Planck's function in emission_rtstep, and Planck's function was also averaged over two levels so B_bar = (B'+B'')/2. Thus we had (E'B'+E'B''+E''B'+E''B'')/4 as the second term of the first equation above. Now, since J_n is returned per level, J_n_bar = ([E'B'-K'B'+E''B''-K''B'')/2, and since K*B is averaged as before, i.e., K_bar*B_bar = (K'B'+K'B''+K''B'+K''B'')/4, we end up with K_bar*B_bar+J_n_bar = (2E'B'-K'B'+K'B''+2E''B''-K''B'+K''B'')/4. The difference above is of course very small when K or B remains fairly close to K_bar or B_bar, respectively, but is nevertheless there and I do not know how to deal with it. Nor do I know if the previous formalism was better or worse than present formalism for our layer formations. I suspect that the ideal solution is to force both of these definitions of K*B+J_n to be similar in the pathing somehow, so as to ensure that the atmospheric absorption is not misscalculated, but this is not part of the present update. * controlfiles/artscomponents/stokesrot/TestStokesRotation.arts: Now touches nlte_source instead of propmat_source_clearsky. * src/absorption.cc: xsec_single_line now returns source cross-section as source non-LTE ratio minus absorption non-LTE ratio times the LTE cross-section, instead of, as it did before, the source non-LTE ratio times the LTE cross-section. * src/agendas.cc: propmat_source_clearsky is replaced by nlte_source in propmat_clearsky_agenda. * src/m_abs.cc: nlte_sourceFromTemperatureAndSrcCoefPerSpecies added. This function multiplies the coefficients with the Planck function. Removed source from propmat_clearskyAddFromAbsCoefPerSpecies. Removed source calculations from all workspace methods that do not need it. * src/{m_,}zeeman.{cc,h}: Changed to the new behavior. * src/rte.{cc,h}: Changed emission_rtstep to take sourcebar as input. Behavior inside should be identical but as above, averaging is done elsewhere now. get_ppath_pmat returns ppath_nlte_source instead of ppath_abs. Same size of both variabels. * src/m_rte.cc: This is where averaging now happends over J_n instead of over E, causing the concern raised above. In iyEmissionStandard. Remaining unlisted files all comply with changes mentioned. Basically, a few names have changed. That is all. 2015-06-22 Richard Larsson * arts-2-3-251 Added a few tests to reduce assertion risk for people trying to trigger NLTE assertions. With these additions, it should not be possible to trigger assertion errors anymore. * src/m_linerecord.cc: Tests that vibrational energies are larger than 0. * src/linerecord.{cc,h}: Line scaling now depends on NLTE condition to stop people from setting up NLTE condititions and then turning them off again to find an assertion. 2015-06-22 Oliver Lemke * arts-2-3-250 * Changed how to setup nlte calculations. Similar to jacobians, sensor and cloudbox, there is one method to turn NLTE calculation off (nlteOff). It resizes NLTE data structure to empty and sets the new WSV flag ntle_do to 0. NLTE calculations are enabled by setting up the input data and then calling nlteSetByQuantumIdentifiers. This method also sets the new WSV flag nlte_do to 1. There will be more nlteSet* methods in the future. * controlfiles/general/general.arts: Replace Tensor4SetConstant for t_nlte_field and Touch nlte_quantum_identifiers by nlteOff. Eventually, ntlteOff should be removed from here and added to all controlfiles. This would be consistent with sensorOff, cloudboxOff and jacobianOff. * src/workspace.cc: Add new flag nlte_do. * src/methods.cc, src/m_checked.cc (nlteOff): New WSM to turn NLTE calculations off. * src/m_linerecord.cc (nlteSetByQuantumIdentifiers), src/methods.cc: Renamed from abs_lines_per_speciesMatchNLTEQuantumIdentifiers. Added call to new chk_nlte function. * src/m_abs_lookup.cc (calc_lookup_error), src/m_abs.cc (abs_xsec_per_speciesInit): nlte_checked -> nlte_do * src/check_input.{cc,h} (chk_nlte), src/m_checked.cc (ntle_checkedCalc): Former WSM ntle_checkedCalc moved from m_checked to check_input and adapted. * controlfiles/artscomponents/**/*.arts, controlfiles/instruments/odinsmr/TestOdinSMR.arts, controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts: Remove nlte_checkedCalc. * src/absorption.cc (xsec_species_line_mixing_wrapper): Ident. 2015-06-18 Jana Mendrok * arts-2-3-249 * controlfiles/artscomponents/clearsky//TestBatch.arts, TestBatch.ybatch.ref.xml: Added. A clear-sky batch test case/example including lookup table calculation. * controlfiles/CMakeLists.txt: Added the above. Moved AbsParticle test to category 'slow'. 2015-06-18 Jana Mendrok * arts-2-3-248 * controlfiles/artscomponents/arts-xml-data/ TestPlanetIsoRatios.[Venus,Mars,Jupiter].y_reference.xml: Corrected reference values (accidentially the previous references corresponded to old line data). 2015-06-18 Oliver Lemke * arts-2-3-247 * src/quantum_parser_hitran.cc: (parse_a1_sym_hitran): Ignore 'g' for O2 (only appears for lines between 30 and 990 kHz). This appears to be another undocumented case. The HITRAN documentation only describes 'd' and 'q' as possible values for O2. Reported by Mathias. (parse_a1_br_hitran): Allow letters up to 4 clicks away from Q. * src/quantum.{cc,h} (operator<<, operator>>, Set, IsValidQuantumNumberName): Added missing quantum number 'Sym'. 2015-06-18 Patrick Eriksson * arts-2-3-246 * Added usage of .empty() in functions listed below. This is just what I found by a quick search for == 0 in the files considered. .empty() should likely be used at many more places. But this I leave for others / the future. * src/m_doit.cc (doit_conv_flagAbsBT, doit_conv_flagLsq) (doit_i_fieldUpdate1D, doit_i_fieldUpdateSeq1D, DoitInit) (DoitCalc): * src/m_checked.cc (sensor_checkedCalc): * src/m_cloudbox.cc (cloudboxSetAutomatically, ParticleTypeAdd) (ParticleType2abs_speciesAdd, pnd_fieldCalcFrompnd_field_raw): * src/m_atmosphere.cc (FieldFromGriddedFieldCheckLatLonHelper): * src/m_montecarlo.cc (MCGeneral): * src/m_rte.cc (yCalcAppend, yCalc): * src/m_sensor.cc (sensor_responseAntenna) (AntennaMultiBeamsToPencilBeams, sensor_responseBackendMetMM) (sensor_responseInit): * src/m_jacobian.cc (jacobianClose): * src/rte.cc (get_ppath_pmat): 2015-06-18 Oliver Lemke * arts-2-3-245 * src/matpack{I,II,II,IV,V,VI,VI}.{cc,h}, src/test_matpack.cc: Add 'empty' member function to all matpack-Const* types. It returns true if any dimension is of length zero. * ChangeLog: Remove conflict marker. 2015-06-18 Richard Larsson * arts-2-3-244 * src/methods.cc: Added text to better describe line matching functions. Suggested by Patrick. 2015-06-17 Patrick Eriksson * arts-2-3-243 * controlfiles/general/general.arts: Added a temporary solution, to get qarts to work without a lot of hazzle: Touch( nlte_quantum_identifiers ) 2015-06-17 Jana Mendrok * arts-2-3-242 * controlfiles/artscomponents/arts-xml-data/ TestPlanetIsoRatios.[Venus,Mars,Jupiter].y_reference.xml: Added reference data missing in commit arts-2-3-240. 2015-06-17 Oliver Lemke * arts-2-3-241 * This code was provided by Richard and committed by me after fixing the bug mentioned further down in my changes: * src/linerecord.h (SetElow): Added. * src/methods.cc, src/m_linerecord.cc (abs_linesReplaceWithLines, abs_linesReplaceParameterWithLinesParameter): Added methods to replace line data. The lines are matched by quantum numbers. * My changes: * src/pressurebroadeningdata.cc (PressureBroadeningData::GetVectorFromData): Fix bug in indexing for PB_AIR_AND_WATER_BROADENING that left uninitialized values. * src/linerecord_partitionfunctiondata.cc (PartitionFunctionData::Type2StorageTag): Remove string resize statement that has no effect. * src/linerecord.h (SetPartitionFunctionData, SetLineMixingData, SetPressureBroadeningData): Pass function arguments by reference to avoid unnecessary copying of objects. * m_linerecord.cc (abs_linesReplaceParameterWithLinesParameter): Change type of lr inside loop to a const reference to avoid unnecessary copying of line records. * src/m_linerecord.cc (abs_linesReplaceWithLines, abs_linesReplaceParameterWithLinesParameter): Define ostringstream only where needed because it is expensive to create. 2015-06-17 Jana Mendrok * arts-2-3-240 * adapted ARTS-XML-DATA-2-2-3 equivalent changes: * controlfiles/artscomponents/absorption/IsoRatios_H2O[orig,mani].xml: Updated N2 iso ratios to state of built-in data (which had changed by 2014-04-07). Fixes broken TestIsoRatio.arts case. * controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios.arts, TestPlanetIsoRatios.[Venus,Mars,Jupiter].y_reference.xml: Apply Compare. Reference data for PlanetIso case added. * doc/uguide/absorption_theory.tex, absorption.tex: Spell/Grammar fixes. 2015-06-16 Jana Mendrok * arts-2-3-239 * src/cloudbox.cc (pnd_fieldMP48): Modified to be consistent with dNdD_MP48, now both applying PRtopnd_MP48. Improved mean density estimation initialization. (PRtopnd_MP48): Fixed bug in distribution parameter setting. * src/m_cloudbox.cc (dNdD_MP48): Introduced choice of input unit. Mimicking unit conversion done in pnd_fieldMP48 as far as possible. * src/methods.cc (dNdD_MP48): Adapted to interface changes due to unit conversion change above. Corrected documentation. (dNdD_*): Removed misleading info in explanation. Added unit info to output parameter descriptor. 2015-06-16 Richard Larsson * arts-2-3-238 WARNING: This update breaks your controlfiles. It adds a test for NLTE compatibility mode for the setups. If you run AtmRawRead in the past, and you have abs_lines_per_species, abs_xsec_agenda, and propmat_clearsky_agenda defined, you should apply nlte_checkedCalc before calling either of the previous agendas. If you do not call AtmRawRead or have not defined abs_lines_per_species, you must either manually set nlte_checked using FlagOn( nlte_checked ) to call these agendas, or you should define t_nlte_field and nlte_quantum_identifiers as zero-sized variables and call nlte_checkedCalc. In the controlfiles included with ARTS FlagOn( nlte_checked ) is used to flag NLTE as safe in those files that are affected. It is recommended to use the other approach whenever possible, and run the full nlte_checkedCalc. * src/linerecord.cc: Fixed bug in NLTE code. Forgot to divide energy by Boltzmann's constant. * src/m_abs.cc, src/methods.cc: abs_xsec_per_speciesInit, abs_xsec_per_speciesInitWithSource, propmat_clearskyInit, and propmat_clearskyInitWithSource now demands that nlte_checked is true. * src/m_abs_lookup.cc: In manual Init-call the nlte_checked is set to one, as this is how propmat_clearsky_agenda_checked is handeled. * src/m_checked.cc: Ironed out some bugs in the checking routine. * src/m_linerecord.cc: Added strict uniqueness check to abs_lines_per_speciesMatchNLTEQuantumIdentifiers so no QuantumIdentifier is overwriting another QuantumIdentifier. * These files have FlagOn( nlte_checked ): controlfiles/artscomponents/absorption/TestAbs.arts controlfiles/artscomponents/absorption/TestAbsParticle.arts controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts controlfiles/artscomponents/cia/TestCIA.arts controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts controlfiles/artscomponents/doitbatch/TestDOITBatch.arts controlfiles/artscomponents/faraday/TestFaradayRotation.arts controlfiles/artscomponents/groundbased/TestGbased.arts controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts controlfiles/artscomponents/wfuns/TestDoitJacobians.arts controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts controlfiles/instruments/amsu/TestAMSU_generic.arts controlfiles/instruments/hirs/TestHIRS.arts controlfiles/instruments/ici/TestICI_fast.arts controlfiles/instruments/mhs/TestMHS_generic.arts controlfiles/instruments/odinsmr/TestOdinSMR.arts * These files have nlte_checkedCalc: controlfiles/artscomponents/absorption/TestAbsDoppler.arts controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts controlfiles/artscomponents/absorption/TestIsoRatios.arts controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios.arts controlfiles/artscomponents/arts-xml-data/TestSpectro_core.arts controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts controlfiles/artscomponents/cia/TestRTwithCIA.arts controlfiles/artscomponents/clearsky/TestClearSky.arts controlfiles/artscomponents/clearsky/TestClearSky2.arts controlfiles/artscomponents/doit/TestDOITprecalcInit.arts controlfiles/artscomponents/doit/doit_calc.arts controlfiles/artscomponents/groundbased/TestFgrid.arts controlfiles/artscomponents/groundbased/TestWinds.arts controlfiles/artscomponents/linemixing/TestLineMixing.arts controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman.arts controlfiles/artscomponents/linemixing/TestLineMixingAndZeemanPreCalc_50_to_70_GHz.arts controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_GHz.arts controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts controlfiles/artscomponents/radiolink/TestRadioLink.arts controlfiles/artscomponents/radiolink/TestRadioLink2.arts controlfiles/artscomponents/radiolink/TestRadioOccultation.arts controlfiles/artscomponents/regrid/TestRegridFields.arts controlfiles/artscomponents/transmission/TestTransmission.arts controlfiles/artscomponents/wfuns/TestWfuns.arts controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts controlfiles/artscomponents/zeeman/TestZeeman.arts controlfiles/artscomponents/zeeman/TestZeemanPreCalc.arts controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts 2015-06-12 Oliver Lemke * arts-2-3-237 * src/quantum_parser_hitran.{cc,h}: Added support for OH. Added special case for group 6 for OH (GI_GROUP6OH) because the catalog format is different for this molecule than for others. Set group 6 to undefined for NO, ClO, OH and don't parse it due to undetermined format issue of the catalog that need further investigation. We compile a list with these issues to ask to the HITRAN guys. (postprocess_group6oh_hitran): Added. * src/linerecord.cc (LineRecord::ReadFromHitran2004Stream): Remove old quantum number parsing code. All molecules that were supported by the old code are now covered by the new quantum parser. * src/m_linerecord.cc (abs_lines_per_speciesMatchNLTEQuantumIdentifiers): Use proper != comparison operator instead of (!X == Y). 2015-06-12 Richard Larsson * arts-2-3-236 * src/m_checked.cc: Added test for LTE case to ensure that overflow does not occur in low level functionality (nlte_checkedCalc). * src/quantum_parser_hitran.cc: Added quantum parsing to CO2, H2O, and O3. Their quantum numbers should now be read properly, except for the local "Sym" field of CO2. We are still debating how to set "Sym"- fields consistently. 2015-06-11 Oliver Lemke * arts-2-3-235 * src/quantum_parser.h, src/quantum_parser_hitran.cc: Added species argument to parsing functions to cover species dependent special cases in catalog format. Added support for NO2, HO2, NO, ClO. * src/linerecord.cc (LineRecord::ReadFromHitran2004Stream): Use quantum parser instead of the old code for the added species. 2015-06-11 Richard Larsson * arts-2-3-234 This update brings the required user space availability to the low level NLTE variables. At the moment, this requires using Artscat5 to set relevant quantum numbers for the mathing functions to work, or to use HITRAN for those species that have quantum number reading. The new parser from Oliver will be used to read more quantum numbers for more species directly from HITRAN in a few updates. I will add a test case and documentation when I am more certain we are doing things the right way. * src/linerecord.cc: The previously inactivated NLTE part is now active again in (GetLineScalingData). If no NLTE information is available to the line, then it will behave as if using atmospheric temperatures. * src/linerecord.h: Added four line state parameters for NLTE. These are used in (GetLineScalingData) and set externally. * src/lineshapes.cc: Minor fixes to make formatting work with my IDE for (faddeeva_algorithm_916). * src/m_atmospheres.cc: Made nlte_quantum_identifiers a default output for (AtmRawRead) and (AtmWithNLTERawRead). (AtmWithNLTERawRead) throws a quandary if nlte_quantum_identifiers and t_nlte_field_raw are not of the same size. * src/m_checked.cc: Added a, for now, non-default test of the NLTE setup. This will catch errors in source function definitions in the two relevant agendas. Not run by default for now. * src/m_linerecord.cc: Added function to make lines aware of their NLTE data. (abs_lines_per_speciesMatchNLTEQuantumIdentifiers) can also set the vibrational energies of the lines as a GIN. This is presently the only way to set vibrational energies. * src/methods.cc: Modified: AtmWithNLTERawRead and AtmRawRead. Added: abs_lines_per_speciesMatchNLTEQuantumIdentifiers and nlte_checkedCalc. * src/workspace.cc: Added: nlte_checked and nlte_quantum_identifiers. 2015-06-11 Oliver Lemke * arts-2-3-233 * New quantum number parser. Work in progress. Only O2 is supported right now. * src/quantum_parser.h, src/quantum_parser_hitran.{cc,h}: Implemented new parser to replace the quantum number parsing code in LineRecord::ReadFromHitran2004Stream with a more generic version. * src/CMakeLists.txt: Add quantum parser cc files. * src/array.h (Array::push_back_n): Add convenience function to add the same element several times. * src/linerecord.cc (LineRecord::ReadFromHitran2004Stream): Use the new parser for O2 quantum numbers. * src/quantum.{cc,h}: Added QN_alpha. 2015-06-10 Richard Larsson * arts-2-3-232 * src/quantum.{h,cc}, src/linerecord.cc: Added and changed some quantum number names to be consistent with HITRAN. 2015-06-09 Richard Larsson * arts-2-3-231 Reverting some files by Patrick's advice. * src/agendas.cc: Reverting iy_main_agenda to not take t_nlte_field. Changed all other code back to previous executing style. * controlfiles/artscomponents/surface/TestSurface.arts: Now touch t_nlte_field. * src/m_cloudradar.cc,src/m_doit.cc,src/m_jacobian.cc, src/m_rte.cc,src/m_surface.cc: No more dummy t_nlte_field. * src/methods.cc: No t_nlte_field in yCalc and iyCalc. * src/rte.{cc,h}: So get_iy, iyb_calc, and iyb_calc_body no longer has t_nlte_field as input. 2015-06-09 Jana Mendrok * arts-2-3-230 * src/m_cloudbox.cc (ScatteringParticleTypeAndMetaRead): Removed spurious cout. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: Minor clean up. 2015-06-09 Richard Larsson * arts-2-3-229 * src/absorption.cc: Changed how non-resonant O2 is handled. Now the method follows from the Debye lineshape approximating VVW/2 line shape. * src/linemixingdata.{cc,h}: Adapted tag. This could break old Artscat5 files but the physics is better. LM NR -0.5 now adapts VVW line shape to VVW/2 for the non-resonant line/band of AER's catalog. * src/lineshapes.cc: Added comment that the lineshape for O2 non-resonant is not used and should not be used. Should it be removed? 2015-06-09 Oliver Lemke * arts-2-3-228 * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts, controlfiles/artscomponents/helpers/TestRegridding.arts: Adapt ERA40 path for restructured arts-xml-data. 2015-06-09 Jana Mendrok * arts-2-3-227 * m_cloudbox.cc, methods.cc (ScatteringParticleTypeAndMetaRead): Pass scat_data locations as ArrayOfString instead of in a file. Derive meta data location from scat_data location applying naming convention scat_data: */*.xml* -> scat_meta: */*.meta.xml*. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestDoitJacobians.arts: Adapted to ScatteringParticleTypeAndMetaRead changes. * controlfiles/testdata/ScatteringMetaFile_H2Oliquid.xml, SingleScatteringFile_H2Oice.xml, ScatteringMetaFile_H2Oice.xml, SingleScatteringFile_H2Oliquid.xml: Adapt for ScatteringParticleTypeAndMetaRead changes (we can't build relative paths from the file-of-files anymore). 2015-06-09 Oliver Lemke * arts-2-3-226 * src/linerecord.cc (ReadFromArtscat5Stream): Don't throw a runtime error for invalid lower quantum numbers. The invalid number could be the next tag. If it isn't, an error is thrown anyway in the next step when it's parsed as a tag. Fixed bug reported by Richard. 2015-06-08 Richard Larsson * arts-2-3-225 WARNING: This update breaks controlfiles that use AtmRawRead wit static parameters. It also breaks controlfiles that specifies their own propmat_clearsky_agenda, abs_xsec_agenda, and iy_main_agenda. To fix, Ignore() the workspace in the error of the agendas, and switch to the new way to use AtmRawRead, i.e., AtmRawRead(basename = basename). Alternatively, you can t_nlte_field_raw in the documented position to continue using the old static call. As is, this code passes the full checks. The intrusive change is necessary because we must pass the non-LTE temperatures along to the absorption agenda in a sane manner (my own method is not to use for mass adoption). * controlfiles/{artscomponents,planetary_toolbox,instruments}/*: Changed AtmRawRead to only give the basename, and to ignoring the agenda variables where special agendas are defined. * controlfiles/general/agendas.arts: Automatically ignore t_nlte_field in unaffected iy_main_agenda. * controlfiles/general/general.arts: Defines t_nlte_field as 0-sized. * src/absorption.{cc,h}: (xsec_species) takes abs_t_nlte. This is passed along as a vector to the line strength scaling function. (xsec_species_line_mixing_wrapper) also takes abs_t_nlte and treats it the same as does (xsec_species). * src/agendas.cc: rtp_temperature_nlte is passed to propmat_clearsky_agenda, abs_t_nlte is passed to abs_xsec_agenda, and t_nlte_field is passed to iy_main_agenda. * src/disort.cc: (dtauc_ssalbCalc) calls propmat_clearsky_agendaExecute with a dummy rtp_temperature_nlte. * src/doit.cc: (cloud_RT_no_background) calls propmat_clearsky_agendaExecute with a dummy rtp_temperature_nlte. (cloud_ppath_update1D_planeparallel) calls propmat_clearsky_agendaExecute twice with a dummy rtp_temperature_nlte. * src/linerecord.{cc,h}: Fixed small bug with O2 quantum numbers. O2 only has v1 regardless of ARTSCAT-4 reporting 3 v-numbers. Also changing (GetLineScalingData) since we need to treat this in another way than before. This function is still in transition... so it produces a warning that will be removed as soon as we have better quantum number reading available for HITRAN. * src/m_abs.cc: (AbsInputFromRteScalars) now also works on abs_t_nlte and rtp_temperature_nlte. (abs_xsec_per_speciesAddLine) now takes abs_t_nlte as input so that abs_t_nlte can be passed to (xsec_species) or (xsec_species_line_mixing_wrapper). (propmat_clearskyAddOnTheFly) Now takes rtp_temperature_nlte and converts it to abs_t_nlte through (AbsInputFromRteScalars) to pass abs_t_nlte along to abs_xsec_agendaExecute. * src/m_abs_lookup.cc: (abs_lookupCalc) now passes a dummy this_t_nlte variable to abs_xsec_agendaExecute. (propmat_clearsky_fieldCalc) now passes a dummy rtp_temperature_nlte to propmat_clearsky_agendaExecute. Most infrastructure is already in place to have the propmat_field calculated using the non-LTE temperatures. (calc_lookup_error) passes a dummy rtp_temperature_nlte to (propmat_clearskyAddOnTheFly). * src/m_atmosphere.cc: (AtmFieldsCalc) now takes t_nlte_field_raw to compute t_nlte_field. Optional behaviour can be set using nlte_when_negative (see documentation). The non-LTE interpolation follows closely the implementation of the VMR interpolation, using the same functions except when nlte_when_negative is given. (AtmFieldsCalcExpand1D) behaves the same as (AtmFieldsCalc). (AtmRawRead) must now set t_nlte_field_raw to zero-size for other functions to behave as expected. This breaks a lot of controlfiles using the static variable passings to AtmRawRead. (AtmWithNLTERawRead) is new identical to (AtmRawRead) except that it expects there to be a $BASENAME.t_nlte.xml file in the basename directory. And that this file should contain the non-LTE state of the atmosphere. The functionality of (AtmWithNLTERawRead) could still change to also require $BASENAME.qi.xml for quantum identifiers and even $BASENAME.ev.xml for state energies, but me and Oliver are still in discussions on how to implement this in the best way, * src/m_cloudradar.cc: (iyCloudRadar) Now creates a dummy t_nlte_field to pass along to (get_ppath_atmvars) so that ppath_t_nlte can be set. ppath_t_nlte is then passed to (get_ppath_pmat). (yCloudRadar) creates a dummy t_nlte_field to pass into iy_main_agendaExecute. * src/m_doit.cc: (DoitGetIncoming) creates a dummy t_nlte_field to pass into (get_iy). (DoitGetIncoming1DAtm) mimics the above. * src/m_fos.cc: (fos) mimics (iyCloudRadar). * src/m_jacobian.cc: (jacobianCalcAbsSpeciesPerturbations) creates a dummy t_nlte_field to send into (iyb_calc). (jacobianCalcTemperaturePerturbations) does the same as above. (jacobianDoit) sends a dummy t_nlte_field to (yCalc) twice. * src/m_rte.cc: (iyCalc) takes t_nlte_field as input to execute iy_main_agendaExecute. (iyEmissionStandard) also takes t_nlte_field as input to calculate ppath_t_nlte, which is used in (get_ppath_pmat). (yCalc_mblock_loop_body) also takes t_nlte_field as input to pass into (iyb_calc). (yCalc) takes t_nlte_field as input to pass into (yCalc_mblock_loop_body) twice. (yCalcAppend) also takes t_nlte_field as input to pass into (yCalc). * src/m_surface.cc: (iySurfaceFastem) creates a dummy t_nlte_field to pass to iy_main_agendaExecute. (iySurfaceRtpropAgenda) and (iySurfaceRtpropCalc) behaves the same. * src/m_transmitter.cc: (iyRadioLink) mimics (iyCloudRadar). (iyTransmissionStandar) mimics (iyCloudRadar) as well but passes the dummy t_nlte_field to more get_ppath_pmat. * src/m_zeeman.cc: (propmat_clearskyAddZeeman) takes rtp_temperature_nlte as input, turns it into a Matrix in AbsInputFromRteScalars, and pass it along to (xsec_species_line_mixing_wrapper_with_zeeman). (propmat_clearskyAddZeemanFromPreCalc) mimics the above. * src/methods.cc: (AtmWithNLTERawRead) is new and behavior explained above. The methods that have been changed otherwise are: AbsInputFromRteScalars, abs_xsec_per_speciesAddLines, AtmFieldsCalc, AtmFieldsCalcExpand1D, AtmRawRead, iyCalc, iyEmissionStandard, propmat_clearskyAddOnTheFly, propmat_clearskyAddZeeman, propmat_clearskyAddZeemanFromPreCalc, yCalc, and yCalcAppend. * src/montecarlo.cc: (clear_rt_vars_at_gp) sends a dummy rtp_temperature_nlte into propmat_clearsky_agendaExecute. (loudy_rt_vars_at_gp) does the same. * src/rte.{cc.h}: get_iy has t_nlte_field as input to pass into iy_main_agendaExecute. (get_ppath_atmvars) outputs ppath_t_nlte from t_nlte_field that has been interpolated per nlte energy level into a matrix similar to ppath_vmr. (get_ppath_pmat) now takes ppath_t_nlte as input to pass it into propmat_clearsky_agendaExecute if there are levels available. (iyb_calc_body) now takes t_nlte_field as input to pass it into iy_main_agendaExecute. (iyb_calc) also takes t_nlte_field as input to pass this into (iyb_calc_body). * src/zeeman.{cc,h}: (xsec_species_line_mixing_wrapper_with_zeeman) takes abs_t_nlte and pass it into (xsec_species_line_mixing_wrapper). * src/workspace.cc: abs_t_nlte is new. It behaves as the VMR equivalent and has size of nlte levels and p_grid, or 0. This will likely change to the size of an ArrayOfQuantumIdentifier -with_some_name- in the near future. rtp_temperature_nlte is also new. This also behaves the same as its VMR equivalent. Size is nlte levels or zero. t_nlte_field is also new. It has size [NLTE levels, p_grid, lat_grid, lon_grid ] or zero. t_nlte_field_raw is also new. It has size [NLTE levels][N_p, N_lat, N_lon]. All of the above behaves as the VMR equivalent but can be size zero when NLTE is not wanted. Also, instead of size from species, size is from the number of non-LTE levels. 2015-06-08 Oliver Lemke * arts-2-3-224 * src/quantum.{cc,h}: (QuantumNumbers::CompareDetailed): Added matching function that also returns details about the match (partial or full match). (QuantumMatchInfo): Class to hold information about how the quantum numbers matched (full or fartial match for now). * src/linerecord.{cc,h} (match_lines_by_quantum_identifier): New function to find matching lines by QuantumIdentifier. * src/methods.cc, src/m_general.cc (Test): Modified test method to show an example on how to use line matching by QuantumIdentifier. 2015-06-05 Oliver Lemke * arts-2-3-223 * src/linerecord.cc (ReadFromArtscat5Stream): Fix parsing bug introduced in arts-2-3-221. 2015-06-05 Oliver Lemke * arts-2-3-222 * src/groups.cc (define_wsv_group_names): Sort groups alphabetically. * src/m_jacobian.cc (jacobianDoitAddSpecies, jacobianDoit): Comment out names of unused arguments to silence compiler warning. * ChangeLog: Fix typo in previous entry. 2015-06-05 Oliver Lemke * arts-2-3-221 * src/quantum.{cc,h}: Implementation of new class QuantumIdentifier. * src/groups.cc, src/xml_io_array_types.cc, src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Added new WSV groups QuantumIdentifier and ArrayOfQuantumIdentifier and XML read/write support. * src/linerecord.cc (ReadFromArtscat5Stream): Better error detection when parsing quantum numbers. * src/xml_io_private.h, src/xml_io.cc (parse_xml_tag_content_as_string): Added. 2015-06-04 Oliver Lemke * arts-2-3-220 * CMakeLists.txt: Added workaround for detection of BLAS. Older cmake versions require fortran to be enabled for the FindBLAS macro to work. Therefore, for cmake < 2.8.8, fortran language support is now automatically turned on. 2015-06-03 Oliver Lemke * arts-2-3-219 * src/CMakeLists.txt, CMakeLists.txt: Fix bug in BLAS detection reported by jana. Cmake did not fail when the required BLAS library wasn't found. Instead compilation failed trying to link against -lOFF. Moved code from src/ to toplevel CMakeLists.txt file and changed detection code to be consistent with other libraries. * README: Added blas to required dependencies. 2015-06-02 Patrick Eriksson * arts-2-3-218 * src/m_rte.cc (iyCalc, yCalc_mblock_loop_body): Changed asserts in last commit into runtime errors. 2015-06-02 Patrick Eriksson * arts-2-3-217 * src/m_rte.cc (iyCalc, yCalc_mblock_loop_body): iy resp. y now asserted to not contain any NaN. 2015-06-02 Jana Mendrok * arts-2-3-216 * src/m_jacobian.cc (jacobianDoit): Skip DOIT calculation if effective perturbation is 0 (happens for rel perturbations if x_ref==0) and set respective jacobians directly to 0. 2015-06-01 Richard Larsson * arts-2-3-215 * src/zeeman.cc: Fixed bug reported by Patrick about source functions. For now the only test that fails when WithSource is active in Init is ycalcappend.TestYCalcAppend. Note that this does not mean that most tests even use the source. Big fixme remaining: The agenda checking must change so that we enforce InitWithSource in both the relevant agendas. 2015-06-01 Patrick Eriksson * arts-2-3-214 * src/m_rte.cc (iyEmissionStandard): Had missed the factor 0.5 when calculating absbar and extbar. * src/rte.cc (emission_rtstep): Complete code for non-LTE now in place. But lack proper tests to be totally sure that all OK. 2015-06-01 Patrick Eriksson * arts-2-3-213 * src/m_basic_types.cc (Compare): NaNs now handled. NaN compared to NaN is allowed. This gives a zero difference. But NaN compared to any other value results in an error. * src/rte.cc (emission_rtstep): Some code added for non-LTE (but it is not complete). 2015-06-01 Richard Larsson * arts-2-3-212 * src/lineshapes.cc: Added VVW factor ff / f0f0 to normalization. Needed for comparison with other models. 2015-06-01 Jana Mendrok * arts-2-3-211 * src/m_jacobian.cc (jacobianDoitAddSpecies): Disallow negative or zero perturbations. * src/math_funcs.cc (mod_gamma_dist): Remove misleading comment from error message. 2015-06-01 Richard Larsson * arts-2-3-210 * src/absorption.cc: Fix to a horrible bug in the phase calculations that I introduced with one of my previous commits. FIXME: I need to design a test that catches this error if I or someone else messes up the code again. Problem: phase matrix gives bad values but all Zeeman tests succeed. 2015-05-31 Patrick Eriksson * arts-2-3-209 * Work in progress ... * controlfiles/general/agendas.arts: Reverted template definitions of propmat_clearsky_agenda. Now propmat_clearskyInit used agian. * src/m_rte.cc (iyEmissionStandard): Adopted to changes in get_ppath_pmat and emission_rtstep. Code in place for calculation of spectra, but not for jacobians. The combination non-LTE and jacobians results in an error. * src/m_fos.cc (fos): Basic adoption to changes in get_ppath_pmat and emission_rtstep. So far just an error if there is any non-LTE point. * src/rte.cc (emission_rtstep): Extended to also have input arguments for non-LTE situations. But no code yet added for non_LTE. * src/m_cloudradar.cc (iyCloudRadar): * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): Updated to changes in get_ppath_pmat. All should be ready here as the methods do not operate with emission. * src/rte.cc (get_ppath_abs): Renamed * src/rte.cc (get_ppath_pmat): New name of function above. Two output arguments added, to handle introduction of propmat_source_clearsky. 2015-05-29 Oliver Lemke * arts-2-3-208 * controlfiles/general/agendas.arts: Replaced by richard's new version that caused crashes. See fix below. * src/m_abs_lookup.cc (abs_lookupCalc): Define src_xsec_per_species as private in OpenMP loop. Otherwise random crashes appear because the same variable is resized by different threads at the same time. 2015-05-29 Oliver Lemke * arts-2-3-207 * src/absorption.cc (xsec_single_line, xsec_species_linemixing_wrapper): Create a non-const empty Vector variable to fix error. This is necessary because objects that are created inline are constant! All tests succeed again. 2015-05-29 Richard Larsson * arts-2-3-206 Fix some bugs in the previous commit. Added initialization schemes for propmat_clearsky and abs_xsec_per_species that makes propmat_source_clearsky and src_xsec_per_species same as their older counterparts. When changeing agendas.cc to initialize with the new initilization schemes (since they should not change the older parts), then these errors remain: 35 - arts.ctlfile.fast.artscomponents.montecarlo.TestMonteCarloDataPrepare (OTHER_FAULT) 39 - arts.ctlfile.fast.instruments.amsu.TestAMSUB_fast (OTHER_FAULT) 40 - arts.ctlfile.fast.instruments.ici.TestICI_fast (OTHER_FAULT) 41 - arts.ctlfile.fast.instruments.mhs.TestMHS_fast (OTHER_FAULT) I tried fixing the montecarlo error but the program exits with "everything is fine", even though it reportedly fails. Same thing for the AMSUB testcase. So I am confused by these errors and gave up. * src/absorption.cc: Actually sends NLTE ratios into xsec_single_line now. * src/m_abs.cc: Fix some error handling. * src/methods.cc: The new methods are called propmat_clearskyInitWithSource and abs_xsec_per_speciesInitWithSource. * src/montecarl.cc: Left minimal formatting improvements around after giving up on the real problem. 2015-05-29 Richard Larsson * arts-2-3-205 This update adds the source function propagation matrix as output. This separate source function is required for NLTE capabilities. It is quite a touchy update for several files. The absorption part should work identically to as it did before. I still need to perform more tests to say when the source function behaves in a sane manner. In particular, more error catchers must be added. * src/absorption.{cc,h}: xsec_source added to xsec_species output. It is tested that this Matrix behaves the same as xsec_attenuation or that it is 0-sized. The latter means no direct source calculations, and the former means there are direct source calculations. xsec_species_line_mixing_wrapper also returns the source in the same way. xsec_single_line now takes different inputs than before, and one of these is the boolean calc_src to calculate the source. There is presently no way to use this feature, since I temporarily have disabled it due to NLTE temperature fields not being available yet. * src/agendas.cc: Added "propmat_source_clearsky" as output of "propmat_clearsky_genda" and added "src_xsec_per_species" as output of "abs_xsec_agenda". * src/linerecord.{cc,h}: All line strength scaling are now gathered in LineRecord::GetLineScalingData. The function follows Futbolin approach and outputs both nlte scalars as well as partition function and Boltzmann factors. * src/linerecord_partitionfunctiondata.{cc,h}: Are under reconstruction. Will change quite a lot soon. * src/m_abs.cc: Added src_coef, src_coef_per_species, and src_xsec_per_species to coefCalcFromXsec. Mimics the abs equivalent behavior when of the right size. abs_xsec_per_speciesInit inits src_xsec_per_species to a zero matrix with the same tag-length as abs_xsec_per_species. Init at other size than zero needs to be handled somehow still. abs_xsec_per_speciesAddLines calls xsec_species with src_xsec_per_species. abs_xsec_per_speciesAddConts mirrors src_xsec_per_species behavior to abs_xsec_per_species behavior if matrix is non-0-length. propmat_clearskyAddFromAbsCoefPerSpecies takes src_coef_per_species and inserts to propmat_source_clearsky if propmat_source_clearsky is non-empty. propmat_clearskyAddParticles mirrors propmat_source_clearsky to propmat_clearsky behavior if propmat_source_clearsky is non-empty. propmat_clearskyAddOnTheFly executes all of the abs_xsec_agenda with source-related inputs. propmat_clearskyForceNegativeToZero mirrors propmat_source_clearsky to propmat_clearsky behavior if propmat_source_clearsky is non-empty. propmat_clearskyZero and propmat_clearskyAddFaraday are ignored so if these are your only input you will have to touch propmat_source_clearsky. * controlfiles/artscomponents/stokesrot/TestStokesRotation.arts: Added Touch( propmat_source_clearsky ). * src/m_abs_lookup.cc: Has been mostly ignored. propmat_clearskyAddFromLookup adds the absorption to propmat_source_clearsky. Note that this means that lookup cannot handle source being different from absorption. * src/m_cia.cc: abs_xsec_per_speciesAddCIA mirors what happens in absorption to source if src_xsec_per_species is initialized. * src/m_zeeman.cc: Mirrors to propmat_source_clearsky except for what happens inside xsec_species_line_mixing_wrapper, which can diverge the two. Offers a polarized source function if initialized. propmat_clearskyAddZeeman and propmat_clearskyAddZeemanFromPreCalc behave qualitatively the same now as before. * src/zeeman.{cc,h}: xsec_species_line_mixing_wrapper_with_zeeman deals with the detailed handling of source function for Zeeman calculations * src/methods.cc: Changed those mentioned in this now very long text. * src/workspace.cc: Added propmat_source_clearsky, src_xsec_per_species, src_coef, and src_coef_per_species. Might have to update the text for these. * src/disort.cc,doit.cc,montecarlo.cc,rte.cc: All have dummy propmat_source_clearsky variables for now. 2015-05-25 Patrick Eriksson * arts-2-3-204 * src/methods.cc (define_md_data_raw): For abs_SpeciesSet, added "*abs_xsec_agenda_checked* and *propmat_clearsky_agenda_checked are set to be false." to on-line doc. * src/jacobian.cc (vmrunitscf): * src/m_jacobian.cc (jacobianDoitAddSpecies): * src/methods.cc (define_md_data_raw): Removed everything around logrel. This removes the logrel option from the standard jacobians. I also removed commented lines in the DOIT jacobians, to completly remove logrel from the code. To get a clean start if it will ever get back. 2015-05-22 Jana Mendrok * arts-2-3-203 * src/m_jacobian.cc, methods.cc: Abandoned "logrel" perturbation option (back to "abs" and "rel" only as "rel" is very similar to "log" and "logrel" regarding the perturbation part). 2015-05-19 Simon Pfreundschuh * arts-2-3-202 Implemented multiplication using BLAS. * src/blas.h Added a header file for the declarations of the external BLAS functions. * src/CMakeLists Linked matpack library to BLAS library. The BLAS library is detected automatically or can be set using the BLASDIR variable. * src/matpackI.h Added mult_general method for the original multiplication implementation that works on all matrices. * src/matpackI.cc Implemented multiplication using the dgemm_ routine for matrix multiplication from the BLAS library. Renamed the original implementation to mult_general which is used as fallback if the matrix operands are not continuous. * src/test_matpack Added test case to test the new matrix multiplication implementation against the old. * src/test_oem Adapted benchmark_mult to benchmark both multiplication methods. * src/test_utils.* File that contains functions that are useful for testing, such as computation of errors and generation of random data. 2015-05-17 Jana Mendrok * arts-2-3-201 * src/m_jacobian.cc, methods.cc: Changed DoitJacobian "logrel" option to use natural logarithm. Documentation adapted accordingly. 2015-05-17 Jana Mendrok * arts-2-3-200 * src/m_jacobian.cc (jacobianDoit): Added "logrel" perturbation option for abs_species and scat_species. Corrected perturbed field calc for "rel" option (now consistent with clearsky as x_pert=x_ref*(1.+dx) compared to x_pert=x_ref*dx before). * src/methods.cc: Moved a couple of WSM (which changed name in the recent past) into their supposed alphabetical order. 2015-05-12 Oliver Lemke * arts-2-3-199 * src/m_sensor.cc (f_gridFromSensor{HIRS,AMSU}): Port Mathias' fix from arts-2.2 for inaccuracies in the frequency grid creation. * controlfiles/instruments/hirs/TestHIRS.arts: Compare result against reference calculation. * controlfiles/instruments/hirs/TestHIRS.NOAA14.ybatch.ref.xml: Added. 2015-05-11 Richard Larsson * arts-2-3-198 This update adds preliminary support for NLTE calculations. I think that much of the code present will change a whole lot before the NLTE implementation is final but as far as I can tell at this point, it works. Still, consider this highly experimental code before you see a few more commits on this train of thought. * src/absorption.{cc,h}: Moved remaining line strength scaling out of xsec_single_line. Some variable names might get updated here in the future to reflect that the changes better. * src/linerecord.{cc,h}: This is where line strength scaling is now calculated in full. * src/linerecord_partitionfunctiondata.{cc,h}: Added PF_Tv for vibrational temperature calculations. Right now, this is an ugly implementation that requires input from ARTSCAT-5 of pressure grid, upper and lower energy state and upper and lower energy state's vibrational temperatures. Note that negative vibrational temperatures are tagged as atmospheric temperatures. This part still requires a lot of work to be usable but it operates similar to expectations... for now. * CHANGES-2.3: Added to ARTSCAT-5 that it does NLTE. With warnings that it is not well-tested and that I need to do more work on this. 2015-05-01 Simon Pfreundschuh * arts-2-3-197 Implemented linear OEM for data retrieval. Added randomized tests and benchmarks for OEM. Using the Matlab C++ interface, the tests use the OEM implementation in the atmlab package to validate the C++ implementation. I also implemented benchmarks in order to see how the C++ code performs. On my computer the C++ code was very slow, that means up to a factor of twenty slower. Since the linear OEM uses only matrix multiplication and inversion, it must be the primitive methods that are responsible for the bad performance. Maybe you could run the benchmarks on your machines. Since we want to use OEM with very large matrices, something must be done about this. I would propose to use LAPACK or something a similar library. LAPACK is built on BLAS whichs is also used by matlab as far as I know. The other possibility would be to optimize the existing code. I would like to hear your comments on that. To build the oem_test executable run cmake -DMATLABDIR=/path/to/your/MATLAB -DATMLABDIR=/path/to/your/atmlabx-x.x Running matlab from C++ also requires the c shell to be installed on your sysem. * src/oem.cc: The implementation of the linear OEM. * src/test_oem.cc: Tests and benchmarks for OEM. Starts a Matlab session and compares results and execution time to the OEM implementation in the atmlab package. Plots of the results are written to the test_oem_files folder in the binary folder. * src/CMakeLists.txt Added executable for oem tests including handling of the external dependencies on matlab and atmlab. * src/test_oem/test_mult.m Matlab script to benchmark matrix multiplication. * src/test_oem/test_inv.m Matlab script to benchmark matrix inversion. * src/test_oem/test_oem.m Matlab script to test linear oem inversion. * src/test_oem/linear_forward_model.m Matlab function representing a linear forward model. * src/test_oem/plot_script.m Matlab script to plot benchmark results. 2015-04-30 Oliver Lemke * arts-2-3-196 * src/m_jacobian.cc (jacobianDoit): Fix critical bug: In the loop where the dydx result vector is calculated, the index was missing. Thus, instead of writing into the right position in dydx, the whole vector was overwritten with a constant value in every iteration. This resulted for, e.g., constant results for all frequencies. Bug reported by Verena and Freddy. 2015-04-28 Oliver Lemke * arts-2-3-195 * tools/vim_syntax/update_vim_arts_syntax: Don't use '-s' option for which. Only known on BSD, not on Linux. 2015-04-28 Richard Larsson * arts-2-3-194 * doc/uguide/absorption_theory.tex: Changed after comments from Jana. Much more detailed tables and descriptions available now. 2015-04-24 Oliver Lemke * arts-2-3-193 * src/m_doit.cc b/src/m_doit.cc (DoitWriteIterationFields), src/methods.cc: Add generic input with frequency indexes. Adapt output filename to contain frequency index and iteration count. Avoids that iterations from different frequencies get overwritten. Changed value to select all frequencies / iterations from 0 to -1. Set default value for both. * CHANGES-2.3: Add changes from above. * controlfiles/artscomponents/doit/doit_setup.arts: Adapt call of DoitWriteIterationFields. * src/m_doit.cc (DoitCalc): Reenable parallelization of frequency loop. * src/parser.cc: Promoted several runtime_errors to ParseErrors to provide proper location information to the user. Better error message when default values in methods.cc for generic inputs contain errors. 2015-04-22 Patrick Eriksson * arts-2-3-192 * doc/uguide/winds.tex: Small change of equation for delta-nu, for better clarity. And added the expression for planet rotation pseudo-wind. 2015-04-18 Simon Pfreundschuh * arts-2-3-191 Dear all, This is my first commit. Maybe you could have a quick look whether the code is OK style-wise. * src/lin_alg.cc (lubacksub): Fixed potential bug in the handling of the pivot vector. The previous version deviated from the reference code in Numerical Recipes and produced incorrect results for certain row permutations. However, I am not quite sure whether the deviation from the reference implementation may have had a purpose, so maybe, Claudia, you could have a look at the code. The new code of course passes all relevant tests. * src/lin_alg.cc (inv): Implemented matrix inversion using LU decomposition * src/test_linalg.cc(test_solve_linear_system) Implemented randomized testing routing for the LU decomposition code, to make sure the code really produced incorrect results. * src/test_linalg.cc(test_inv) Randomized testing routing for matrix inversion. 2015-04-16 Patrick Eriksson * arts-2-3-190 * doc/uguide/faraday.tex: In equation for r, it was only \pi, but should be \pi^2. Also added description of some more of the variables in these equations. 2015-04-02 Richard Larsson * arts-2-3-189 Everyone, I would like to hear your comments on the added documentation! * doc/uguide/absorption_theory.tex: Added short text on Faddeeva function. It lacks references at the moment. At the end of line shape subsection, just before the partitoin function subsection. Added a short text on line mixing at the end of the spectroscopy section, just before the very short Zeeman effect entry. Added Artscat-5 line format table similar to Artscat-3 and Artscat-4. Added subsubsections on Artscat-5 pressure broadening and Artscat-5 line mixing. Both refer back to rpevious technical discussions. Key science question: I have only ever looked properly and indepth at molecular oxygen. O2 has no pressure shift. When I designed water and air broadening, I added a self pressure shift parameter, mostly because it looks symmetric for all species to have the same parameters of their own. Looking at the previous formats, such a parameter is not present anywhere. Is self pressure shift even possible or should we remove the parameter before the format gets used more? Documentation structure question: should we comment that PWR93 line shapes are the imaginary part of the Lorentzian times the first order line mixing correction plus the real part, or do you want to leave the full model section as is for the future? Is anything unclear about the added documentation? * doc/uguide/references.bib: Added a few references. Should more be added? Is any part under-referenced? 2015-03-30 Richard Larsson * arts-2-3-188 Structural changes to high level Artscat5 and to low level absorption scheme. Partition function is now calculated in a slightly altered manner. This new way should make it much easier to add individual partitions to lines, making it cleaner to interact with low level abbsorption schemes. The work is mostly preparatory at this stage for the additions of simple NLTE calculations within ARTS in the near future but is presently only capable of doing what has been done before with partition datan being built-in. That said, the scheme already allows the user to specify input an Artscat5 file with specialized coefficients for different temperature schemes, making it useful for planetary applications when todday's 150-350 K is not the best idea. * src/CMakeLists.txt: Added linerecord_partitionfunctiondata.cc. * src/absorption.cc: Changed so partition function is calculated in linerecord_partitionfunctiondata rather than directly through abs_species. * src/linerecord.cc: Added tag "PF" for partition function data from Artscat5 file format. This acts similarly to "LM" and "QN" and "PB". FIXME: Not certain about the write-back to XML file feature. Finally added GetPartitionFunctionData through which partition is calculated. * src/linerecord.h: Includes linerecord_partitionfunctiondata.h and has a PartitionFunctionData variable with a few methods of interaction similar to how LineMixingData works. * src/linerecord_partitionfunctiondata.{h,cc}: Added. Deals with partition function data per line. Defaults to built-in when no data is given. Note that it can presently only do exactly what built in is doing with coefficients and nothing more. The structure is so that it should be clean to extend this in the future. I am presently waiting for NLTE data where a pressure grid is gridded to a vibrational temperature. This will be added when the data is understood. 2015-03-25 Richard Larsson * arts-2-3-187 WARNING! This update break controlfiles. WARNING! * src/methods.cc: Renamed ZeemanLineRecordPreCalc to zeeman_linerecord_precalcCreateFromLines. (Also did plumbing for stuff seen below.) * src/m_linerecord.cc: added (abs_linesRelativeLineStrengthShift) to work on *abs_lines*. * src/m_zeeman.cc: Changed name of function shown at top. 2015-03-24 Richard Larsson * arts-2-3-186 Beta code. Do not use yet, behavior is not as predicted. * src/m_linemixing.cc: Added abs_linesShiftFrequency and abs_lines_per_speciesRelativeLineStrengthShift to do what their names suggest. * src/ methods.cc: Plumbing. 2015-03-20 Richard Larsson * arts-2-3-185 * src/m_linerecord.cc: Added as a way to collect methods to change the LineRecord. Presently only function is (abs_lines_per_speciesShiftFrequency), which shifts the freqeuncy of all lines in abs_lines_per_species by input frequency_shift. 2015-03-19 Jana Mendrok * arts-2-3-184 * src/m_cloudbox.cc (ParticleTypeAddAll): Bugfix. * controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts, controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: Adapt to ARTS changes. * controlfiles/planetary_toolbox/demos/passive/DemoVenus_fullRT_1D_cloudy.arts: Comment fix. 2015-03-19 Jana Mendrok * arts-2-3-183 * src/methods.cc (jacobianDoit, jacobianDoitAddSpecies): Proper built-in doc. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: iy_unit="1" setting no required for DoitCalc anymore. Removed. 2015-03-19 Richard Larsson * arts-2-3-182 * src/methods.cc (CIARecordReadFromFile): Changed documentation to point towards abs_speciesSet for the CIA tag name. 2015-03-19 Oliver Lemke * arts-2-3-181 * src/methods.cc (abs_speciesSet): Fix typo in CIA tag name. Thanks Richard! 2015-03-19 Oliver Lemke * arts-2-3-180 * src/methods.cc (abs_speciesSet): Add docs for CIA tags. * src/workspace.cc (abs_cia_data): Refer to abs_speciesSet for tag docs. 2015-03-19 Patrick Eriksson * arts-2-3-179 * src/workspace.cc: Fix in description of sensor_pol regarding LHC/RHC was not complete. 2015-03-18 Richard Larsson * arts-2-3-178 * src/m_cia.cc: Changed two functions to a single function with GIN option of clobbing new CIARecord instead of adding. By Oliver's suggestion. * src/methods.cc: Plumbing. * src/linerecord.cc: SO reading of quantum numbers added so as to allow Zeeman effect calculations on SO (application is Io). 2015-03-17 Richard Larsson * arts-2-3-177 * src/cia.{cc,h}: Added append CIARecord functionality to CIARecord. * src/m_cia.cc: Added direct reading of individual CIARecord HITRAN file function. Added Append abs_cia_data with CIARecord functionality. Added Clobber abs_cia_data with CIARecord functionality. All just copy-paste of previously internal functions. Usecase: We want to change between CIA models to allow He-H2 and H2-H2 below 600 GHz for JUICE SWI comparison. HITRAN provides two separate models. Original CIA is only for above 600 GHz. Testing required. By reading arts-xml-data CIA file, printing it, clobbing it with below 600 GHz data, printing the changed abs_cia_data, then reclobbing with above 600 GHz model, and printing again. Output in the end is not identical to as before. Consider this a beta run. * src/methods.cc: Plumbing. * src/groups.cc: CIARecord now visible from controlfile. 2015-03-17 Richard Larsson * arts-2-3-176 * controlfiles/general/moon_io.arts: Added Io standard moon. Will add rest of the interesting moons when required. Since isotopologue ratios are unknown, I set these to point at the Jupiter file. * the rest: Plumbing, also added Artscat-5 to Changes 2.3 since if anyone finds an out-and-about Artscat-5 they should be able to trace it back to a 2.3 feature. 2015-03-16 Oliver Lemke * arts-2-3-175 * src/methods.cc (ybatchCalc): Corrected documentation on robust option. It does work with numthreads>1. Thanks jana! * src/workspace_ng.cc (Workspace::del): Remove spurious &. Second condition in if statement always evaluated to true. No practical impact though. * Satisfy some complaints from the static analyzer: * src/file.cc (double_istream::parse_on_fail): Initialize variable. * src/gzstream.cc (gzstreambuf::underflow): Add assertion. * src/continua.cc (CKD_mt_250_co2): Compare int variable I1J to int value instead of float. * src/absorption.cc (SpeciesAuxData::ReadFromStream): Add initialization of variable. 2015-03-13 Jana Mendrok * arts-2-3-174 A first sufficiently stable and testes Doit Jacobians version. * src/m_jacobian.cc (jacobianDoit): Added y of non-perturbed case as output. Added a robust option to avoid complete fail e.g. for partly unphysical perturbations. Added a FIXME list. Fixed bug in presence check of perturbed scat_species. * src/m_optproperties.cc (pha_mat_sptFrom*): Added check that scat_data_mono and pnd_field extends are consistent. * src/m_doit.cc (doit_conv_flagAbsBT): Spellfix. * src/methods.cc: Adaption to jacobianDoit interface changes. Fixed doc of ybatchCalc robust option. * src/agendas.cc: Fix of pha_mat_spt_agenda doc. * controlfiles/artscomponents/wfuns/TestDoitJacobians.arts, ybatchREFERENCE_DoitJacobians.xml, ybatch_jacobiansREFERENCE_DoitJacobians.xml: Added. Cloudy Jacobians test case and reference data. * controlfiles/CMakeLists.txt: Added TestDoitJacobians to check list. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Added author info. 2015-03-11 Jana Mendrok * arts-2-3-173 * Next iteration of Doit Jacobians * src/m_jacobian.cc (jacobianDoit): Fixing issue of T-perturbations affecting (inArts- calculated) pnd_field by always recalculating pnd_field within the perturbation loop (unless pnd_field hasn't been inArts-calculated anyways). Added scat_speciesXXfield perturbation capabilities (untested so far). (jacobianDoitAddSpecies): Fixme reminder added. * src/methods.cc (jacobianDoit): Adapted interface parameters. * src/make_array.h: Extended array definition to allow longer WSM parameter lists. * src/methods_aux.cc (MdRecord::MdRecord): Some more helpful output info when something wrong with WSM interface parameters. 2015-03-10 Jana Mendrok * arts-2-3-172 * First implementations for DoitJacobian. Work in progress! * src/m_jacobian.cc: (jacobianDoit): Added. Main WSM for cloudy-sky Jacobians using Doit. (jacobianDoitAddSpecies): Added. WSM to set up Jacobian species for JacobianDoit case. 2015-03-02 Oliver Lemke * arts-2-3-171 * src/agenda_class.cc (Agenda::set_outputs_to_push_and_dup): Only add output variables of agendas to the list of outputs for WSMs that do execute a generic input agenda. Fixes crash because of an uninitialized value. Added assertion to double-check that the generic input agenda is not a controlfile generated agenda. Should never happen because this is checked elsewhere. 2015-02-27 Jana Mendrok * arts-2-3-170 * src/m_doit.cc (doit_i_fieldSetFromPrecalc): Set upwelling at lower boundary from precalc field if lower boundary is at surface (actually, implementation: at lowest atm pressure level). * src/jacobian.h, src/xml_io_compound_types.cc: Prepwork for doit jacobians: Added SubSubTag entry to definition of RetrievalQuantity. * src/constants.cc: Prepwork for doit jacobians: Added SCATSPECIES_MAINTAG. * src/methods.cc (jacobianOff): Fixed doc. * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, TestDOITFromIndividualFields.arts: Improved header info. Added author. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Updated some comments. 2015-02-26 Oliver Lemke * arts-2-3-169 * src/methods.cc: Turn on normalize by default for doit_i_fieldUpdateSeq1D with a threshold of 1.0. * controlfiles/artscomponents/doitbatch/TestDOITBatch.ybatch.ref.xml: Updated for slightly different results after turning on normalization. 2015-02-26 Oliver Lemke * arts-2-3-168 * src/m_doit.cc (doit_i_fieldSetClearsky), src/methods.cc: (doit_i_fieldSetClearsky): Operate on the whole doit_i_field instead of just doit_i_field_mono. This means it has to be called outside of the doit_mono_agenda now, after DoitGetIncoming. (doit_i_field_monoSetConst): Renamed from doit_i_fieldSetConst. Although initialization should be done now outside of the doit_mono_agenda, I left this method in because it can be useful for testing. (doit_i_fieldSetConst): Added. Internally uses doit_i_field_monoSetConst to set the whole doit_i_field. * controlfiles/general/agendasDOIT.arts, controlfiles/artscomponents/doit/doit_setup.arts, Remove doit_i_fieldSetClearsky from doit_mono_agenda. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts, controlfiles/artscomponents/doit/doit_calc.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: Add doit_i_fieldSetClearsky. * doc/uguide/scattering.tex, src/methods.cc: Corrected remaining occurrences of doit_i_fieldIterate. Updated documentation about Doit initialization. Corrected call order, first DoitInit, then DoitGetIncoming. Moved doit_i_fieldSetClearsky documentation to the initialization part. * src/agendas.cc: Updated docs for doit_mono_agenda. * CHANGES-2.3: Updated. 2015-02-26 Oliver Lemke * arts-2-3-167 * src/m_doit.cc (doit_i_field_monoIterate), src/methods.cc: Add check for NaNs in doit_i_field_mono to catch initialization errors. Renamed from doit_i_fieldIterate. * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/general/agendasDOIT.arts: Updated for doit_i_field_monoIterate name change. * CHANGES-2.3: Updated. 2015-02-26 Oliver Lemke * arts-2-3-166 * src/m_doit.cc (doit_i_fieldSetFromPrecalc), src/methods.cc: Adjusted function to operate the full doit_i_field instead of doit_i_field_mono. The method must now be called directly after DoitGetIncoming instead of inside the doit_mono_agenda. Renamed from doit_i_fieldSetFromPrecalcdoit_i_field. * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Initialize from precalculated field outside of doit_mono_agenda. * CHANGES-2.3: Updated. 2015-02-25 Jana Mendrok * arts-2-3-165 * src/m_doit.cc (DoitInit): Initialize fields with NaN instead of 0. * src/m_cloudbox.cc (particle_massesFromMetaData): Renamed from particle_massesFromMetaDataAndScat_species as scat_species is not used anymore. (ScatteringParticlesSelect): Improved error message. * src/cloudbox.cc (pnd_fieldXX): Corrected a couple of error messages. * src/m_checked.cc (cloudbox_checkedCalc): Added consitency check of scat_species and scat_data sizes. We can not just rely on ScatteringParticlesSelect for that as ScatteringParticlesSelect is not mandatory to execute. * src/methods.cc: Adapted for changes of cloudbox_checkedCalc and particle_massesFromMetaData. * CHANGES-2.3: Updated. 2015-02-25 Oliver Lemke * arts-2-3-164 * src/m_cloudbox.cc (ScatteringParticleTypeAndMetaRead): Add the location of filename_scat_data and filename_scat_meta_data temporarily to the data search path. This makes the use of relative paths in the scat_data and scat_meta_data files possible. * controlfiles/testdata/ScatteringMetaFile_*, controlfiles/testdata/SingleScatteringFile_*: Remove "testdata/" from the paths to make use of the feature mentioned above. 2015-02-25 Oliver Lemke * arts-2-3-163 * src/m_disort.cc (DisortCalc): Added clear warning message about the current state of disort. 2015-02-24 Patrick Eriksson * arts-2-3-162 * The documentation of ARTS is inconsistent on the definition of the V Stokes element. Ch 5 seems to deviate here. AUG and the ARTS-2 paper seems to be consistent with Mishchenko et al. [2002]. This reviewed together with Richard. This confusion had slipped into the definition given for sensor_pol and the associated stokes2pol internal function, and then also affecting MetMM. * CHANGES-2.3: Added comment on this commit. * doc/uguide/polarization.tex: Added text in two places, warning about the confusion around the V element. * src/sensor.cc (stokes2pol): Changed place on LHC and RHC. (met_mm_polarisation_hmatrix): Same here. * src/workspace.cc: Changed place of LHC and RHC in description of sensor_pol. 2015-02-24 Jana Mendrok * arts-2-3-161 * src/m_doit.cc (doit_i_fieldSetFromPrecalcdoit_i_field): WSM and GIN name adapted. Added doit_i_field as input, since we also need the incoming clearsky here (previously provided by scat_i_p; now this info is directly put into doit_i_field by DoitGetIncoming). (DoitInit): Removed obsolete initialization variables. * src/methods.cc: Adapted to changes above. Removed any references to doit_i_field1D_spectrum. * src/workspace.cc: Removed doit_i_field1D_spectrum. Added docstring to all agenda definitions (refering to agendas.cc in online-doc is ugly. the general user shouldn't be pointed to source code.). * src/agendas.cc: Spell fixes. * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Adapted to doit_i_fieldSetFrom* changes above. * doc/uguide/refr_index_theory.tex, absorption.tex: Minor bug and spell fixes. * doc/uguide/references.bib: Missing reference added. 2015-02-23 Patrick Eriksson * arts-2-3-160 * src/sensor.cc (met_mm_polarisation_hmatrix): MARSS is now art least formally handled. Polarisation part needs to be confirmed. * controlfiles/instruments/metmm/sensor_descriptions/sensor_deimos.arts: You will not get an error if using it, saying that the file is not finalised. * src/m_rte.cc (yCalc): Default for geo pos is now NaN. That is, this * src/rte.cc (iyb_calc): is what you get don't define geo_pos_agenda. 2015-02-20 Bengt Rydberg * arts-2-3-159 * controlfiles/instruments/metmm/sensor_descriptions/sensor_ismar.arts: updated * controlfiles/instruments/metmm/sensor_descriptions/sensor_marss.arts: updated 2015-02-19 Patrick Eriksson * arts-2-3-158 * src/m_ppath.cc (geo_posWherePpathPassesZref): If altitude not passed, goe_pos now set to NaN. 2015-02-19 Patrick Eriksson * arts-2-3-157 * src/m_ppath.cc (geo_posWherePpathPassesZref): New WSM for geo positioning. 2015-02-17 Patrick Eriksson * arts-2-3-156 * src/m_sensor.cc (sensor_responseBackendMetMM): Check of met_mm_antenna was wrong. Removed check of sensor_los, to allow that sensor_los can be set after calling this method. Started revision on how azimuth angles are handled. 2015-02-16 Patrick Eriksson * arts-2-3-155 * controlfiles/instruments/metmm/sensor_descriptions/sensor_*.arts: Checked all files that sensor_pos and sensor_los are not set, which still was the case in some cases. All Select calls now at end of files. 2015-02-11 Patrick Eriksson * arts-2-3-154 * Unfinished work. A start to get 2D antennas back, but not got time to finish the work. That is, 2D antennas are not working for the moment. But wanted to commmit the small improvements done. * src/m_sensor.cc (sensor_responseAntenna): One grid sorting error resulted in assert, now proper error given. (antenna_responseGaussian): The function can now generate also a simple 2D antenna pattern. * src/sensor.cc (antenna1d_matrix): Improved comments. (antenna2d_simplified): Now inactive. 2015-02-11 Jana Mendrok * arts-2-3-153 * doc/uguide/development.tex: Added "how to add a PSD". * src/m_cloudbox.cc (pnd_fieldCalcFromscat_speciesFields): Add reference to ADG in adding-another-PSD comment. 2015-02-11 Jana Mendrok * arts-2-3-152 * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, TestDOITBatch.ybatch.ref.xml: Added rain to considered scat_species. In order to test non-zero setting for other than scat_species_mass_density_field fields. yref data adapted accordingly. * controlfiles/artscomponents/doit/TestDOITFromIndividualFields.arts: Added. A test/demo case for cloudy calcs with pnd_field from hydrometeor profiles from non-compact atmosphere. The setup is a bit complicated. In future, I might add cloud-equivalents to AtmRawRead and AtmFieldsCalc. But for now this is sufficient, I think. * controlfiles/CMakeLists.txt: Above test case added. * controlfiles/testdata/chevallierl91_all_extract_wbackground_scenario0.*.xml: Added. A one-file-per-component atmosphere with hydrometeor profiles used in test case above. Scenario is taken from (hence identical to) the 0.th case in chevallierl91_all_extract.xml with N2 and O2 added. * controlfiles/testdata/empty_profile.xml: Added. An empty atmospheric field covering pressure range sufficient for full Earth atmo. Needed for test case above. * a couple of svn ignore settings. 2015-02-10 Oliver Lemke * arts-2-3-151 * src/cloudbox.cc (find_cloudlimits): Variable i was used uninitialized if cloudbox_margin was -1 leading to wrong return values for upper cloudbox limit. Adapted doxygen documentation for lower and upper parameters to 'param[in,out]'. Changed 'Determine' to 'Adjust' in function description to make clear that the upper and lower parameters have to be initialized already outside this function. Otherwise this function will return wrong values. 2015-02-10 Jana Mendrok * arts-2-3-150 * src/cloudbox.cc (chk_pndsum): Another bug... 2015-02-10 Jana Mendrok * arts-2-3-149 * src/cloudbox.cc (chk_pndsum): Fixed bug introduced with last commit. 2015-02-10 Jana Mendrok * arts-2-3-148 * src/m_cloudbox.cc (cloudboxSetAutomatically): Fix handling of non-set (empty) scat_species_*_*_field. Like for winds, empty fields should be valid, too (at least here). (pnd_fieldCalcFromscat_speciesFields): Downgraded all warning message on expected scattering species names to level2. * src/cloudbox.[cc,h] (find_cloudlimits): Moved this functionality to a subroutine, so we can reuse it per scat_species_*_*_field. 2015-02-09 Jana Mendrok * arts-2-3-147 * controlfiles/artscomponents/doitbatch/scatData/*.xml, controlfiles/artscomponents/doitbatch/ScatteringMetaFile_H2O[ice,liquid].xml, controlfiles/artscomponents/doitbatch/SingleScatteringFile_H2O[ice,liquid].xml: Moved to controlfiles/testdata/ to allow wider usage. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Adapted according to above changes. 2015-02-06 Oliver Lemke * arts-2-3-146 * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Revert the comparison precision back to 2e-1 after discussion with Jana. The idea of this test is to show that even with a 0 initial guess field the calculation still converges to the "same" result. Just with more iterations. Therefore it should not fail when commenting out setting the initial field. 2015-02-01 Patrick Eriksson * arts-2-3-145 * Added a WSM to allow using FASTEM with MC and DOIT. * src/m_surface.cc (specular_losCalc): Added some input checks. (surfaceFastem): New. A Fastem method fitting surface_rtprop_agenda. (iySurfaceFastem): Removed Water from name, to get this WSM starts like other iySurfaceXxxx WSMs. Large part of the code moved to surfaceFastem, and that method is instead called. 2015-01-31 Jana Mendrok * arts-2-3-144 * src/m_atmosphere.cc (AtmFieldPRegrid, AtmFieldPRegridHelper): Added. Method(s) to regrid non-raw atmospheric fields in pressure. Available for Tensor3 and Tensor4. Following the strategy of GriddedFieldPRegrid. (AtmFieldsRefinePgrid): Use AtmFieldPRegrid for z_field, t_field, and vmr_field regridding. (p_gridDensify): Modify behaviour to be consistent with p_gridRefine assuming we modify an in-use p_grid, i.e. set the respective check variables to 0 (unchecked) and do not allow to overwrite p_grid in place, but keep the old p_prid. (p_gridRefine): Use some log10->ln conversion of p_step as in abs_lookupSetup. * src/m_basic_types.cc (Compare): Added variant for Tensor4. * src/methods.cc: Modified according to changes above. * controlfiles/artscomponents/regrid/TestRegridFields.arts: Extended with test of individual regridding of (clearsky) atmospheric fields, ensuring consistency with AtmFieldsRefinePgrid. 2015-01-30 Oliver Lemke * arts-2-3-143 * This commit completely removes the old internal DOIT communication variables scat_i_* and doit_i_field1D_spectrum. * CHANGES-2.3: List changes that need controlfiles to be adapted. * src/methods.cc, src/doit.cc, src/m_doit.cc: Remove obsolete scat_i_* and doit_i_field1D_spectrum variables and replace them with doit_i_field/doit_i_field_mono in all DOIT methods. (doit_i_fieldSetFromdoit_i_field1D_spectrum): Replace doit_i_field1D_spectrum by generic input Tensor7 doit_i_field_spectrum. (Temporary fix, this method will be changed further soon) (DoitCloudboxFieldPut): Removed. Not needed anymore. * src/m_disort.cc (DisortCalc): Replace scat_i_* and doit_i_field1D_spectrum with doit_i_field. * src/agendas.cc: Remove scat_i_* and doit_i_field1D_spectrum from doit_mono_agenda. * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Create variable doit_i_field_ref and read it from file. Replaces the former WSV doit_i_field1D_spectrum. * controlfiles/artscomponents/doit/doit_calc.arts: Remove scat_i_p and doit_i_field1D_spectrum. * controlfiles/artscomponents/doit/doit_setup.arts, controlfiles/general/agendasDOIT.arts: Remove obsolete DoitCloudboxFieldPut. * doc/uguide/scattering.tex: Remove paragraph about scat_i_* WSVs. * controlfiles/artscomponents/doit/doit_i_fieldREFERENCE_DOIT.xml: Renamed from doit_i_field1D_spectrumREFERENCE_DOIT.xml and changed to Tensor7 by adding the missing dimensions with size 1 without touching the original values. * controlfiles/artscomponents/disort/TestDISORT.arts: Adapt for changes in ARTS to make it run again. Had to set rigorous to 0 in iyInterpCloudboxField. Didn't look further into the problem. 2015-01-30 Oliver Lemke * arts-2-3-142 * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Vastly tighten the required precision for the reference comparison. Even though I screwed up the test case by not reading the radiation field from file (essentially using a zero field), it was still succeeding. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITsensorInsideCloudbox.arts: Same tightening in precision for reference comparison. 2015-01-28 Oliver Lemke * arts-2-3-141 * controlfiles/artscomponents/doit/yREFERENCE_DOITsensorInsideCloudbox.xml: Forgot to add reference file in last commit. 2015-01-28 Oliver Lemke * arts-2-3-140 * src/doit.{cc,h} (iy_interp_cloudbox_field), src/m_doit.cc, src/methods.cc (iyInterpCloudboxField, iyInterpPolyCloudboxField): Replace scat_i_p, scat_i_lat, scat_i_lon, doit_i_field1D_spectrum by doit_i_field. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Cleanup test cases by moving repeated parts to doit_setup.arts and doit_calc.arts include files. * controlfiles/artscomponents/doit/doit_calc.arts, controlfiles/artscomponents/doit/doit_setup.arts: Added. * controlfiles/artscomponents/doit/TestDOITsensorInsideCloudbox.arts, controlfiles/CMakeLists.txt: Add test case with sensor inside the cloudbox. 2015-01-28 Patrick Eriksson * arts-2-3-139 * src/m_surface.cc (iyWaterSurfaceFastem): FASTEM returns unphysical values for propagation close to the horizon, here emissivity and reflectivity can be outside [0,1]. Now, if either emissivity or reflectivity is below/above 0/1, it is set to 0/1, and the other value is set to 1/0. That is, e+r=1 is enforced. These problems start about 15 degrees from the horizon. * src/physics_funcs.cc (invplanck): Polishing of error message. 2015-01-27 Oliver Lemke * arts-2-3-138 * Work in progress. Adding frequency dimension to doit_i_field. * src/agendas.cc, src/doit.{cc,h}, src/m_doit.cc, src/methods.cc, src/workspace.cc: Change doit_i_field from Tensor6 to Tensor7. Add WSV doit_i_field_mono. This replaces doit_i_field in all internal DOIT methods whereas doit_i_field is output of DoitCalc. Also rename doit_i_field_old to doit_i_field_old_mono. Affected WSMs: DoitCloudboxFieldPut, doit_conv_flag*, doit_scat_fieldCalc, doit_scat_fieldCalcLimb, DoitWriteIterationFields, doit_za_grid_optCalc. doit_i_fieldIterate, doit_i_fieldSetFromdoit_i_field1D_spectrum, doit_i_fieldSetClearsky, doit_i_fieldSetConst, doit_i_fieldUpdate*. Note: The names of the last 5 WSMs have intentionally not been changed to doit_i_field_mono* yet. Affected agendas: doit_conv_test_agenda, doit_mono_agenda, doit_scat_field_agenda, doit_rte_agenda. Affected internal functions: cloud_ppath_update1D_noseq, cloud_ppath_update3D, cloud_RT_no_background, cloud_RT_surface, interp_cloud_coeff1D, cloud_ppath_update1D_planeparallel, doit_scat_fieldNormalize. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/general/agendasDOIT.arts: Change doit_i_field to doit_i_field_mono at appropriate places. Remove explicit WSM input to doit_conv_flagAbs and use keywords instead. 2015-01-26 Oliver Lemke * arts-2-3-137 * Cleanup of initialization of DOIT WSVs before starting work on doit_i_field changes. * src/m_doit.cc: (DoitInit): Add initialization of scat_i_* for 3D. Introduce some helper variables for frequently used dimension sizes for readability. (DoitCloudboxFieldPut, DoitGetIncoming, DoitGetIncoming1DAtm): Remove resizing of scat_i_*, it's now in DoitInit. (doit_i_fieldSetClearsky, doit_i_fieldSetConst, doit_i_fieldSetFromdoit_i_field1D_spectrum): Remove doit_i_field resizing, because it is already done in DoitInit. * src/methods.cc: Change variables that are initialized in DoitInit and were defined as output-only in DoitCalc, DoitCloudboxFieldPut, doit_i_fieldSetConst, doit_i_fieldSetFromdoit_i_field1D_spectrum and DoitGetIncoming to input+output. Otherwise their initialization in DoitInit has no effect. Output-only variables are resized to 0 before they're passed to a workspace method. The code worked anyway because they were resized again in the respective functions. 2015-01-25 Patrick Eriksson * arts-2-3-136 * src/m_rte.cc (yCalc_mblock_loop_body): Now probing the H matrix to find boresight directions by Stokes vectors = [1 0 0 0], which is obviuosly the right thing to do. Before [1 1 1 1] was applied and this caused failures in some cases with sensor rotation. 2015-01-24 Patrick Eriksson * arts-2-3-135 * controlfiles/instruments/metmm/sensor_descriptions/sensor_mhs.arts: Removed ; after last line in antenna_dlos. Existing settings caused an error as band touched at LO. Changed these band to have 0 offset and doubled bandwidth, following the treatment of e.g. channel 15 of AMSU-A. * src/sensor.cc (met_mm_polarisation_hmatrix): Changed to take dza as input. This as the rotation depends on the angle with respect to the platform reference direction, and not absolute za. The sign of the rotation angle is so far just a guess, for all instruments. The sign does not matter as long as U=0. * src/m_sensor.cc (sensor_responseBackendMetMM): Adopted call of met_mm_polarisation_hmatrix. 2015-01-23 Oliver Lemke * arts-2-3-134 * AgendaExecute bug fix part 3/2. ;-) * src/agenda_class.cc: (Agenda::is_input): The check for WSVs used as inputs by agendas passed as generic inputs was overly ambitious. A recursive check of the methods inside the agenda is not needed. It actually causes false errors depending on the order of initialization of agendas. Only the interface variables of the agenda should be checked. Fixes bug reported by Patrick. (Agenda::set_outputs_to_push_and_dup): Instead of having one special case for the output variables of AgendaExecute, treat all Agendas passed as generic input the same way. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/agendas/TestAgendaExecute.arts: Added test case for agenda scoping. * src/cloudbox.cc (pnd_fieldMGD_LWC, pnd_fieldMGD_IWC): Remove unused variable min_rho. 2015-01-23 Manfred Brath * arts-2-3-133 * src/cloudbox.{h,cc} (pnd_fieldS2M, WCtopnd_S2M), src/m_cloudbox.cc (pnd_fieldSetup): Added two moment scheme distributions. * src/m_cloudbox.cc (dNdD_S2M), src/methods.cc: Added new WSMs for the new distributions. * src/math_func.{h,cc} (mod_gamma_dist): Added generalized modified gamma distribution 2015-01-23 Oliver Lemke * arts-2-3-132 * src/rte.cc (iyb_calc): Added exception handling for geo_pos_agenda. 2015-01-23 Patrick Eriksson * arts-2-3-131 * src/m_sensor.cc (sensor_responseBackendMetMM): Softened the demand of za in sensor_los. This angle can now be inside [160,180], to allow some handling of cases where the central position of the scanning is not a at nadir, due to non-nominal pitch and roll. This solution should be sufficient for 1D. For 3D, a total general treatment of pitch+roll would require more variables. The present solution is only totally accurate when the scan centre position has moved exactly in the direction of the corresponding azimuth angle. If the scan centre position is at some other azimuth, you simulation will be performed an OK zenith angle, but the azimuth will be wrong. This also means that the geo-positioning will be incorrect. * src/rte.cc (iyb_calc): Added if (failed) continue before calling geo_pos_agenda. The call of geo_pos_agenda should probably be inside a try/catch. 2015-01-23 Patrick Eriksson * arts-2-3-130 * src/m_sensor.cc (sensor_responseBackendMetMM): stokes_dim > 1 again accepted. Seems to work, but there is a big potential for problems here. As it is now, iy_unit must be set to its final value before calling this WSM. If it is reset afterwards, there could be an error of a factor 2. This is associated with calibration and all this needs a revision! Leave as it is for the moment. * src/rte.cc (iyb_calc): Used ws instead of l_ws when calling geo_pos_agenda, that caused intermittent failures. 2015-01-23 Oliver Lemke * arts-2-3-129 AgendaExecute bug fix part 2/2. Scoping for AgendaExecute should now work properly. * src/agenda_class.cc: (Agenda::set_outputs_to_push_and_dup): If the Agenda contains an AgendaExecute call, also collect the outputs of that agenda for proper scoping. (Agenda::is_input): Cosmetics. Use WsvGroupMap to find the Agenda index. * src/m_agenda.cc (AgendaExecuteExclusive): Call AgendaExecute. 2015-01-22 Oliver Lemke * arts-2-3-128 AgendaExecute bug fix part 1/2 * src/m_agenda.cc (AgendaExecute): Partial fix for severe bug in AgendaExecute. It did not apply any scoping. This means that all workspace variables that were modified in the executed agenda were leaked into the global scope. Now only variables explicitly defined as output are passed back (but still leak into global scope, will be fixed in part 2). * src/agenda_class.{cc,h} (find_unused_variables): Remove unused function. * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsua.arts: Remove duplicate met_mm_polarisation initialization. Thanks Alex! 2015-01-22 Patrick Eriksson * arts-2-3-127 * A system to geo-position the data in place, but should for the moment just be seen as a test feature. Anyhow: Adding geo-positioning is achived by setting geo_pos_agenda. For a downward-looking operational sensors, this should be the standard choice: AgendaSet( geo_pos_agenda ){ geo_posEndOfPpath } The final geo-pos is returned as y_geo. Works for all atmosphere_dim, but of course most useful for 3D. Commemnts: There is no actual description of the bore-sight for calculations with antenna. The bore-sight is instead determined by probing the sensor response matrix, which results in a bit of calculation burden to achieve the geo-positioning. How well this works for cases with an antenna pattern applied has not yet tested. * src/m_ppath.cc (geo_posEndOfPpath,geo_posLowestAltitudeOfPpath): The new WSMs, to be used inside geo_pos_agenda. * controlfiles/general/general.arts: Added definition of geo_pos_agenda. This version set geo_pos to be empty. * src/m_jacobian.cc (jacobianCalcAbsSpeciesPerturbations) (jacobianCalcPointingZaRecalc) (jacobianCalcTemperaturePerturbations): Added geo_pos_agenda and adopted call of iyb_calc. * src/rte.cc (iyb_calc): Added geo_pos_agenda. It is here that it is actually called. (iyb_calc_body): Added ppath as output argument. * src/m_rte.cc (yCalcAppend, yCalc): Added geo_pos_agenda and adopted call of iyb_calc. 2015-01-22 Oliver Lemke * arts-2-3-126 * src/parser.{cc,h}: Throw runtime error if a ...Create WSM is called inside an agenda. This is to avoid confusion how variables are working in ARTS. WSVs are always global, even if they were created inside an agenda. Therefore defining two agendas that create the same variable (even if they are never executed) will throw an error that the variable already exists. It's therefore better to only allow Create being called inside the global scope where it actually creates the variables in. * controlfiles/artscomponents/absorption/TestAbsParticle.arts, controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, controlfiles/artscomponents/surface/TestSurface.arts: Call Create right before AgendaSet instead of inside. * CHANGES-2.3: Updated. 2015-01-22 Patrick Eriksson * arts-2-3-125 * Work in progress!: Trying to add a feature for geo-positioning. The MetMM part now throws an error if stokes_dim > 1, as the results are worng (probably just a factor of 2 to fix). * src/m_jacobian.cc: Adopted all calls of iyb_calc. * src/rte.cc (iyb_calc): Added handling of geo_pos. * src/m_rte.cc (yCalc, yCalcAppend): Added handling of y_geo, here and in sub-functions. * src/agendas.cc: Added geo_pos_agenda. * src/workspace.cc: Added geo_pos and y_geo. * src/rte.cc (iyb_calc): Removed some outdated comments. * src/m_sensor.cc (sensor_responseBackendMetMM): The mirror_dza feature now working. Noticed that results incorrect for stokes_dim > 1. Not yet solved and just added an error if used. 2015-01-21 Patrick Eriksson * arts-2-3-124 * src/m_sensor.cc (sensor_responseBackendMetMM): Expanded built.in do text. Added checks of input. For example, za in sensor_los must now be 180 deg. Started to work on simpler handling of 3D. * controlfiles/instruments/amsu/amsub_metmm.arts: The settings removed below are now found here. * controlfiles/instruments/metmm/sensor_descriptions/sensor_amsub.arts: Removed setting of sensor_pos and sensor_los. * src/ppath.cc (map_daa): The aa_grid value was limited to [-5,5]. Don't understand why; the algorithm should work for any angle. Now limited to [-180,180]. 2015-01-21 Oliver Lemke * arts-2-3-123 * controlfiles/instruments/metmm: Created directory for new sensor setups. The proposed subdirectory structure is: metmm/sensor_descriptions/ metmm/test_cases/ metmm/clearsky_batch/ metmm/cloudy_batch/ metmm/spectroscopy/ metmm/zeeman/ * controlfiles/instruments/metmm/sensor_descriptions/ {sensor_amsua.arts, sensor_amsub.arts, sensor_deimos.arts, sensor_ismar.arts, sensor_marss.arts, sensor_mhs.arts}: Added sensor descriptions for AMSU-A, AMSU-B, MHS, ISMAR, DEIMOS, MARSS. TODO: Add viewing angles for I, D and M. Add HIRS, AVHRR... * controlfiles/instruments/amsu/amsub_metmm.arts: Adapted to use the new sensor description. Also shows how to select a subset of channels and viewing angles for the calculation. * controlfiles/instruments/mhs/mhs.sensor_los.xml: Corrected viewing angles for MHS. They were the same as AMSU-B, but they are actually slightly different. 2015-01-21 Oliver Lemke * arts-2-3-122 * src/m_sensor.cc (sensor_responseBackendMetMM), methods.cc: Turn freq_spacing into a Vector to behave the same as freq_number. * controlfiles/instruments/amsu/amsub_metmm.arts, controlfiles/instruments/amsu/TestAMSUB_MetMM.arts: Adapted. 2015-01-21 Oliver Lemke * arts-2-3-121 * src/m_select.h, src/methods.cc: Add [-1] as special case for needleindexes to select all elements. Throw runtime error instead of asserting if needleindexes contains negative elements (except for the special case of course). 2015-01-19 Patrick Eriksson * arts-2-3-120 * Many changes around the files. Not all details written down. The overall aim was to increase the flexibility and consistency of how LOS values are handled. A main driver was to go away from a rectangular mblock za-aa grid. All tests run (including test on uguide!), but there could still be bugs from all these changes. Tell me if you get strange results. Most changes should not affect standard usage. The most noticable changes are: * mblock_za_grid is now renamed to mblock_dlos_grid and is now a matrix. As long as 1D antennas are used, all you need is to convert mblock_za_grid to a single column matrix. * AntennaSet1D is removed. Replace this WSM with IndexSet(antenna_dim,1). * src/(agendas.cc m_checked.cc m_jacobian.cc m_rte.cc m_sensor.cc methods.cc rte.cc rte.h sensor.cc sensor.h workspace.cc): Affected source files. * controlfiles/../(TestFgrid.arts TestGbased.arts TestRteCalcMC.arts TestStokesRotation.arts TestWfuns.arts amsub_metmm.arts odinsmr_501.arts odinsmr_501_1D.arts odinsmr_544.arts): Affected control files. * doc/uguide: Updated email address for Stefan in start pages of the docs. Updated copyright years. Fixed references to renamed WSV and WSM. Mainly the ones listed below, but also some on the scattering side. * Renamed + modified WSVs: antenna_los -> antenna_dlos mblock_za_grid -> mblock_dlos_grid sensor_response_za_grid -> sensor_response_dlos_grid sensor_response_za -> sensor_response_dlos Removed WSVs: mblock_aa_grid sensor_response_aa_grid sensor_response_aa Modified WSVs: stokes_rotation is now a vector (before a matrix) * src/m_sensor.cc (AntennaSet1D,AntennaSet2D): Removed. Now just setting antenna_dim=1/2. 2015-01-17 Patrick Eriksson * arts-2-3-119 * controlfiles/instruments/amsu/amsub_metmm.arts: Now using antenna_los. * src/m_sensor.cc (sensor_responseBackendMetMM): atmosphere_dim now checked, and only 1D allowed at this point. The set of input relative angles now specified by antenna_los. mblock_za_grid now only output. This for better consistency with other sensor methods. 2015-01-16 Patrick Eriksson * arts-2-3-118 * Contrary to what I wrote in an email to the arts mailing lists, surface_rtprop_agenda must stay as it is used of MC and DOIT. To allow combining the surface type system and MC/DOIT, this means that I instead had to introduce the surface_rtprop_sub_agenda series, to have one such agenda for each iy_surface_sub_agendaX. iy_surface_agenda and surface_rtprop_agenda remain unchanged and you can use these two agendas exactly as before. The corresponding agenda seriers are just needed if you want to operate with surface types. * controlfiles/general/agendas_surface_sub.arts: Dummy definition of the new agenda series. No need to include this file for standard calculations. * src/m_surface.cc (iySurfaceCallSubAgendaX): Renamed, and now handling X = 0 to 5. That also means that all those agendas must be defined. (surface_rtpropCallSubAgendaX): New WSM. * src/agendas.cc: The set of surface type agendas are now called iy_surface_sub_agendaX, where X is 0 to 5. Also introduced a parallel set of agendas: surface_rtprop_sub_agendaX. 2015-01-15 Jana Mendrok * arts-2-3-118 * src/m_atmosphere.cc, methods.cc (p_gridRefine): Added. WSM to calculate refined p_grid with log10 spacings of p below a given threshold. Mimicking the creation of a finer grid as done in AtmFieldsRefinePgrid (including fix to use p_step indeed for log10 spacings as said in doc, not for ln spacings). (AtmFieldsRefinePgrid): Apply new WSM p_gridRefine for fine p_grid creation. * controlfiles/artscomponents/regrid/TestRegridFields.arts, TestRegridFields.odepth_refineREFERENCE.xml, TestRegridFields.y_refineREFERENCE.xml, controlfiles/CMakeLists.txt: Added test case for regridding of atmospheric fields (Tensor data level). * src/workspace.cc (cloudbox_checked): Updated obsolete reference to *basics_checked*. 2015-01-15 Patrick Eriksson * arts-2-3-117 * src/m_surface.cc (FastemStandAlone): Upper limit of frequency had a typo, was set to 100 GHz. 2015-01-14 Patrick Eriksson * arts-2-3-116 * src/m_surface.cc (FastemStandAlone): Temperature now adjusted to 270K if below this value. 2015-01-14 Jana Mendrok * arts-2-3-115 * src/m_doit.cc (doit_i_fieldSetFromdoit_i_field1D_spectrum): Remove the next freshly introduced bug *sigh*. 2015-01-14 Jana Mendrok * arts-2-3-114 * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Use correct DOIT initial guess input file. 2015-01-14 Jana Mendrok * arts-2-3-114 * Bugfix in first-guess DOIT field setting: the radiation incident on the cloudbox boundaries shall not be set from the first guess, but from the (potentially modified) clearsky incoming field. * src/m_doit.cc, methods.cc (doit_i_fieldSetFromdoit_i_field1D_spectrum): After setting doit_i_field from doit_i_field1D_spectrum, update the incoming radiation streams on the boundaries according to scat_i_p/lat/lon (precalculated! use e.g. DoitGetIncoming). * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Add call of DoitGetIncoming to derive scat_i_p/lat/lon now also required for non-clear initial guess from doit_i_fieldSetFromdoit_i_field1D_spectrum. * controlfiles/artscomponents/doit/TestDOIT.doit_i_field1D_spectrum.xml: Removed. Last re-added data was wrong. Also, bad idea to use a TestDOIT dependent, constantly rewritten file as reference/starting point for TestDOITprecalcInit. * controlfiles/artscomponents/doit/doit_i_field1D_spectrumREFERENCE_DOIT.xml: Added. New i_field data (taken from from TestDOIT, not to be overwritten in future) as initial guess input to TestDOITprecalcInit. 2015-01-14 Patrick Eriksson * arts-2-3-113 * controlfiles/artscomponents/surface/TestSurface.arts: Now using iySurfaceRtpropCalc. Everything before in surface_rtprop_agenda now in iy_surface_agenda. * src/agendas.cc: Added surface_type[2,5]_agenda. * src/m_surface.cc (iySurfaceRtpropAgenda): New WSM. (surfaceFlatScalarReflectivity): Changed, stokes_dim-s higher than 1 are now also allowed. 2015-01-14 Patrick Eriksson * arts-2-3-112 * Implemented handling of different surface types, including selection from predefined mask. * src/agendas.cc: Introduced surface_type0_agenda and surface_type1_agenda. Will add more when more testing as been made. * src/workspace.cc: Introduced surface_type, surface_type_aux and surface_type_mask. * src/m_surface.cc (surface_typeInterpTypeMask): New WSM. (iyFromSelectedSurfaceTypeAgenda): New WSM. 2015-01-13 Patrick Eriksson * arts-2-3-111 * src/workspace.cc: Corrected unit string for scat_species_mass_density_field. * src/m_surface.cc (iyWaterSurfaceFastem): Stupid typo among intial input checks. Had to introduce sensor_los_dummy. rtp_los was used beofre, but telescoping for 3D cases gives wrong dimension for resulting matrix. 2015-01-13 Manfred Brath * arts-2-3-110 * doc/uguide/scattering.tex: Corrected the last paragraph in the subsection "DOIT main agenda" concerning doit_i_field1D_spectrum and scat_i_p. 2015-01-13 Jana Mendrok * arts-2-3-109 * src/cloudbox.cc, m_cloudbox.cc, methods.cc, workspace.cc, controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, controlfiles/artscomponents/arts-xml-data/TestClouds_Venus.arts, controlfiles/artscomponents/disort/TestDISORT.arts, controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doit/TestDOITprecalcInit.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Renamed pnd_fieldCalc -> pnd_fieldCalcFrompnd_field_raw and pnd_fieldSetup -> pnd_fieldCalcFromscat_speciesFields. 2015-01-13 Patrick Eriksson * arts-2-3-108 * src/ppath.h: Added declaration of resolve_lon. * src/m_surface.cc (InterpGriddedField2ToPosition): New WSM. (FastemStandAlone): Better descrption of relative azimuth. (iyWaterSurfaceFastem): Angle between LOS and wind direction now considered. The method should now be complete. 2015-01-13 Jana Mendrok * arts-2-3-107 * src/m_abs.cc, methods.cc, doc/uguide/absorption.tex: Added option to propmat_ClearskyAddParticle to use total particle extinction instead of particle aborption in Schwarzschild RTE. Adapted built-in doc and AUG accordingly. * controlfiles/planetary_toolbox/demos/common/DemoMarsClouds1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_FOS_1D.arts, controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Minor layout fixes. 2015-01-13 Richard Larsson * arts-2-3-106 * src/absorption.cc: Removed old header information. * src/pressurebroadeningdata.cc: Fixed fatal bug in how self broadening was stored and read in my implementation for ARTSCAT-5. * src/linemixingdata.{cc,h}: Added explicit 1st order line mixing functionality. This was technologically possible with 2nd order line mixing, but it was confusing to read and understand. 2015-01-13 Patrick Eriksson * arts-2-3-105 * src/m_rte.cc (iyEmissionStandard): iy_aux now also considered even if iy_agenda_call1==0. A bit of overhead in the general case, but handy in some cases. For example, totally needed to handle FASTEM in an efficient manner. * src/m_surface.cc (iyWaterSurfaceFastem): Some simple tests done and the method seems to work. 2015-01-12 Patrick Eriksson * arts-2-3-104 * src/m_surface.cc (iyWaterSurfaceFastem): New WSM. Complete but needs changes in how iy_aux is handled for secondary ppaths. (FastemStandAlone): Better documentation. Transmittance now also vector. * src/surface.cc (surface_calc): Moved from rte.cc. * src/fastem.cc: Extended header text. Za is now expected to be [90,180]. 2015-01-12 Jana Mendrok * arts-2-3-103 * controlfiles/artscomponents/doit/yREFERENCE_DOIT.xml, TestDOIT.doit_i_field1D_spectrum.xml: Re-added accidentially deleted test data. 2015-01-12 Jana Mendrok * arts-2-3-102 * src/agendas.cc, m_disort.cc, m_doit.cc, methods.cc, workspace.cc, controlfiles/artscomponents/doit/TestDOIT.arts, TestDOITprecalcInit.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts, doc/uguide/scattering.tex: Renamed ScatteringDoit -> DoitCalc, ScatteringDisort -> DisortCalc. 2015-01-12 Patrick Eriksson * arts-2-3-101 * src/m_surface.cc (FastemStandAlone): Just started. * src/m_general.cc (Test): Just adopted to change below. * src/fastem.h: Removed default for FASTEM version. This will be controlled by setting in methods.cc. * src/fastem.cc: Changed salinity from o/oo to be between 0 and 1, following how we treat VMR. 2015-01-08 Richard Larsson * arts-2-3-100 This updates clears some technological debts in how linemixing was dealt with in a completely different manner than pressure broadening, yet their data structures are similar. Still a debt left with non-resonant O2, which is treated as linemixing because the mathematics is so very similar but requires a specialized line shape function to operate properly. * src/absortprion.cc: All specialized line mixing xsec functions have been removed and are now part of linemixingdata.{cc,h} and the wrapper function. * src/linemixingdata.{cc,h}: Now has a generic "GetData" functionality. * src/pressurebroadeningdata.cc: Just a tiny bit of tidying up. 2014-12-19 Richard Larsson * arts-2-3-99 This update fixes a bug with line mixing lblrtm at high temperatures found from looking at artscat5 output. Conversion from artscat3 to artscat5 more consistent though not perfect. Water and air pressure broadening scheme added. Promted due to finding: "Pressure broadening of oxygen fine structure lines by water" in JQSRT Volume 154, March 2015, Pages 24–27. Tried for molecular oxygen at 118 GHz between 113 and 121 GHz with 5x subarctic-summer water content. Results on initial trial gives difference to air broadening scheme of upwards 0.7 K for ground-based and as low as 0.01 K for satellite-based platforms in this frequency range. Note that the paper gives two values for water pressure broadening found using different spectroscopic techniques. The least broadening had a factor ~3 less difference with air broadening scheme as the values above * src/absorption.cc: Using a routine to find the water index in abs_species. Passing this along to pressure broadening. * src/linemixingdata.h: Minor formatting. * src/linerecord.*,m_abs.cc: Fixed bug on reading line mixing parameters at high temperatures. Fixed error in conversion from artscat3 to artscat5. artscat5 is identical to artscat3 given the right pressure broadening definition, but before artscat3to4 was used as a layer. Found that this fix removed strangeness in reading lines from external, storing lines, then rereading lines from artscat5. Now just reading lines from external is more close to the previous scheme, but some cases it still produce strangeness (though at numerical drift levels of uncertainity). * src/pressurebroadeningdata.*: Added a water and air pressure broadening scheme. This assumes air pressure is pressure-self_pressure-water pressure for non-water species then copies the simple air broadening scheme for the rest. This method is used only if artscat5 pressure broadening scheme tag is "WA", and expects a bit different variables than simple air broadening. No data error is stored, contrary to how air is dealt with. Proper documentation pending on time. 2014-12-17 Oliver Lemke * arts-2-3-98 * src/linerecord.cc (LineRecord::ReadFromArtscat5Stream, operator<<): Don't store the number of elements for pressure broading and linemixing inside the catalog. Use the ExpectedVectorLengthFromType instead. 2014-12-17 Richard Larsson * arts-2-3-97 Added lm_p_lim as a limit to pressure for line mixing. Default is 0. This is because I encountered a problem with lblrtm line mixing temperature grid at high altitude, where atmospheric temeprature is low. Opted for workspace variable instead of linemixing variable by advice from Oliver. The other options were to make it part of abs_species or store limit per line, one of which is confusing, the other of which is a waste of space. * src/linemixingdata*: Changed so that each function that deals with line mixing accepts pressure and pressure limit. If pressure is lower than pressure limit, then the line mixing output is set to zero, essentailly ignoring it. * the rest: passing lm_p_lim to the right position. 2014-12-12 Patrick Eriksson * arts-2-3-96 * src/methods.cc: The description of aux var Transmission, of iyEmissionStandard and iyTransmissioStandard, was cryptic, or maybe even wrong. Now hopefully more clear. 2014-12-10 Jana Mendrok * arts-2-3-95 * src/m_doit.cc (CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Renamed to DoitGetIncoming[1DAtm]. Added doit-initialized check to 1DAtm variant. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts, doc/uguide/scattering.tex: Followed name change CloudboxGetIncoming -> DoitGetIncoming. * src/methods.cc (CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Renamed CloudboxGetIncoming[1dAtm] -> DoitGetIncoming[1DAtm] at all occurences. (dNdD_*): Updated docs making sure, scaling and scaling parameter are pointed out. * src/agendas.cc (met_profile_calc_agenda): Updated WSM names in example agenda setting. * src/cloudbox.cc (parse_part_size), src/workspace.cc (scat_species): Corrected doc (assuming diamter, not radius). * CHANGES-2.2, CHANGES-2.3: Updated. 2014-12-11 Oliver Lemke * arts-2-3-94 * src/linerecord.cc: (LineRecord::ReadFromArtscat5Stream): Use double_imanip for parsing floating point numbers. Otherwise breaks using the failbit for error detection in gcc. Contrary to clang, gcc sets the failbit to true if it encounters a NaN value. (operator<<): Don't write Sgam separately into ARTSCAT-5. It is part of the pressurebroadening. 2014-12-11 Oliver Lemke * arts-2-3-93 * src/src/linemixingdata.cc (LineMixingData::GetLBLRTM, LineMixingData::GetLBLRTM_O2NonResonant): Add chk_interpolation_grids to avoid assertion. 2014-12-11 Patrick Eriksson * arts-2-3-92 * ChangeLog: Removed old conflict marker. 2014-12-10 Jana Mendrok * arts-2-3-91 * src/methods.cc, workspace.cc, m_cloudbox.cc, cloudbox.cc: Updated and completed online-doc on scat_species_mass/number_density/flux_field. Updated terminology in code comments. 2014-12-10 Jana Mendrok * arts-2-3-90 * ChangeLog: with change message arts-2-3-89 2014-12-10 Jana Mendrok * arts-2-3-89 * Added a DOIT testcase demonstrating first guess field from read-in precalculated doit_i_field1D_spectrum * controlfiles/artscomponents/doit/TestDOITprecalcInit.arts: Added. Precalculated first guess test case. * controlfiles/artscomponents/doit/TestDOIT.doit_i_field1D_spectrum.xml: Added. DOIT in-cloudbox solution from TestDOIT.arts as input to TestDOITprecalcInit.arts * controlfiles/CMakeLists.txt: Include TestDOITprecalcInit in regular test case set. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/testdata/testdoit_gas_abs_lookup.xml, testdoit_gas_abs_lookup.xml.bin: Slight modifications in existing DOIT test case, e.g. using 2 frequencies and using 2 scattering elements. * controlfiles/artscomponents/absorption/TestAbsParticle.arts: Using same abs_lookup as TestDOIT.arts, hence adapted to changes made there. * controlfiles/artscomponents/absorption/yREFERENCE_AbsParticle.xml, controlfiles/artscomponents/doit/yREFERENCE_DOITprecalcInit.xml, yREFERENCE_DOIT.xml: Reference output for 3 more cases added. 2014-12-10 Jana Mendrok * arts-2-3-88 * src/m_doit.cc, methods.cc (CloudboxGetIncoming): Check whether doit has been initialized beforehand. 2014-12-10 Jana Mendrok * arts-2-3-87 * Changes of controlfiles (and some test data) in accordance with arts-2-3-72 and ARTS-XML-DATA-2-3-4, i.e. providing compact batch input as ArrayOfGriddedField4 instead of ArrayOfMatrix. * controlfiles/testdata/garand_profiles.xml.gz, chevallierl91_all_extract.xml, controlfiles/instruments/amsu/chevallierl91_clear_q_extract.xml.gz, mhs/chevallierl91_clear_q_extract.xml.gz: Converted compact batch state data to ArrayOfGriddedField4. * controlfiles/instruments/avhrr/TestAVHRR.arts, ici/TestICI_fast.arts, hirs/TestHIRS.arts, amsu/TestAMSU_MetMM_generic.arts, TestAMSU_generic.arts, mhs/TestMHS_generic.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Adapted input of compact batch state data handling. * src/methods.cc, workspace.cc: Adaptations according to changes above and clarification on some WSM/WSV. 2014-12-10 Oliver Lemke * arts-2-3-86 * Preliminary ARTSCAT version 5 implementation. * src/linemixingdata.{cc,h}: Declare all member functions that don't modify the object as const. (LineMixingData::StorageTag2SetType): For convenience, return the string instead of using a reference parameter. * src/linerecord.{cc,h}: (LineRecord::ARTSCAT5FromARTSCAT4): New conversion function. (LineRecord::ReadFromArtscat5Stream): Add ARTSCAT-5 reading routine. (operator<<): Add writing support for ARTSCAT-5. * src/methods.cc, src/m_abs.cc (abs_linesArtscat5FromArtscat34): New WSM to convert an ARTSCAT-3 and ARTSCAT-4 to ARTSCAT-5 format. * src/pressurebroadeningdata.{cc,h}: (Sgam, Nself): Add assertion. (PressureBroadeningData::Type2StorageTag): For convenience, return the string instead of using a reference parameter. Fix typo for tag 'PA' -> 'AP'. * src/quantum.{cc,h}: (IsValidQuantumNumberName): Added. Check if QN name is valid. (QuantumNumbers::Set): Added. Set QN to rational by name. (QuantumNumbers::nNumbers): Added. Returns number of used QNs. * src/rational.cc (operator>>): Don't use term quantum number in rational class. Improved error output. * src/xml_io_array_types.cc (xml_read_from_stream): Add ARTSCAT-5 support for ArrayOfLineRecord. 2014-12-10 Oliver Lemke * arts-2-3-85 * src/methods.cc, src/m_atmosphere.cc (atm_fields_compactAddConstant, atm_fields_compactAddSpecies, batch_atm_fields_compactAddConstant, batch_atm_fields_compactAddSpecies): Add support for inserting a field at the beginning of [batch_]atm_fields_compact in addition to appending it. * src/m_atmosphere.cc (atm_fields_compactExpand): Add prepend support. Use joker instead of Range(joker) for readability. * src/m_cloudbox.cc: (cloudboxSetAutomatically): Commented out currently unused variables. (pnd_fieldSetup): Commented out currently unused parameter scat_species_number_density_field. * src/absorption.cc (xsec_species): Remove unused lineshape_norm_data. 2014-12-09 Oliver Lemke * arts-2-3-84 * 3rdparty/fastem/*: Add FASTEM from RTTOV. README contains email conversion with RTTOV helpdesk that gives us permission to integrate FASTEM into ARTS. * CMakeLists.txt, 3rdparty/CMakeLists.txt, config.h.cmake, src/CMakeLists.txt, src/main.cc (main): Add FASTEM support. * src/fastem.{cc,h}: Replace old fastem function with interface to rttov_fastem5. * src/m_general.cc (Test): Call fastem with some test values and output results. 2014-12-05 Manfred Brath * arts-2-3-83 * src/cloudbox.cc (pnd_fieldMGD_LWC, LWCtopnd_MGD_LWC, pnd_fieldMGD_LWC, LWCtopnd_MGD_LWC, pnd_fieldF07TR, IWCtopnd_F07TR, pnd_fieldF07ML, IWCtopnd_F07ML): Changed the used size parameter from maximum dimension diameter to volume equivalent spherical diameter. * src/cloudbox.cc (pnd_fieldMGD_LWC,pnd_fieldMGD_LWC): Furthermore added an error-notification, if the density of the used particles are too different. * src/methods.cc (pnd_fieldSetup): Updated online documentation. 2014-12-05 Oliver Lemke * arts-2-3-82 * ChangeLog: Removed conflict marker. 2014-12-04 Patrick Eriksson * arts-2-3-81 * src/montecarlo.cc (mcPathTraceGeneral): Changed max number of ppath steps from 5k to 25k. Things seem to work and you could reach the upper limit by chance which then results in a frustrating crash. 2014-12-03 Oliver Lemke * arts-2-3-80 * src/linerecord.h: Add ma, mgupper and mglower to element initialization list in constructor and set them to NAN. Other they ended up being uninitialized when converting from ARTSCAT-3 to ARTSCAT-4. * src/m_abs_lookup.cc (abs_lookupSetupBatch): Initialize T_index and z_index with -1 to avoid false compiler warning. 2014-12-02 Manfred Brath * arts-2-3-79 * src/cloudbox.{h,cc} (pnd_fieldMGD_LWC, LWCtopnd_MGD_LWC, pnd_fieldMGD_LWC, LWCtopnd_MGD_LWC, pnd_fieldF07TR, IWCtopnd_F07TR, pnd_fieldF07ML, IWCtopnd_F07ML), src/m_cloudbox.cc (pnd_fieldSetup): Added new distributions. * src/m_cloudbox.cc (dNdD_F07TR, dNdD_F07ML, dNdD_MGD_LWC, dNdD_MGD_IWC), src/methods.cc: Added new WSMs for the new distributions. 2014-12-02 Oliver Lemke * arts-2-3-78 * src/m_xml.cc, src/m_xml.h, src/methods.cc: Added new WSM ReadXMLIndexed. 2014-11-30 Jana Mendrok * arts-2-3-77 * src/m_optproperties.cc (ExtractFromMetaSingleScatSpecies): Don't shadow WSV with a generic one. Improved checks. * src/m_cloudbox.cc, methods.cc: Typos fixed. 2014-11-28 Jana Mendrok * arts-2-3-76 * Modifications to allow DOIT's first guess doit_i_field to be set from precalculated doit_i_field1D_spectrum (instead of from clearsky). To be backported to ARTS-2.2. * src/m_doit.cc (doit_i_fieldSetFromDoit_i_field1D_spectrum): Added. Method to set first make arts guess doit_i_field from precalculated full spectrum field doit_i_field1D_spectrum (e.g. from a similar, but not identical atmospheric scenario). Note, works for 1D only. Currently a very basic versions that requires the precalculated field to be on same grids (freq, atm levels, angles) as the current calculation, i.e. no interpolation. In future, atm level and angle grid interpolation could/should be allowed. (DoitCloudboxFieldPut): Don't resize and zero doit_i_field1D_spectrum. It has been initialized by DoitInit already. However, for atm_dim=1 always set it from doit_i_field, not only when sensor inside cloudbox (we might want to output it for later use/analysis). (ScatteringDoit): Don't zero-size doit_i_field1D_spectrum before entering doit_mono_agenda. It might contain data we want to use inside the agenda. (DoitInit): Initialize, i.e. properly size and set to zero, scat_i_p/lat/lon and doit_i_field1D_spectrum. Needed as either group of them can be used to set the first guess doit_i_field, meaning that the other group usually remains uninitialized otherwise. Note, this change requuires DoitInit to be called BEFORE any other WSM setting input for ScatteringDoit like CloudboxGetIncoming (else the data will be erased again).. * src/methods.cc: Adapt to changes of WSMs above. * src/agendas.cc (doit_mon_agenda): Added doit_i_field1D_spectrum as input. * controlfiles/artscomponents/doit/TestDOIT.arts, doitbatch/TestDOITBatch.arts: Move DoitInit call to before CloudboxGetIncoming, adopting to DoitInit changes above. * controlfiles/artscomponents/absorption/TestAbs.arts, TestAbsDoppler.arts: Replaced references to obsolete abs_coefCalc. 2014-11-28 Jana Mendrok * arts-2-3-75 * src/m_abs_lookup.cc (abs_lookupSetupBatch): Fix bug (missing setting of z_index). Pointed out by Oliver. 2014-11-27 Patrick Eriksson * arts-2-3-74 * src/workspace.cc: Removed or corrected old information for iy_aux, y_aux and iy_aux_vars. 2014-11-27 Jana Mendrok * arts-2-3-73 * a couple of WSM for analysis of PSD data. * src/m_cloudbox.cc (pndFromdNdD): Method to convert dNdD to pnd, i.e. size bin integrated number densities. Mimics what is happening inside pnd_fieldSetup. * src/m_optproperties.cc (ExtractFromMetaSingleScatSpecies): Method to extract parameters from meta data structure. * src/m_basic_types.cc (VectorVectorMultiply): Method for element-wise multiplication of 2 vectors. * src/methods.cc: Definition and doc of the above new WSM. 2014-11-22 Jana Mendrok * arts-2-3-72 * Changed approach of handling compact and batch scenarios. Now allows the compact batch (ArrayOfGriddedField4) to be the basic data type, not anymore the ArrayOfMatrix. * src/m_atmosphere.cc (AtmFieldsFromCompact): Revised atm_fields_compact to *_fields conversion, selection approach. No more constraints on order of fields. All matching/selection done based on field name tags. Cleaner handling of scattering species data fields. They are now sorted into data fields depending on their type - no mixing of mass densities and fluxes, etc. anymore. (AtmFieldsExpand1D): Allow switching off rejection of fields with NaN values. Need that to be able to expand the scat_species_*_*_field when converting to 3D atmosphere. * src/m_abs_lookup.cc (abs_lookupSetupBatch): Revised to work with new batch_atm_fields_compact definition (e.g. consider fields are not sorted). * src/m_cloudbox.cc (cloudboxSetAutomatically): Consider all scat_species_*_*_fields, not just mass_density. Improved efficiency of cloudbox limits search. Ensure, it's only run for 1D, throwing an error for higher dims. (pnd_fieldSetup): For MP48, pass mass_flux field. * src/check_input.[cc,h] (chk_atm_field): Keyword to switch off NaN rejection. * cloudbox.[cc,h] (chk_scat_species_field): Consider NaN as a non-set value that doesn't trigger the cloudbox, equivalently to zero values. (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13, pnd_fieldH13Shape, pnd_fieldH98, pnd_fieldMP48): Proper error check, ensuring whatever field is needed by the PSD is present, i.e. has a non-NaN value. For PSD with PSD shape being a function of mass content or flux, disallow negative mass content/flux values; Ok for PSD, where mass content/flux only scales the pnd. (parse_atmcompact_speciestype, parse_atmcompact_speciesname, parse_atmcompact_scattype): Added methods to parse field name tags of compact atmospheres. * src/workspace.cc, methods.cc: Revised and updated documentation of all compact atmosphere related WSV and WSM. Adapted doc to further changes above. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/instruments/ici/TestICI_fast.arts, controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts, controlfiles/instruments/amsu/TestAMSU_generic.arts, controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/mhs/TestMHS_generic.arts: Adapted batch_atm_fields_compact field_names to new convention. 2014-11-20 Oliver Lemke * arts-2-3-71 * src/methods.cc, src/m_sensor.cc: (sensor_responseBackendMetMM): Remove use_polarisation input. stokes_dim is used to determine whether or not to calculate polarisation. Add mblock_za_grid as input. sensor_los contains now the nadir zenith angle direction of the sensor (e.g. 180 for AMSU). And mblock_za_grid the off-nadir scan angles. For each looking angle a measurement block is now used. * src/sensor.cc (met_mm_polarisation_hmatrix): Fix bug in if/elseif. Add doxygen documentation. * src/workspace.cc: Add polarisation docs to met_mm_polarisation. * controlfiles/instruments/amsu/amsub.arts: Use lines based on hitran12 catalog. * controlfiles/instruments/amsu/amsub.hitran12_o3_lines.xml.gz: Extracted from hitran12. Also vastly reduce catalog size by only including O3 lines instead of all species. * controlfiles/instruments/amsu/TestAMSUB.ybatch.ref.xml: Updated based on calculation with hitran12 lines. * controlfiles/instruments/amsu/amsub_metmm.arts: Use mblock_za_grid for scan angles. Add channel polarisation settings. * controlfiles/instruments/amsu/TestAMSUB_MetMM.arts: Include new TestAMSU_MetMM_generic.arts. * controlfiles/instruments/amsu/TestAMSU_MetMM_generic.arts: Based on TestAMSU_generic. Removed sensor_los because it can't be changed here anymore. It has to be set before the sensor setup because sensor_response now contains scan angle dependent polarisation information. * controlfiles/instruments/amsu/amsub.mblock_za_grid.xml: Added. AMSU-B scan angles. * controlfiles/CMakeLists.txt: Add TestAMSUB_MetMM. 2014-11-18 Patrick Eriksson * arts-2-3-70 * src/m_rte.cc (iyEmissionStandard): Added a check of obtained ppath to catch infinite loops at the surface. This could happen if you set (or as we did disturb) specular_los in an incorrect way, or potentially also happen due limited numerical accuarcy. 2014-11-18 Patrick Eriksson * arts-2-3-69 * src/surface.cc (surface_specular_R_and_b): surface_rmatrix(3,2) had the wrong sign, compared to equation in ATD. See further email to arts-users. 2014-11-11 Richard Larsson * arts-2-3-68 This commit fixes a strangeness found in the quadratic normalisation. Warning: it breaks controlfiles for clarity. * constrolfiles/instruments/odinsmr/odinsmr.arts: Changes reflect above. * src/absorption.cc{cc,h} Removed quadratic lineshape normalization test. * src/lineshapes.cc: moved hv/2kT/sinh(hv/2kT) into the normalisation routine. Changed name of routine to “Rosenkranz_quadratic” to reflect what was going on inside absorption.cc before this commit. * src/methods.cc: Updated documentation to properly reflect new and old behaviour for quadratic normalisation. 2014-11-11 Richard Larsson * arts-2-3-67 Restructuring of pressure broadening in preparation for ARTSCAT-5 format. * src/absorption.{cc,h}: These files were restructured to reflect changes below. * src/linerecord.{cc,h}: The linerecord no longer contains an assortment of pressure broadening parameters but a single pressurebroadeningdata class. This is reflected in how the reading routines handle pressure data. There are adaptions to all the relevant previous calls to return individual line parameters inside the pressure broadening class. One important design decision is that we no longer allow internally different temperatures for line parameters and pressure parameters. All old formats that allowed this have been adapted to store pressure broadening internally at the appropriate temperature by (T0/T1)^n conversion for gamma and (T0/T1)^(.25+1.5n) for deltaf. * src/linemixingdata.{cc,h}: restructured slightly to reflect design decisions in pressurebroadeningdata. * src/pressurebroadeningdata.{cc,h} (added): This class contains a structure of data that is similar to the structures that previously were kept in linerecord. 2014-11-10 Jana Mendrok * arts-2-3-66 * controlfiles/testdata/testdoit_*.xml: Moved all test data from artscomponents/doit/ folder to here in order to use it for other test cases, too. * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/absorption/TestAbsParticle.arts: Adapted according to data moves above. * controlfiles/CMakeLists.txt: Added TestAbsParticle.arts to regular tests. 2014-11-10 Jana Mendrok * arts-2-3-65 * src/m_cloudbox.cc (ParticleTypeAdd, ParticleType2abs_speciesAdd): Fixed for use with ArrayOfArray scat_data. * src/m_abs.cc (propmat_clearskyAddParticles): Fixed for use with ArrayOfArray scat_data. Don't silently assume there's only one scat species, instead allow scat_data to contain multiple. * src/methods.cc (ParticleType2abs_speciesAdd): More precise doc. * doc/uguide/absorption.tex: Revised absorbing-only particles section. Added reference to setup example. * doc/uguide/rte_basics.tex: Reworded 'Absorbing species and particles' to 'Absorbing species and scattering particles' in order to avoid misreading as 'absorbing particles'. * controlfiles/artscomponents/absorption/TestAbsParticle.arts: Added a test case for absorbing-only particles. * controlfiles/artscomponents/doit/TestDOIT.arts: Modified to use two scattering elements instead of only one (that's better to detect bugs in handling ArrayOfArray and other non-1D elements). 2014-11-07 Jana Mendrok * arts-2-3-64 * src/methods.cc (pnd_fieldSetup): Cleaned up documentation. Completed available distribution info. * src/m_cloudbox.cc (pnd_fieldSetup): Add a reminder comment to update tag info in methods.cc whenever new distributions are added. 2014-11-03 Richard Larsson * arts-2-3-63 * src/absorption.cc: Simplified so cutoff is not dependent on linemixing. We (me and Manfred) found this produced most consistent results with AER's own simulations. Note that line mixing will produce negative absorption at some frequencies in the present only option so zero forcing is required. 2014-10-30 Richard Larsson * arts-2-3-62 * src/methods.cc: propmat_clearsky is now also input to the zero forcing function. 2014-10-30 Richard Larsson * arts-2-3-61 * src/{m_abs.cc,methods.cc}: Added propmat_clearskyForceNegativeToZero, which force propmat_clearsky to zero if negative. This seems necessary for CO2 line mixing from testing. 2014-10-30 Richard Larsson * arts-2-3-60 * src/absorption.{cc,h}: Fixed how line mixing deals with cutoff. Also added sec_species tests to wrapper. 2014-10-29 Richard Larsson * arts-2-3-59 * src/abs_species_tag.cc: Removed tagging problems with line mixing. * src/absorption.{cc,h}: Removed LineRecord dependency for internal- most loop of (xsec_species). The function call inside to (xsec_single_line) now only depends on base variables. The advantage is that neither Zeeman nor line mixing must copy LineRecords to work, reducing their slowest test case by a factor 3 in runtime for the fastest setup requiring PreCalc. (calc_gamma_and_deltaf_artscat4) was changed to reflect previous behaviour. There are some other small changes inside (xsec_single_line) resulting in small gains but the function call is complicated so the overall runtime running no Zeeman and no line mixing is slightly slower (less than 5%) in our test case. The old methods are still included in the function but there is no way to use them without altering code. The speed increase is from accessing the absorption calculations from the wrappers instead of through xsec_species. Line mixing is now done internally in (xsec_singel_line) instead of in wrapper. * src/linerecord.h: Can return artscat4 full vectors now. * src/lineshapes.cc: Fixed slight error in (faddeeva_algorithm_916) use of aux vector. * src/m_abs.cc: Minor change in input to wrapper to work with above. * src/m_zeeman.cc: PreCalc now only touch the LineRecord before calculations. The frequency shift is passed along to wrapper before being applied to frequency input in (xsec_single_line). * src/methods.cc: Changed LineRecord to not be an output of PreCalc. * src/zeeman.{cc,h}: Zeeman wrapper now pass central frequency along for PreCalc and empty vector for level-by-level calculations. 2014-10-27 Jana Mendrok * arts-2-3-58 * src/m_cloudbox.cc (ScatteringParticlesSelect): Replace 'are equal' checks of size limits by more robust proximity estimation. 2014-10-27 Jana Mendrok * arts-2-3-57 * src/m_cloudbox.cc, methods.cc (dNdD_H11, dNdD_Ar_H13, dNdD_H98, dNdD_MH97, dNdD_MP48), src/cloudbox.cc/h (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13, pnd_fieldH13Shape, pnd_fieldMP48, pnd_fieldH98, IWCtopnd_MH97, IWCtopnd_H11, IWCtopnd_H13, IWCtopnd_H13Shape, area_ratioH13, LWCtopnd, PRtopnd_MP48): Adapt size parameter namings to agreed naming convention (diameter_XX). 2014-10-27 Jana Mendrok * arts-2-3-56 * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Set correct mass value. In order to have a demonstration case that could also work with pnd_fieldSetup (mass is the basic parameter there, required by ALL psd). * src/m_optproperties.cc (ScatteringMergeParticles1D): Removed duplicate setting of merged scattering element's description string. 2014-10-26 Patrick Eriksson * arts-2-3-55 * src/check_input.cc (chk_interpolation_grids_loose_no_data_check) (chk_interpolation_grids_loose_check_data) (chk_interpolation_grids): Adjusted how the input error string is outputted. Did not look good with long strings, as the ones fixed below. There could be a need to adjust other input strings ... * src/m_optproperties.cc (pha_mat_sptFromDataDOITOpt) (opt_prop_sptFromData, pha_mat_sptFromMonoData) (ScatteringMergeParticles1D): Tweaked temperature interpolation error string. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: * src/tmatrix.cc: * src/methods.cc: * src/m_tmatrix.cc: Changed my mind, and also checked with some others this time! Renamed axial_ratio back to aspect_ratio throughout the code. This as the later is a more general term. 2014-10-23 Oliver Lemke * arts-2-3-54 * src/m_optproperties.cc (ScatteringMergeParticles1D): Resize outer array of scat_data_merged to 1. Use correct flattened index to pnd_field. Improve error message. 2014-10-22 Patrick Eriksson * arts-2-3-53 * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Mass now not set to a dummy value. Default NaN is used now, after Oliver's fix. 2014-10-22 Jana Mendrok * arts-2-3-52 Renamed massdensity_field to scat_species_mass_density_field, added scat_species_mass_flux_field and scat_species_number_density_field (so far only placeholders) and changed some massdensity_field methods to support the new fields. * src/workspace.cc: Renamed massdensity_field to scat_species_mass_density_field. Added scat_species_mass_flux_field and scat_species_number_density_field. Adapted documentation. * src/methods.cc, m_cloudbox.cc, m_atmosphere.cc: Renamed all occurences of massdensity_field to scat_species_mass_density_field. * src/methods.cc, m_cloudbox.cc (Massdensity_cleanup): Renamed method to scat_species_fieldCleanup and adapted to be applicable for all scat_species_XX_fields, i.e. now taking/providing generic Tensor4 in/output. * src/cloudbox.cc, cloudbox.h (chk_massdensity_field): Renamed method to chk_scat_species_field and adapted to be applicable for all scat_species_XX_fields * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Adapt for change of Massdensity_cleanup to scat_species_fieldCleanup. * src/m_basic_types.cc: Spell fix. 2014-10-22 Oliver Lemke * arts-2-3-51 * controlfiles/artscomponents/doitbatch/ScatteringMetaFile_H2Oice.xml, controlfiles/artscomponents/doitbatch/ScatteringMetaFile_H2Oliquid.xml: Correct wrong xml version. Should be 1.0 not 3.0. 2014-10-22 Oliver Lemke * arts-2-3-50 * src/parser.cc (ArtsParser::set_gin_to_default, ArtsParser::parse_numvector_from_string): Add support for "NaN" values in defaults for generic inputs (for Numeric and Vector). Note, it does not work yet to pass 'NaN' values to generic inputs in the controlfile. E.g., this will not work: Test(ginput1=3., ginput2=NaN). 2014-10-22 Richard Larsson * arts-2-3-49 * src/abs_species_tags.cc: Turned off test forcing LM to run alone without continua as another tag. Hopefullt this will reduce discrepancies found by Manfred. 2014-10-22 Patrick Eriksson * arts-2-3-48 * controlfiles/CMakeLists.txt: TestTMatrixSSD.arts removed. * controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Extended, now also testing scat_data_singleTmatrix, diameter_maxFromDiameter_volume_equ and diameter_volume_equFromDiameter_max. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Removed. * src/m_tmatrix.cc (diameter_maxFromDiameter_volume_equ): New name of theis WSM. And now also returns maximum axial area. (diameter_volume_equFromDiameter_max): New name of this WSM. (scat_data_singleTmatrix): Now also setting single_meta_data. * src/methods.cc: * src/tmatrix.h: * src/tmatrix.cc: * src/m_tmatrix.cc: Changed "aspect ratio" to "axial ratio" throughout the code, to follow what seems to be the standard nomenclature. At least, this is the name used in Mishchenko&Travis, 1998. 2014-10-21 Jana Mendrok * arts-2-3-47 * src/cloudbox.cc(pnd_field*): Ensure that meta data required by specific size distribution method is available for each individual scattering element, else throw error. * src/methods.cc, m_cloudbox.cc(dNdD_MH97, dNdD_MP48), cloudbox.cc(pnd_fieldMH97, pnd_fieldMP48, IWCtopnd_MH97, PRtopnd_MP48): Change from using volume equivalent diameter to mass equivalent diameter, Dmass, in MH97 and melted equivalent diameter, Dmelt, in MP48. MH97 according to definition in MH97 paper. For MP48 literature is not very clear. MP48 itself only discussed rain drops, but MP48 is widely used for precipitating hydrometeors in general, e.g. in RTTOV (see doherty07:_ice_amsu_b_qjrms). Literature is not clear though, what diameter to be used in case of frozen hydrometeors. Considering the measurement technique used by MP48 is seems most plausible to assume melted diameter. * controlfiles/artscomponents/doitbatch/TestDOITBatch.ybatch.ref.xml: Adjusted. Using Dmass instead of Dvol in MH97 causes small changes in BT due to slightly different assumption of ice density. 2014-10-21 Richard Larsson * arts-2-3-46 * controlfiles/*{zeeman,linemixing}*: Fixed to reflect the changes. * src/absorption.cc: Cutoff was implemented poorly for phase, and the implementation does not work with line mixing at all. Now, cutoff must be turned off for line mixing and Zeeman calculations to work. * src/rational.{h,cc}: Less Simplify() calls. * src/*zeeman.{h,cc}: Small speed improvements moving variables around. Still a huge speed loss for copying inputs to speedy Zeeman case. 2014-10-17 Oliver Lemke * arts-2-3-45 * src/array.h (TotalNumberOfElements, FlattenedIndex): Add missing & to array argument. 2014-10-16 Oliver Lemke * arts-2-3-44 * src/cloudbox.cc (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13, pnd_fieldH13Shape, pnd_fieldMP48, pnd_fieldH98): Fix bug introduced in arts-2-3-31. The scat_meta elements were used in unsorted order. Bug found by Jana. 2014-10-15 Jana Mendrok * arts-2-3-43 Change of scattering meta data structure. Adaption of all methods that use scat_meta. Removed material tag fromscat_species. * src/optproperties.h (ScatteringMetaData): Revised format of class. * src/xml_io_compound_types.cc: Read/write support for new (version3) nScatteringMetaData class format. Removed version1 and 2 support. * src/m_cloudbox.cc (ScatteringParticlesSelect): Removed obsolote material tag based selection. (pnd_fieldSetup): Removed any use of material meta info. (dNdD_*): Renamed from dN_* to properly reflect output parameter. Removed density as input parameter. (particle_massesFromMetaDataSingleCategory): Use mass info from meta data. (particle_massesFromMetaDataAndScat_species): Renamed (from particle_massesFromMetaDataAndScat_species). Use mass info from meta data. * src/cloudbox.cc/h: (chk_scat_species): Adapt for removed material tag. (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13, pnd_fieldH13Shape, pnd_fieldMP48, pnd_fieldH98): Adapted to new fromat of scattering meta data. Cleaned up a little. (IWCtopnd_MH97, IWCtopnd_H11, IWCtopnd_H13, IWCtopnd_H13Shape, area_ratioH13, LWCtopnd, PRtopnd_MP48): Removed density from method interfaces. More consistent naming of method parameters. (chk_pndsum): Replace method input volume and density by mass. (scale_H11, scale_H13, parse_part_material): Removed obsolete methods. * src/m_tmatrix.cc: Removed methods scat_metaAddTmatrix, scat_dataFromMeta, scat_metaAddTmatrixOldVersion. New meta data format does not support Tmatrix inpu anymore. * src/constants.cc: Density of water ice and liquid water added. * src/methods.cc, workspace.cc: Revised scat_meta_single and scat_species documentation. Revised documntation of methods using these. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Adapted to scat_meta and scat_species changes. * controlfiles/artscomponents/doitbatch/scatData/*.meta.xml.gz: Adapted test case meta data to new format. * controlfiles/artscomponents/doitbatch/ScatteringMetaFile_H2Oice.xml, ScatteringMetaFile_H2Oliquid.xml, SingleScatteringFile_H2Oice.xml, SingleScatteringFile_H2Oliquid.xml: Added. Scattering data and meta files for DoitBatch test case, separated by scattering species. * controlfiles/artscomponents/doitbatch/SingleScatteringFile.xml, ScatteringMetaFile.xml: Removed. * doc/uguide/scattering.tex: Bugfix. 2014-10-15 Richard Larsson * arts-2-3-42 * src/m_zeeman.cc: Created two new functions to calculate Zeeman effect a little bit different. These new methods makes the Zeeman test cases 10 to 25% faster, but should offer much larger speed improvements on higher p_grid:s. The old Zeeman code still works as before but will be slower for magnetic fields that are exactly zero. Documentation pending. Use (ZeemanLineRecordPreCalc) after the linerecords are finalized and change (propmat_clearskyAddZeeman) to (propmat_clearskyAddZeemanFromPreCalc) in the agenda to use the new method. * src/zeeman.{cc,h}: Incorporated linerecord creation in this file. * src/workspace.cc: Added zeeman_linerecord_precalc. * {the rest}: Controlfiles for test added; looks at the same comparison with both Zeeman methods. Agenda call added to agendas.arts. Corresponding fixes in m_checked and methods. 2014-10-15 Oliver Lemke * arts-2-3-41 * src/quantum.{cc,h} (QuantumNumbers): Change QuantumContainer from std::map to Array. Speeds up the extensive zeeman test case by 1.5x on Linux and 2x on Mac. Even though the array now allocates space for all quantum numbers instead of just the ones that actually exist, early test have shown that it does not use more memory than the prior std::map implementation. 2014-10-14 Richard Larsson * arts-2-3-40 * src/m_zeeman.cc: Starting modularization of code. * src/zeeman.{cc,h}: Modules for the Zeeman code added. The goal is to make Zeeman more modular to make extensions of functionality easier. Hope is for more speed improvements. Work still in progress. 2014-10-14 Oliver Lemke * arts-2-3-39 * src/absorption.cc (xsec_species_line_mixing_2nd_order, xsec_species_line_mixing_LBLRTM, xsec_species_LBLRTM_O2NonResonant): Slight performance improvements. * src/absorption.{cc,h} (xsec_species_line_mixing_none): Removed. * src/m_zeeman.cc (propmat_clearskyAddZeeman): Approx. 50% performance improvement for extensive test case. 2014-10-14 Oliver Lemke * arts-2-3-38 * src/absorption.cc (xsec_species_line_mixing_wrapper): Vectorized pressure loop. Use index array to select non-linemixing lines to improve performance. 2014-10-14 Richard Larsson * arts-2-3-37 * src/absorption.{cc,h}: Small optimization for several pressure levels in line mixing. 2014-10-14 Richard Larsson * arts-2-3-36 * src/absorption.{cc,h}: Added support for several pressure levels in line mixing. 2014-10-13 Oliver Lemke * arts-2-3-35 * src/xml_io_compound_types.cc (xml_read_from_stream): Add runtime error check for ptype for SingleScatteringData version < 2. * src/cloudbox.cc (chk_scat_data): Change ptype check to assertion. Runtime error check is now done in the reading routine. Replace references to ptype 10,20,30 with strings. * src/montecarlo.cc (opt_propExtract), src/rte.cc (emission_rtstep): Replace references to ptype 30 with string. 2014-10-10 Jana Mendrok * arts-2-3-34 Make sure, SingleScatteringData and UseDOIT wiki parts are represented in AUG or built-in doc. * doc/uguide/clouds.tex: Checked for complete coverage of wiki's SingleScatteringData info. Some small issues updated along the way. FIXMEs raised on angular grid requirements. * doc/uguide/scattering.tex: removed DOIT theory part from here, i.e. the scattering doc in AUG. Checked for complete coverage of wiki's UseDOIT info. Some small issues updated along the way. * doc/uguide/doit.tex: Added. DOIT part for ATD, containing the method theory description formerly in AUG. * doc/uguide/montecarlo.tex, atmosphere.tex, ppath.tex, absorption.tex, integration.tex, concept.tex, arts_user.tex: References adapted to AUG/ATD separation of DOIT part. * doc/uguide/arts_theory.tex, CMakeLists.txt: Adapted to cover moved ATD DOIT chapter. * src/cloudbox.cc: spellfix. 2014-10-10 Oliver Lemke * arts-2-3-33 * doc/uguide/Figs/scattering/interp_err.pdf, doc/uguide/clouds.tex, doc/uguide/montecarlo.tex, doc/uguide/scattering.tex: Replace p10, p20, p30 with strings "general", "macroscopically_isotropic" and "horizontally_aligned". 2014-10-09 Oliver Lemke * arts-2-3-32 * ChangeLog: Slight retouching. 2014-10-09 Oliver Lemke * arts-2-3-31 * Change of data types of scat_data and scat_meta from ArrayOfSingleScatteringData to ArrayOfArrayOfSingleScatteringData and ArrayOfScatteringMetaData to ArrayOfArrayOfScatteringMetaData. * src/workspace.cc: Change type of scat_meta to ArrayOfArrayOfScatteringMetaData. Change type of scat_data to ArrayOfArrayOfSingleScatteringData. Change type of scat_data_mono to ArrayOfArrayOfSingleScatteringData. * src/groups.cc: Add ArrayOfArrayOfSingleScatteringData/ScatteringMetaData. * src/methods.cc: (particle_massesFromMetaDataAndPart_species): Remove scat_data_per_scat_species and scat_species inputs. (pnd_fieldSetup, ScatteringParticlesSelect): Remove scat_data_per_scat_species input/output. * src/m_cloudbox.cc (ParticleType2abs_speciesAdd): Adapt to new type of scat_data. FIXME: Correct to add as a new scattering species to scat_data? * src/m_tmatrix.cc (scat_metaAddTmatrix): Adapt to new type of scat_meta. FIXME: Where to add to scat_meta? Currently appended to last species. * src/m_abs.cc (propmat_clearskyAddParticles): Adapt to new type of scat_data_mono. FIXME: Is it correct to just use the first scattering species? * src/array.h: (TotalNumberOfElements): Convenience function that returns the total number of elements in an ArrayOfArrayOf. (FlattenedIndex): Returns the flattened index of an element in an ArrayOfArrayOf. * src/cloudbox.{cc,h}: (pnd_field*): Adapt all particle distributions functions to new scat_meta type. Remove scat_data_start and npart arguments. Instead add a scat_species Index argument. * src/disort.{cc,h} (phase_functionCalc): Adapt to new scat_data_mono type. * src/m_batch.cc (ybatchMetProfiles), src/m_checked.cc (cloudbox_checkedCalc), src/m_cloudbox.cc (cloudboxOff, ParticleTypeInit, ParticleTypeAdd, ParticleTypeAddAll, pnd_fieldZero), src/m_doit.cc (DoitInit), src/m_fos.cc (fos, iyFOS), src/m_rte.cc (iyMC), src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard), * src/rte.{cc,h} (get_ppath_ext): Adapt to new type of scat_data. * src/m_cloudbox.cc: (ScatteringParticleTypeAndMetaRead): Adapt to new type of scat_data and scat_meta. (ScatteringParticlesSelect): Adapt to new type of scat_data and scat_meta. Remove scat_data_per_scat_species. (particle_massesFromMetaDataSingleCategory, particle_massesFromMetaDataAndPart_species, pnd_fieldSetup) Adapt to new scat_meta type. * src/m_cloudradar.cc (iyCloudRadar), Adapt to new type of scat_data. * src/m_disort.cc (ScatteringDisort): Adapt to new type of scat_data and scat_data_mono. * src/m_montecarlo.cc (MCGeneral): Adapt to new type of scat_data_mono. * src/m_optproperties.cc: Adapt MACROS to new type of scat_data. (pha_mat_sptFromData, opt_prop_sptFromData, scat_dataCheck, ScatteringMergeParticles1D): Adapt to new type of scat_data. (pha_mat_sptFromDataDOITOpt, opt_prop_sptFromMonoData, pha_mat_sptFromMonoData): Adapt to new type of scat_data_mono. (DoitScatteringDataPrepare, scat_data_monoCalc): Adapt to new type of scat_data and scat_data_mono. * src/m_tmatrix.cc: (scat_metaInit): Adapt to new type of scat_meta. (scat_dataFromMeta): Adapt to new type of scat_meta and scat_data. * src/montecarlo.{cc,h} (cloudy_rt_vars_at_gp, findZ11max, is_anyptype30, mcPathTraceGeneral, opt_propCalc, pha_mat_singleCalc, Sample_los): Adapt to new type of scat_data_mono. * src/optproperties.h: Add typedef for ArrayOfArrayOfSingleScatteringData/ScatteringMetaData. * src/xml_io_array_types.cc, src/xml_io_instantiation.h src/xml_io_types.h: Add reading/writing support for ArrayOfArrayOfSingleScatteringData/ScatteringMetaData. 2014-10-08 Jana Mendrok * arts-2-3-30 * src/continua.cc, m_abs.cc, partition_function_data.cc, species_data.cc, controlfiles/general/continua.arts: Corrected version tag of new MTCKD: CKDMT250->CKDMT252. * doc/uguide/absorption.tex: Added MTCKD2.5.2 continua in table of available continua. 2014-10-07 Jana Mendrok * arts-2-3-29 * doc/uguide/cloudradar.tex, absorption.tex, wfuns.tex, scattering.tex, polarization.tex, rte_basics.tex, rte_theory.tex, clouds.tex, rte.tex, montecarlo.tex, absorption_theory.tex: Revised doc for terminology (particle type->scattering species/element). 2014-10-06 Oliver Lemke * arts-2-3-28 * controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts, controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts, controlfiles/planetary_toolbox/demos/common/DemoMarsClouds1D.arts, controlfiles/planetary_toolbox/demos/common/DemoVenusClouds1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_FOS_1D.arts, controlfiles/planetary_toolbox/demos/passive/DemoScat_MC_1D.arts, controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts, controlfiles/planetary_toolbox/includes/mars/getclouds_mars.arts, controlfiles/planetary_toolbox/includes/venus/getclouds_venus.arts, doc/uguide/absorption.tex, doc/uguide/clouds.tex, doc/uguide/rte_basics.tex, doc/uguide/scattering.tex, src/cloudbox.cc, src/cloudbox.h, src/disort.cc, src/disort.h, src/m_abs.cc, src/m_batch.cc, src/m_checked.cc, src/m_cloudbox.cc, src/m_cloudradar.cc, src/m_disort.cc, src/m_doit.cc, src/m_fos.cc, src/m_montecarlo.cc, src/m_optproperties.cc, src/m_rte.cc, src/m_tmatrix.cc, src/m_transmitter.cc, src/mc_interp.cc, src/mc_interp.h, src/methods.cc, src/montecarlo.cc, src/montecarlo.h, src/optproperties.cc, src/optproperties.h, src/partition_function_data.cc, src/rte.cc, src/rte.h, src/tmatrix.cc, src/tmatrix.h, src/workspace.cc, src/xml_io_compound_types.cc: Huge scattering renaming commit: scat_data -> scat_data_single scat_meta -> scat_meta_single scat_data_array -> scat_data scat_meta_array -> scat_meta scat_data_array_mono -> scat_data_mono scat_data_arrayCheck -> scat_dataCheck scat_data_arrayFromMeta -> scat_dataFromMeta scat_data_array_monoCalc -> scat_data_monoCalc scat_dataTmatrix -> scat_data_singleTmatrix scat_data_array_monoCalc -> scat_data_monoCalc scat_meta_arrayAddTmatrix -> scat_metaAddTmatrix scat_meta_arrayInit -> scat_metaInit Also replaced PARTICLE_TYPE_* with PTYPE_* and some local variables accordingly. 2014-10-06 Oliver Lemke * arts-2-3-27 * src/cloudbox.cc, src/m_cloudbox.cc, src/m_optproperties.cc, src/m_tmatrix.cc, src/methods.cc, src/montecarlo.cc, src/optproperties.cc, src/optproperties.h, src/tmatrix.cc, src/tmatrix.h, src/workspace.cc, src/xml_io_compound_types.cc, controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Rename particle_type to ptype, ParticleType to PType and ParticleType{From,To}String to PType{From,To}String. 2014-10-04 Jana Mendrok * arts-2-3-26 * src/*.cc,*.h: Revised doc of internal function (and code comments) regarding particle type -> scattering species/element terminology. 2014-10-04 Jana Mendrok * arts-2-3-25 * src/methods.cc, workspace.cc: Revised built-in doc regarding particle type -> scattering species/element terminology. Some further spell, grammar, and formulation fixes. * controlfiles/instruments/ici/ici_fast.arts: base on ici.arts by actually including it. minimize risk of inconsistent setting between fast and normal case. * controlfiles/instruments/ici/ici.arts: minor layout adaptions. 2014-10-03 Patrick Eriksson * arts-2-3-24 * src/math_funcs.cc (unitl): Corrected header. * src/m_sensor.cc (sensor_responseStokesRotation): Changed the method to make use of the internal function mueller_rotation, to avoid duplication of very similar code. Forgot that we had this method when implementing mueller_rotation! 2014-10-02 Richard Larsson * arts-2-3-23 We can now calculate non-resonant O2 from LBLRTM catalogue. * doc/uguide/absorption.tex: Document how to use the changes. * src/absorption.{cc,h}: Added a special function to deal with non-resonant molecular oxygen band at zero frequency in the same way that LBLRTM deals with this. * src/linemixingdata.{h,cc}: The complementary class metods were added here. * src/linerecord.cc: And the reading routine here was also adjusted. * src/lineshapes.cc: Added a special line shape for non-resonant O2. It is not recommended to use this line shape elsewhere, since it is custom made for non-resonance. 2014-09-30 Richard Larsson * arts-2-3-22 * src/linerecord.cc: Fixed so that Zeeman calculations for molecular oxygen works with the LBLRTM catalog. * doc/uguide/absorption.tex: Document changes in line mixing. 2014-09-30 Oliver Lemke * arts-2-3-21 * src/abs_species_tags.cc: (SpeciesTag::SpeciesTag): Remove tag LM_2NDORDER. Instead a -LM flag should be placed after the species name (or the optional Z tag). (SpeciesTag::Name): Adapt for LM tag change. * src/methods.cc: Update docs for LM tag change. * controlfiles/artscomponents/linemixing/TestLineMixing*.arts: Adapt for LM tag change. 2014-09-30 Oliver Lemke * arts-2-3-20 * src/absorption.cc (xsec_species_line_mixing_wrapper): Fix incorrect parenthesis. 2014-09-29 Patrick Eriksson * src/math_funcs.cc (unitl): 2014-09-29 Patrick Eriksson * arts-2-3-19 * src/sensor.cc (met_mm_polarisation_hmatrix): Added rotation information for ISMAR. And on the same time rearranged the code and the notation, hopefully to make things clearer. 2014-09-29 Richard Larsson * arts-2-3-18 Implementation of LBLRTM line mixing now works. For O2, this produces less than 0.1 K difference with PWR98 in the band center, and about 0.5 K difference in the band wings. The test was done on straight-downward looking geometry across the 60 GHz band. * src/linemixingdata.{cc,h}: Fixed interpolation scheme so that it does not crash at run. * src/linerecord.cc: Fixed non-working test and error in conversion factor. 2014-09-29 Patrick Eriksson * arts-2-3-17 * src/m_tmatrix.cc (scat_dataTmatrix): Removed "From" from name and fixed typos in description. (ParticleDmaxFromDe, ParticleDeFromDmax): Also renamed, now using From instead of To, to have the output variable first in WSM name. 2014-09-27 Patrick Eriksson * arts-2-3-16 * src/m_tmatrix.cc (ParticleDeToDmax, ParticleDmaxToDe): New. Not yet tested in detail. * src/m_tmatrix.cc (scat_dataFromTmatrix): Write on-line doc for the WSM. (scat_meta_arrayAddTmatrixOldVersion): Removed. * src/optproperties.h: * src/cloudbox.cc (chk_scat_data): * src/optproperties.cc (ParticleTypeFromString) (ParticleTypeToString): Removed PARTICLE_TYPE_SPHERICAL. This ptype has not been implemented in any part. 2014-09-27 Patrick Eriksson * arts-2-3-15 * src/m_tmatrix.cc (scat_dataFromTmatrix): Missed that r, not d should be input to T-matrix. Now seems to match old implementation. Documentation not yet in place. And unsure about setting of ptype. 2014-09-26 Jana Mendrok * arts-2-3-14 * controlfiles/instruments/ismar: Folder added for ISMAR setups (rather: all FAAM microwave radiometer, includes MARSS and Deimos). * controlfiles/instruments/ismar/marss.arts, deimos.arts, ismar.arts: Basic sensor description setups. So far contain only the sensor_description matrix (in amsu form. to be updated when new format is implemented.). 2014-09-26 Richard Larsson * arts-2-3-13 * src/absorption.{cc.h}: Added functionality to deal with lines that are not mixed even though the species is mixed. Also added LBLRTM mixing scheme. This is still very much in testing. * src/linemixingdata.cc: Added some more error checking. * src/m_conversion.h: Added functionality to convert wavenumber units to frequency. This makes testing CO2 line mixing data easier, since the units are usually in wavenumbers. These are (FrequencyFromCGSAngularWavenumber) and (FrequencyFromCGSKayserWavenumber) * src/methods.cc: Made access point to reading routine for LBLRTM data (abs_linesReadFromLBLRTM). 2014-09-26 Oliver Lemke * arts-2-3-12 * src/methods.cc, src/m_sensor.cc (sensor_responseBackendMetMM): Work in progress commit for the new WSM to generate a sensor setup for meteorological millimeter instruments. * src/workspace.cc: Add met_mm_{antenna, backend, polarisation}. * src/sensor.{cc,h} (met_mm_polarisation_hmatrix): Added based on Patrick's Test example in m_general.cc. * src/parser.{cc,h}: (parse_intvector_from_string): Added. (ArtsParser::set_gin_to_default): Add support for ArrayOfIndex. * src/check_input.{cc,h} (chk_met_mm_backend): Added. * src/array.h (CmpArrayOfNumeric): Add helper class that can be used to apply a sort order of a ArrayOfNumeric to a Vector. * controlfiles/instruments/amsu/TestAMSUB_MetMM.arts, controlfiles/instruments/amsu/amsub_metmm.arts: Temporarily added for testing. * controlfiles/instruments/amsu/amsub.arts: Store sensor_response for diagnostics. 2014-09-25 Richard Larsson * arts-2-3-11 Big changes in line mixing handling. Now line mixing is part of the line instead of, as before, a lookup table. View this update as first beta version of the new line mixing functionality that we are adding. * controlfiles/general/general.arts: Removed old line mixing scheme. * src/CMakeLists.txt: Added linemixingdata.cc * src/abs_species_tags.{cc,h}: Changed line mixing from type to on/off switch. Still work to be done here so that the abs_species tag is "LM" instead of "LM_2NDORDER" to trigger line mixing on switch. * src/absorption.{cc,h}: Now interacts with LineMixingData whenever line mixing is active. (xsec_species_line_mixing_wrapper) will now loop over all lines if the species is actively doing line mixing and then switch between line mixing calculations depending on the tag of line mixing carried by the line. Note that so far this has only been implemented for the old case of 2nd order line mixing, and that it is not fully representable of the physics because it ignores lines that are not line mixed. This will change in the coming days/weeks. That is only (xsec_species_line_mixing_2nd_order) will work in this version. * src/linemixingdata.{h,cc}: This contains the LineMixingData class, which is a part of all LineRecords since this version. This class will handle all line mixing data, except the builtin, in ARTS. It is presently feature incomplete but performs on par with previous scheme. * src/linerecord.{h,cc}: Fixed (ReadFromHitran2001Stream), which was broken. Also added (ReadFromLBLRTMStream) as a copy of the previous function that can also read the LBLRTM line mixing catalog. Also, LineRecord now contains the LineMixingData class. * src/m_abs.cc: Added (abs_linesReadFromLBLRTM). Also fixed mentionings of previous line mixing scheme. * src/m_linemixing.cc: The function (line_mixing_dataMatch) has been adapted to work with the new scheme. This still requires a lot of clean-up. * src/m_zeeman.cc: Is adapted for the new line mixing scheme. * src/methods.cc: Is adapted for new scheme. Old methods remains but are commented out. * src/workspace.cc:: Is adapted for new scheme. Old variable remains but are commented out. 2014-09-25 Patrick Eriksson * arts-2-3-10 * src/m_tmatrix.cc (scat_dataFromTmatrix): Started on this basic Tmatrix WSM. Not finished. * src/tmatrix.h: Corrected and extended header. 2014-09-24 Patrick Eriksson * arts-2-3-9 * src/workspace.cc: Removed WSVs mc_cloud_opt_path, mc_cloud_opt_path_error, mc_IWP and mc_IWP_error, as not now not used by any WSM. Just causing confusion to have them around. 2014-09-24 Patrick Eriksson * arts-2-3-8 * doc/uguide/scattering.tex: Added a second chapter inside the file, a chapter on MC. Moved stuff the Wiki page. Adopted the first lines in the DOIT chapter. * src/m_montecarlo.cc (MCGeneral): Renamed y_unit to iy_unit inside the method. * Fixed ticket 78 around iy_calc. See below. make check runs. check-all takes just too much time on my laptop, will check that later at the office. * controlfiles/general/agendas.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/surface/TestSurface.arts: Adopted by adding Ignore( iy_unit ) in some agenda definitions. * src/m_fos.cc (fos): Adopted call of get_iy_of_background. * src/m_surface.cc (iySurfaceRtpropAgenda): * src/m_jacobian.cc (jacobianCalcAbsSpeciesPerturbations) (jacobianCalcPointingZaRecalc) (jacobianCalcTemperaturePerturbations): * src/rte.cc (iyb_calc_za_loop_body, iyb_calc, get_iy_of_background): * src/m_rte.cc (iyCalc, yCalcAppend, yCalc, yCalc_mblock_loop_body): * src/m_cloudradar.cc (yCloudRadar): Adopted to change of iy_main_agenda. iy_unit just added as input and passed on. * src/CMakeLists.txt: Removed m_doit2.cc. * src/m_doit2.cc: Removed from svn. Old stuff of new use anymore. * src/m_doit.cc (CloudboxGetIncoming): * src/m_doit.cc (CloudboxGetIncoming1DAtm): iy_unit now hard-coded to "1". * src/agendas.cc: Added iy_unit as input to iy_main_agenda, iy_sub_agenda and iy_surface_agenda. 2014-09-23 Patrick Eriksson * arts-2-3-7 * src/m_general.cc (Test): Now includes demo code. To be incorporated in some method by Oliver. * src/sensor.cc (mueller_rotation): New function. * src/m_sensor.cc (sensor_responsePolarisation): Renamed y_unit to iy_unit, be consistent with renaming of corresponding WSV. 2014-09-17 Oliver Lemke * arts-2-3-6 * CHANGES-2.3, ChangeLog: Missed that scat_data_per_part_species also was renamed to scat_data_per_scat_species in arts-2-3-4. 2014-09-17 Oliver Lemke * arts-2-3-5 * CHANGES-2.3: Added to document changes in the dev version. Especially renaming of WSMs and WSVs should be written down here. 2014-09-17 Oliver Lemke * arts-2-3-4 * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/general/general.arts, src/cloudbox.cc, src/cloudbox.h, src/m_abs_lookup.cc, src/m_atmosphere.cc, src/m_cloudbox.cc, src/methods.cc, src/workspace.cc Rename part_species -> scat_species Rename scat_data_per_part_species -> scat_data_per_scat_species Rename ParticleSpeciesInit -> scat_speciesInit Rename ParticleSpeciesSet -> scat_speciesSet 2014-09-16 Oliver Lemke * arts-2-3-3 * tools: Add new tools directory. * tools/bash_completion: Add bash_completion script. * tools/vim_syntax: Add vim syntax script by Lukas Kluft. 2014-09-16 Oliver Lemke * arts-2-3-2 * README: Add info about profiling. 2014-09-15 Patrick Eriksson * arts-2-3-1 * src/m_basic_types.cc (MatrixAddScalar): New WSM, based on the vector version. 2014-09-15 Oliver Lemke * arts-2-3-0 * Start new development version by increasing minor version number. 2014-09-15 Oliver Lemke * arts-2-2-24 * src/m_optproperties.cc, src/methods.cc: Rename ScatteringDoitMergeParticles1D -> ScatteringMergeParticles1D. 2014-09-05 Oliver Lemke * arts-2-2-23 * src/m_batch.cc (ybatchCalc): Use schedule(dynamic) for better CPU utilization in batch jobs. * src/methods.cc, src/m_general.cc (StringCompose): Add new convenience WSM to concatenate several strings at once. 2014-08-15 Oliver Lemke * arts-2-2-22 * src/continua.cc (CKD_mt_250_co2): Fix array out of bounds access. Replaced tdep_bandhead[J-1196] with tdep_bandhead[(I1 + J-1)-1196] and introduced helper variable I1J. 2014-07-29 Mayuri Tatiya * arts-2-2-21 * src/continua.h, src/continua.cc: fixed the bug in "CO2-CKDMT250" 2014-07-23 Jana Mendrok * arts-2-2-20 * controlfiles/CMakeLists.txt: missed to commit in previous attempt. 2014-07-23 Jana Mendrok * arts-2-2-19 * controlfiles/instruments/[ici,smr]/ [ici,ciwsir,cloudice,iss-smr,jaxa-smr].sensor_response_f_fast.xml: Added. Data for sensor_response_f set such that y_f created on their basis can safely be used with yApplyUnit (essentially, square of channel frequency is sum over monochromatic frequencies times their weight associated with the respective channel). * controlfiles/instruments/[ici,smr]/ [ici,ciwsir,cloudice,iss-smr,jaxa-smr]_fast.arts: Read sensor_response_f with BT-conversion valid frequencies from file (overwrites sensor_response_f set from sensor_responseSimpleAMSU). * controlfiles/instruments/ici/*.*: Moved all ICI related data & controlfiles here (from instruments/smr/). * controlfiles/CMakeLists.txt: Adapted to above move of ICI files. * controlfiles/instruments/smr/jaxa-smr*.*: Renamed smr*.* to jaxa-smr for better recognizability. * src/m_abs.cc (abs_h2oSet): Removed spurious cout. 2014-07-17 Jana Mendrok * arts-2-2-18 * src/m_abs.cc(abs_h2oSet, abs_n2Set, abs_o2Set): Do not throw error if respective species (H2O, N2, O2) is not given. Instead set the abs_XX with a dummy, absence flagging value (-99). This to get rid of the requirement to always include H2O, N2, and O2 when any continuum/full model is to be applied although for the specific continuum they might not be needed at all). * src/continua.cc (xsec_continuum_tag): Introduced checks for valid abs_n2/o2/h2o for the specific continua that require those variables. Throw proper error message indicating the "problematic" continuum tag and the missing species. * src/continua.cc,continua.h(CKD_222_self_h2o,CKD_222_foreign_h2o, CKD_242_self_h2o, CKD_242_foreign_h2o, CKD_mt_100_self_h2o, CKD_mt_100_foreign_h2o, CKD_mt_250_self_h2o, CKD_mt_250_foreign_h2o): Removed abs_n2 as input parameter as abs_n2 is actually not used within in these functions. * controlfiles/instruments/amsu/amsub_fast.arts,smr/iss-smr_fast.arts: Use full path to f_grid and sensor_response files in order to be able to use these as ARTS include files from everywhere. 2014-07-16 Mayuri Tatiya * arts-2-2-17 * src/continua.h, src/continua.cc: Added functions of species for new MTCKD2.5 ("H2O-SelfContCKDMT250", "H2O-ForeignContCKDMT250","O2-visCKDMT250", "N2-CIArotCKDMT250", "N2-CIAfunCKDMT250", "CO2-CKDMT250") * src/m_abs.cc (abs_xsec_per_speciesAddConts, abs_o2Set): Added variable abs_o2 and a function to derive that from vmr_field as required by MTCKD2.5 N2 continuum. * src/partition_function_data.cc, src/species_data.cc: Added species tags for MTCKD2.5. 2014-07-16 Mayuri Tatiya * arts-2-2-16 * controlfiles/general/continua.arts: Added defintions for new MTCKD 2.5 continua. 2014-07-14 Oliver Lemke * arts-2-2-15 * src/m_optproperties.cc (ScatteringDoitMergeParticles1D): Removed old code. Fix from jana was correct. We don't have+want an operator* overload for Numeric*Vector Multiplication. This problem was caused by the one exception we made (operator* for scalar Vector*Vector multiplication). The Numeric is automatically casted to a ConstVectorView and the following scalar product fails because the two Vectors have different number of elements. 2014-07-10 Jana Mendrok * arts-2-2-14 * src/m_optproperties.cc (ScatteringDoitMergeParticles1D): Phase matrix merging using array multiplication caused asserts. Tentatively(?) fixed by replacing it with explicit loop. 2014-06-11 Jana Mendrok * arts-2-2-13 * src/cloudbox.cc (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13): Revert check for equal aspect ratios introduced in arts-2-1-755 (r8634). This seems unnecessary: it's perfectly fine to run those parametrizations on different aspect ratio particles (as is, e.g., the Hong data for a fixed habit!). In contrast to what arts-2-1-755 suggests, this has never been a requirement before. 2014-06-26 Patrick Eriksson * arts-2-2-12 * src/m_surface.cc (surfaceLambertianSimple): Extended the comment with a page reference for a 1988 edition of the cited book. 2014-06-26 Patrick Eriksson * arts-2-2-11 * src/m_surface.cc (surfaceLambertianSimple): Added reference motivating how the rmatrices are set. After input from Michael Kahnert. * src/methods.cc: Also some extra informaton here. 2014-06-26 Oliver Lemke * arts-2-2-10 * src/check_input.cc (chk_interpolation_grids_loose_no_data_check): Fix code for ascending grids. * src/m_atmosphere.cc: (GriddedFieldZToPRegrid): Add zeropadding support. (GriddedFieldZToPRegridHelper): New helper function. * src/methods.cc: Add zeropadding to GriddedFieldZToPRegrid. * controlfiles/artscomponents/regrid/: Extend test case. 2014-06-25 Oliver Lemke * arts-2-2-9 * src/m_basic_types.cc, src/methods.cc: Add Compare method for GriddedField3. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/regrid: Add regridding test case. 2014-06-24 Richard Larsson * arts-2-2-8 * src/m_atmosphere.cc: Added (GriddedFieldZToPRegrid), which should allow the user to input altitude-gridded datafields of type GriddedField3. 2014-06-24 Oliver Lemke * arts-2-2-7 * src/parser.{cc,h} (ArtsParser::at_end_of_argument): Add additional check to catch invalid characters at the end of named argument parameters instead of silently ignoring them. * src/m_nc.h (WriteNetCDFIndexed): Remove unused argument to fix compiler warning when compiling without netcdf support. 2014-06-11 Jana Mendrok * arts-2-2-6 * src/montecarlo.cc (opt_propCalc): Check whether atm temperature is in valid particle property temperature range. * controlfiles/instruments/smr/ici_fast.arts: Give full path to f_grid and sensor_response files. 2014-06-19 Oliver Lemke * arts-2-2-5 * src/matpackI.cc (vector_angle): Due to numerical inaccuracy, the argument to acos might end up being slightly larger than 1 and thus acos returns nan. Those cases are now caught and 0 is returned. 2014-06-17 Richard Larsson * arts-2-2-4 * src/m_zeeman.cc: Fixed bug that made zero-magnetic field runs crash when there is no line mixing. 2014-06-11 Jana Mendrok * arts-2-2-3 * controlfiles/instruments/smr/ici_fast.arts, ici.sensor_response_fast.xml, ici.f_grid_fast.xml: Added. Optimized frequency setup (derived fromsimulated annealing) for ICI. * controlfiles/instruments/smr/TestICI_fast.arts, TestICI_fast.ybatch.ref.xml: Added. ICI test case and corresponding reference output. * controlfiles/CMakeLists.txt: ICI test case added in "fast" chain. * controlfiles/instruments/smr/ici.arts: bugfix in comments. 2014-06-11 Jana Mendrok * arts-2-2-2 * src/m_cloudbox.cc, methods.cc: Added WSMs interfacing the hydrometeor size distribution parametrizations providing dN/dsize. For details see built-in doc. 2014-06-10 Jana Mendrok * arts-2-2-1 * continua.cc (MPM93IceCrystalAbs, MPM93WaterDropletAbs): Include vmr limits into if-branch of xsec calc. Fixes missing xsec calc for liquid water/ice continuum for abs_lookup, bug reported by Ian Adams. 2014-06-06 Oliver Lemke * arts-2-2-0 * 2.2 Release 2014-06-06 Oliver Lemke * arts-2-1-897 * doc/doxygen/Doxyfile.in: Remove obsolete variables. * src/continua.cc: Comment out unused constants. 2014-06-05 Oliver Lemke * arts-2-1-896 * CHANGES-2.2: Move pnd_field and scat_data calculations to Key Features. * CMakeLists.txt: Remove g95 support (not working properly). Throw error if size of long != 8 if Fortran is enabled. * README: Add note about Fortran requirements. 2014-06-05 Jana Mendrok * arts-2-1-895 * CHANGES-2.2: added zeropadding. 2014-06-05 Jana Mendrok * arts-2-1-894 * CHANGES-2.2: minor corrections/completions. 2014-06-05 Patrick Eriksson * arts-2-1-893 * CHANGES-2.2: Added some points to General, partly by moving down from Key features. 2014-06-05 Oliver Lemke * arts-2-1-892 * CHANGES-2.2: Added. 2014-06-02 Oliver Lemke * arts-2-1-891 * src/src/m_nc.h (WriteNetCDFIndexed): Call WriteNetCDF instead of calling nca_write_to_file directly. * src/src/nc_io.cc (nca_read_from_file, nca_write_to_file), src/m_abs.cc (WriteMolTau): Put critical regions around all NetCDF IO because the NetCDF C-library is not thread-safe. 2014-06-01 Patrick Eriksson * arts-2-1-890 * src/m_rte.cc (yCalcAppend): Improved consistency checks. For absorption species, it is now checked that the same unit is used (vmr, nd ...) and for temperature HSE must now either be ON or OFF for both parts. Changes after some testing by Ole Martin. 2014-05-28 Oliver Lemke * arts-2-1-889 * src/abs_species_tags.h (SpeciesTag::operator==): Also take the CIA dataset index into account for equality comparison. Fixes bug reported by Mayuri. 2014-05-27 Patrick Eriksson * arts-2-1-888 * src/ppath.cc (raytrace_2d_linear_basic): It was assumed that zenith angle after tangent/turning point is below 90. Fixed. Should now work with "super-refractivity". (ppath_step_refr_1d): New version of this function. A new approach to handle paths starting with zenith angles below 90 and moving to > 90 due to "super-refractivity" was needed. The solution was just to adopt the 2D algorithm to 1D. That is, refraction in 1D, 2D and 3D are now handled in basically the same manner. * src/m_ppath.cc (ppath_stepRefractionBasic) (VectorZtanToZaRefr1D): Adopted call of get_refr_index_1/2d. * src/ppath_NotUsed.cc: Removed old version of refr_gradients_1d as these functions now use another set of arguments. (raytrace_1d_linear_basic): Old version put here. * src/refraction.cc: z_field was a vector for 1D etc. This differed from e.g. t_field, and z_field now Tensor3 inside the file. (refr_gradients_1d): New function, a downscaled version from 2D. * src/ppath.cc: Removed everything around do_gridcell_2d (the byltest version used). The code of do_gridcell_2d is found in ppath_NotUsed.cc. 2014-05-27 Patrick Eriksson * arts-2-1-887 * src/m_refraction.cc (complex_refr_indexIceWarren84): BUG FIX! The fortran sub-routine got wrong argument. It got 1/lambda, with lambda in m. Old code: n = refice_(f_grid[f] / SPEED_OF_LIGHT, t_grid[t]); While the input shall be lambda in um. For microwaves, this bug had biggest impact below 100 GHz. No significant impact for real part between 100 and 1000 GHz. 2014-05-26 Oliver Lemke * arts-2-1-886 * src/methods.cc, src/m_nc.h (WriteNetCDFIndex): Added writing of indexed NetCDF files analogous to WriteXMLIndexed. 2014-05-23 Oliver Lemke * arts-2-1-885 * src/m_optproperties.cc (ScatteringDoitMergeParticles1D): Don't force particles to have same temperature grid. Don't calculate top-most pressure levels, it's 0 anyway in pnd_field. Bug fix: Only set lower-most pnd_field to 0 if cloudbox does not touch the surface. * src/methods.cc (ScatteringDoitMergeParticles1D): Add z_field and z_surface as inputs. 2014-05-22 Patrick Eriksson * arts-2-1-884 * src/m_rte.cc (yCalcAppend): Removed a cout statement, that was just added for test purposes. 2014-05-22 Oliver Lemke * arts-2-1-883 * src/m_cloudbox.cc, src/m_optproperties.cc (ScatteringDoitMergeParticles1D): Moved to m_optproperties.cc. Ignore particles with density <= PND_LIMIT. 2014-05-21 Oliver Lemke * arts-2-1-882 * src/methods.cc (ScatteringDoitMergeParticles1D): Put alphabetically in the correct place. 2014-05-21 Oliver Lemke * arts-2-1-881 * src/m_cloudbox.cc, src/methods.cc (ScatteringDoitMergeParticles1D): New experimental method to speed up DOIT calculations. This method pre-calculates a weighted sum of all particles per pressure level before the actual DOIT calculation is taking place in *ScatteringDoit*. It should be called directly after pnd_fieldSetup (but after cloudbox_checkedCalc). *pnd_field* is resized to [np, np, 1, 1]. Where np is the number of pressure levels inside the cloudbox. The diagonal elements of the new *pnd_field* are set to 1, all others to 0. Accordingly, *scat_data_array* is resized to np. Each particle is the weighted sum of all particles at this presssure level. This is an experimental method currently only working for very specific cases. All particles must be of the same type and all particles must share the same f_grid and za_grid. And pha_mat_data, ext_mat_data and abs_vec_data must be all the same size. This method can only be used with a 1D atmosphere. 2014-05-20 Patrick Eriksson * arts-2-1-880 * src/m_rte.cc (yCalcAppend): Completed. * controlfiles/CMakeLists.txt: Added the test below as a fast one. * controlfiles/artscomponents/ycalcappend/TestYCalcAppend.arts: New folder and file. * src/m_jacobian.cc (jacobianClose): Removed jacobian as output. It wa sjust sized and set to zero, which anyhow is (and should be) done) in yCalc. * src/workspace.cc: Removed old non-active variables. * src/m_rte.cc (iyEmissionStandard): Only first element of iy_aux was set for "Radiative background". 2014-05-19 Patrick Eriksson * arts-2-1-879 * src/m_rte.cc (yCalcAppend): Start on new WSM. So far just y itself that is handled. 2014-05-19 Stefan Buehler * arts-2-1-878 * src/m_abs.cc (abs_lines_per_speciesAddMirrorLinesOld): Removed this function, since it is obsolete. (abs_lines_per_speciesAddMirrorLines): Added const qualifier to Index n definition. * src/methods.cc (abs_lines_per_speciesAddMirrorLinesOld): Removed. 2014-05-16 Oliver Lemke * arts-2-1-877 * src/m_abs.cc (abs_xsec_per_speciesInit): Add check to ensure that the species indexes in abs_species_active are smaller than the number of species. Fixes assertion reported by Theresa. 2014-04-30 Jana Mendrok * arts-2-1-876 * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_1D_cloudy.arts: Added info on poor DOIT and MC performance. * controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: (Re)Define iy_cloudbox_agenda with explicitly setting maxratio in iyInterpCloudboxField, using same value as for ClouboxGetIncoming. 2014-04-30 Oliver Lemke * arts-2-1-875 * Reverted 2-1-874. Turns out there are a whole bunch of other problems with OS X 10.5. As it is EOL anyway, we hereby officially drop support for OS X 10.5. I reverted the previous fix because the manual allocation introduces a possible buffer overflow. 2014-04-30 Oliver Lemke * arts-2-1-874 * src/file.cc (get_absolute_path): Workaround a bug in the C-library realpath function on OS X < 10.6 that leads to a crash. Reported by Patrick. 2014-04-29 Jana Mendrok * arts-2-1-873 * src/m_ppath.cc (VectorZtanToZaRefr1D, VectorZtanToZa1D): Added runtime error catch of sensor position lower than given tangent altitude case. 2014-04-29 Jana Mendrok * arts-2-1-872 * src/ppath.cc (raytrace_1d_linear_basic): Improved checks for problematic refraction cases. Currently used: check that current predicted path point is still within grid cell. Implemented, but currently outcommented (switch on & test, please): check that path constant rule can be fulfilled over whole grid cell. * src/m_refraction.cc (refr_index_airMWgeneral): Minor doc improvement. * controlfiles/planetary_toolbox/includes/common/makegeometry3D_*.arts: Use refellipsoidForAzimuth for better fitting 1D refellipsoid to the 3D observation geometry. This (almost?) perfectly ensures correct zenith angles from tanh for ellipsoidal planet cases (before, north/south were undesireably pointing to different effective tangent altitudes than east/west for identical tanh requests - indicated by different Tb baseline). * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_3D_clearsky.arts: Cleaned up from planet rotation pseudo-wind testing stuff. Corrected info on zang-from-tanh limitations. Set an f_grid that is more illustrative of wind effects. * controlfiles/planetary_toolbox/demos/common/DemoMarsAtmo3D.arts: Switch on E-W winds again, now that planet rotation pseudo-wind issues fixed. * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_cloudy.arts: Added more clear doc on limitations of the different scattering solvers, specifically in Venus. * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_clearsky.arts: Add info on refraction issues to header. * controlfiles/planetary_toolbox/demos/passive/DemoScat_FOS_1D.arts, DemoMars_fullRT_1D_clearsky.arts: Minor fixes. 2014-04-28 Patrick Eriksson * arts-2-1-871 * src/ppath.cc (raytrace_1d_linear_basic): It is clear that some cases with very strong refraction not is handled. All should be OK for Earth, but low altitudes of e.g. Venus is not properly handled with refraction. As a temporary solution, added a check that gives a runtime error (giving a rough idea about the problem), to not end up with an asseert as before. Some tuning of the crieria for issuing the error could be needed. 2014-04-28 Oliver Lemke * arts-2-1-870 * src/methods.cc: Add wind_u_field as input to wind_u_fieldIncludePlanetRotation. It was only defined as output variable but used as input in the implementation. * src/m_atmosphere.cc (wind_u_fieldIncludePlanetRotation): Add missing initialization to 0 after resizing wind_u_field. Otherwise the += inside the loop is adding to garbage values. 2014-04-28 Oliver Lemke * arts-2-1-869 * src/interpolation.cc: Increase FD_TOL from 1e-3 to 1.5e-3 to fix assertion in gridpos_check_fd called from ppath_end_1d for Manfred's CIRC case. 2014-04-25 Jana Mendrok * arts-2-1-868 * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_1D_cloudy.arts, DemoMarsClouds1D.arts, controlfiles/planetary_toolbox/includes/mars/getclouds_mars.arts, clouds_mars.arts: Added. Martian cloud/dust case files. * controlfiles/planetary_toolbox/demos/common/DemoMarsSurface1D.arts: Use z_surface from 0th z_field level as preset setting (that's the only case when DOIT works...). * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_cloudy.arts: Improved documentation, particularly on scattering solver limitations. * controlfiles/planetary_toolbox/demos/passive/DemoScat_DOIT_1D.arts: More zenith angles in presetting. * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_clearsky.arts: Minor layout adjustment. * src/methods.cc: Spell/formulation fixes. 2014-04-25 Oliver Lemke * arts-2-1-868 * src/m_atmosphere.cc (AtmFieldsFromCompact): Fix assertion. Throw runtime error if abs_species only contains the first n species from atm_fields_compact. (n < number of species in atm_fields_compact) 2014-04-24 Jana Mendrok * arts-2-1-867 * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_cloudy.arts: Added/updated documentation. Slight adjustments to (tentatively) demonstrate malfunction of refracted path calculation. Added/updated cloud case documentation: * controlfiles/planetary_toolbox/demos/passive/DemoScat_[MC,DOIT,FOS]_1D.arts * controlfiles/planetary_toolbox/demos/common/DemoVenusClouds1D.arts * controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts * controlfiles/planetary_toolbox/includes/venus/getclouds_venus.arts * controlfiles/planetary_toolbox/demos/common/ Demo[Venus,Mars,Jupiter]Atmo[1,3]D.arts, controlfiles/planetary_toolbox/includes/common/createvars.arts: Moved more regularly used WSV creation into createvars.arts. 2014-04-11 Oliver Lemke * arts-2-1-866 * src/linerecord.{cc,h} (LineRecord::ReadFromHitran2004Stream): Add optional parameter fmin. If the line center is below fmin, skip parsing the whole line. This can speed up catalog reading significantly depending on fmin (and indirectly fmax). * src/m_abs.cc (abs_linesReadFromHitran): Pass fmin to LineRecord::ReadFromHitran2004Stream. 2014-04-09 Oliver Lemke * arts-2-1-865 !!! IMPORTANT !!! From this version on, ARTS will only work with the HITRAN 2012 catalog by default. 'cmake -DWITH_HITRAN2008=1 ..' can be used to switch to HITRAN 2008. * src/m_abs.cc (abs_linesReadFromHitran): Add runtime error if catalog filename doesn't match the version arts was compiled for. * CMakeLists.txt, README: Add cmake option WITH_HITRAN2008. Update docs. * config.h.cmake, src/species_data.cc (define_basic_species_data): Use preprocessor variable USE_HITRAN2008 to switch between Hitran versions. 2014-04-08 Jana Mendrok * arts-2-1-864 * src/species_data.cc: Fixed typo in HNO3 isoratio (thanks oliver!). * controlfiles/artscomponents/cia/TestRTwithCIA.iy_reference.xml: Updated. Values slightly changed (sub-mK) due to slight changes in isoratios of H2O in arts-2-1-862. 2014-04-08 Patrick Eriksson * arts-2-1-863 * controlfiles/planetary_toolbox/demos/active/demo_earth_ionosphere.m: Correction of header text. 2014-04-07 Jana Mendrok * arts-2-1-862 * src/species_data.cc: Added CO2-727. Appeared newly in HITRAN2012. NOTE: with this, tag assignments for CO2-838 changed in HITRAN. This version of species_data.cc still made with 2008-and-older assignments (change to 2012 prepared: switch manually by out- & uncommenting the respective 2 lines in here - auto-switch seems not feasible, though.). Furthermore, updated all HITRAN iso-abundances to molparam.txt values from most recent version (2013!). * src/partition_function_data.cc: Added CO2-727. NOTE: CO2-727 needs also to be added to planet isoratio data files. So, also update your arts-xml-data! * controlfiles/artscomponents/absorption/IsoRatios_H2Oorig.xml: Adapted to be consistent with slight changes in species_data.cc. * src/methods.cc (iy_Calc), 3rdparty/partFct/partition_functions.py: Spellfixes. 2014-04-07 Oliver Lemke * arts-2-1-861 * src/m_abs.cc (abs_linesReadFromHitran): Output the line number in error message for easier debugging. * src/agenda_class.h (Agenda::push_back): Pass MRecord as const reference. 2014-04-03 Jana Mendrok * arts-2-1-860 * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_cloudy.arts: Added. Demo cloud case for Venus. MISSING proper DOC. * controlfiles/planetary_toolbox/demos/common/DemoVenusClouds1D.arts: Added. Demos/templates for getting venus cloud data. MISSING proper DOC. * controlfiles/planetary_toolbox/includes/common/makeclouds1D.arts: Added. Include file to prepare cloud data (get scat data into scat_data_array and pnd fields into pnd_field_raw, determine cloudbox, derive pnd_field from raw data). MISSING DOC. * controlfiles/planetary_toolbox/includes/venus/controlfiles/ getclouds_venus.arts, clouds_venus.arts: Added. Includes with Venus cloud data definitions and to pre-prepare Venus cloud single scattering and pnd data of selected setup for digestion into ARTS. MISSING DOC. * controlfiles/planetary_toolbox/demos/passive/ DemoScat_[MC,DOIT,FOS]_1D.arts: Added. Demos/templates for scattering solver setups for cloudy cases. * controlfiles/planetary_toolbox/includes/common/createvars.arts: Predefined some more helper WSVs with view on clouds. * controlfiles/planetary_toolbox/demos/common/DemoVenusSurface1D.arts: Default setting for t_surface in order to make MC setups (3D!) automatically work for all surface settings. Minor doc fix. * controlfiles/planetary_toolbox/includes/[venus,mars,jupiter]/ atmo_[venus,mars,jupiter].arts: Moved creating of WSV atmobase into createvars.arts (might BREAK Atmlab compatibility). * controlfiles/planetary_toolbox/includes/venus/getatmo_venus.arts, controlfiles/planetary_toolbox/demos/common/DemoVenusAtmo1D.arts, controlfiles/general/agendas_surface.arts: Minor doc fix. * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_3D_clearsky.arts: Re-include possible use of make-and-use-absLUT.arts. With the fixes from previous commits, this now also works for 3D. Added some doc on the possible use of either make-and-use-absLUT.arts or make-and-use-absLUT_1Dfor3D.arts. * controlfiles/general/agendas.arts: Added note on setting of iy_cloudbox_agenda. * controlfiles/general/agendasDOIT.arts: Updated to use passing of named parameters into WSMs. * src/m_append.h (Append): Added capability to append a Numeric to a Vector. * src/methods.cc (Apppend): Adapted to above and slight polishing of doc info. 2014-03-24 Jana Mendrok * arts-2-1-859 * src/m_abs_lookup.cc (find_nonlinear_continua): Bugfix. 2014-03-24 Jana Mendrok * arts-2-1-858 * src/m_abs_lookup.cc (find_nonlinear_continua): H2-, He-, CH4-CIA added as h2o_abs independent (i.e., not a non-linear species). 2014-03-24 Oliver Lemke * arts-2-1-857 * src/m_abs_lookup.cc (find_nonlinear_continua): Check for continuum tags by using SpeciesTag::TYPE_PREDEF and SpeciesTag::TYPE_CIA. Fixes crash reported by Jana. 2014-03-23 Jana Mendrok * arts-2-1-856 * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_3D_clearsky.arts: Added. A demo case for 3D, here made for making full use of martian winds. Also applies planet rotation. Disclaimer: (a) seems to be not fully functional when using global fields (some odd things seem going on with wind_u_fieldIncludePlanetRotation - asked Oliver to have a look on that) and (b) abs_lookup uses a 1D workaround as abs_lookup doesn't currently work properly for 3D (but that's ok for the toolbox case(s) as the atm data anyway is homogeneous; asked Oliver & Stefan to have a look) on the issue. * controlfiles/planetary_toolbox/includes/common/ make-and-use-absLUT_1Dfor3D.arts: Added. abs_lookup workaround for 3D cases based on 1D raw atmospheric fields (when trying to use 3d raw fields, AtmFieldsCalc will complain, i.e., should be save to use without side effects). * controlfiles/planetary_toolbox/includes/common/ makegeometry3D_refracted-air+electrons_geometrictanh.arts, makegeometry3D_refracted-air+electrons_truetanh.arts, makegeometry3D_refracted-air_geometrictanh.arts, makegeometry3D_refracted-air_truetanh.arts, makegeometry3D_unrefracted.arts: Added. Geometry-includes for 3D. * controlfiles/planetary_toolbox/demos/common/DemoMarsSurface3D.arts: Added. Demo/template for setting surface properties for 3D case. * controlfiles/planetary_toolbox/includes/common/getgrids_3Dsimple.arts: Discarded hard-coding of lat/lon_grid setup (2pts in each horizontal dimension (caused significant deltaTb when using with (inhomogeneous!) t_surface from file) and introduced number of grid points in lat/lon as user parameter. Using number of gridpoint instead of grid spacing ensures that end points are included in either case. Updated documentation accordingly & fixed some doc mistakes. * controlfiles/planetary_toolbox/demos/common/DemoMarsAtmo3D.arts: Introduced number of grid points in lat/lon as user parameter (see getgrids_3Dsimple.arts). Switched on winds in repository version. Moved abs_f_interp_order setting to any-wind section and removed "only MODIFY if you know, what you are doing" warning as you HAVE to reset it if winds shall be used. Fixed some spelling and layout issues. * controlfiles/planetary_toolbox/demos/common/DemoMarsAtmo1D.arts, DemoJupiterAtmo3D.arts: Removed "only MODIFY if you know, what you are doing" warning from winds section as one HAVE to reset abs_f_interp_order if winds shall be used. * controlfiles/planetary_toolbox/includes/common/use-absOnTheFly.arts: Removed (re)setting of and references to abs_f_interp_order. That's better done in the Demo*Atmo*.arts as there one knows, whether one wants winds (and needs to reset abs_f_interp_order), less prone to side effects. * controlfiles/planetary_toolbox/demos/common/DemoMars_fullRT_1D_clearsky.arts, DemoMarsSurface1D.arts, controlfiles/planetary_toolbox/includes/common/ make-and-use-absLUT.arts, makegeometry1D_unrefracted.arts, makegeometry1D_refracted-air_geometrictanh.arts, makegeometry1D_refracted-air+electrons_geometrictanh.arts, makegeometry1D_refracted-air_truetanh.arts, makegeometry1D_refracted-air+electrons_truetanh.arts: Doc/layout fixes. 2014-03-22 Oliver Lemke * arts-2-1-855 * cmake/modules/ArtsTestcases.cmake, controlfiles/CMakeLists.txt: Change naming scheme of testcases. Generate the name automatically from the controlfile path (just replacing the directory separator / with .): Old: arts.ctlfile.fast.pencilbeam New: arts.ctlfile.fast.artscomponents.pencilbeam.TestPencilBeam This change makes it much easier to identify the controlfile that belongs to each testcase. Omits the need to run 'ctest -V -N -R arts.ctlfile.fast.pencilbeam' to find out. Requested by Jana. Note that because the testnames are now longer than before, a terminal window wider than 120 chars is required for clean output. 2014-03-20 Oliver Lemke * arts-2-1-854 * src/file.{cc,h} (find_file, find_xml_file): In some cases the same file could be found through different paths (absolute/relative/~). This led to a warning being issued even though the two paths pointed to the same file. All filenames are now converted to absolute paths to avoid this. Bug reported by Richard. Sometimes the search order was wrong for filenames that needed an extension to be appended to be found. find_xml_file would return a match from a directory that is placed later in the search path than the directory which contains the correct match. Reverted change from 2-1-850: Ignoring the search path for filenames starting with './' breaks things when running arts from a different path than where the controlfile is located. Although using ./ to force the file being read from the current directory would be 'more correct' than what we do now, the problem is that '.' currently means 'the directory where arts is called'. It would work correctly if '.' could be expanded to 'the directory where the controlfile / include file is located that contains the ReadXML statement for this file'. The cost of implementing this logic in the parser doesn't justify the relatively low benefits. 2014-03-19 Richard Larsson * arts-2-1-853 * controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman_50_to_70_G: Updated the slow test so that it no longer fails after arts-xml-data update. 2014-03-19 Oliver Lemke * arts-2-1-852 * src/linerecord.cc (LineRecord::ReadFromArtscat4Stream): Fix typo in vstr comparison. 2014-03-19 Oliver Lemke * arts-2-1-851 * src/linerecord.cc (LineRecord::ReadFromArtscat4Stream): 0 values for quantum numbers were falsely ignored. 2014-03-19 Oliver Lemke * arts-2-1-850 * src/file.{cc,h}: (find_file): Improved implementation. Remove unnecessary extension argument. Return list of all matching files found in the search path. Don't search all paths if filename starts with ./ (find_xml_file): List all matching files found in warning message. (open_input_file): Adapt call to find_file. * src/m_abs.cc (abs_speciesDefineAllInScenario): Use new find_xml_file function. * src/parser.cc (ArtsParser::parse_agenda): Adapt call to find_file. * src/m_optproperties.cc (scat_data_arrayCheck): Indent output messages. 2014-03-19 Jana Mendrok * arts-2-1-849 * controlfiles/planetary_toolbox/demos/passive/ DemoJupiter_fullRT_1D_clearsky.arts: Added. Complete version for Jupiter 1D clearsky RT. * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_clearsky.arts, DemoMars_fullRT_1D_clearsky.arts: Corrected note on negative/false tangent altitudes (for both true and geometric tanh they can be negative. for tru tanh, they are not allowed to be below the actual surface, though.). 2014-03-19 Jana Mendrok * arts-2-1-848 * controlfiles/planetary_toolbox/demos/passive/ DemoVenus_fullRT_1D_clearsky.arts: Added. Complete version for Venus 1D clearsky RT. * controlfiles/planetary_toolbox/demos/common/DemoVenusSurface1D.arts: Added. Demo/template for setting/deriving surface properties (altitude, temperature, reflection type) for Venus. * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_1D_clearsky.arts: Improved documentation following Patrick's comments. * controlfiles/planetary_toolbox/includes/common/ makegeometry1D_refracted-[air,air+electrons]_effectivetanh.arts -> makegeometry1D_refracted-[air,air+electrons]_truetanh.arts: Renamed effective tanh to true tanh. * controlfiles/planetary_toolbox/includes/common/make-and-use-absLUT.arts, controlfiles/artscomponents/arts-xml-data/TestSpectro_core.arts: Updated to new atmfields_checked requirements of abs_lookupSetup. 2014-03-18 Patrick Eriksson * arts-2-1-847 * src/m_refraction.cc (refr_index_airThayer): The coefficients in the expression applied are now GIN variables, and nominal values can now be modified. 2014-03-18 Oliver Lemke * arts-2-1-846 * src/file.{cc,h} (find_xml_file): Output full name of the selected and ignored file for better diagnostics. 2014-03-17 Oliver Lemke * arts-2-1-845 * src/file.{cc,h} (find_xml_file): Added. This method also outputs a warning to out1 if a .xml and .xml.gz version of the input file exists. (Suggested by Richard) * src/xml_io.cc (xml_read_from_file, xml_read_arts_catalogue_from_file): Use new find_xml_file function to avoid code duplication. * src/m_abs.cc (abs_cont_descriptionInit): Prepend abs_cont_ to variable names to avoid name clash with global parameters variable (clang 5.1). * src/methods.cc: Add info about extensions automatically being added to filenames by ReadXML. (Suggested by Manfred) 2014-03-17 Oliver Lemke * arts-2-1-844 * src/agenda_class.cc (Agenda::execute): Add a note to the bad_alloc exception message that reducing the number of threads might solve out of memory issues for large jobs. Suggested by Jana. 2014-03-13 Richard Larsson * arts-2-1-843 * src/m_lineshapes.cc: Fixed unsaved spelling mistake... 2014-03-13 Richard Larsson * arts-2-1-842 * src/m_lineshapes.cc: Added "Hui_etal_1978", implementation by Rosenkranz. This is based on a classic paper from 1978 referenced in the function's meta data. This function is most likely faster than the Faddeeva algorithm but might or might not fall apart for some input. This is not thouroughly tested by me. The function was added to minimize differences between RTTOV and ARTS. * src/controlfiles/artscomponents/zeeman/TestZeeman.arts, controlfiles/artscomponents/linemixing/TestLineMixingAndZeeman.arts: Modified to also use the "Hui_etal_1978" line shape. (Note that I did not have to change the reference file!). 2014-03-11 Jana Mendrok * arts-2-1-841 * src/m_checked.cc (atmfields_checkedCalc): Be a bit more helpful in abs_f_interp_order-in-case-of-wind error message (you have to set it >0 even if absLUT are not used). * controlfiles/general/general.arts: Downgrade the do-only-modify-when-you-know message on abs_f_interp_order as user HAS to change it if wind is to be used. 2014-03-10 Richard Larsson * arts-2-1-840 * src/m_zeeman.cc: BUG. There was a difference between theory in the Zeeman paper and code in ARTS. They way it was coded, horizontal and vertical polarization got shift around. I found this while restructuring the code to make it easier to compare with theory. 2014-03-07 Jana Mendrok * arts-2-1-839 * src/m_abs_lookup.cc (abs_lookupSetup): Pass atmfields_checked as input. To avoid abs_lookupSetup acting on (obviously) buggy data like negative temperatures. Remove a bunch of checks that are obsolte now as they are checked by atmfields_checkedCalc. (choose_abs_nls_pert): Avoid letting maxdev become infinity (as we can not divide a range [x,inf] into any number of steps and will forever stay in the make-steps while loop). And if it (still) is, throw a runtime error. * src/m_basic_types.cc (NumericInvScale): Added. A method to perform a divide. This as plenty of divide operations can only be represented by multiplication in an ugly way. * src/methods.cc: Adapt to the above changes. * src/species_data.cc: Corrected H2S HITRAN tag assignment. It's basically a HITRAN bug: For H2S HITRAN does not follow its own convention that tags are sorted in terms of isotopologue abundance. However, it's a very old bug, hence probability that HITRAN will fix it is low. So, we have to do something to make ARTS work properly with buggy HITRAN. If not fixed (i.e., for all previous ARTS versions!), HITRAN-to-ARTSCAT conversion of H2S minor isotopologues is WRONG! * src/absorption.h (SpeciesRecord): Removed check for increasingly sorted HITRAN tags. This to allow the above change to work. * controlfiles/artscomponents/cia/TestRTwithCIA.iy_reference.xml: Updated with values matching modified O2 & H2O data in Perrin line data. * controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts: Do atmfields_checkedCalc before abs_lookupSetup. * controlfiles/artscomponents/arts-xml-data/spectrotest.py: (get_data): Consider that each abs_species entry is an array of tags and allow for multi-tag entries. (first_substring): Catch case when substring is not found. * doc/uguide/absorption.tex: In CIA part, added note on CO2-CO2 alternative. 2014-03-06 Patrick Eriksson * arts-2-1-838 * Things fixed, inspired by question from Jana: * src/m_sensor.cc (AntennaConstantGaussian1D): The algorithm for setting up mblock_za_grid was not perfect. I had selected "cumsum", while "cumtrapz" is a better option to avoid what could be seen as an edge effect. Also added a runtime check. * src/m_sensor.cc (antenna_responseGaussian): Added a runtime check. * src/methods.cc: Editing to reflect change below, for affected methods. * src/sensor.cc (gaussian_response_autogrid): The creation of the grid slightly changed, from using linspace to nlinspace. To ensure perfect fit with defined end points. Now the spacing adjusted accordingly, downwards. So grid spacing now becomes slightly smaller. 2014-03-05 Richard Larsson * arts-2-1-837 * controlfiles/CMakeLists.txt: Added one slow line mixing test. * controlfiles/artscomponents/linemixing/*: There is one more test here that shows how to set this up for the entire band. I might add a test later to show how to do Zeeman for one line but Line Mixing for the entire band. The other files are updated because I had forgotten that artscat4 requires all species to be defined. This error was pointed out to me by Jana. * controlfiles/artscomponents/zeeman/*: The files are updated because I had forgotten that artscat4 require all species to be defined. This error was pointed out to me by Jana. 2014-03-05 Oliver Lemke * arts-2-1-836 * src/linerecord.cc (LineRecord::ReadFromArtscat4Stream): Parse additional quantum numbers v1, v2, v3 and f. Check that species is O2 because the format for other species is different. 2014-03-03 Patrick Eriksson * arts-2-1-835 * src/m_sensor.cc (antenna_responseGaussian) (backend_channel_responseGaussian): Just changed to use gaussian_response_autogrid. (antenna_responseVaryingGaussian): New WSM. * src/sensor.cc (gaussian_response): Now this function just calculates the gaussian response. That is, a more proper "core" function. (gaussian_response_autogrid): The old function renamed.This one also creates a grid. 2014-02-28 Richard Larsson * arts-2-1-834 * controlfiles/CMakeLists.txt: Added two line mixing tests. * controlfiles/artscomponents/linemixing/*: These are the tests. There is still no reading routine to get vibrational numbers out of Agnes catalog, so these tests are only preliminary and will have to be extended at a later date when this reading routine is in place. The problem with not reading the vibrational state is that we do not know inside ARTS which line is supposed to be line matched --- no two lines are allowed to be matched with the same input. * controlfiles/artscomponents/zeeman/*: More strongly linked this test to arts-xml-data, removing the magnetic field files that this folde used to contain. 2014-02-27 Richard Larsson * arts-2-1-833 * controlfiles/CMakeLists.txt: Activated a Zeeman test if arts-xml-file is in path. * controlfiles/artscomponents/zeeman/*: Adapted the Zeeman test. Note that there are differences between the previous HITRAN using test and this test that uses Agnes catalog. These differences were at 45 K. * src/m_zeeman.cc: Added a simple check to allow the user to set the magnetic field strength manually. Useful for model comparisons. 2014-02-27 Oliver Lemke * arts-2-1-833 * src/linerecord.cc (LineRecord::ReadFromArtscat4Stream): Fix parsing of QuantumNumbers N + J. * controlfiles/artscomponents/zeeman/TestZeeman.arts: Read from Agnes Catalog. 2014-02-25 Richard Larsson * arts-2-1-832 * src/make_auto_md_cc.cc: Added the function below. * src/methods.cc: Added the function below * src/m_reduce.h: Function to reduce higher order tensors to lower order tensors. Can, e.g., convert a 1x4 matrix to Vector type. This is a simple function that is complementary to the Extract function. 2014-02-25 Oliver Lemke * arts-2-1-831 * src/matpack{VI,VII}.cc: Hot fix for hudson build error. 2014-02-25 Oliver Lemke * arts-2-1-830 * src/matpack{III,V}.cc: Missed these in previous commit. 2014-02-25 Oliver Lemke * arts-2-1-829 * src/matpackVI.{h,cc}, src/matpackVII.{h,cc}: Add get_c_array. * src/matpack*.cc: Make error message for get_c_array less convoluted. 2014-02-25 Patrick Eriksson * arts-2-1-828 * src/sensor.cc (sensor_integration_vector): Changed expressions for x2 and x3, to avoid numerical problems for e.g. (f+df)^3-f^3. A slight rewrite of c0 and c1, common term now outside ( ). Added an error message, if f >=0 and and any h <= -small_value. 2014-02-23 Patrick Eriksson * arts-2-1-827 * src/m_general.cc (Test): Now including a test of sensor_integration_vector and sensor_integration_vector2. It confirms that sensor_integration_vector gives exact result when the two functions are piece-wise linear. * src/sensor.cc (sensor_integration_vector): Header text improved. Some cleaning/changes of the code. The only real change is that the grid normalisation is changed. The normalisation now maps x_f to [0,1] (before x_g). In addition, the final result did not consider this normalisation. This was a bug, but still all OK with sensor_norm set to 1. A note: Tried to deactivate normalisation and the Odin-SMR test then raised an error. Seems that Tb changed with 7 K. So the code appears to be sensitive for numerical issues ... (sensor_integration_vector2): A version of the function above, but strictly following the sensor repsonse article. * src/sensor.cc: Removed some old inactive code related to Stokes rotation. 2014-02-21 Patrick Eriksson * arts-2-1-826 * controlfiles/CMakeLists.txt: Added running file below, as part of fast. * controlfiles/artscomponents/stokesrot/TestStokesRotation.arts: A file demonstrating and testing Stokes rotation, as well as shows how to simply set up an atmosphere lacking attenuation. * src/m_abs.cc (propmat_clearskyZero): New WSM. Use with care! * src/rte.cc (get_ppath_abs): Now handles the case of no abs_species. * src/m_checked.cc: A small fix to avoid crash if abs_species is empty. Then no need to search for negative VMRs. 2014-02-21 Patrick Eriksson * arts-2-1-825 * src/m_sensor.cc: Removed some inactive code at end of file. This including an old version of new method below. (sensor_responseStokesRotation): New WSM . * src/workspace.cc: Added stokes_rotation. 2014-02-19 Richard Larsson * arts-2-1-824 * AUTHORS: Added myself to "important component" contributor list. Remove or move as you see fit. * doc/uguide/absorption_theory.tex: Changed the Zeeman part of the theory to only reference the Zeeman module paper. The old text was written before there was support for DJ=0 species, and before we had taken into account magneto optics. * doc/uguide/references.bib: Added the Zeeman paper. If there is another way to reference 'internal' papers, please let me know. 2014-02-18 Oliver Lemke * arts-2-1-823 * src/CMakeLists.txt: Fix link libraries for test_omp. (Bug reported by Patrick) 2014-02-06 Jana Mendrok * arts-2-1-822 * controlfiles/planetary_toolbox/demos/passive/ DemoMars_fullRT_1D_clearsky.arts: Added. Complete version for 1D clearsky RT. * controlfiles/planetary_toolbox/demos/common/: Added. Folder for active/passive shared templates (user is supposed to modify these files). * controlfiles/planetary_toolbox/demos/common/DemoVenusAtmo1D.arts, DemoJupiterAtmo1D.arts, DemoMarsAtmo1D.arts, DemoVenusAtmo3D.arts, DemoJupiterAtmo3D.arts, DemoMarsAtmo3D.arts: Moved here from controlfiles/planetary_toolbox/. * controlfiles/planetary_toolbox/demos/common/DemoMarsSurface1D.arts: Added. Demo/template for setting/deriving surface properties (altitude, temperature, reflection type). * controlfiles/planetary_toolbox/includes/common/use-absOnTheFly.arts: Do abs_xsec_agenda_checkedCalc in there. * controlfiles/general/agendas_surface.arts controlfiles/planetary_toolbox/includes/common/ makegeometry1D_unrefracted.arts: Minor fixes. * controlfiles/planetary_toolbox/demos/passive/fullRT_Mars.arts, My-Version-Of-DemoMarsAtmo1D.arts: Deleted work-in-progress version. 2014-02-03 Jana Mendrok * arts-2-1-821 * controlfiles/planetary_toolbox/demos/passive/fullRT_Mars.arts: Continued to work on. Included: - selectable level of refraction (via INCLUDEs) - selectable way of absorption calc (via INCLUDEs) - applicable also with wind and stokes_dim>1 (tested) * controlfiles/planetary_toolbox/includes/common/ makegeometry1D_unrefracted.arts, makegeometry1D_refracted-air_effectivetanh.arts, makegeometry1D_refracted-air+electrons_effectivetanh.arts, makegeometry1D_refracted-air_geometrictanh.arts, makegeometry1D_refracted-air+electrons_geometrictanh.arts: Added. Bunch of plug&play type INCLUDEs to prepare viewing geometry setup (allowing to specify and handle both viewing angles AND tangent altitudes within one run) and handle different ways of refraction. * controlfiles/planetary_toolbox/includes/common/use-absOnTheFly.arts, make-and-use-absLUT.arts: Added. plug&play type INCLUDEs to handle different ways of absorption calculations (LUT, OtF). * controlfiles/planetary_toolbox/DemoMarsAtmo1D.arts, controlfiles/planetary_toolbox/demos/passive/My-Version-Of-DemoMarsAtmo1D.arts: Unbreak wind settings (getwinds_mars.arts didn't like NSwind and EWwind to be conmpletely ignored). * controlfiles/planetary_toolbox/DemoMarsAtmo1D.arts, DemoVenusAtmo3D.arts, DemoJupiterAtmo3D.arts, DemoMarsAtmo3D.arts, controlfiles/planetary_toolbox/demos/passive/My-Version-Of-DemoMarsAtmo1D.arts: For winds to work, included (outcommented, to be conciously uncommented by user) "IndexSet( abs_f_interp_order, 1 )". * controlfiles/artscomponents/arts-xml-data/TestSpectro_core.arts Updated to unbreak (for changes related to CIA inclusion). * controlfiles/artscomponents/arts-xml-data/spectrotest.py: Improved plotting and stats report for spectroscopy tests. * src/species_data.cc, workspace.cc, m_abs.cc, doc/uguide/absorption.tex, controlfiles/general/general.arts, controlfiles/artscomponents/cia/TestRTwithCIA.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_[Venus,Mars].arts, controlfiles/planetary_toolbox/DemoJupiterAtmo1D.arts: Minor spelling and layout fixes. 2014-01-20 Stefan Buehler * arts-2-1-820 * src/gas_abs_lookup.cc (Adapt): Added runtime error if a species is missing in the lookup table, but requested in the calculation. (On request by Jana Mendrok.) 2014-01-15 Patrick Eriksson * arts-2-1-819 * src/ppath.cc: Removed some lines now obselete after changes in the do_gridcell_Xd_byltest functions. Found by Oliver, using Xcode code analyser. 2014-01-14 Oliver Lemke * arts-2-1-818 * src/m_rte.cc (yCalc), src/rte.cc (iyb_calc): Extract parallel loop bodies into separate functions. Works around the OpenMP performance issue mentioned in previous commit when neither the mblock nor za loop actually run vectorized. Speed ups vary. E.g. TestWfuns runs 25% faster on our 32 core server when number of cores > nza. Print diagnostic info about parallelization and iteration count to out3. (iyb_calc): Further tweak parallel loop condition for za loop. Only delay parallelization if nf >= 10*nza. * src/m_ppath.cc (ppathFromRtePos2): Remove duplicate code. los and dza where calculated twice for atmosphere_dim <= 2 (inside and after the if statement). * src/debug.h (DEBUG_VAR, DEBUG_VAR_FLT): Added more debug macros. * src/m_disort.cc (ScatteringDisort): Use DEBUG_VAR instead of DEBUG_PRINT. * src/xml_io.cc (ArtsXMLTag::read_from_stream): Initialize ch. 2014-01-13 Patrick Eriksson * arts-2-1-817 * src/m_checked.cc (sensor_checkedCalc): Added special check that sensor_response_aa is empty if antenna_dim = 1. Not catched before. 2013-12-12 Oliver Lemke * arts-2-1-816 * OpenMP performance improvements. * rte.cc (get_ppath_trans): Remove parallelization. Performance breaks down if threads > 4. This behavior is consistent with different compiler versions on different operating systems and machines. It can lead to deadlocking. OdinSMR test case with 32 threads sometimes never finishes. For explanation see below. * src/test_omp.cc, src/CMakeLists.txt: Add testcase to illustrate performance impact of 'nested' OpenMP loops. Case 1): Runtime without #pragma omp in outer loop. Case 2): Runtime with #pragma omp if (0) in outer loop, still only the inner loop will run in parallel exactly as before. (1) Laptop 8 threads: 6.3s (2) Laptop 8 threads: 22.1s (1) Server 8 threads: 3.2s (CPU Load 700-800%) (2) Server 8 threads: 36.3s (CPU Load only 300%) This is a quirk with OpenMP. When the program starts, OpenMP creates X threads (X=8 in the test above). In case (1), these threads will be used for parallelizing the inner loop. However, in case (2), even though the outer loop runs sequentially due to the if (0) condition, OpenMP cannot use the already existing 8 threads for the inner loop. Every time it enters the inner loop, it has to create 8 new threads. As creating threads is very expensive, this leads to the seen drop in performance. 2013-12-29 Patrick Eriksson * arts-2-1-815 * src/sensor.cc (antenna1d_matrix): Wrong size variable used for interpolation of aresponse_za_grid: n_za replaced by n_ar_za * src/m_sensor.cc (sensor_responseAntenna): Added call of antenna_response.checksize_strict(). This check was missing. 2013-12-15 Patrick Eriksson * arts-2-1-814 * src/ppath.cc (raytrace_2d_linear_basic): Had missed to set l_start to lraytrace when calling do_gridcell_2d_byltest, as done for the corresponding 3d function in arts-2-1-402. 2013-12-12 Gerrit Holl * arts-2-1-813 * controlfiles/general/agendas.arts: Fix small typo in comment * controlfiles/instruments/smr/ici.arts: Set instrument geometry 2013-12-12 Oliver Lemke * arts-2-1-812 * CMakeLists.txt: Bump cmake requirement to 2.8.0. 2013-12-11 Gerrit Holl * arts-2-1-811 * src/agendas.cc: Point to include file 'agendas.arts' that should be useful for most users. * src/methods.cc: Fix typo. * controlfiles/instruments/smr/ici.arts, controlfiles/instruments/amsu/mwi.arts, controlfiles/instruments/amsu/mws.arts: Added reference setups for ICI, MWI, MWS (all include 183-GHz channels). MWI and MWS need some tuning before use, in particular regarding the frequency grid spacing for the lower frequencies, where I don't know good values. * doc/uguide/formalism.tex: Fix typo. * doc/uguide/concept.tex: Tell user that general.arts can be nice to look at. 2013-11-21 Jana Mendrok * arts-2-1-810 * controlfiles/planetary_toolbox/demos/passive/fullRT_Mars.arts, My-Version-Of-DemoMarsAtmo1D.arts: Added. A first simple demo for full passive planetary RT calc. * controlfiles/planetary_toolbox/DemoMarsAtmo1D.arts, controlfiles/planetary_toolbox/demos/passive/demo_planets_limbcomp.m: Minor layout and spell fixes. * src/m_batch.cc, methods.cc (MatrixExtractFromTensor3): Introduced this WSM for matrix from tensor3 extraction, i.e. for getting a slice in whatever dimension out of a tensor3. Equivalent to VectorExtractFromMatrix. (Would be nicer, though, if we had a common method for extracting TensorN-1 out of TensorN...). 2013-11-04 Patrick Eriksson * arts-2-1-809 * src/optproperties.cc (ParticleTypeFromString): The option macroscopically_isotropic was not included in error message. * src/m_tmatrix.cc (scat_meta_arrayAddTmatrixOldVersion): As a temporary solution, extracted the version from arts-2-1-754 and gave it this name. 2013-10-31 Richard Larsson * arts-2-1-808 * doc/uguide/absorption.tex: Added a warning about using HITRAN04 and HITRAN08 in conjunction with line mixing. There appears to be some quantum coding error in the older versions of HITRAN that causes the line mixing data to be matched with the wrong lines. Recommended solution is to use HITRAN2012. I am presently uncertain how/where to warn the user in ARTS about this issue. 2013-10-29 Patrick Eriksson * arts-2-1-807 * controlfiles/artscomponents/faraday/test_faraday.m: * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Files now changed to allow that complete test is run from matlab with one call, before some manual editing of the arts cfile was needed. 2013-10-28 Patrick Eriksson * arts-2-1-806 * controlfiles/planetary_toolbox/demos/passive/demo_planets_limbcomp.m: * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_earth_ionosphere.m: * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Added optional argument workfolder to all these functions, to make it possible to extract control and data files from the run. 2013-10-27 Patrick Eriksson * arts-2-1-805 * Made some changes that hopfully shall decrease the risk to mix up rtp_pos and rte_pos when used for interpolation. This commit brakes backwards-compatibility: InterpSurfaceFieldToRtePos changed to InterpSurfaceFieldToPosition InterpAtmFieldToRtePos changed to InterpAtmFieldToPosition. For both these methods, the GIN pos is removed. The standard choice to use as position is rtp_pos. This is now default. Please check that rte_pos is not used here in your cfiles (that was the case earlier). * controlfiles/instruments/mhs/mhs.arts: * controlfiles/instruments/amsu/amsub_fast.arts: * controlfiles/instruments/amsu/amsub.arts: * controlfiles/instruments/amsu/amsua.arts: * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/artscomponents/clearsky/TestClearSky2.arts: * controlfiles/artscomponents/clearsky/TestClearSky.arts: * controlfiles/artscomponents/cia/TestRTwithCIA.arts: * controlfiles/artscomponents/doit/TestDOIT.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: * controlfiles/artscomponents/absorption/TestIsoRatios.arts: Adopted to changes below. Switched to use pre-defined agendas in most cases. For the AMSU and MHS files, rte_pos was incorrectly used instead of rtp_pos! This had no effect as 1D, but would otherwise give incorrect results. * controlfiles/general/agendas_surface.arts: Updated to match changes below. * src/m_surface.cc (InterpSurfaceFieldToPosition): Renamed from InterpSurfaceFieldToRtePos, and changed pos (GIN) to rtp_pos (IN). Also added z_surface as input to allow that rtp_pos is roughly consistent with the surface altitudes. * src/m_atmosphere.cc (InterpAtmFieldToPosition): Renamed from InterpAtmFieldToRtePos, and changed pos (GIN) to rtp_pos (IN). * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: [R,T,O,A] was added just in header. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Fixed bad comment. 2013-10-22 Patrick Eriksson * arts-2-1-804 * controlfiles/planetary_toolbox/demos/passive/demo_planets_limbcomp.m: Adopted to changes below. For abs_xsec_per_speciesAddCIA, using T_extrapolfac=3. More warnings in header text. * controlfiles/planetary_toolbox/includes/jupiter/atmo_jupiter.arts: * controlfiles/planetary_toolbox/DemoJupiterAtmo3D.arts: * controlfiles/planetary_toolbox/DemoJupiterAtmo1D.arts: Added H2-CIA-H2-0, H2-CIA-He-0, H2-CIA-CH4-0, CH4-CIA-CH4-0 * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Adopted to change below. * controlfiles/planetary_toolbox/DemoMarsAtmo3D.arts: * controlfiles/planetary_toolbox/DemoMarsAtmo1D.arts: * controlfiles/planetary_toolbox/includes/mars/atmo_mars.arts: Added CIA and PWR CO2-CO2, and modified accordingly. 2013-10-22 Patrick Eriksson * arts-2-1-803 * controlfiles/planetary_toolbox/demos/passive/demo_planets_limbcomp.m: New. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m. Fixed a typo. 2013-10-22 Patrick Eriksson * arts-2-1-802 * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_earth_ionosphere.m: * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Added [R,T,O,A] as output for all four functions. 2013-10-18 Patrick Eriksson * arts-2-1-801 * src/m_cloudradar.cc (iyCloudRadar): Added Transmission as aux variable. 2013-10-18 Oliver Lemke * arts-2-1-800 * src/abs_species_tags.h: == operator should return false for a CIA species where the second species doesn't match. 2013-10-18 Patrick Eriksson * arts-2-1-799 * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: Fixed a high number of spelling mistakes in the header text. 2013-10-18 Stefan Buehler * arts-2-1-798 * src/lineshapes.cc (lineshape_norm_VVH): Fixed bug reported by Patrick. (Take absolute value of line center frequency, so that the factor works also for mirror lines at negative center frequency.) At least I think this fixes the bug, but I have no good testcase. Patrick, please test. :-) (lineshape_norm_linear): Same fix also here, although this function is deprecated anyway and no longer user visible. 2013-10-17 Patrick Eriksson * arts-2-1-797 * Defined 100 MHz as the lower frequency limit if there is any refraction due to free electrons! * src/m_refraction.cc (refr_index_airFreeElectrons): Changed check with respect to plasma grequency to use f_grid[0]. Also added a general demand that f_grid[0] is >= 100 MHz, to have a safe margin to birefringence (following article by Hartmann and Leitinger). * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Adjusted axis for one plot. 2013-10-17 Patrick Eriksson * arts-2-1-796 * Made some additions to test if they could help decreasing impact on radio occultation simulations of abrupt gradient changes in input data (as is the case for Venus). Helped a bit, but no huge success. Smaller peak values, but now both positive and negative "peaks". * src/m_atmosphere.cc (p_gridDensify): New WSM. (AtmFieldsCalc): Added GIN vmr_nonegative. (AtmFieldsCalcExpand1D): Adopted to change above. * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Now all test settings removed. Now final!?!? 2013-10-16 Jana Mendrok * arts-2-1-795 * src/gas_abs_lookup.cc(Extract): Relaxed identity check of f_grid entries according to Stefan's suggestion. Identity on floats is delicate, so now checking for diff<1Hz. 2013-10-16 Patrick Eriksson * arts-2-1-794 * Something is wrong with line mirroring !!! * src/m_abs.cc (abs_lines_per_speciesAddMirrorLinesOld): This is the old version. Put it back for test purpose. But shows the same bad feature. 2013-10-16 Patrick Eriksson * arts-2-1-793 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Something starnge is happening here, trying to understand what. * controlfiles/planetary_toolbox/demos/active/demo_earth_ionosphere.m: * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Adopted to renaming of O fields, and polishing of coemments. 2013-10-16 Patrick Eriksson * arts-2-1-792 * controlfiles/planetary_toolbox/DemoVenusAtmo3D.arts: * controlfiles/planetary_toolbox/DemoVenusAtmo1D.arts: Changed following addition below. * controlfiles/planetary_toolbox/includes/venus/atmo_venus.arts: Added "CO2-SelfContPWR93, CO2-ForeignContPWR93" as 'species'. 2013-10-15 Patrick Eriksson * arts-2-1-791 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Switched position between GPS and LEO, using new feature in the atmlab function used. 2013-10-15 Patrick Eriksson * arts-2-1-790 * doc/uguide/absorption.tex (subsection{Continua and complete absorption models}): Added H066 also here. 2013-10-15 Patrick Eriksson * arts-2-1-789 * controlfiles/general/continua.arts: CO2-SelfContHo66 and CO2-ForeignContHo66. * src/species_data.cc (define_basic_species_data): Added SelfContHo66 and ForeignContHo66. * src/continua.cc (xsec_continuum_tag): Added CO2-SelfContHo66 and and CO2-ForeignContHo66. (Ho66_CO2_self_continuum, Ho66_CO2_foreign_continuum): New. * Removed everything added by Stefan in arts-2-1-786. Sorry! 2013-10-14 Patrick Eriksson * arts-2-1-788 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Just changed fs to 14. 2013-10-14 Patrick Eriksson * arts-2-1-787 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Fine tuned settings. Partly to mimic figures from journal articles. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Just fixed a comment. * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: Defocus method 2 selected here. As this method appears most stable for the GPS altitude (and lower). 2013-10-14 Stefan Buehler * arts-2-1-786 * src/continua.cc (Oschlisniok2012_CO2_venus): Added this function. Just a stubb at the moment, implementation of equation left to Patrick. (xsec_continuum_tag): Added Oschlisniok2012 continuum call. * src/species_data.cc (CO2): Added CO2-Oschlisniok2012 absorption model. * controlfiles/general/continua.arts: Added entry for CO2-Oschlisniok2012 absorption model. 2013-10-14 Patrick Eriksson * arts-2-1-785 * controlfiles/artscomponents/radiolink/TestRadioLink.arts: defocus_shift hard coded to 1e-3, to not ruin consistency with reference values. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Just played around with settings. * src/methods.cc: After some tests, changed default for defocus_shift from 1e-3 to 3e-3. Was found to give more stable results. And maybe better represent the fact that there is a Fresnel zone. 2013-10-13 Patrick Eriksson * arts-2-1-784 * src/m_abs.cc (abs_lines_per_speciesAddMirrorLines): Added GIN max_f, to give the for stopping the mirroring at some frequency. Default is "mirror all", as before. 2013-10-13 Patrick Eriksson * arts-2-1-783 * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: Just removed a "keyboard" * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Now also covering gas absorption. Header and comments written. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Typo in comment. * controlfiles/planetary_toolbox/demos/active/ demo_earth_fascode_ionosphere.m: Was still in svn. 2013-10-12 Patrick Eriksson * arts-2-1-782 * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: Missed to do svn add. 2013-10-12 Patrick Eriksson * arts-2-1-781 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Some polishing of settings, but not ready. * controlfiles/planetary_toolbox/demos/active/demo_earth_ro.m: New. Includes both power and Faraday. Should be complete. * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Now using propmat_clearsky_agenda__OnTheFly_Faraday. * controlfiles/general/agendas.arts: Defined propmat_clearsky_agenda__OnTheFly_Faraday. * controlfiles/planetary_toolbox/demos/active/demo_earth_ionosphere.m: Made the name of the function a bit short (removed fascode_). And some fine tuning of plotting. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Now a complete test, with detailed comments. 2013-10-12 Jana Mendrok * arts-2-1-780 * src/m_abs.cc(abs_xsec_per_speciesInit): Bugfix(?). Added a safety check that number of abs_species_active is not larger than number of abs_species. Might happen, when the abs_xsec_per_species* WSM are accessed directly and not through the agenda (e.g. in TestCIA.arts). * controlfiles/general/agendas.arts: Added abs_xsec_agenda__withCIAextraT for CIA with (sufficient in practice) temperature extrapolation range. * controlfiles/planetary_toolbox/includes/venus/atmo_venus.arts, DemoVenusAtmo1D.arts, DemoVenusAtmo3D.arts: Bugfix. There were some more species in day profiles than in night. Added them as selectable (also requires an arts-xml-data update). Added a CO2-CO2-CIA species. 2013-10-11 Patrick Eriksson * arts-2-1-779 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Now using arts_radioocc_1D_power. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Now including some test settings. * src/m_transmitter.cc (iyRadioLink): -1 instead of f_grid was sent to defocusing functions!!! This has worked until now without any bug, but was now catched by free electron refr_index method. * controlfiles/general/agendas.arts: Removed an unnecessary ignore from refr_index_air_agenda__GasThayerAndElectrons. * src/m_refraction.cc (refr_index_airFreeElectrons): Introduced demand_vmr_value, for higher flexibility. Extended built-in doc to warn about the default constrain on abs_species, and that demand_vmr_value shall be used with care. * src/ppath.cc (raytrace_1d_linear_basic): Tangent point a few mm below a pressure level could lead to infinite loop. A bug caused by change of how tangent points are handled. Fixed by adding: za_flagside = za_v[1]; 2013-10-11 Jana Mendrok * arts-2-1-778 * src/test_cia.cc(test01): Fixed the cia_interpolation call that Hudson didn't like. 2013-10-11 Jana Mendrok * arts-2-1-777 * src/m_cia.cc, methods.cc (abs_xsec_per_speciesAddCIA): Added temperature extrapolation factor as method input. * src/cia.cc,cia.h(Extract,cia_interpolation): Handling temperature extrapolation factor. * src/m_refraction.cc(refr_index_airMWgeneral): Catch case sum(vmr)=0 over all refraction species in rescaling. Fixes issue pointed out by Patrick. 2013-10-11 Patrick Eriksson * arts-2-1-776 * controlfiles/planetary_toolbox/demos/active/demo_venus_ro.m: Started. * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Added data and info. 2013-10-11 Oscar Isoz * arts-2-1-775 * src/m_sensor.cc src/sensor.cc src/methods.cc: Corrected how the passbands are calculated for the AMSU-A sensor. 2013-10-10 Patrick Eriksson * arts-2-1-774 * controlfiles/planetary_toolbox/demos/active/demo_mars_ro.m: Just a start. 2013-10-10 Patrick Eriksson * arts-2-1-773 * controlfiles/planetary_toolbox/demos/active/ demo_earth_fascode_ionosphere.m: A demo script using the new atmlab functions. * controlfiles/planetary_toolbox/demos/active/ earth_tropical_false3d_0to64km_lowfreq.arts: * controlfiles/planetary_toolbox/demos/active/ earth_tropical_false3d_0to1000km_lowfreq.arts: Updated these two include files. * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: Finished this demo file. * controlfiles/general/agendas.arts: Defined iy_transmitter_agenda__UnitUnpolIntensity. 2013-10-10 Jana Mendrok * arts-2-1-772 * controlfiles/planetary_toolbox/includes/venus/getwind_venus.arts, controlfiles/planetary_toolbox/includes/jupiter/getatmo_jupiter.arts, controlfiles/planetary_toolbox/includes/jupiter/getwind_jupiter.arts, controlfiles/planetary_toolbox/includes/jupiter/getmagfield_jupiter.arts, controlfiles/planetary_toolbox/includes/mars/getwind_mars.arts, controlfiles/planetary_toolbox/includes/common/makemagfield.arts, controlfiles/planetary_toolbox/includes/common/makefield1D.arts, controlfiles/planetary_toolbox/includes/common/makefield3D.arts, controlfiles/planetary_toolbox/includes/common/makeatmo1D.arts, controlfiles/planetary_toolbox/includes/common/makeatmo3D.arts, controlfiles/planetary_toolbox/includes/common/getgrids_1D.arts: Improved documentation. 2013-10-09 Jana Mendrok * arts-2-1-771 * src/m_atmosphere.cc(GriddedFieldLatLonRegrid): Added the true-3D-data check here already to catch mistakenly empty grids (else is_cyclic causes an assert). * controlfiles/planetary_toolbox/TestJupiterAtmo.arts, TestVenusAtmo.arts: Removed. Get replaced by the files below. * controlfiles/planetary_toolbox/DemoVenusAtmo[1,3]D.arts, DemoJupiterAtmo[1,3]D.arts: Added. Demos/templates for getting venus and jupiter atmospheric data. Separate setups for 1D and 3D. Replace the previous Test*Atmo.arts. * controlfiles/planetary_toolbox/DemoMarsAtmo[1,3]D.arts, controlfiles/planetary_toolbox/includes/mars/getatmo_mars.arts, controlfiles/planetary_toolbox/includes/common/makemagfield.arts: Minor fixes. * controlfiles/planetary_toolbox/includes/venus/atmo_venus.arts, getatmo_venus.arts, jupiter/atmo_jupiter.arts, getatmo_jupiter.arts: Improved documentation. * controlfiles/planetary_toolbox/includes/mars/getwind_mars.arts, controlfiles/planetary_toolbox/includes/jupiter/getmagfield_jupiter.arts: Bugfixes. 2013-10-09 Patrick Eriksson * arts-2-1-771 * Removed/changed stuff stopping iyRadioLink to be used with ppath_agenda__FollowSensorLosPath. This combination can i fact be very useful. * src/m_transmitter.cc (iyRadioLink): Removed if statement demanding transmitter. rte_los now an input, passed on to ppath_agenda. * src/rte.cc (defocusing_sat2sat): Changed if-statement detecting if limb sounding is being performed. Old one demanded tracking of transmitter. 2013-10-09 Jana Mendrok * arts-2-1-770 * controlfiles/planetary_toolbox/DemoMarsAtmo3D.arts, DemoMarsAtmo1D.arts, getgrids_1D.arts, getgrids_3Dsimple.arts, getgrids_3Dspaced5deg.arts, getatmo_mars.arts, atmo_mars.arts: Improved documentation. 2013-10-09 Richard Larsson * arts-2-1-769 * controlfiles/general/continua.arts: Added O2-MPM89 support since it is already in ARTS. 2013-10-09 Jana Mendrok * arts-2-1-768 * controlfiles/planetary_toolbox/includes/mars/getatmo_mars.arts: Remove grid settings recently introduced by Patrick. We rather do them in a separate include (and they do not belong in here, where we just read the raw atmospheric grids). * controlfiles/planetary_toolbox/TestMarsAtmo.arts: Removed. Gets replaced by the files below. * controlfiles/planetary_toolbox/DemoMarsAtmo[1,3]D.arts: Added. Demos/templates for getting mars atmospheric data. Separate setups for 1D and 3D. They replace the previous TestMarsAtmo.arts. * controlfiles/planetary_toolbox/includes/common/getgrids_1D.arts, getgrids_3Dsimple.arts, getgrids_3Dspaced5deg.arts: Added. Include files that create p/lat/lon grid purely on p/lat/lon_min/max specifications by the user (everything else set or extracted internally). * controlfiles/planetary_toolbox/includes/common/makemagfield.arts, makefield1D.arts, makefield3D.arts: Use named parameters instead of positional passing. * controlfiles/planetary_toolbox/includes/common/createvars.arts: A string variable added. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Added abs_xsec check within outcommented make-LUT part. * ChangeLog: Added my forgotten-to-commit last entry and fixed version numbering. 2013-10-08 Richard Larsson * arts-2-1-767 * src/methods.cc: Changed documentation on the definition function for line shapes to include the Faddeeva option. 2013-10-07 Patrick Eriksson * arts-2-1-766 * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Updated reference values, to have a clear reference (data and platform given as comment in file). Increased tolerance for y to 2e-17, following data reported by Nicolas. This is about 2%, but impact of numerical inaccuracy on defocuisng results are high (see comment for arts-2-1-495) * controlfiles/artscomponents/faraday/test_faraday.m: Improved comment and accuracy of scaling factor. * doc/uguide/faraday.tex: Corrected a citep to citet. 2013-10-06 Jana Mendrok * arts-2-1-765 * src/m_cloudbox.cc, methods.cc (ParticleTypeAdd, ParticleTypeAddAll, ParticleType2abs_speciesAdd): Removed p/lat/lon_grid as passed variables. We don't need them in there. Whether they are consistent with atmosphere_dim is not necessary to be checked HERE! * controlfiles/artscomponents/arts-xml-data/TestClouds_Mars.arts, TestClouds_Venus.arts: Added. Cloud data tests. * controlfiles/CMakeLists.txt: Cloud data test added to test suite. 2013-10-04 Jana Mendrok * arts-2-1-764 * controlfiles/CMakeLists.txt: Oops, TestGridsExtract requires arts-xml-data. Moved into the corresponding if clause. 2013-10-04 Jana Mendrok * arts-2-1-763 * src/m_atmosphere.cc,methods.cc (lat_gridFromRawField, lon_gridFromRawField): Added. For extraction of lat_ and lon_grid from data grids. Similar to p_gridFromZRaw, but acting on a generic GriddedField3 instead of on z_field_raw. * controlfiles/artscomponents/helpers/TestGridsExtract.arts: Added. Testing above introduced grid extraction including cropped grids as introduced in 2-1-759. * controlfiles/CMakeLists.txt: Added above test case to the test suite. 2013-10-04 Jana Mendrok * arts-2-1-762 * src/m_refraction.cc(refr_index_airMWgeneral): Added H2O with reference refractivity calculated from Thayer. * src/methods.cc(refr_index_airMWgeneral): Description adapted accordingly. * doc/uguide/refr_index.tex, refr_index_theory.tex: AUG and ATD on refr_index_airMWgeneral adapted accordingly. 2013-10-04 Jana Mendrok * arts-2-1-761 * src/m_atmosphere.cc(GriddedFieldPRegrid,GriddedFieldPRegridHelper): No attempt of interpolation if old grid is completely outside new grid. Rather set everything to 0 if zeropadding (else throw error, as usual). Fixes issue reported by Patrick in 2-1-760. 2013-10-03 Patrick Eriksson * arts-2-1-760 * src/m_refraction.cc (refr_index_airMWgeneral): Commented out if-statement demanding that sum(vmr) is close to 1. This is not working together with the Mars data. Discussed with Jana, and seems difficult to keep the constrain. Note that the method applies a "rescaling" to sum(vmr)=1. * controlfiles/planetary_toolbox/includes/mars/getatmo_mars.arts: Found a setting p_grid resulting in an assert error. Not tracked down, but setting left as a comment in the file. 2013-10-03 Patrick Eriksson * arts-2-1-759 * Jana and I have decided on a general principle for inclusion of atmospheres. Basically following what is already in place in eg. getatmo_mars.arts, but extend to automatically set p/lat/lon_grid, with the option to crop the grids. Some first step to implement this: * src/m_basic_types.cc (VectorCrop): New WSM. Note default values, trying to mimic +-Inf. For example this works: VectorCrop( out=p_grid, in=p_grid, min_value=0.1e2 ) * controlfiles/planetary_toolbox/TestMarsAtmo.arts: Removed setting of p_grid, lat_grid and lon_grid. * controlfiles/planetary_toolbox/includes/mars/getatmo_mars.arts: p_grid, lat_grid and lon_grid are now set here. lat_grid and lon_grid set to be empty if not 3D. Values for 3D are just test values, things will be improved ... 2013-09-30 Patrick Eriksson * arts-2-1-758 * controlfiles/general/agendas.arts: Defined. refr_index_air_agenda__GasThayerAndElectrons. This as refr_index_air_agenda__GasMWgeneralAndElectrons is NOT working for Earth, as water vapour is not considered at all by the MWgeneral method. 2013-09-23 Richard Larsson * arts-2-1-757 * src/{continua.{cc,h},species_data.cc,partition_function_data.cc}, controlfiles/general/continua.arts: Added Tretyakov et al. 2005 mpm-like continua model. Call "O2-TRE05" to get to it. This addition is just a copy of mpm93 with the Tretyakov et al. 2005 numbers instead of the mpm. * src/{m_zeeman.cc,linerecord.cc}: Added some quantum number reading for N and J so Zeeman Hund case b should work now. * doc/uguide/absorption.tex: Changed text on Zeeman here since NO can do b-case now. Also added O2-TRE05 to the right list. 2013-09-16 Johan Strandgren * arts-2-1-756 * src/cloudbox.cc (area_ratioH13): Corrected the values for alpha and beta. 2013-09-16 Johan Strandgren * arts-2-1-755 * src/methods.cc (scat_meta_arrayAddTmatrix): Updated GIN and description due to the changes for the aspect ratio and size inputs. Numeric aspect_ratio --> Vector aspect_ratio_grid Vector diameter_grid --> Vector diameter_max_grid * src/workspace.cc (scat_meta): Corrected two errors in the description. * src/m_tmatrix.cc (scat_meta_arrayAddTmatrix): Changed size input from equivalent diameter to diameter_max and changed the aspect ratio from Numeric to Vector. Added a loop to calculate meta data for each combination of diameter_max and aspect_ratio. Before the diameter_max was calculated, now it's the volume that is calculated from diameter_max and aspect_ratio. * src/m_cloudbox.cc (pnd_fieldSetup): Added a new PND parametrization with an included shape distribution (H13Shape). * src/cloudbox.cc: (pnd_fieldMH97, pnd_fieldH11, pnd_fieldH13): Added a check to make sure that just one aspect ratio is used for these parametrizations, just as before. (pnd_fieldH13Shape): The new PND parametrization with an included shape distribution (H13Shape). (IWCtopnd_H13Shape, area_ratioH13): The actual parametrizations containing the equations and variables to calculate the PND and area ratio based on temperature. * src/cloudbox.h: (pnd_fieldH13Shape, IWCtopnd_H13Shape, area_ratioH13): The same parametrizations have been added as in src/cloudbox.cc. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Updated due to the changed inputs (diameter_max_grid and aspect_ratio_grid) 2013-09-04 Johan Strandgren * arts-2-1-754 * src/optproperties.h (ScatteringMetaData): Changed complex_refr_index from being a Tensor3 to a Griddedfield3 * src/m_cloudbox.cc (pnd_fieldSetup): * src/cloudbox.cc (pnd_fieldH13, IWCtopnd_H13, scale_H13): * src/cloudbox.h (pnd_fieldH13, IWCtopnd_H13, void scale_H13): Added the updated version of Heymsfield's PSD from 2013. Very similar to the earlier version (H11), only updated variable values. * src/methods.cc (complex_refr_indexRegrid): Removed this WSM used for interpolation of the refractive index. * src/m_tmatrix.cc (complex_refr_indexRegrid): Deleted and replaced with a built-in interpolation function inside scat_data_arrayFromMeta instead (see below). (scat_meta_arrayAddTmatrix): removed check-function for refractive index. Simplified and clarified the equation used for calculation of diameter_max. (scat_data_arrayFromMeta): Added a built-in interpolation function that interpolates the refractive index to fit the frequency and temperature grids chosen for the T-matrix calculations. 2013-08-23 Johan Strandgren * arts-2-1-753 * src/methods.cc: (complex_refr_indexIceWarren84, complex_refr_indexIceLiebe93): Renamed GINs: f_grid --> data_f_grid t_grid --> data_T_grid. (complex_refr_indexRegrid): Added new WSM to interpolate complex_refr_index. * src/m_refraction.cc: (complex_refr_indexWaterLiebe93): Added a warning if temperatures below 250 K are used. * src/m_tmatrix.cc: (complex_refr_indexRegrid): Added the interpolation method mentioned above. (scat_meta_arrayAddTmatrix): changed complex_ref_index to be IN instead of GIN. Updated the variable names in the check functions. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: * controlfiles/artscomponents/doit/TestDOIT.arts: Adapted the changed variable names. 2013-08-22 Patrick Eriksson * arts-2-1-752 * After discussion with Stefan, removed abs_check. This leaves stokes_dim and f_grid "uncovered". Add checks where required. See start of yCalc for the checks performed earler in abs_checkedCalc (and before that in basics_checkedCalc)... * artscomponents/absorption/TestAbsDoppler.arts: * artscomponents/absorption/TestCompareArtscat3And4.arts: * artscomponents/absorption/TestIsoRatios.arts: * artscomponents/arts-xml-data/TestPlanetIsoRatios.arts: * artscomponents/arts-xml-data/TestSurf_Earth.arts: * artscomponents/arts-xml-data/TestSurf_Mars.arts: * artscomponents/arts-xml-data/TestSurf_Venus.arts: * artscomponents/cia/TestRTwithCIA.arts: * artscomponents/clearsky/TestClearSky.arts: * artscomponents/clearsky/TestClearSky2.arts: * artscomponents/disort/TestDISORT.arts: * artscomponents/doit/TestDOIT.arts: * artscomponents/doitbatch/TestDOITBatch.arts: * artscomponents/faraday/TestFaradayRotation.arts: * artscomponents/groundbased/TestFgrid.arts: * artscomponents/groundbased/TestGbased.arts: * artscomponents/groundbased/TestWinds.arts: * artscomponents/montecarlo/TestMonteCarloGeneral.arts: * artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts: * artscomponents/montecarlo/TestRteCalcMC.arts: * artscomponents/pencilbeam/TestPencilBeam.arts: * artscomponents/radiolink/TestRadioLink.arts: * artscomponents/radiolink/TestRadioLink2.arts: * artscomponents/radiolink/TestRadioOccultation.arts: * artscomponents/transmission/TestTransmission.arts: * artscomponents/wfuns/TestWfuns.arts: * artscomponents/zeeman/TestZeeman.arts: * instruments/amsu/TestAMSU_generic.arts: * instruments/hirs/TestHIRS.arts: * instruments/mhs/TestMHS_generic.arts: * instruments/odinsmr/TestOdinSMR.arts: * instruments/odinsmr/TestOdinSMR_1D.arts: Adopted. * src/m_montecarlo.cc (MCGeneral): * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): * src/m_disort.cc (ScatteringDisort): * src/m_doit.cc (CloudboxGetIncoming,CloudboxGetIncoming1DAtm,ScatteringDoit): * src/m_rte.cc (iyCalc,yCalc): * src/m_cloudradar.cc (iyCloudRadar): Adopted. Added check of stokes_dim, where this WSV is input. * src/m_checked.cc (abs_checkedCalc): Removed. * src/workspace.cc: Removed abs_checked. 2013-08-22 Jana Mendrok * arts-2-1-751 * controlfiles/testdata/isoquantum.xml: Removed. It's a plain copy of zeeman_constants.xml in arts-xm-data. So, we directly want to use that instead! * controlfiles/artscomponents/zeeman/TestZeeman.arts: Adapted accordingly to use zeeman_constants.xml from arts-xm-data. * controlfiles/CMakeLists.txt: Accordingly, moved Zeeman test into arts-xml-data section. * src/geodetic.cc(cart2poslos): Spellfixes in comments. 2013-08-22 Oliver Lemke * arts-2-1-750 * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts src/m_cloudbox.cc, src/methods.cc, src/workspace.cc: Rename WSV part_species_nout -> scat_data_per_part_species. 2013-08-21 Patrick Eriksson * arts-2-1-749 * Polishing of last commit. Mixed CloudboxGetIncoming with iyInterp.... The CloudboxGetIncoming WSMs shall use the checked WSVs. Added these WSVs also to some other WSMs not even using basics_checked, but should have done. Fixes pointed out in email from Jana. Thanks. * ChangeLog: Edited entry for 2-1-748, to not have misleading information in the file. * src/m_disort.cc (ScatteringDisort): * src/m_doit.cc (CloudboxGetIncoming) (ScatteringDoit,CloudboxGetIncoming1DAtm): Now using abs_checked, atmfields_checked and atmgeom_checked and cloudbox_checked. * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: Changed to 1e-6 also here. Not needed, but for consistency. * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: Test using this file failed worked my work desktop, but failed on home Mac desktop. The diff on the Mac was 1.1e-8, and the limit was set to 1e-8. A very hard limit, now relaxed to 1e-6. Diffs below 1-e3 should have no practical importance. 2013-08-20 Patrick Eriksson * arts-2-1-748 * Warning! New WSVs and WSMs introduced. You need to change your 2.1 cfiles. Basically all cfiles should be affected. * Revision of the variables and method of check-type now activated. More WSVs of checked-type, for better modularity and making the variables easier to use in WSMs. Note that the checked-variables only are used in methods normally called directly in the control file, but not used in methods normally placed in agendas, for efficiency reasons. So, yCalc, ppathCalc etc. uses the variables, but I have removed old checks in e.g. iyMC to be consistent with this rule. That is, if you make direct calls of methods like iyMC and iyEmissionStandard its on your own risk. If you use bad input for such calls, you can obtain an assert instead of an error, or even worse, incorrect result. However, you can of course call e.g. atmfields_checkedCalc anyhow before calling e.g. iyMC. That will decrease the risk of bad surprises later on. For a claculation with yCalc you now need these calls propmat_clearsky_agenda_checkedCalc abs_checkedCalc atmfields_checkedCalc atmgeom_checkedCalc cloudbox_checkedCalc sensor_checkedCalc * controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts: * controlfiles/instruments/odinsmr/TestOdinSMR.arts: * controlfiles/instruments/mhs/TestMHS_generic.arts: * controlfiles/instruments/hirs/TestHIRS.arts: * controlfiles/instruments/avhrr/TestAVHRR.arts: * controlfiles/instruments/amsu/TestAMSU_generic.arts: * controlfiles/artscomponents/arts-xml-data/TestPlanetIsoRatios.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScen_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScen_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScen_Jupiter.arts: * controlfiles/artscomponents/cia/TestRTwithCIA.arts: * controlfiles/artscomponents/disort/TestDISORT.arts: * controlfiles/artscomponents/groundbased/TestFgrid.arts: * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts: * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: * controlfiles/artscomponents/ppath/TestRefractPlanets.arts: * controlfiles/artscomponents/wfuns/TestWfuns.arts: * controlfiles/artscomponents/zeeman/TestZeeman.arts: * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/artscomponents/doit/TestDOIT.arts: * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/clearsky/TestClearSky2.arts: * controlfiles/artscomponents/clearsky/TestClearSky.arts: * controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Earth.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Jupiter.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Mars.arts: * controlfiles/artscomponents/absorption/TestIsoRatios.arts: * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: * controlfiles/artscomponents/absorption/TestAbsDoppler.arts: * controlfiles/artscomponents/groundbased/TestWinds.arts: * controlfiles/artscomponents/groundbased/TestGbased.arts: * controlfiles/artscomponents/ppath/TestPpath3D.arts: * controlfiles/artscomponents/ppath/TestPpath2D.arts: * controlfiles/artscomponents/ppath/TestPpath1D.arts: * controlfiles/artscomponents/helpers/TestHSE.arts: Adopted to changes below. * src/m_doit2.cc (CloudboxGetIncoming2, iyInterpCloudboxField2): Removed these from methods.cc. Unfinished work. Do not even remember that I had started this! * src/m_rte.cc (iyMC): * src/m_ppath.cc (ppathFromRtePos2): Now not using any of the check variables, see comment at top. * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): Now using abs_checked and atmfields_checked, instead of basics_checked. * src/m_rte.cc (iy_auxFillParticleVariables): * src/m_atmosphere.cc (z_fieldFromHSE): Now using atmfields_checked, instead of basics_checked. * src/m_ppath.cc (ppathCalc): Now using atmgeom_checked, instead of basics_checked. * src/m_montecarlo.cc (MCGeneral): * src/m_rte.cc (iyCalc): * src/m_cloudradar.cc (yCloudRadar): * src/m_rte.cc (yCalc): Now using abs_checked, atmgeom_checked, atmfields_checked, instead of basics_checked. * src/m_checked.cc (basics_checkedCalc, basics_checkedCalcNoGeo): Removed these WSMs and related internal functions. Code already reused in atmfields_checkedCalc, atmgeom_checkedCalc. (propmat_clearsky_agenda_checkedCalc): Commented out needs_free_electrons, variable not used. * src/workspace.cc: Removed basics_checked, and added: abs_checked atmfields_checked atmgeom_checked 2013-08-20 Patrick Eriksson * arts-2-1-747 * src/methods.cc (particle_massesFromMetaDataSingleCategory): Extended doc text, for hopefully better clarity. * src/geodetic.cc (cart2poslos): Removed assert of abs( abs(za) - RAD2DEG*acos(dr) ) < 1e-4 Added this assert as a double check that correct angle was resolved and there is no real loopholes in the code. Ole Martin now got a case with a difference of 1.018e-4. This is a numerical issue. No point in just relaxing the assert, the assert has fulfilled its purpose. 2013-08-20 Johan Strandgren * arts-2-1-746 * src/workspace.cc: (scat_meta, scat_meta_array): updated online doc. * src/methods.cc: (scat_meta_arrayAddTmatrix, scat_data_arrayFromMeta): updated online doc. 2013-08-20 Jana Mendrok * arts-2-1-745 * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.y.xml: Added. Reference file for test case TestSurf_Mars.arts (missed in arts-2-1-738). * doc/uguide/absorption.tex: Spellfix. 2013-08-20 Oliver Lemke * arts-2-1-744 * One more WSV rename. This concludes the renaming of the scattering WSVs / WSM. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, src/m_cloudbox.cc, src/methods.cc, src/workspace.cc: scat_data_array_nelem -> part_species_nout 2013-08-20 Oliver Lemke * arts-2-1-743 * Warning! WSM and WSV renaming in this commit!!! * controlfiles/artscomponents/disort/TestDISORT.arts, controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts, controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts, doc/uguide/absorption.tex, doc/uguide/clouds.tex, doc/uguide/rte_basics.tex, doc/uguide/scattering.tex, src/cloudbox.cc, src/cloudbox.h, src/disort.cc, src/disort.h, src/m_abs.cc, src/m_batch.cc, src/m_checked.cc, src/m_cloudbox.cc, src/m_cloudradar.cc, src/m_disort.cc, src/m_doit.cc, src/m_fos.cc, src/m_montecarlo.cc, src/m_optproperties.cc, src/m_rte.cc, src/m_tmatrix.cc, src/m_transmitter.cc, src/mc_NotUsed.cc, src/methods.cc, src/montecarlo.cc, src/montecarlo.h, src/partition_function_data.cc, src/rte.cc, src/rte.h, src/workspace.cc: single_scattering_data -> scat_data scat_data_raw -> scat_data_array scat_data_mono -> scat_data_array_mono scat_data_nelem -> scat_data_array_nelem scat_data_meta -> scat_meta scat_data_meta_array -> scat_meta_array Resulting WSM renames: scat_data_meta_arrayAddTmatrix -> scat_meta_arrayAddTmatrix scat_data_meta_arrayInit -> scat_meta_arrayInit scat_data_monoCalc -> scat_data_array_monoCalc scat_data_rawCheck -> scat_data_arrayCheck scat_data_rawFromMeta -> scat_data_arrayFromMeta 2013-08-20 Patrick Eriksson * arts-2-1-742 * Work in progress, no active changes yet. * Start on revision of checked WSVs and WSMs. Following the lines of Jana's changes, but instead using more WSVs. And trying to better distinguish between atmospheric and absorption parts. For example, basics_checkedCalc requires f_grid to be set, while f_grid is not always used, such as when calling ppathCalc. Now planning to have these flag WSVs: abs_checked atmfields_checked atmgeom_checked cloudbox_checked sensor_checked For abs_checked to be true, both abs_xsec_agenda_checked and propmat_clearsky_agenda_checked must be true, and some additional tests done. So it is a "super flag" for the absorption part. * src/m_checked.cc: New file and placed all WSM returning checked-variables here. The idea is by putting them side-by-side it should be easier to make sure that the checks are complete and there is a good logic between the methods. (atmfields_checkedCalc, atmgeom_checkedCalc, abs_checkedCalc): New methods, not yet active. * Corrected date for commit below. 2013-08-20 Oliver Lemke * arts-2-1-741 * README: Extend section on enabling / disabling Fortran features. * CMakeLists.txt: Add -Wno-return-type-c-linkage to shut up clang warning about Complex C++ return type used in C call to refice_. It's fine. Remove f2c related code. * config.h.cmake: Remove f2c cmakedefine. * src/CMakeLists.txt: Removed test_disort. Now in 3rdparty dir. * 3rdparty/disort1.2/CMakeLists.txt: Add test_disort. * 3rdparty/disort1.2/ErrPack.f: DSERRMSG->ERRMSG. * 3rdparty/refice/REFICE.f: ERRMSG->RERRMSG. Easier to rename it here than in the Disort code. * 3rdparty/disort1.2/CMakeLists.txt, 3rdparty/refice/CMakeLists.txt, 3rdparty/tmatrix/CMakeLists.txt: Simplify. Tweak messages. * controlfiles/CMakeLists.txt: Promote tmatrix tests from nocheck to fast. 2013-08-19 Jana Mendrok * arts-2-1-740 * src/m_cloudbox.cc: Renamed particle_massesSet -> particle_massesFromMetaDataAndPart_species. Corrected mixed up dimensions pointed out by Patrick. * src/methods.cc: Renamed particle_massesSet. Minor fixes in particle_massesFromMetaDataSingleCategory. * src/workspace.cc: Minor fixes in particle_masses. 2013-08-19 Patrick Eriksson * arts-2-1-739 * src/m_cloudbox.cc (particle_massesFromMetaDataSingleCategory): New WSM. Can set particle_masses from scat_data_meta_array for some special conditions. * src/m_general.cc (Test): Just removed verbosity to avoid compiler warning. * src/m_refraction.cc (complex_refr_indexWaterLiebe93): Changed built-in doc to reflect change below. * src/refraction.cc (complex_n_water_liebe93): Changed lower temperature limit to -40. * src/m_tmatrix.cc (scat_data_meta_arrayAddTmatrix): Defined default for material and density, as a way to indicate that they are not actuall needed for T-matrix (as description, already having "" as default). Default for density is -999, to get a number that is easy to detect as unphysical. * src/workspace.cc: A very small change of text for particle_masses. 2013-08-17 Jana Mendrok * arts-2-1-738 * controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: Adapted to changes in surface_complex_refr_index handling. * controlfiles/artscomponents/absorption/IsoRatios_H2Oorig.xml, controlfiles/artscomponents/absorption/IsoRatios_H2Omani.xml: Include N2-45 to fix broken test case. * controlfiles/artscomponents/absorption/TestIsoRatios.arts: Minor adaption. * controlfiles/artscomponents/arts-xml-data/TestIsoRatios.arts: Renamed to TestPlanetIsoRatios.arts to avoid mexing up output with absorption/TestIsoRatios.arts case. * controlfiles/CMakeLists.txt: Adapted accordingly. * src/species_data.cc,partition_function_data.cc: A bit of cleaning up (tag updates, layouting, missed data updates) after arts-2-1-721. * src/workspace.cc,methods.cc: Minor fixes. 2013-08-17 Patrick Eriksson * arts-2-1-737 * 2D ray tracing now following the approached already used for 3D. Less elegant but seems needed to get away from a constant tuning of settings to handlle the numerical problems. * src/ppath.cc (ppath_step_geom_2d): Now calling do_gridcell_2d_byltest. If you run into problems with the new 2D ppath calculations, just change if(0) to if(1) on line 3311. (raytrace_2d_linear_basic): As above, including a if-statement to switch back to old code. * src/geodetic.cc (cart2pol, cart2poslos): Changes to get the functions to work with negative zenith angles. 2013-08-16 Patrick Eriksson * arts-2-1-736 * src/ppath.cc (do_gridcell_2d_byltest): A 2D version of the corresponding 3D one. Not yet active, fails at least for negative za. 2013-08-15 Johan Strandgren * arts-2-1-735 * src/m_refraction.cc: Included physics_funcs.h. (complex_refr_indexIceWarren84): Corrected the name of the WSM. Removed "scat_" from "scat_f_grid" and "scat_t_grid". 2013-08-15 Patrick Eriksson * arts-2-1-734 * src/m_tmatrix.cc (single_scattering_dataFromTmatrix): Removed. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Adopted. * controlfiles/artscomponents/surface/TestSurface.arts: Adopted to changes below. * controlfiles/artscomponents/surface/create_gfields.m (create_gfields): Updated, complex_n_field now GriddedField5. * controlfiles/artscomponents/doit/TestDOIT.arts: Included, adopted, agenda defintion from below. * controlfiles/general/agendas_surface.arts: Removed definition of surface_rtprop_agenda__Specular_Pol_Water_SurfTFromt_field. A bit to specific to be generally defined. * src/m_refraction.cc (ParticleRefractiveIndexConstant) (ParticleRefractiveIndexWaterLiebe93) (ParticleRefractiveIndexIceWarren84): Renamed to start with complex_refr_index. In all cases changed output from being GOUT to OUT. Names of GIN variables changed. E.g. scat_ removed from grid names. (complex_refr_indexConstant): New version. Now there are no input grids. * src/m_cloudradar.cc (iyCloudRadar): Used complex_refr_indexWaterLiebe93, adopted this call. * src/refraction.cc (complex_n_water_liebe93): New function, based on old complex_refr_indexWaterLiebe93. * src/m_refraction.cc: Removed complex_refr_indexWaterLiebe93. * src/methods.cc (define_md_data_raw): Removed defintion of complex_refr_indexWaterLiebe93. * src/m_surface.cc (surfaceFlatRefractiveIndex): Adopted to change of type for surface_complex_refr_index. (surface_complex_refr_indexFromGriddedField5): Also adopted, and changed to take Field4 to Feidl5 as input. The new dimension is temperature, to be fully consistent with complex_refr_index. * src/workspace.cc: Redefined surface_complex_refr_index to GriddedField3. Removed old complex_refr_index and replaced with new version. * src/m_refraction.cc: * src/m_physics.cc: Moved all methods for complex refractive index from m_pysics to m_refraction. 2013-08-14 Patrick Eriksson * arts-2-1-733 * src/m_general.cc (Test): Now including code to test function below. * src/special_interp.cc (complex_n_interp): New. Function to interpolate variables of complex_refr_index type. * src/workspace.cc: Added complex_refr_indexNew (only temporary name). Wrote text describing the format of variables of this type. 2013-08-14 Richard Larsson * arts-2-1-732 * src/linerecord.cc: Reading from HITRAN now gets the quantum numbers for Zeeman. There is something wrong in the 2004 paper explaining the format because it seems the Symmetry field is also 2A1, not just as stated in the text that the Branch letter is 2A1, for OH. * doc/uguide/absorption.tex: Changed text on Zeeman here. 2013-08-14 Patrick Eriksson * arts-2-1-731 * doc/uguide/ppath.tex: * doc/uguide/refr_index.tex: * doc/uguide/refr_index_theory.tex: My last changes were not completely OK. One \ too many. 2013-08-14 Oliver Lemke * arts-2-1-730 * src/optproperties.{h,cc}: Add enum ParticleSSDMethod. Change type of particle_type in SMD from String to ParticleType. Add methods for mapping ParticleType and ParticleSSDMethod from/to enum value to/from String. Add ssd_method member to SMD. * src/xml_io_compound_types.cc: Add version attribute to SingleScatteringData. New data is now always written as version 2. Save particle_type as String in SingleScatteringData and ScatteringMetaData. Mapped to/from enum value on read/write. * src/m_tmatrix.cc: (scat_data_meta_arrayAddTmatrix): Set smd.ssd_method to T-Matrix. Use ParticleTypeFromString for particle_type String->enum conversion. (single_scattering_dataFromTmatrix): Use ParticleTypeFromString. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Change horiz_al to horizontally_aligned. Store and load scat_data_meta_array and scat_data_raw. 2013-08-14 Patrick Eriksson * arts-2-1-729 * doc/uguide/refr_index_theory.tex: * doc/uguide/ppath.tex: * doc/uguide/rte.tex: * doc/uguide/refr_index.tex: * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/ppath/TestRefractPlanets.arts: * controlfiles/artscomponents/ppath/TestPpath3D.arts: * controlfiles/artscomponents/ppath/TestPpath2D.arts: * controlfiles/artscomponents/ppath/TestPpath1D.arts: * controlfiles/general/agendas.arts: * src/ppath.cc: * src/m_ppath.cc: * src/m_refraction.cc: * src/refraction.cc: * src/methods.cc: * src/agendas.cc: * src/workspace.cc: As decided in skype meeting, in all files above changed: refr_index -> refr_index_air refr_index_group -> refr_index_air_group refr_index_agenda -> refr_index_air_agenda 2013-08-14 Johan Strandgren * arts-2-1-728 * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Adapted testcase to new variable names (see below) and additional minor changes. * src/optproperties.h (ScatteringMetaData): Renamed some of the variables: type -> material d_max -> diameter_max V -> volume A_projec -> area_projected asratio -> aspect_ratio f_grid -> scat_f_grid T_grid -> scat_T_grid ref_index -> complex_refr_index * src/xml_io_compound_types.cc (xml_write_to_stream/xml_read_to_stream): Updated with the new variable names. * src/cloudbox.cc: (pnd_fieldMH97/pnd_fieldH11/pnd_fieldMP48/pnd_fieldH98/parse_part_type): Updated with the new variable names. * src/m_cloudbox.cc: (ScatteringParticlesSelect/particle_massesSet/pnd_fieldSetup/): Updated with the new variable names. * src/m_tmatrix.cc: (scat_data_meta_arrayAddTmatrix): renamed from scat_data_meta_arrayAdd to scat_data_meta_arrayAddTmatrix. Updated with the new variable names. Removed the hardcoding of the density. Renamed Spherical to spheroidal. Replaced the GIN r_grid with GIN diameter_grid. Allowed aspect_ratio to be 1 for cylindrical particles. Updated to SI units. Changed to lowercase letters where possible. (scat_data_rawFromMeta): Renamed from scat_data_rawFromTmatrix to scat_data_rawFromMeta. Changed to lowercase letters where possible. Updated with the new variable names. Renamed Spherical to spheroidal. (single_scattering_dataFromTmatrix): Renamed macro_iso to macros_iso. Renamed spherical to spheroidal. Changed to SI units. * scat_data_meta (scat_data_meta): Updated description accoring to new variable names. * src/cloudbox.h (parse_part_material): updated from "type" to "material" * src/methods.cc: (ParticleRefractiveIndexIceWarren84/ParticleRefractiveIndexWaterLiebe93): scat_ref_index -> complex_refr_index (scat_data_meta_arrayAddTmatrix): renamed from scat_data_meta_arrayAdd to scat_data_meta_arrayAddTmatrix. Updated with the new variable names. (scat_data_rawFromMeta): Renamed from scat_data_rawFromTmatrix to scat_data_rawFromMeta. 2013-08-14 Richard Larsson * arts-2-1-727 General: Zeeman now runs for NO2 and HO2. * src/m_zeeman.cc: Removed S>0, since Sigma may be less than zero. * src/linerecord.cc: Added reading for NO2 and HO2 quantum numbers. * controlfiles/testdata/isoquantum.xml: Added NO2 and HO2 to the Zeeman species in this file. WARNING: the g_s is for a free electron assumption and I have no idea how good that assumption is for these molecules. 2013-08-14 Oliver Lemke * arts-2-1-726 * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: p_type -> particle_type 2013-08-14 Oliver Lemke * arts-2-1-725 * src/cloudbox.cc, src/m_cloudbox.cc, src/m_optproperties.cc, src/m_tmatrix.cc, src/methods.cc, src/montecarlo.cc, src/optproperties.cc, src/optproperties.h, src/tmatrix.cc, src/xml_io_compound_types.cc: SingleScatteringData.ptype -> SingleScatteringData.particle_type ScatteringMetaData.p_type -> ScatteringMetaData.particle_type * src/workspace.cc: Move scat_data_meta_array detailed docs to scat_data_meta. 2013-08-14 Patrick Eriksson * arts-2-1-724 * src/ppath.cc (rslope_crossing2d): Changed dmin from 1e-12 to 5e-12. A setting to handle numerical problems. Another case from Ole Martin required a dmin of 1.8e-12 to be handled. So increased dmin with some margin. 2013-08-13 Patrick Eriksson * arts-2-1-723 * src/ppath.cc (ppath_calc): Improved check if TOA reached. Added second part of if-statement. Required for some fatal cases where the start part otherwise can jump outside the atmosphere. This fixed one failing case provided by Ole Martin. 2013-08-12 Jana Mendrok * arts-2-1-722 * doc/uguide/refr_index_theory.tex: Added. Moved refractive index (models) theory/background parts from AUG to here and merge info from ESA-Planetary TN1 into it. Currently an own chapter; in future rather make it a section in propagation paths chapter? * doc/uguide/refr_index.tex: Minor updates, corrections. Few parts moved to ATD. * doc/uguide/arts_theory.tex: Include the refractive index chapter. * doc/uguide/references.bib: Added newell65 as refractive index reference. 2013-08-12 Richard Larsson * arts-2-1-721 * src/linerecord.cc: Reading some quantum numbers for ClO and NO now. * src/m_zeeman.cc: Preliminary compatibility with NO and ClO now. Not tested yet. Any suggestions on how to test this? I could not find any models doing this. * src/quantum.{h,cc}: Added QN_Omega. * src/partition_function_data.cc, src/species_data.cc: Can now work with HITRAN2012 based on the HITRAN ref-table.pdf. For isotopes already in these files, I only added the HITRAN tag number. For isotopes of already existing molecules, I assumed Q(T) to by from the most abundant of the species, the mass was calculated from the most common isotope with integer addition for all extra mass. For new molecules, the atomic mass as an integer of the isotopic parts was assumed, C4H2 was assumed linear and SO3 assumed non-linear for the Q(T)={T,T^1.5}, and were thus given the corresponding degree of freedoms. HBr have 2 molecules with molecule number "11" in the new HITRAN. The latter of these is now named 11_2 in ARTS, whilst the first remains unchanged in name. The completely new isotopologues are: HNO3-156, HBr-29, HBr-11_2, HI-27, N2-45, and COF2-369 The completely new species are C4H2, and SO3. The isotopologues new in HITRAN2012 number are: HCl-25, HCl-27, HF-29, H2-11, and H2-12. Some check-all tests will fail with this commit. 2013-08-12 Patrick Eriksson * arts-2-1-720 * src/m_rte.cc (iyEmissionStandard): Uh, mixed up rows and cols. Now changed to x[is] = -trans_partial(iv,is,0,ip)*dbdt; And also noticed that a factor 2 was not included in x[is] for is>0. So that was another bug. 2013-08-11 Patrick Eriksson * arts-2-1-719 * src/m_rte.cc (iyEmissionStandard): For T jacobian changed the lines including: x[is] = -trans_partial(iv,0,is,ip)*dbdt; is was 0 on the right-hand side. Another bug in this part, of the same type! 2013-08-09 Johan Strandgren * arts-2-1-718 * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Adapted testcase to use scat_data_meta_array. * src/m_physics.cc: Added ParticleRefractiveIndexConstant. * src/workspace.cc: Updated docs for scat_data_meta_array. * src/tmatrix.{cc,h} (calcSingleScatteringDataProperties): Removed phase. * src/methods.cc: Added SingleScatteringData to Extract. Added ParticleRefractiveIndexConstant, scat_data_meta_arrayInit. Renamed single_scattering_dataCalcTMatrixTest to scat_data_rawFromTMatrix. * src/m_tmatrix.cc: (scat_data_meta_arrayAdd): Made it compatible with cylinders and spherical particles with other aspect ratios than one. removed density as an input, which is now set using the input material. Added the feature to autocreate a description based on the input data. (scat_data_rawFromTMatrix): Made it compatible with cylinders and spherical particles with other aspect ratios than one. 2013-08-09 Oliver Lemke * arts-2-1-717 * CMakeLists.txt, 3rdparty/disort1.2/CMakeLists.txt, 3rdparty/refice/CMakeLists.txt, 3rdparty/tmatrix/CMakeLists.txt: Detect Fortran compiler and set commandline options accordingly. Currently only gfortran is fully supported. g95 partially works. Throws an error for unsupported compilers. * KNOWN_ISSUES: Add note that compilation with g95 fails in some configurations. * config.h.cmake: Add FORTRAN_COMPILER. * src/main.cc (main): Add Fortran info to -v. 2013-08-08 Richard Larsson * arts-2-1-716 * src/linerecord.cc: Pass on NO quantum numbers for now. Will need more testing here it seems. 2013-08-08 Patrick Eriksson * arts-2-1-715 * src/m_tmatrix.cc (single_scattering_dataFromTmatrix): A version of single_scattering_dataCalcTMatrixTest, that potentially could be the basic WSM for T-matrix. Work in progress. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Some small changes in existing code to get the file to run. Added a second part calling single_scattering_dataFromTmatrix. 2013-08-08 Oliver Lemke * arts-2-1-714 * 3rdparty/disort1.2/ErrPack.f: Rename ErrMsg to DSErrMsg to avoid conflict with function in REFICE.f. * CMakeLists.txt, config.h.cmake: Check for f2c header. * src/CMakeLists.txt: Disable test_disort if f2c.h is unavailable. 2013-08-07 Patrick Eriksson * arts-2-1-713 * src/m_rte.cc (iyEmissionStandard): sibi was incorrect if stokes_dim > 1. Replaced (iv,0) with (iv,is) in for loop. * src/methods.cc: Reverted change in arts-2-1-695. That is, for jacobianAddPolyfit, changed default for no_pol_variation back to 0. This is the best default value. It is up to qpack2 to handle possible complications. 2013-08-07 Oliver Lemke * arts-2-1-712 * src/m_physics.cc, src/methods.cc: Add WSM ParticleRefractiveIndexIceWarren84. * 3rdparty/refice, 3rdparty/CMakeLists.txt, CMakeLists.txt, src/CMakeLists.txt, config.h.cmake, src/main.cc, src/physics_funcs.h: Add REFICE fortran routine. 2013-08-05 Patrick Eriksson * arts-2-1-711 * src/m_transmitter.cc (iyTransmissionStandard): y changed to y[is] at end of temparure jacobian part. Same fix as in arts-2-1-689. 2013-08-02 Johan Strandgren * arts-2-1-710 * src/optproperties.h: Updated the format of ScatteringMetaData. Added p_type, f_gridScat, T_gridScat and ref_index as generic inputs. * src/m_tmatrix.cc: (scat_data_meta_arrayAdd): Added a method for adding elements to scat_data_meta_array. (single_scattering_dataCalcTMatrixTest): expand to a vector of equiv_radius. * src/xml_io_compound_types.cc (xml_read_from_stream) (xml_write_to_stream): Adapted to changes of ScatteringMetaData. * src/methods.cc: added scat_data_meta_arrayAdd and adapted to changes of single_scattering_dataCalcTMatrixTest 2013-08-02 Jana Mendrok * arts-2-1-709 * src/methods.cc,workspace.cc: Replaced complex_n by complex_refr_index and surface_complex_refr_index. Renamed related WSM accordingly depending on intended usage (complex_nWaterLiebe93->complex_refr_indexWaterLiebe93, complex_nFromGriddedField4->surface_complex_refr_indexFromGriddedField4). * src/m_cloudradar.cc(iyCloudRadar), src/m_physics.cc(complex_nWaterLiebe93, ParticleRefractiveIndexWaterLiebe93), src/m_surface.cc(complex_nFromGriddedField4, surfaceFlatRefractiveIndex): Adapted to above name changes. * controlfiles/artscomponents/surface/create_gfields.m: Adapted to above name changes. * controlfiles/artscomponents/surface/TestSurface.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts, controlfiles/general/agendas_surface.arts: Adapted to above name changes. * doc/uguide/absorption.tex: Fixed broken links to AUG. Corrected line-mixing data example. 2013-08-02 Oliver Lemke * arts-2-1-708 * src/methods.cc, src/m_physics.cc: (ParticleRefractiveIndexWaterLiebe93): New method. (complex_nWaterLiebe93): Make method less chatty in out2. * doc/uguide/check_refs.py: Exit code should be 0 if no error occured. 2013-08-01 Jana Mendrok * arts-2-1-707 * src/m_abs.cc (propmat_clearsky_agenda_checkedCalc): Removed requirement for AddFaraday when free_electrons in abs_species (we might want them for refraction , not for faraday). (propmat_clearskyAddFaraday): Fixed error message. * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): Require basics_checked (non-geometry level; see below). In turn, remove local checks. * src/m_atmosphere.cc (basics_checkedCalcNoGeo): Reduced version of basics_checked without surface/geometry checks. Returns basics_checked=1 when passed. (basics_checkedCalc): Now returning basics_checked=2 when passed. (z_fieldFromHSE): Adapt to modified basics_checked behaviour. * src/m_cloudbox.cc (cloudbox_checkedCalc): Adapt to modified basics_checked behaviour. Moved check for no "particles" in abs_species further up. * src/m_doit2.cc(CloudboxGetIncoming2), src/m_montecarlo.cc(MCGeneral), src/m_cloudradar.cc(yCloudRadar), src/m_ppath.cc(ppathCalc, ppathFromRtePos2), src/m_rte.cc(iyCalc, iy_auxFillParticleVariables, yCalc), src/m_doit.cc(CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Adapt to modified basics_checked behaviour. * src/methods.cc(basics_checkedCalcNoGeo, basics_checkedCalc, propmat_clearsky_fieldCalc), workspace.cc(basics_checked): Adapted to changes above. 2013-07-31 Richard Larsson * arts-2-1-706 * src/lineshapes.cc: Made some constants const (faddeeva_algorithm_916). * src/linerecord.cc: Changed, hopefully fixed, a very strange bug in the NO quantum number HITRAN reading routine. 2013-07-25 Jana Mendrok * arts-2-1-705 * doc/uguide/absorption.tex: Added sections on propmat_clearskyAddFaraday and propmat_clearskyAddParticles. Added info on setting isotopologue_ratios. Moved input-to-LbL paragraphs into their own subsection (it's not only for LbL. and that way we have a proper place to document how to set iso ratios). Minor updates (it's propmat now!), rewording, re-layouting, spellfixes... * doc/uguide/references.bib: Zeeman paper added. * doc/uguide/absorption_theory.tex: Updated info on isotopologue ratios (not hard-coded anymore!) * doc/uguide/clouds.tex: Section label added. * doc/uguide/symbol_defs.tex: \chem makro added. * src/workspace.cc, methods.cc: Sorted some stuff in its (alphabetically) right place (particularly propmat*). In abs_speciesSet added clear note that order of tag groups matters. * src/gas_abs_lookup.cc (Adapt): Error message improved(?). 2013-07-23 Oliver Lemke * arts-2-1-704 * doc/uguide/Figs/abs/propmat_clearsky_agenda_detail.pdf: Updated. * doc/uguide/absorption.tex: Remove fixme. 2013-07-23 Oliver Lemke * arts-2-1-703 * src/m_tmatrix.cc, src/methods.cc: (single_scattering_dataCalcTMatrixTest): Add WSM that takes all parameters needed for Tmatrix calculations as input for easier testing. * src/tmatrix.{cc,h}: (calcSingleScatteringDataProperties): Don't pass ConstMatrixView as reference. * controlfiles/artscomponents/tmatrix/TestTMatrixSSD.arts: Add simple test case to calculate single_scattering_data for given parameters and save it to a file. * controlfiles/CMakeLists.txt: Add TestTMatrixSSD.arts. 2013-07-23 Richard Larsson * arts-2-1-702 * doc/uguid/absorption.tex: Zeeman is now a subsection of "Calculating gas absorption". This fix why line mixing was considered a subsection of Zeeman. 2013-07-23 Oliver Lemke * arts-2-1-701 * src/tmatrix.{cc,h}: Add checks for ref index size. * src/xml_io_compound_types.cc: Fix typo. * src/wigner_functions.cc (wigner3j): Add braces for outer if to avoid confusion where the inner else belongs to. (wigner9j): Return NAN to avoid warning. * src/test_matpack (test45): Use explicit cast to avoid warning. 2013-07-19 Jana Mendrok * arts-2-1-700 * src/methods.cc (propmat_clearskyAddParticles, propmat_clearskyAddFaraday): Added description. (propmat_clearskyAddZeeman, ParticleType2abs_speciesAdd, basics_checkedCalc): Spell fixed, more internal links, little rewording. * src/m_abs.cc (propmat_clearskyAddParticles, propmat_clearskyAddFaraday): Catch case of rtp_los not specified (happened when methods get called from propmat_clearsky_fieldCalc). * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): Temporary(?) bugfix. Do NOT require all 3 magfield components to be explicitly specified, but allow implicit zero-setting for separate components. This particularly circumvents silently ignoring magfield as happened with previous version. * doc/uguide/refr_index.tex: Added internal reference to Faraday section. 2013-07-16 Oliver Lemke * arts-2-1-699 * src/test_matpack.cc: Help gcc 4.2 to pick the right pow function. 2013-07-10 Oliver Lemke * arts-2-1-698 * src/file.{h,cc} (make_filename_unique): Add optional extension argument. Incrementing numbers are inserted before this extension. Also increase numbering if a gzipped version of the file already exists. * src/xml_io.cc (xml_write_to_file): Pass xml extension to make_filename_unique. 2013-07-10 Oliver Lemke * arts-2-1-697 * src/test_binaryio.cc, src/test_quantum.cc, src/test_sparse.cc, src/test_xml.cc: Adapt calls to WriteXML and xml_write_to_file. 2013-07-10 Oliver Lemke * arts-2-1-696 * src/methods.cc, src/xml_io.{h,cc}, src/xml_io_instantiation.h, src/m_xml.{h,cc}: Add option no_clobber to WriteXML and xml_write_to_file. Appends an incrementing number to the filename if it already exists. (WriteXMLNoClobber): Removed. Sorry Richard, I decided to make no_clobber a flag to WriteXML instead. * src/m_abs.cc (abs_lines_per_speciesWriteToSplitArtscat), src/m_batch.cc (ybatchMetProfilesClear), src/m_doit.cc (DoitWriteIterationFields), src/m_ppath.cc (ppathWriteXMLPartial): Adapt calls to WriteXML and xml_write_to_file. * src/m_xml.h (WriteXML): Add critical region around xml_write_to_file. * src/file.{cc.h} (make_filename_unique): Added. (file_exists): Make sure to return false if lstat call fails. * src/methods.cc: Add AgendaExecuteExclusive. * src/m_agenda.cc (AgendaExecuteExclusive): Renamed from ...Critical. 2013-07-09 Patrick Eriksson * arts-2-1-695 * src/methods.cc: For jacobianAddPolyfit, changed default for no_pol_variation from 0 to 1. This as a temporary fix to allow Qpack2 to be used with stokes_dim > 1. Need to think how this shall be handled. I assume that nobody is affected by this change. 2013-07-09 Richard Larsson * arts-2-1-694 * src/m_xml.{cc,h}: Dummy added (WriteXMLNoClobber). This does nothing now. * src/m_agenda.cc: Dummy added (AgendaExecuteCritical). Does nothing yet. 2013-07-09 Oliver Lemke * arts-2-1-693 * src/tmatrix.h (calcSingleScatteringDataProperties): Add public interface to header file. * src/tmatrix.cc: Add documentation for tmatrix_, ampl_ and avgtmatrix_. Make PI only visible in functions where it is used. * 3rdparty/tmatrix/ampld.arts.f: Move quiet parameter to group it together with other inputs. 2013-07-08 Richard Larsson * arts-2-1-692 * src/absorption.cc (xsec_species_line_mixing_2nd_order): Added test for line mixing inputs. Also changed provided input file in arts-xml-data. 2013-07-08 Oliver Lemke * arts-2-1-691 * src/m_linemixing.cc (ArrayOfLineMixingRecordReadAscii): Add check that the input stream is good(). Otherwise the last value gets added twice. 2013-07-05 Oliver Lemke * arts-2-1-690 The interface between ARTS and the T-Matrix Fortran codes, as well as providing the same functionality as PyARTS, is now pretty much completely. Except for calculating the refractive index, calcSingleScatteringDataProperties now does the same as SingleScatteringData.calc in PyARTS. TODO: - Integration of calcSingleScatteringDataProperties with the rest of ARTS, so that it can be practically used. - Better error handling if Fortran code fails. - Ensure all calls into the Fortran codes are threadsafe (via omp critical). * src/tmatrix.{cc,h}: (calcSingleScatteringDataProperties): Calculate Csca integral for oblate and prolate particles and from that K_abs. (integrate_phamat_*): Add gauss legendre integration for phamat over different angles thet0, phi, alpha. (calc_ssp_fixed_test, calc_ssp_random_test): Updated. 2013-07-05 Richard Larsson * arts-2-1-689 * src/m_rte.cc: Changed y to y[is] on line 913 and 915. 2013-07-04 Oliver Lemke * arts-2-1-688 * ChangeLog: Mixed up prolate/oblate in my previous two entries. * src/tmatrix.cc (integrate_phamat): Finished this function. 2013-07-04 Richard Larsson * arts-2-1-687 * src/m_zeeman.cc: Added some tests for 3D atmosphere and ppath_los being defined that was missing. Also made the test of quantum numbers print more information when the user defines Zeeman species that are not really Zeeman affected. 2013-07-04 Oliver Lemke * arts-2-1-686 * src/tmatrix.cc: (integrate_phamat): Add Gauss Legendre phase matrix interpolation. (calcSingleScatteringDataProperties): Calculate phase matrix for prolate particles. (calc_phamat): Remove unit conversion. Now done in ampmat_to_phamat. 2013-07-04 Oliver Lemke * arts-2-1-685 * src/tmatrix.{h,cc}: (calcSingleScatteringDataProperties): Started PARTICLE_TYPE_HORIZ_AL. Implemented calculation of phase matrix for oblate particles and extinction matrix for oblate and prolate particles. TBD: Csca integral to get abs_vec_data. Phase matrix for prolate particles. (tmatrix_fixed_orientation): Add wrapper for Fortran subroutine tmatrix_. (avgtmatrix_): Add fortran interface. (calc_phamat): Calculate phase matrix. (ampmat_to_phasmat): Renamed phasmat. Convert phase matrix to m^2. (calc_ssp_fixed_test): Add test for particles with fixed orientation. * 3rdparty/tmatrix/avg_tmatrix.f: Added from PyARTS. * 3rdparty/tmatrix/CMakeLists.txt: Add avg_tmatrix.f. * 3rdparty/tmatrix/tmd.lp.f: Output Csca and Cext. * 3rdparty/tmatrix/tmatrix_tmd.ref: Updated. * src/m_tmatrix.cc (TMatrixTest): Add calc_ssp_fixed_test. 2013-07-02 Oliver Lemke * arts-2-1-684 * src/tmatrix.cc: (calcSingleScatteringDataProperties): Port of PyARTS' calc_SSP function. Implemented particle type 20 and verified that results are consistent with PyARTS. (calc_ssp_test): Test function to compare results to PyARTS. (tmatrix_random_orientation): Convenience function for T-Matrix calculations of randomly oriented particles. Based on tmat_rnd in PyARTS. (tmd_): Add documentation. * src/tmatrix.h: Add calc_ssp_test. * src/m_tmatrix.cc (TMatrixTest): Call calc_ssp_test. * 3rdparty/tmatrix/tmd.arts.f: Comment out unhelpful info output. 2013-07-01 Richard Larsson * arts-2-1-683 * doc/uguide/references.bib, doc/uguide/absorption.tex: Added Zeeman explanation. Made line mixing explanation more exhaustive. I am not entirely certain if this is sufficient as documentation, but it should now explain the steps necessary to attain make the program run. 2013-06-27 Patrick Eriksson * arts-2-1-682 * controlfiles/artscomponents/zeeman/TestZeeman.arts: No change done. This test case now runs again, after the change below. But there is a deviation to reference data of -0.043 K, that is outside the set limit of 0.01 K. * src/m_zeeman.cc (Part_Return_Zeeman): Added "if( temp_lut.size() > 0 )", on line819. This fix suggested by Richard. 2013-06-26 Oliver Lemke * arts-2-1-681 * More work in progress on T-Matrix code. * 3rdparty/tmatrix/{ampld.lp.f, ampld.lp.f.orig, ampld.par.f, ampld.arts.f, tmatrix_ampld.ref}: Added T-Matrix codes for nonspherical particles in a fixed orientation. ampld.arts.f is based on the version in PyARTS. Added RAT as a parameter, renamed subroutines that are also present in tmd.arts.f to avoid duplicate symbol errors. Use LaPACK version of TT subroutine from ampld.lp.f. * 3rdparty/tmatrix/tmd.arts.f: Renamed from tmd.pyarts.f. * 3rdparty/tmatrix/CMakeLists.txt: Add ampld.arts.f to tmatrix library. Add target tmatrix_ampld for reference calculation. * 3rdparty/tmatrix/README: Updated. * 3rdparty/tmatrix/tmd.lp.f: Don't output time. It's incorrect. * src/tmatrix.{h,cc}: Add functions tmatrix_ampld_test, phasmat. Add declarations for Fortran subroutines tmatrix_ and ampl_. * src/m_tmatrix.cc (TMatrixTest): Add tmatrix_ampld.test. 2013-06-25 Oliver Lemke * arts-2-1-680 * src/tmatrix.cc, src/tmatrix.h, src/m_tmatrix.cc: Added. Basic integration of low-level T-Matrix codes for randomly oriented nonspherical particles. Fortran routine tmd can be called from ARTS and produces the same results as the reference example included with the original code. * 3rdparty/tmatrix/{README, License.txt, lpd.f, tmatrix_tmd.ref, tmd.lp.f, tmd.lp.f.orig, tmd.par.f, tmd.pyarts.f}: Added T-Matrix codes for randomly oriented nonspherical particles. For ARTS I rely on the same version as used by PyARTS. It has already been adapted to be called as a subroutine and results are identical to the latest version from the T-Matrix homepage. * 3rdparty/tmatrix/CMakeLists.txt: Add tmatrix_tmd executable. * README: Add ENABLE_FORTRAN option. * src/methods.cc: Add TMatrixTest for testing the T-Matrix code. * src/CMakeLists.txt: Add tmatrix.cc and m_tmatrix.cc to artscore. * config.h.cmake: Add ENABLE_TMATRIX. * controlfiles/CMakeLists.txt, controlfiles/artscomponents/tmatrix/TestTMatrix.arts: Add basic tmatrix test case. 2013-06-25 Patrick Eriksson * arts-2-1-679 * src/jacobian.cc (diy_from_path_to_rgrids): Removed variable r_grid, that was only used to make code somewhat simpler. Added and modified code to handle retrieval grids having length 1. 2013-06-25 Oliver Lemke * arts-2-1-678 * Preparations for better fortran integration. No more f2c. * 3rdparty/CMakeLists.txt, 3rdparty/disort1.2/CMakeLists.txt, 3rdparty/tmatrix/CMakeLists.txt: Added. * CMakeLists.txt: Remove f2c stuff. Add option ENABLE_FORTRAN. Add 3rdparty subdirectories. * src/disort_DISORT.h, src/m_disort, controlfiles/artscomponents/disort/TestDISORT.arts: Remove f2c stuff. Update for changes in arts. Needs more work, don't use. * controlfiles/CMakeLists.txt: Make disort controlfile available. Currently fails. * src/main.cc: Add info about tmatrix support to -v. 2013-06-21 Stefan Buehler * arts-2-1-677 * src/m_abs.cc, src/methods.cc (f_gridSelectFIndex): Removed, since this is obsolete with the new absorption lookup table frequency treatment. * doc/uguide/absorption.tex: Overall revision, added new intro and CIA part. * doc/uguide/common.tex: Removed deprecated dvips option from \usepackage{graphicx}. * doc/uguide/interpolation.tex (Higher order interpolation): Added paragraph on zeroth-order interpolation (nearest neighbor). * doc/uguide/references.bib (richard:12): Added. * doc/uguide/Figs/abs/plot_all_arts_cia_generic_1.pdf: Added. * doc/uguide/Figs/abs/plot_earth_continua_1_1.pdf: Added 2013-06-20 Oliver Lemke * arts-2-1-676 * src/xml_io.cc (xml_open_output_file, xml_read_from_file): Properly handle filenames that are 3 characters or less. * doc/uguide/Figs/abs/{abs_lookupCalc.pdf,abs_xsec_agenda.pdf, propmat_clearsky_agenda.pdf,propmat_clearsky_agenda_detail.pdf}, doc/uguide/absorption.tex: Add some absorbing flow charts. 2013-06-18 Patrick Eriksson * arts-2-1-675 * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: Removed old incorrect comment. 2013-06-19 Richard Larsson * arts-2-1-674 * src/wigner_functions.{cc,h}: Preparation for ECS line-mixing. Mathematical functions that calculate the wigner 3j and 6j functions. Not yet in use. * doc/uguide/absorption.tex: Some comments on how to use line-mixing. * src/absorption.{cc,h}: Changes in 2nd order line mixing routine to allow more pressure levels necessary for abs_lookup. Also, small changes in {h} for implementing different Q(T) calculations soon. 2013-06-18 Patrick Eriksson * arts-2-1-673 * controlfiles/planetary_toolbox/demos: Started this folder. * controlfiles/planetary_toolbox/demos/active/DemoLinkBudget.arts: A first attempt to a demo script. 2013-06-17 Patrick Eriksson * arts-2-1-672 * doc/uguide/rte_basics.tex: Same error as below here for vmr_field. * src/workspace.cc: It said incorrectly g/m3 for vmr_field and rtp_vmr, changed to kg/m3. 2013-06-14 Oliver Lemke * arts-2-1-671 * src/parameters.cc (get_parameters): Tweak helptext for docserver. 2013-06-14 Oliver Lemke * arts-2-1-670 * controlfiles/artscomponents/absorption/TestAbsDoppler.arts, controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts, src/m_abs.cc (WriteMolTau), src/m_abs_lookup.cc (abs_mat_fieldCalc), src/workspace.cc, src/methods.cc: Rename abs_mat_field and abs_mat_fieldCalc to propmat_clearsky_field and propmat_clearsky_fieldCalc. * src/m_abs_lookup.cc (propmat_clearsky_fieldCalc): Add mag_*_field as input. Add checks for magnetic field. Add los Vector as generic input. 2013-06-12 Patrick Eriksson * arts-2-1-669 * src/m_transmitter.cc (iyTransmissionStandard): Same changes as below. * src/m_rte.cc (iyEmissionStandard): ppath_awx now a pointer variable. Change after discussion with Oliver. Not sure if previous version was a bug or not. This would then affect u and w component wind jacobians. Removed k1 and k2 variables from T-jac part. 2013-06-12 Oliver Lemke * arts-2-1-668 * src/linerecord.cc (LineRecord::ReadFromHitran2004Stream): Allow one extra space at the end of the line. Workaround for formatting bugs in HITRAN 2012. 2013-06-11 Patrick Eriksson * arts-2-1-667 * Extension of analytical Jacobians ready. Memory usage decreased for larger calculations involving Jacobians or iy_aux (but the reversed can happen for small calculations). There should also be a slight speed improvement for analytical Jacobians. * doc/uguide/wfuns.tex: Some more details on temperature, general case. * src/m_transmitter.cc (iyTransmissionStandard): Changed to mimic iyEmissionStandard as far as possible. Old jacobian code removed. Replaced with code from iyEmissionStandard, but with all emission terms removed and no special treatment of Stokes 1 for unpolarised case. * src/m_rte.cc (iyEmissionStandard): New version now active. Code for Jacobians with polarised absorption in place. * src/m_transmitter.cc (iyRadioLink): * src/m_fos.cc (fos): * src/m_cloudradar.cc (iyCloudRadar): Adopted to change of get_ppath_abs. Required some reorganisation of code. * src/rte.cc (get_ppath_abs): Now two output variables. One with summed absorption, and one with "abs_per_species", but only for selected species. This in order to avoid repeated summation of absorption. Memory usage is also decreased, except when all species are either retrieved or their absorption is put into iy_aux. (get_ppath_trans2): Adopted to new version of ppath_abs. (get_ppath_trans): Adopted to new version of ppath_abs. Some internal variables could be removed. 2013-06-07 Patrick Eriksson * arts-2-1-666 * src/m_rte.cc (iyEmissionStandard2): Backup commit. Work in progress. 2013-06-05 Patrick Eriksson * arts-2-1-665 * src/m_rte.cc (iyEmissionStandard2): Temporary playground for extending WFs to also handle polarised absorption. 2013-06-05 Patrick Eriksson * arts-2-1-664 * Work to avoid repeated checks if ext_mat is diagonal. Mainly justified for extension of WFs, but should give a slight general speed improvement. * src/m_fos.cc (fos): * src/m_rte.cc (iyEmissionStandard): Adopted call of get_ppath_trans and emission_rtstep. * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): * src/m_cloudradar.cc (iyCloudRadar): Adopted call of get_ppath_trans. * src/rte.cc (get_ppath_trans, get_ppath_trans2): Adopted call of ext2trans, and added output argument to pass on icase. (emission_rtstep): Added input argument matching icase. This avoids a call of is_diagonal, for each frequency. * src/montecarlo.cc (mcPathTraceGeneral): * src/m_fos.cc (fos): Adopted call of ext2trans. * src/doit.cc (rte_step_doit): Adopted call of ext2trans, and using icase to remove a call of is_diagonal. * src/rte.cc (ext2trans): The found structure of ext_mat is now returned, as *icase*. If icase already known, that information can also be provided to save time. 2013-06-04 Patrick Eriksson * arts-2-1-663 * doc/uguide/wfuns.tex: Corrected some mistakes from writing earlier today. Resurrected some text about more fully handling the vector case analytically. 2013-06-04 Patrick Eriksson * arts-2-1-662 * doc/uguide/wfuns.tex: A complete rewrite of the analytical expressions. Now common terms are really discussed first, and separately. And the complete calculation procedure is represented mathematically. Hopefully more easy to understand what is actually done, and the difference between unpolarised and polarised more clearly separated. 2013-06-03 Patrick Eriksson * arts-2-1-661 * src/m_sensor.cc (sensor_responseMixer): Check of symmetry of response grid allowed a margin on 1kHz, but that cause problems in the core functions. Now no margin allowed. Safest, and simplest for the implementation. This opens for potential practical problems due rounding errors in files etc., but hopefully possible to handle ... 2013-05-31 Patrick Eriksson * arts-2-1-660 * src/rte.cc (ext2trans): Added comment explaining why assert( ext_mat(0,0) >= 0 ); is removed. * src/m_atmosphere.cc (basics_checkedCalc): Added argument negative_vmr_ok. If false, vmr_field now demanded to be >= 0. This is set to be default. Note the difference for t and vmr: t>0 while vmr>=0 Made also search for negative f_grid more efficient. Just needed to check for element when the vector is known to be increasing. 2013-05-30 Patrick Eriksson * arts-2-1-659 * src/rte.cc (ext2trans): Commented out assert( ext_mat(0,0) >= 0 ); This assert made qpack2_demo in atmlab to fail. I guess due to negative vmr. Uh, not sure how to handle this and removing the assert to avoid the problem for the moment! 2013-05-29 Patrick Eriksson * arts-2-1-658 * doc/uguide/wfuns.tex: A number of smaller corrections. 2013-05-29 Patrick Eriksson * arts-2-1-657 * doc/uguide/wfuns.tex: More rewriting. * doc/uguide/arts_user.tex: Changed position of WF chapter. 2013-05-29 Oscar Isoz * arts-2-1-656 * src/rte.cc (ext2trans) : Fixed a sign error in the assertion between ext_mat(3,0) and ext_mat(0,3) (removed the '-' sign) 2013-05-29 Patrick Eriksson * arts-2-1-655 * doc/uguide/wfuns.tex: Started to restructure the presentation of analytical expressions, with the aim of getting matching expressions for scalar and vector cases. 2013-05-27 Patrick Eriksson * arts-2-1-654 * doc/uguide/wfuns.tex (subsubsection{General case}): Finished a first version of this sub-section, dealing with absorption WFs with polarised absorption. 2013-05-26 Oscar Isoz * arts-2-1-653 * src/sensor.cc (find_effective_channel_boundaries): Minor bugfix found just after the last commit * src/m_sensor.cc (f_gridFromSensorAMSUgeneric): Fixed an issue with how the passband frequency grid is calculated * src/m_sensor.cc (sensor_responseGenericAMSU): Found (and fixed) a discrepancy in how the properties of the AMSU-A sensor is saved in amsua.arts vs how it is used in this function. Introduced a slight reduction in the effective bandwidth of the channels by 60 Hz in order to avoid for them to merged by f_gridFromSensorAMSUgeneric (this was donet to save computational time and make more room for optimisations of the frequency grid) 2013-05-24 Patrick Eriksson * arts-2-1-652 * doc/uguide/references.bib: Added Dattorro2011. * doc/uguide/wfuns.tex (subsubsection{General case}): Further work. Had to change strategy somehwat. 2013-05-23 Patrick Eriksson * arts-2-1-651 * doc/uguide/wfuns.tex: Changed to use Jacobian in preference of weighting functions. Some rearrangement to introduce expressions for polarised absorption. * doc/uguide/rte.tex: Some typos from last commit, and expanded slightly around calculation of matrix exp. 2013-05-23 Oliver Lemke * arts-2-1-650 * src/logic.cc: (is_increasing): Adapt the if statement so that the functions correctly return false if the Vector contains NaN values: if( x[i] <= x[i-1] ) return false; -> if( !(x[i] > x[i-1]) ) return false; Although logically the same for floating point numbers, the second implementation behaves correctly for NaN values because any comparison with NaN returns false. (is_decreasing, is_sorted): Same. * src/test_matpack.cc: Add test44 to check above changes. 2013-05-23 Patrick Eriksson * arts-2-1-649 * src/check_input.cc (chk_atm_field): Error now thrown if field contains NaNs. Implemented for both versions of the function. 2013-05-23 Patrick Eriksson * arts-2-1-648 * doc/uguide/rte_basics.tex: * doc/uguide/rte.tex: Replaced a few B with \Planck. * doc/uguide/wfuns.tex: Included a high number of "symbold_defs". * doc/uguide/CMakeLists.txt: Added symbol_defs.tex dependencies. * doc/uguide/symbol_defs.tex: Removed some odd, and not used, definitions. Fixed some comment typos. Bold i was used both for Stokes vector and total vector of pencil beam monochormatic data, so to avoid this clash redefined as follows \PpathLng: s changed to l \StoVec: i changed to s Added: \SttElm with friends and \Trn with friend. 2013-05-22 Jana Mendrok * arts-2-1-647 * controlfiles/planetary_toolbox/includes/mars/*.arts: Added include files for getting Mars atmospheric setups (selecting scenario and species/parameters to include, reading in, and bringing to calculation grids). * controlfiles/planetary_toolbox/Test{planet}Atmo.arts: Moved the previous My{planet}.arts from their respective directories to here as these are the templates for the actual main controlfiles (we don't want to hide them too far down). Made all includes absolute (allow to use or include this file from anywhere). * controlfiles/planetary_toolbox/includes/venus/[getatmo_venus,getwind].arts, controlfiles/planetary_toolbox/includes/common/createvars.arts: Minor docu- and bug-fixes. 2013-05-22 Oscar Isoz * arts-2-1-646 * src/sensor.cc (find_effective_channel_boundaries): Modified the code so that it can ignore frequencies where the filter response explicitly is set to zero, particularly useful for the AMSU-A channels. * src/m_sensor.cc (f_gridFromSensorAMSUgeneric): Added support to have set a separate frequency grid spacing for each channel * src/m_sensor.cc (sensor_responseGenericAMSU): Minor bugfixes, main change was to make the slopes of edges of the backend_channel_response f_grid edges constant. * controlfiles/CMakeLists.txt, instruments/amsu/TestAMSUA.arts : Added AMSU-A test case, not run by default yet 2013-05-22 Jana Mendrok * arts-2-1-645 * src/m_atmosphere.cc (GriddedFieldLatLonRegrid): Bugfix. Added check for new lat/lon_grids not empty in the beginning, before any of them is tried to be used. * src/m_abs_lookup.cc (abs_mat_fieldCalc), methods.cc,workspace.cc: Minor updates of variable namings and variable descriptions. 2013-05-21 Jana Mendrok * arts-2-1-644 * controlfiles/planetary_toolbox/includes/[common,jupiter,venus]/*.arts: Added a couple of controlfiles (of includes nature) for getting atmospheric setups (selecting scenario and species/parameters to include, reading in, and bringing to calculation grids). My{planet}.arts is the respective main file for each planet. It's supposed to be used as template - i.e., for usage, make a copy of it and modify according to your wishes. It's work in progress, some things not in satisfying state yet (too much room for bugs/breaking the file), evaluating better options. 2013-05-21 Richard Larsson * arts-2-1-643 * src/partition_function_data.cc: Defines partition function type in the defaults to allow for other types of partition functions. * src/absorption.h: Changed mqcoeff to a Vector and added some more variables. These are: mqcoefftype which is defined from the public enum and influences what type of partition function will be used in the switch added to (alculatePartitionFctRatio) to change between the previous standard way of only allowing coefficients in the now called (CalculatePartitionFctAtTempFromCoeff) to also allowing gridded funtions that can be interpolated in (CalculatePartitionFctAtTempFromData). To use the new FromData function it is necessary to specify the grid, the data and the interpolation order in present design, together with the partition function type. * src/absorption.cc: Here (CalculatePartitionFctAtTempFromData) is defined. * src/methods.cc: Added format documentation to (ArrayOfLineMixingRecordReadAscii). 2013-05-20 Oliver Lemke * arts-2-1-642 * src/m_basic_types.h: Add missing Array types for nelemGet. 2013-05-17 Patrick Eriksson * arts-2-1-641 * Work on MC, to finish changes to just use ext2trans. Used a calculation with 200e3 photons to check that result not changed. (ext2trans and matrix_exp_p30 also compared directly). The change made MC 1-2% slower, but MC can now handle any ext_mat (at least for this step, before p30 or simpler was assumed) and now ext_mat is asserted carefully. * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: Uptaed references values to 198.7 and 7.9 K, assuming that this file should give same result as the one below. * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: Updated reference value to 198.7, which was the combined result of two 200k photon runs, see above. * src/m_general.cc (Test): Commenetd out present test code (as using matrix_exp_p30. * src/montecarlo.cc (matrix_exp_p30): Moved to mc_NotUsed.cc. * src/montecarlo.cc (mcPathTraceGeneral): Switched to use ext2trans, that required some internal changes (opp_depth_mat -> ext_mat). * src/rte.cc (ext2trans): Synced header with content. Removed old version of the function. 2013-05-17 Patrick Eriksson * arts-2-1-640 * Started to clean up conversion of extinction to transmission. Beside for MC, this is now only done by ext2trans. One step forward is that ext2trans checks all expected symmetries of ext_mat. Also tried to make it faster by using special expressions for "p30". In matlab the special expressions are one order of magnitude faster than Pade, but the overall improvement in ARTS is only marginal. Hence, ARTS' Pade-approximation is very fast, or the matrix exponential is not a calculation bootleneck. * src/lin_alg.cc (matrix_exp): Only Pade-approximation is now done. Special treatment of diagonal matrices removed, now checked before calling the function. * src/montecarlo.cc (matrix_exp_p30): Several terms calculated twice, now instead copied. * src/mc_interp.cc (interpTArray): Moved to mc_NotUsed.cc. * src/m_fos.cc (fos): Now using ext_mat, instead of matrix_exp. And also using the flag introduced below. * src/doit.cc (rte_step_doit): Now takes a flag telling if trans_mat is already calculated. Now using ext_mat, instead of matrix_exp. * src/rte.cc: Removed declaration of unused constants. (get_ppath_trans, get_ppath_trans2): Now using ext_mat, instead of matrix_exp. (ext2trans): Rewritten and extended. Expected symmetry of ext_mat now fully checked. Matrix exponential calculated in three different ways depending on structure of ext_mat. The three cases are diagonal, "p30" and general. For p30 special expressions are used, following matrix_exp_p30 and double-checked with a text book. 2013-05-16 Patrick Eriksson * arts-2-1-640 * src/rte.cc (ext2transNEW): New version of the function below, with the aim of introdocing special expressions, as well as more asserts. Not yet used. (ext2trans): Discovered that the function is not used as planned. matrix_exp called instead. Work to do ... 2013-05-13 Patrick Eriksson * arts-2-1-639 * src/m_physics.cc (complex_nWaterLiebe93): Updated comment. Changed 146.4 to 146, to be consistent with paper, and eps_water_liebe93 in atmlab. 2013-05-13 Oliver Lemke * arts-2-1-638 * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: Include planet_mars.arts instead of planet_venus.arts. 2013-05-08 Richard Larsson * arts-2-1-637 * src/lineshapes.cc: Confirmation on which order Faddeeva's frequency grid should be arranged. It is the opposite of how Jefferies etal wrote it down. Changed the function Accordingly * src/m_zeeman.cc: Made this compatible with line-mixing. Differences of 1 K in the Bern test simulations followed. * src/absorption.cc: Better comments now. 2013-05-08 Oliver Lemke * arts-2-1-636 * src/groups.cc: Add ArrayOfLineMixingRecord. * src/m_linemixing.cc, src/methods.cc: Split the reading of line mixing data from the matching process. See builtin docs of ArrayOfLineMixingRecordReadAscii and line_mixing_dataMatch. * src/m_abs.cc (abs_lines_per_speciesCreateFromLines): Cosmetics. 2013-05-06 Oliver Lemke * arts-2-1-635 * src/rational.{h,cc}: (Rational::Rational(int)): Add conversion ctor for int. (bool()): Removed. Conversion operators are evil for all the pitfalls they bring along, so let's get rid of them. (Numeric()): Renamed to toNumeric(); (Index()): Renamed to toIndex(). Change the assert to a runtime error. Otherwise invalid conversions from Rational to Index will go unnoticed in non-debug mode. E.g. 3/2 would be silently converted to 3. Simplify code by not calling Simplify() (on a copy of the object). Rational objects are always immediately simplified when they're modified or initialized, no need to do it here again. Move implementation to cc file. Get rid of arithmetic and boolean operators where second argument is not a Rational. They were only implemented in one direction, e.g. Rational + Index worked but not Index + Rational. Instead of implementing a dozen more operators, let's get rid of them altogether. Sometimes less is more: By removing the conversion operators, all the operations work in both directions (Index+Rational and Rational+Index). Because now, the compiler has no other choice than converting the other argument into a Rational. Exactly what we want! Moved all operators that don't modify the object outside the class. Only implement full logic for operator== and operator<. Implement all other boolean operators by calling those two. (assignment operators): Should always return a reference to the object itself. Assignment operator with Index no longer needed. Uses converting ctor implicitly. * src/m_zeeman.cc: Use Rational::toNumeric. * src/quantum.h (QuantumNumbers::operator[]): Change return type to const. * src/interpolation_poly.cc: Do same caching for LOOPIDX as for LOOPW. Move the CACHE* statements from the innermost loop to the outer loops right after the corresponding variables definition. * src/test_matpack.cc: Add test43 for Rational. 2013-05-06 Patrick Eriksson * arts-2-1-634 * doc/uguide/Figs/rte/ycalc_flow.odg: abs_mat_per_species_agenda changed to propmat_clearsky_agenda. 2013-05-02 Oliver Lemke * arts-2-1-633 * src/groups.cc: Add ArrayOfArrayOfLineMixingRecord. * src/workspace.cc: Change type of line_mixing_data to ArrayOfArrayOfLineMixingRecord. * src/linemixingrecord.{cc,h} (LineMixingRecord): Implement class. * src/absorption.{h,cc} (xsec_species_line_mixing_wrapper, xsec_species_line_mixing_2nd_order), src/m_abs.cc (abs_xsec_per_speciesAddLines), m_linemixing.cc (line_mixing_dataInit, line_mixing_dataRead), src/m_zeeman.cc (propmat_clearskyAddZeeman): Adapt for type change of line_mixing_data from ArrayOfArrayOfVector to ArrayOfArrayOfLineMixingRecord. * src/m_linemixing.cc (line_mixing_dataRead): Read the species tag from the line mixing data file. Improved parsing of data values. * src/absorption.{h,cc} xsec_species_line_mixing_2nd_order): Change local variables data and lut to reference type to avoid unnecessary copying of arrays. * src/make_auto_md_h.cc, make_auto_workspace_h.cc: Include linemixingrecord.h in generated code. * src/xml_io_compound_types.cc, src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add IO routines for LineMixingRecord, ArrayOfLineMixingRecord and ArrayOfArrayOfLineMixingRecord. * src/test_quantum.cc: Updated. 2013-05-02 Oliver Lemke * arts-2-1-632 * src/nc_io_array_types.cc, src/nc_io_compound_types.cc, src/nc_io_instantiation.h, src/nc_io_types.h: Cleanup. Get rid of all dummy implementations for non-supported types. In contrast to WriteXML, WriteNetCDF is only defined for a limited set of types. Only those need to be defined. * src/matpackI.{h,cc} (Vector): Add converting constructor from std::vector. 2013-05-02 Patrick Eriksson * arts-2-1-631 * src/m_fos.cc (fos): Shit, by copy and paste one for-loop became wrong (used nfs instead of nf). Caused a bug with use_mean_scat_data set to true (a case I had not tested). * src/rte.cc (get_ppath_ext): Extended header test, to be clearer around use_mean_scat_data. * controlfiles/general/general.arts: use_mean_scat_data now set here, to 0. * src/m_cloudbox.cc (cloudboxOff): Now NOT setting use_mean_scat_data. As not a standard variable, and not checked by cloudbox_checkedCalc. 2013-04-29 Oliver Lemke * arts-2-1-630 * src/quantum.{h,cc}: Don't include arts.h, just matpack.h. Remove empty default constructors. (QuantumNumbers): Implement input operator. Update output operator. * src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Implement xml io routines for QuantumNumberRecord and QuantumNumbers. * src/rational.h: Use element initialization list in constructors. Remove copy assignment operator. The implicit one will do just fine. Remove assignment operator for int. * src/linemixingrecord.{cc,h}: Add stub for line mixing data class. * src/CMakeLists.txt: Add linemixingrecord.cc to artscore. * src/test_quantum.cc: Updated. * src/doit.cc (cloud_RT_no_background): Get rid of the pointers for swapping around the two propmat_clearsky instances. Use the new swap() function instead. More readable code. 2013-05-02 Patrick Eriksson * arts-2-1-629 * controlfiles/artscomponents/doit/TestDOIT.arts: Adopted to renamed agenda. * controlfiles/general/agendas_surface.arts: Changed NoPol to Pol for surface_rtprop_agenda__Specular_Pol_Water_SurfTFromt_field. This agenda is based on surfaceFlatRefractiveIndex, that is of polarised nature. * src/methods.cc: Corrected several typos for surfaceFlatReflectivity. 2013-05-02 Stefan Buehler * arts-2-1-628 * src/gas_abs_lookup.cc (GasAbsLookup::Extract): Pre-calculate interpolation weights outside species loop for speed optimization. 2013-05-02 Patrick Eriksson * arts-2-1-627 * src/rte.cc (get_ppath_f): Added more comments to the function. To hopefully in the future avoid confusion about the signs to apply for the terms. For a moment I got lost here ... 2013-05-01 Oliver Lemke * arts-2-1-626 * src/matpack*.h (*::get): Add a non-asserting element accessor to Vector, Matrix and Tensor* View classes. Should only in places were maximum speed is of the essence. * src/interpolation.{h,cc}: Cache the begin() and end() iterators in loops. Use the matpack get function inside the loops. Speeds up interpolation, especially the GasAbsLookup::Extract function. For example, arts.ctlfile.slow.amsub runs 30% faster. * src/m_rte.cc (yCalc), src/rte.cc (iyb_calc): Tweak OpenMP loop condition for cases where the number of frequencies is smaller than nmblock and nza. 2013-05-01 Oliver Lemke * arts-2-1-625 * src/absorption.cc (xsec_species): Fix bug for lineshapes that don't calculate phase information. ls_phase was never initialized and garbage values where used in later calculations. this_ls_phase *= this_fac was up to 2 times slower under some circumstances (mostly in the profiler) when t_l_p contained garbage. Further phase calculations are now skipped if the chosen lineshape doesn't return phase. Still some memory allocation overhead left. Would be much nicer to be able to pass in a zero-sized xsec_phase to skip the phase calculations altogether. But that's tricky with the current use of Views. Removed variables base_attenuation and base_phase as they were only used in one place. * src/m_abs.cc (abs_xsec_per_speciesAddLines): Don't make a full copy of another variable and then set it to zero. Instead use the appropriate constructor to create it with the right size and value in one go. 2013-05-01 Oliver Lemke * arts-2-1-624 * src/make_auto_md_cc.cc: Add assertion to *_agendaExecute functions to make sure the input_agenda is valid. * src/agenda_class.h (checked): Add access function. 2013-04-30 Patrick Eriksson * arts-2-1-623 * src/m_fos.cc (fos): Now using ext_matFromabs_vec. * src/rte.cc (get_iy_of_background): Added chk_not_empty call for all agendas used. To catch highly non-standard usage where dummy agendas can end up to being called. * src/check_input.cc: Type for x was wrong for most chk_size functions. 2013-04-30 Jana Mendrok * arts-2-1-622 * src/optproperties.[cc,h] (ext_matFromabs_vec): Added. Method for deriving/setting an extinction matrix from the absorption vector. * src/m_abs.cc (propmat_clearskyAddParticles): Replacing own code for extinction matrix from absorption vector by ext_matFromabs_vec. 2013-04-30 Oliver Lemke * arts-2-1-621 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag): I hate BSD for providing an isnumber function. s/isnumber/isdigit/ 2013-04-30 Oliver Lemke * arts-2-1-620 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag): Make parsing of SpeciesTag strings more robust. Invalid frequency numbers where silently ignored. Same for wrong placement of Zeeman tag. It must be located after the species, not after the isotopologue. 2013-04-30 Patrick Eriksson * arts-2-1-619 * src/m_fos.cc: Now also fos_za_interporder considered. 2013-04-30 Jana Mendrok * arts-2-1-618 * Nicer (not mis-using pnd_field) version of handling particles as absorbing-only, reverting obsolete parts of the older version. Now EACH particle type is added as an instance to abs_species, with its pnd field going into the corresponding vmr_field(_raw) entry. Single scattering data continue to be hold in scat_data_raw (we disallow parallel usage of "particles" in abs_species and scattering (i.e., cloudbox on) calculations). A new method added - ParticleType2abs_speciesAdd - corresponding to ParticleTypeAdd (corresponding version of ParticleTypeAddAll to come soon), which adds a "particle" instance to abs_species, reads the single scattering data, reads and appends pnd data to vmr_field_raw. * src/m_abs.cc (propmat_clearskyAddParticles): Adapted for looping over abs_species, handling multiple "particles" instances therein (provinding propmat_clearsky separately for particle type). * src/m_cloudbox.cc (cloudbox_checkedCalc): Added check that abs_species has not "particles" while cloudbox is on. * src/abs_species_tags.cc (check_abs_species): Removed obsolete requirement of only one "particles" instance in abs_species. * src/rte.[cc,h] (get_ppath_atmvars, get_ppath_abs): Removed parameters ppath_pnd, pnd_field, cloudbox_on. * src/m_rte.cc (iyEmissionStandard), m_cloudradar.cc (iyCloudRadar), m_transmitter.cc (iyRadioLink, iyTransmissionStandard) m_fos.cc (fos): Removed ppath_pnd, pnd_field, cloudbox_on from calls of get_ppath_atmvars and get_ppath_abs. * src/agendas.cc (propmat_clearsky_agenda), montecarlo.cc (clear_rt_vars_at_gp, cloudy_rt_vars_at_gp), disort.cc (dtauc_ssalbCalc), m_abs_lookup.cc (abs_mat_fieldCalc) doit.cc (cloud_RT_no_background, cloud_ppath_update1D_planeparallel): Removed obsolete usage of rtp_pnd in propmat_clearsky_agenda call. * src/workspace.cc: Removed rtp_pnd. * src/m_atmosphere.cc (basics_checkedCalc): Removed pnd_field checks and method parameters pnd_field, cloudbox_on. * src/cloudbox.[cc,h] (chk_pnd_data, chk_pnd_raw_data): Remove obsolete parameters p_grid, lat_grid, lon_grid. * src/m_append.h (Append): Added a version for Tensor-to-Tensor append (leading dimension only). Needed for appending (modified) data (like profiles/fields of a single absorbing species) to vmr_field. * src/array.h: spell fix. * src/methods.cc: Adapted to changes above. * controlfiles/general/agendas.arts, controlfiles/artscomponents/doit/TestDOIT.arts, doitbatch/TestDOITBatch.arts, helpers/TestAgendaCopy.arts, montecarlo/TestMonteCarloGeneralGaussian.arts, faraday/TestFaradayRotation.arts: Removed rtp_pnd usage in propmat_clearsky_agenda definitions. * controlfiles/general/general.arts: Removed obsolete pnd_field=0 and cloudbox_on=off settings. 2013-04-29 Oliver Lemke * arts-2-1-617 * src/m_rte.cc (iyMC): Fix parallelization of frequency loop. There is no further parallisation in the MonteCarlo code, therefore it is best to parallelize for nf>1 instead of nf>max_threads. 2013-04-29 Stefan Buehler * arts-2-1-616 * Implemented frequency interpolation in lookup table extraction, to allow for more elegant Doppler shift treatment. * src/gas_abs_lookup.{h,cc} (GasAbsLookup:fgp_default): Added this new member, which holds the trivial frequency grid positions (without frequency interpolation). (GasAbsLookup::Adapt): Initialize fgp_default. (GasAbsLookup::Extract): Implemented frequency interpolation. Required significant reorganization. The new philosophy is to first determine grid positions for all dimensions, including trivial grid positions in case a dimension should not be interpolated. Then the code for the interpolation itself (calculate weights and interpolate) can be the same for all cases. So, overall messiness somewhat reduced. * src/rte.cc (get_ppath_abs): Get rid of rtp_doppler, directly pass ppath_f to propmat_clearsky_agendaExecute. (get_ppath_f): Inverted the sign of the Doppler shift. For absorption features to shift to higher frequencies, the calculation grid for the absorption calculation has to be shifted to lower frequencies. With this change, the TestWinds control file gives the same result as before. Patrick, please confirm my change. * src/montecarlo.cc: Adapted. * src/disort.cc: Adapted. * src/doit.cc: Adapted. Also removed or commented-out some cout command that seem to be old debugging remnants. * src/interpolation_poly.cc (gridpos_poly): Implemented nearest neighbour interpolation (interpolation order 0). This is very handy, because it can be used to make interpolation code robust to the case that a particular dimension should not be interpolated at all. * src/test_interpolation.cc: Test the new order 0 interpolation. * src/main.cc (arts_mod_time): Added "compiled" to give some indication what the date/time means. (main): Added a copy of the command line to the report output. My main reason is that I wanted see the name of the control file from the report file. But perhaps also useful to see what other switches were used. * src/workspace.cc (rtp_doppler): Removed. Bye-bye. * src/methods.cc (propmat_clearskyAddFromLookup) (propmat_clearskyAddOnTheFly, propmat_clearskyAddZeeman): Removed input argument rtp_doppler. Updated documentation. * src/agendas.cc (propmat_clearsky_agenda): Removed input argument rtp_doppler. * src/m_abs.cc (propmat_clearskyAddOnTheFly): Removed input argument rtp_doppler and code handling it. * src/m_zeeman.cc (propmat_clearskyAddZeeman): Removed input argument rtp_doppler and code handling it. * src/m_abs_lookup.cc (abs_lookupCalc): Initialize fgp_default. (propmat_clearskyAddFromLookup): Added input argument abs_f_interp_order. Considerably simplified the function itself, since more work is now done in GasAbsLookup::Extract. (abs_mat_fieldCalc): Adapted. Also renamed all ampsXXX variables back to absXXX. This method still takes Doppler shift as input (it is just used for plotting and testing purposes, where this is handy). It constructs a new frequency grid and calls propmat_clearsky_agendaExecute with it. A remark: It would make sense to get rid of the Stokes dimension in abs_mat_field. abs_mat_fieldCalc can anyway not handle effects that would cause polarization, so only the (1,1) element of the absorption matrix (propmat_clearsky) is of interest here. And then revert both to their old names (abs_field and abs_fieldCalc). (calc_lookup_error): Adapted. * controlfiles/artscomponents/absorption/TestAbsDoppler.arts: Adapted and tested. * controlfiles/artscomponents/doit/TestDOIT.arts: Cosmetics. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Set abs_f_interp_order to 1, to avoid runtime error with wind Jacobians. 2013-04-29 Patrick Eriksson * arts-2-1-615 * src/m_rte.cc (iyEmissionStandard): Added Transmission as aux var. * src/methods.cc: Polishing of escription of Transmission and Optical dept aux variables * ChangeLog: Slight edit of message for 2-1-613 to make clear that the comment refers to a specific method, and not generally for the file. 2013-04-29 Oliver Lemke * arts-2-1-614 * ChangeLog: Fix version numbers in previous two commits. 2013-04-29 Mathias Milz * arts-2-1-613 * src/m_sensor.cc (sensor_responseWMRF): removed the check if the f_grid is inside the sensor_reponse_function. This is apparently obsolete. 2013-04-29 Richard Larsson * arts-2-1-612 * src/lineshapes.cc: Made the lorentz function slower by calculating the phase shape function as well, which is necessary for Zeeman and line mixing. * src/absorption.cc (xsec_species_line_mixing_2nd_order): Fixed error in the mathematics that ignored the first-order line-mixing. Also, it only accepts calculations if the specified line-shape returns the phase, as this is necessary for line-mixing. Also, now takes data in SI units. The data will soon be added to arts-xml-data. 2013-04-28 Oliver Lemke * arts-2-1-611 * src/matpack*.{h,cc}: (Sparse): Don't use pointer variables for the members mdata, mrowind and mcolptr. Several advantages: No custom memory management needed -> Copy constructor, copy assignment operator and destructor removed. Code is much more readable. (mult, transpose): Non-const iterators were used to loop over elements of the const input parameter. (*Iterator*): Remove copy constructor from all Iterator classes. The implicit one generated by the compiler does just fine. And in C++11 the presence of a custom copy constructor will prevent the generation of an implicit move constructor. Might give better performance. (Vector, Matrix, TensorX): Change the argument type of the assignment operator from a const reference to a call by value. This way, we can let the copy constructor do the work instead of duplicating its initialization code in the assignment op. Additionally, with this implementation, the copy assignment operator will also work as a move assignment operator in C++11. And this implementation is exception safe. With the previous one, if the copy operation failed, the current object was left in an undetermined state. Add swap function to swap two objects. * src/xml_io_basic_types.cc: Adapt for Sparse changes. * src/matpack.h: Include debug.h * src/debug.h: Include iostream, add some std::. * controlfiles/instruments/odinsmr/yREFERENCE*.xml: Add ref values. * controlfiles/instruments/odinsmr/TestOdinSMR*.arts: Compare y against reference. * src/m_fos.cc (fos): Add explicit cast to Numeric for 'nin' in division to silence compiler warning. 2013-04-28 Patrick Eriksson * arts-2-1-610 * src/m_fos.cc: A complete version. So far only 1D only, and just a few rudimentary checks made. * src/doit.h: Included rte_step_doit. * src/doit.cc (rte_step_doit): Removed some inactive old lines. 2013-04-27 Oliver Lemke * arts-2-1-609 * src/test_complex.cc, src/test_gridded_fields.cc, src/test_linalg.cc src/test_matpack.cc, src/test_tensor.cc: Forgot to fix the test_* files in previous commit. * src/describe.{cc,h}: Use our String class instead of the standard string. Good example for a type error that went unnoticed before because std::string was visible everywhere although we don't want to use it. 2013-04-26 Oliver Lemke * arts-2-1-608 * src/matpack.h: Remove 'using namespace std;' from header. It is bad practice because it pollutes the global namespace of every file it is included by. Removing it here makes at least matpack behave nicely. Still present in arts.h. * src/array.h src/complex.{cc,h}, src/exceptions.h, src/fastem.cc, src/file.h, src/gridded_fields.{cc,h}, src/make_array.h, src/matpack*.{cc,h}, src/mystring.h, src/rational.{cc,h}, src/sourcetext.{cc,h}: In header files, add prefix std:: to all entities from the std namespace. In cc files, it is ok(ish) to use 'using namespace std;'. But it is preferable to only import what is actually used. This can be done at the beginning of the file after the include directives, e.g. 'using std::runtime_error;'. * src/sourcetext.cc (operator<<): Write to os not cout. * src/jacobian.h (RetrievalQuantity): Remove unneeded copy constructor. Change type of grids argument in constructor from MakeArray to ArrayOfVector. * src/m_jacobian.cc: Remove unnecessary assignments of RetrievalQuantity() in variable definitions. 2013-04-26 Patrick Eriksson * arts-2-1-607 * src/m_fos.cc: Extended, but still not complete. * src/methods.cc: GIN for sensor_responseBackendFrequencySwitching had inconsistent names. * src/workspace.cc: Introduced fos_scatint_angles and fos_iyin_za_angles. 2013-04-26 Oliver Lemke * arts-2-1-606 * src/linerecord.{cc,h}: Added. Move LineRecord class from absorption.{cc,h} into its own file. It's a large class and absorption.{h,cc} became very cluttered. Also moved all method documentation from the cc into the header file. (LineRecord::ReadFromHitranStream): Rename to ReadFromHitran2001Stream to be consistent with ReadFromHitran2004Stream. * src/m_abs.cc (abs_linesReadFromHitranPre2004): Call lr.ReadFromHitran2001Stream. * src/absorption.{cc,h}: Remove LineRecord class. Remove unnecessary includes. Include linerecord.h. * src/mystring.h: Moved extract helper function from absorption.cc to here. It is not specific to absorption and might be handy for other cases. * src/CMakeLists.txt: Add linerecord.cc to artscore. 2013-04-26 Oliver Lemke * arts-2-1-605 * src/continua.{cc,h}: Move definition of constant variables with model data to .cc file. Reduces header file size by 200kB. 2013-04-26 Patrick Eriksson * arts-2-1-604 * src/m_cloudradar.cc: * src/m_fos.cc: * src/m_transmitter.cc: * src/m_rte.cc: Adopted all calls of get_ppath_abs. * src/rte.cc (get_ppath_abs): Introduced only_sum_abs. This flag can be set to true when only summed absorption is needed, that in some cases will save considerable amount of memory. Cases where this flag must be false is when abs_species jacobians are calculated, "abs per species" is aux output and when Faraday is aux output. * src/rte.cc (get_ppath_trans): Removed obselete comment about Faraday. * src/m_fos.cc: Further work on reimplementation ... 2013-04-26 Oliver Lemke * arts-2-1-603 * src/matpack.h: Include cmath before applying the isnan-isinf-fix for GCC C++11. 2013-04-25 Oliver Lemke * arts-2-1-602 * src/absorption.h (LineshapeRecord): Add bool member to store if this lineshape calculates phase information. Important to determine later whether this lineshape can be used for line mixing calculations. * src/absorption.cc (xsec_species_line_mixing_2nd_order): Add example code for Richard on how to get LineshapeRecord::Phase(). * src/global_data.h: Declare lineshape_data and lineshape_norm_data. * src/lineshapes.cc (define_lineshape_data): Add PHASE or NO_PHASE to each LineshapeRecord constructor call. Define lineshape_data and lineshape_norm_data inside global_data namespace. * src/m_abs.cc: extern const... -> using... for l_d and l_n_d. 2013-04-25 Oliver Lemke * arts-2-1-601 * Cleanup of global variables. * src/global_data.h: Gather extern const declarations of all global variables in a separate namespace and document in which files the variables are defined. If you need access to a global variable (e.g. md_data), include this file and make the variable visible in the function where you need it with: using global_data::md_data; (The old way was: extern const Array md_data;) Now you can access the variable as usual: md_data.bla(); To keep things clean, this file should never be included in .h files, only in .cc files. * src/globals_2.cc: Removed. Moved definitions into the cc files where the initialization function of each variables is implemented. * src/CMakeLists.txt: Remove globals_2.cc. * src/abs_species_tags.cc, src/absorption.{cc,h}, src/agenda_class.cc, src/agenda_record.cc, src/agendas.cc, src/cia.cc, src/continua.cc, src/docserver.cc, src/groups.cc, src/m_abs.cc, src/m_abs_lookup.cc, src/m_atmosphere.cc src/make_auto_md_cc.cc, src/make_auto_md_h.cc, src/make_auto_workspace_h.cc, src/methods.cc, src/methods_aux.cc src/parser.cc, src/partition_function_data.cc, src/species_data.cc src/test_quantum.cc, src/test_xml.cc, src/xml_io_compound_types.cc, src/main.cc: Import global_data.h where needed and replace all 'extern const...' statements by 'using global_data::...'. * src/abs_species_tags.{cc,h}, src/absorption.{h,cc}: Move species_index_from_species_name and species_name_from_species_index from a_s_t to absorption. They act on the species, not on the species tag. Also removes the necessity of SpeciesMap being a global variable which is defined in absorption.cc. * src/absorption.{h,cc} (LineRecord::BroadSpecSpecIndex): Move implementation to cc file. * src/matpack.h: Move isnan and isinf fix from arts.h to here. * src/debug.h: Added. Move debug macros from arts.h to here. * src/arts.h: See above. 2013-04-25 Patrick Eriksson * arts-2-1-600 * src/m_fos.cc: Adding support for fos_n > 0. Work in progress. Don't use FOS at all!!! * src/m_rte.cc (iyEmissionStandard): Removed non-active code, moved to sub-function. * src/workspace.cc: Removed all FOS specific variables. 2013-04-24 Richard Larsson * arts-2-1-599 * src/absorption.h: Two new functions: (xsec_species_line_mixing_wrapper) and (xsec_species_line_mixing_2nd_order) that will act as a line mixing layer for (xsec_species). * src/m_linemixing.cc: Fix to work with new ArrayOfArray* line_mixing_data*. * src/m_abs.cc: Made line_mixing_data* active variables. Added call to (xsec_species_line_mixing_wrapper) where appropriate. * src/absorption.cc: (xsec_species_line_mixing_wrapper) and (xsec_species_line_mixing_2nd_order) added. When utilized with data from Makarov etal 2011 these will change O2 band near 6 GHz both positively and negatively (I have seen at most 1 K). These still require more testing. 2013-04-24 Oliver Lemke * arts-2-1-598 * src/methods.cc (abs_xsec_per_speciesAddLines, propmat_clearskyAddZeeman): Add line mixing as input. * src/abs_species_tags.{cc,h} (SpeciesTag): Add line mixing type support. (SpeciesTag::operator==): Add mtype and mline_mixing_type. * src/m_abs.cc (abs_xsec_per_speciesAddLines): Prepare for line mixing support. * controlfiles/general/general.arts: Touch line_mixing_data and line_mixing_data_lut. 2013-04-23 Stefan Buehler * arts-2-1-597 * src/gas_abs_lookup.h: Cosmetics. * src/gas_abs_lookup.cc (GasAbsLookup::Adapt): The current species list may now contain species that are not included in the original lookup table IF they are trivial species, such as free electrons or zeeman species, for which there is no lookup table absorption anyway. The data for these additional species is simply set to NAN, the same value that *GasAbsLookup::Adapt* would produce. * src/check_input.h (runtime_error_not_found, runtime_error_not_unique): Added these two new classes, which are public derivatives of *runtime_error*. (chk_contains): Use the new error classes. This makes it possible for the caller to selectively catch one of the two error conditions, which is needed in *GasAbsLookup::Adapt*. 2013-04-23 Oliver Lemke * arts-2-1-596 * src/abs_species_tags.{h,cc} (check_abs_species): Gather checks for abs_species in one function. * m_abs_lookup.cc (abs_speciesSet, abs_speciesAdd, abs_speciesAdd2): Call check_abs_species after modifying abs_species. 2013-04-23 Oliver Lemke * arts-2-1-595 * src/m_linemixing.cc, src/methods.cc, src/workspace.cc: line_mixing_o2 -> line_mixing_data. line_mixing_o2_lut ->line_mixing_data_lut line_mixing_o2Read -> line_mixing_dataRead line_mixing_o2Init -> line_mixing_dataInit Change type of l_m_d to ArrayOfArrayOfVector. This way it can hold all the line mixing data for all species. Add argument species_tag to line_mixing_dataRead to specify to which abs_species this line mixing data should be attached to. * src/absorption.cc (find_matching_lines): If isotopologue index equals the total number of isotopologues in that species, it is also treated as a wildcard. Consistent with the behavior of SpeciesTag. * src/abs_species_tags.h (get_tagindex_for_Strings): Removed. Unused, no implementation present. * src/test_quantum.cc: Updated. 2013-04-22 Oliver Lemke * arts-2-1-594 * src/absorption.cc (LineRecord::ReadFromHitran2004Stream): Fix parsing of v1 for O2. Add parsing of F'' for O2. * src/quantum.{h,cc}: Add quantum number F. * src/rational.cc (operator>>): Don't check for EINVAL. * src/m_linemixing.cc (line_mixing_o2Read): Add out3 info for matches. 2013-04-22 Oliver Lemke * arts-2-1-593 * src/m_linemixing.cc (line_mixing_o2Read): Implement reading of line mixing data and matching it to lines in abs_lines_per_species. Needs more work in picking the right species. Currently just looks for the first O2 tag. * src/absorption.{cc,h} (find_matching_lines): Use -1 as wildcard for species and isotopologue. Add docs. * src/methods.cc, src/m_linemixing.cc (line_mixing_o2Init): Added. * src/workspace.cc (line_mixing_o2_lut): Update docs. * src/test_quantum.cc: Updated. 2013-04-22 Oliver Lemke * arts-2-1-592 * src/rational.{cc,h} (operator>>): Implement input operator for quantum numbers. * src/quantum.cc (operator<<): Prettier output with QN names. * src/absorption.cc (LineRecord::ReadFromHitran2004Stream): Parse upper/lower global quanta v1 value for O2. * src/test_quantum.cc: More tests. 2013-04-21 Jana Mendrok * arts-2-1-591 * Introduced a "particles" abs_species, that takes the absorption properties from scat_data_raw and "vmr"s prom pnd_field. Note that this approach completely ignores scattering - both in extinction as well as in source part! Allows to consistently use the cloud/dust optical property data and density fields from arts-xml-data in non-scattering calcs (and only there!). The only change required for "usual" ARTS setups is when applying DOIT, iyEmissionStandard in the iy_main_agenda needs to get passed an empty dummy pnd_field. TO DO: Adapt documentation in AUG. Adapt abs_mat_fieldCalc. * src/abs_species_tags.cc: Adapted constructor and tag name extraction for new species "particles". * src/species_data.cc, partition_function_data.cc, abs_species_tags.h: Introduced species "particles" and type PARTICLES. * src/m_abs.cc (propmat_clearskyAddParticles): Introduced this method. Provides the propmat_clearsky for abs_species "particles" from scat_data_raw and rtp_pnd (taken from pnd_field). (abs_xsec_agenda_checkedCalc, propmat_clearsky_agenda_checkedCalc): Adapted for new abs_species "particles" and its type PARTICLES. * src/workspace.cc: Added rtp_pnd. * src/agendas.cc: Added rtp_pnd as input to propmat_clearsky_agenda. * src/rte.[cc,h] (get_ppath_atmvars): Added ppath_pnd as output, pnd_field and cloudbox_on as input, and functionality to calc ppath_pnd (only in case cloudbox_on is false). (get_ppath_abs): Added ppath_pnd as input and pass to propmat_clearsky_agenda. * src/m_rte.cc (iyEmissionStandard): Added pnd_field as input allowing to use in clear-sky absorption calculations (for abs_species "particle). Adapted all calls of get_ppath_atmvars and get_ppath_abs accordingly. * src/m_transmitter.cc, m_cloudradar.cc, m_fos.cc (iyRadioLink, iyTransmissionStandard, iyCloudRadar, iyFOS): Adapted calls of get_ppath_atmvars and get_ppath_abs. * src/montecarlo.cc, disort.cc, doit.cc: Adapted all calls of propmat_clearsky_agenda passing a dummy rtp_pnd. * src/m_abs_lookup.cc (abs_lookupCalc, abs_speciesSet): Adapted for use with abs_species "particles". (abs_mat_fieldCalc): Temporarily adapted call of propmat_clearsky_agenda passing a dummy rtp_pnd. * src/gas_abs_lookup.cc (GasAbsLookup::Extract): Adapted for new type PARTICLES (no extraction for this. in analogy to FREE_ELECTRONS). * src/m_atmosphere.cc (basics_checkedCalc): Added some pnd_field and "particles" abs_species related checks ("particles" only allowed when cloudbox off; if cloudbox off & pnd_field set, then pnd_field needs to cover whole atmo AND "particles" need to be in abs_species). * src/m_cloudbox.cc (ParticleTypeAdd, ParticleTypeAddAll): Removed any usage of cloudbox_limits. (pnd_fieldCalc): Allow empty cloudbox_limits assuming then pnd_field has to cover complete atmosphere (this facilitates the non-cloudbox usage of pnd_field for "particles" abs_species). * src/cloudbox.[cc,h] (chk_pnd_data, chk_pnd_raw_data): Removed check for all non-zero pnd values to be inside the cloudbox. Makes ParticleTypeAdd independent of the cloudbox definition, i.e. allows to get the particle data before defining the cloudbox (useful e.g. for auto-cloudbox detection). Check is then anyway done by pnd_fieldCalc using chk_pnd_field_raw_only_in_cloudbox. * src/m_doit.cc, m_doit2.cc (CloudboxGetIncoming): Moved if (!cloudbox_on) to the very beginning. We don't need to do anything here, if cloudbox is off - not even checking that certain other checks were done. (CloudboxGetIncoming1DAtm): As CloudboxGetIncoming. And added sensor_checked for consitency with CloudboxGetIncoming. (CloudboxGetIncoming2): Added sensor_checked for consitency with CloudboxGetIncoming. * src/methods.cc: Adapted to changes above. * controlfiles/general/agendas.arts, controlfiles/artscomponents/helpers/TestAgendaCopy.arts, controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Adapted propmat_clearsky_agenda definitions to ignore rtp_pnd. * controlfiles/general/general.arts: Default set FlagOff( cloudbox_on ) and empty pnd_field. * controlfiles/artscomponents/doit/TestDOIT.arts, doitbatch/TestDOITBatch.arts: Pass empty dummy pnd_field into iyEmissionStandard (to avoid it trying to use the real, cloudbox-targeted pnd_field when called from CloudboxGetIncoming with a cloudbox_on=false flag) * controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, TestMonteCarloGeneral.arts: Use named method parameters. 2013-04-21 Oliver Lemke * arts-2-1-590 * src/m_abs_lookup.cc (abs_lookupCalc): Increase spec index if a species is skipped (Zeeman / free_electrons). Otherwise the following species are stored in the wrong place. 2013-04-19 Oliver Lemke * arts-2-1-589 * src/agendas.cc, src/methods.cc: doit_mono_agenda and doit_i_fieldSetClearsky defined doit_i_field as output only. This works fine if the all_frequencies flag is set to true (the default). However, if set to false, doit_i_field is resized when the first frequency is calculated. For the following frequencies, doit_mono_agenda is assuming that doit_i_field has already been resized, essentially misusing the output variable as an input. Nowadays, output-only variables are initialized to 0 to catch these cases of variable abuse. Hence, doit_i_field is now also defined as input for doit_mono_agenda and doit_i_fieldSetClearsky. Fixes bug reported by Patrick. 2013-04-19 Patrick Eriksson * arts-2-1-588 * src/m_fos.cc (iyFOS): A bit better handling of hgher stokes_dims. 2013-04-19 Patrick Eriksson * arts-2-1-587 * src/m_fos.cc (iyFOS): FOS restarted. So far just some kind of zero-order verson. * doc/uguide/faraday.tex (section{Practical usage}): Fixed typo, that check-all did not like. * src/make_array.h: Introduced array lengths 38 and 39. Turned out to be not needed right now, but kept anyhow. * src/doit.cc (rte_step_doit): rte_step_std renamed. * src/rte.cc (rte_step_std): Moved and renamed (see above). (emission_rtstep): New, dedicated for iyEmission. * src/m_transmitter.cc (iyTransmissionStandard): Typo in a comment * controlfiles/general/general.arts: Remobed fos_i. * src/workspace.cc: * src/agendas.cc: Commented out all variables associated with FOS. 2013-04-19 Oliver Lemke * arts-2-1-586 * src/m_zeeman.cc (propmat_clearskyAddZeeman): Check that abs_species and abs_lines_per_species match in size. * src/workspace.cc: Add line_mixing_o2 and line_mixing_o2_lut. Names might change. * src/methods.cc: Add line_mixing_o2Read. * src/src/m_linemixing.cc: New file. Only contains stub for line_mixing_o2Read. * src/CMakeLists.txt: Add m_linemixing.cc. 2013-04-19 Oliver Lemke * arts-2-1-585 * src/quantum.{h,cc}: Change internal storage class of Quantum Numbers from ArrayOfRational to a map. Saves memory and is also faster. * controlfiles/artscomponents/zeeman/yREFERENCE_3D.xml: Update references values to calculation results after richard's previous change. * src/absorption.cc (find_matching_lines): Return ret. * src/test_quantum.cc: Playing around. 2013-04-18 Richard Larsson * arts-2-1-584 * src/m_zeeman.cc: Use the unDefined * src/lineshape.cc: Return to the previous way of doing Faddeeva. I personally think there is something fishy going on in how we use gamma and sigma in ARTS. I think there should be a more clear-cut definition and that names should change more often between the functions (e.g. be clear when gamma is self-broadening, Lorentz-broadening and/or collisional half-life). In any case, the Faddeeva function passes the standard clearsky test case and should therefore represent the Voigt shape quite well. 2013-04-18 Oliver Lemke * arts-2-1-583 * src/m_abs_lookup.cc (abs_lookupCalc): Initialize abs_lookup.xsec with NAN. Ignore free_electrons species. * src/gas_abs_lookup.cc (GasAbsLookup::Extract): Ignore species such as Zeeman and free_electrons which are not stored in the lookup table. For those the result is set to 0. 2013-04-18 Oliver Lemke * arts-2-1-582 * src/xml_io_basic_types.cc: Use double_imanip() whenever reading a floating point number from an ASCII XML file. Allows proper reading of nan and inf values even if the compiler doesn't support it by default (such as gcc). 2013-04-18 Oliver Lemke * arts-2-1-581 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag(String def)): Initialize misotopologue with -1. * src/gas_abs_lookup.cc (GasAbsLookup::Adapt): species -> abs_species in chk_contains message. 2013-04-18 Oliver Lemke * arts-2-1-580 * ChangeLog: Correct filename in previous entry. 2013-04-18 Oliver Lemke * arts-2-1-579 * src/partition_function_data.cc: (define_partition_species_data): Add assertion at the end to ensure that all species have been taken care of. Add dummy entry for the free_electrons species. (spec, iso): Remove empty if statements that were just there to avoid an unused variable warning from the compiler when compiling without assertions. Instead, add _U_ in function parameter list to the variable that is only used in the assertion. * src/file.cc (open_input_file): Respect ARTS search path. 2013-04-17 Oliver Lemke * arts-2-1-578 * src/rational.h: Tweak comparison operators. If the denominator is 0, the comparison is always false (except !=). * CMakeLists.txt: Don't run testcases with 'nocheck' in their name automatically. This way we can have testcases defined that are currently broken / under construction without breaking 'make check' and still run them easily with ctest directly. * controlfiles/CMakeLists.txt: Enable test_zeeman, add 'nocheck' to testcase name. 2013-04-17 Oliver Lemke * arts-2-1-577 * src/CMakeLists.txt: Add test_quantum. * src/absorption.{h,cc} (LineRecord::ReadFromHitran2004Stream): Store quantum numbers for O2 in new QuantumNumberRecord. (find_matching_lines): Search in ArrayOfLineRecord. * src/m_zeeman.cc (propmat_clearskyAddZeeman): Use quantum numbers from the QuantumNumberRecord. * src/rational.h: Define RATIONAL_UNDEFINED and add isUndefined method. * src/quantum.{cc,h}: Add Compare function and simple output operators. Remove QUANTUM_UNDEFINED and use new RATIONAL_UNDEFINED instead. 2013-04-16 Patrick Eriksson * arts-2-1-576 * src/ppath.cc (raytrace_1d_linear_basic) (raytrace_2d_linear_basic, raytrace_3d_linear_basic): With ppath_lmax=-1, lmax was effectively set lraytrace and number of path points could differ between geometric and refraction calcs. Expanded an if-statement, to solve this problem. 2013-04-16 Oliver Lemke * arts-2-1-575 * src/arts.h: Add define for isnan an isinf to fix compilation on g++ (>=4.7) using the new c++11 standard. * controlfiles/artscomponents/zeeman/yREFERENCE_3D.xml: Update reference file. * controlfiles/artscomponents/zeeman/TestZeeman.arts: Remove abs_n2. * src/m_extract.h: Update docs for Extract template function. 2013-04-15 Jana Mendrok * arts-2-1-574 * src/m_extract.h (Extract): Removed Extract for Index from ArrayOfIndex as this - according to Oliver - is implicitly included in the template function. 2013-04-15 Jana Mendrok * arts-2-1-573 * src/m_extract.h (Extract): Added Extract for Index from ArrayOfIndex. * src/m_doit.cc (CloudboxGetIncoming, iyInterpCloudboxField): Introduce sanity check for radiance field interpolation - throws an error if radiance ratio between two interpolation points exceeds a threshold. Can be switched off (and old non-check behaviour used instead, which is preferable for very thin atmospheres, where radiance field is a step function when going from downlooking to limb) via "rigorous" keyword. Only for 1D case implemented, though. (doit_za_grid_optCalc): Throw level-1 warning instead of runtime error if number of zenith angles for grid optimizations seems too low (<500). * src/methods.cc: Adapted to the changes in WSM above. * src/doit.[cc,h] (iy_interp_cloudbox_field): Sanity check for radiance field interpolation (see iyInterpCloudboxField above). * src/ppath.cc (ppath_start_stepping): Minor fix: in 3D allow sensor to be right on the edge of the defined lon-grid. * src/continua.cc controlfiles/artscomponents/arts-xml-data/TestAtmScen_Mars.arts: Minor spellfixes. * doc/uguide/gridded_field_gridnames.txt: Some more specifications. 2013-04-12 Oliver Lemke * arts-2-1-572 * src/quantum.{cc,h}: Quantum numbers implementation. Unfinished. * src/absorption.{cc,h}: Rename QuantumNumbers to QuantumNumbersString. Will be removed once the new implementation is completed. Add QuantumNumberRecord to LineRecord. * src/CMakeLists.txt: Add quantum.cc. * src/rational.{cc,h}: Remove assertion for denom>0 (for now). Because we want to use Rational(0,0) as an undefined value. Use less controversial names for member variables. top -> mnom, low -> mdenom. 2013-04-10 Oliver Lemke * arts-2-1-571 * src/m_abs.cc, src/absorption.h (linesElowToJoule): Removed unused function. * src/rational.{cc,h}: Add typedef for ArrayOfRational. Move implementation of Simplify to cc file. 2012-04-10 Oscar Isoz * arts-2-1-570 * src/methods.cc, src/m_sensor.cc (sensor_responseGenericAMSU,f_gridFromSensorAMSUgeneric): Added workspace methods for implementation of AMSU-A type sensors, * controlfiles/instruments/amsu/TestAMSUA.arts, controlfiles/instruments/amsu/amsua.arts : Added preliminary testcases for AMSU-A type sensor 2013-04-09 Stefan Buehler * arts-2-1-569 * src/methods.cc (basics_checkedCalc): Added input variable *abs_f_interp_order*. * src/m_atmosphere.cc (basics_checkedCalc): If any of the wind fields exist, abs_f_interp_order must not be zero. This to make sure that absorption lookup table extraction still works if the frequency grid is Doppler shifted. * controlfiles/artscomponents/groundbased/TestWinds.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Jupiter.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Mars.arts: Set abs_f_interp_order to 1 to avoid runtime error. 2013-04-09 Oliver Lemke * arts-2-1-568 * README: Cleanup TESTS section. Fix factual error: clang does NOT support OpenMP. 2013-04-09 Oliver Lemke * arts-2-1-567 * src/docserver.cc (Docserver::doc_method): Instead of listing variables that are used both as input and output twice, just list them once and mark them with 'OUT+IN'. 2013-04-09 Oliver Lemke * arts-2-1-566 * src/workspace.cc: Remove abs_species_lookup and abs_species_onthefly. * src/methods.cc, src/m_abs_lookup.cc (SpeciesPartitionLookupOnthefly): Removed. 2013-04-08 Oliver Lemke * arts-2-1-565 * tests/: Get rid of empty directory. * ChangeLog: Aesthetics. Fix indentation, shorten line length to 80 chars. 2013-04-05 Richard Larsson * arts-2-1-564 * src/absorption.cc: Fix HITRAN reading routine for species without isotopologues. * controlfiles/artscomponents/cia/TestCIA.arts: Fix what previous commit broke. 2013-04-05 Richard Larsson * arts-2-1-563 * src/workspace.cc: Returned to not having a phase xsec. Also added extra commentary to isotopologue_quantum. * src/m_zeeman.cc: Removed reference to line mixing. LM will be handeled internally in xsec_species in the future. * src/methods.cc,src/m_abs.cc,src/agendas.cc: Returned to not having a phase xsec explicitly for functions that don't care about it. (xsec_species) still return the phase variable because functions like m_zeeman require the phase. * src/lineshapes.cc: Fixed major bug in treatment of pressure broadening in (faddeeva_algorithm_916). We treat the pressure broadening parameter as half width half strength, not full width half strength. So to get the necessary parameter for the Faddeeva function, gamma should thus be divided by 2PI and nothing else. This might have to be clarified in the related paper, but it does not change the results in there the slightest, since the related paper is clearly in the temperature region of atmospheric broadening. 2013-03-31 Oliver Lemke * arts-2-1-562 * src/cia.{cc,h}: (cia_get_index): Fix critical bug. ArrayOfCIARecord was accidentally passed in by value instead of reference, causing horrible slowdown in abs_xsec_per_speciesAddCIA due to copying of all CIA species data on every call in inner loop. Single-threaded CIA calculations now 5x faster, multi-threaded (8 cores) 20x faster than before. (cia_interpolation): Only create out3 output if needed. * src/check_input.cc (chk_interpolation_grids): Only create ostringstream if needed. * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Got rid of one unnecessary ostringstream in the inner loop. * CMakeLists.txt: Set COMPILE_FLAGS just before creating config.h. Otherwise arts -v might not show the correct flags. Remove NDEBUG from CMAKE_C*_FLAGS earlier. 2013-03-25 Oliver Lemke * arts-2-1-561 * absorption.{cc,h}: (LineRecord): Add member mquantum_numbers. (LineRecord::ReadFromArtscat4Stream): Read quantum numbers into string. (LineRecord::operator<<): Do not write quantas from Hitran into ARTSCAT-4. They are incompatible with our format. Instead, use the quantum numbers that were read from the original ARTSCAT-4 file (if this LineRecord has them). 2013-03-24 Oliver Lemke * arts-2-1-560 * src/m_cloudbox.cc (ParticleTypeInit): Do a resize(0) instead of a reserve(20) because the latter does not do any initialization. This is required behaviour of Init methods. * arts.h (DEBUG_PRINT): Add convenience macro for debugging to cerr. DEBUG_PRINT(x) outputs DBG: x: 1 Can be used with expressions too: DEBUG_PRINT(x+1) outputs DBG: x+1: 2 * src/m_general.{cc,h}, src/methods.cc: Fix behaviour of timer WSV. Instead of outputting the timer values inside the timerStop method, move that implementation to Print. 2013-03-21 Oliver Lemke * arts-2-1-559 * src/m_doit.cc (DoitInit): Throw runtime_error if scat_za_grid is not increasing. Fixes assertion in doit_scat_fieldCalcLimb reported by Jana. Fix typo in the scat_aa_grid runtime error (s/za/aa/). 2013-03-21 Oliver Lemke * arts-2-1-558 * WARNING! This version requires you to adapt your controlfiles: Replace SpeciesSet with abs_speciesSet! Insert abs_xsec_agenda_checkedCalc and propmat_clearsky_agenda_checkedCalc where needed. I recommend to always call abs_speciesSet, abs_speciesAdd and abs_speciesDefineAllInScenario by keyword: Use abs_speciesSet( species=["CO2"] ) instead of abs_speciesSet( abs_species, ["CO2"] ). Same for abs_speciesAdd and DefineAllScenarios: abs_speciesAdd( species=["H2O"] ) abs_speciesDefineAllInScenario( basename="testdata/tropical" ) * src/methods.cc, src/m_abs.cc, src/m_abs_lookup.cc: (abs_xsec_agenda_checkedCalc, propmat_clearsky_agenda_checkedCalc): Two new checks that have to be called before abs_xsec_agenda or propmat_clearsky_agenda are used. They ensure that the two agendas contain the required methods to satisfy calculation of all tags set in abs_species. (abs_speciesDefineAllInScenario, abs_speciesAdd, abs_speciesAdd2): Add propmat_clearsky_agenda_checked and abs_xsec_agenda_checked as output. (propmat_clearskyInit): Add propmat_clearsky_agenda_checked as input. (abs_xsec_per_speciesInit): Add abs_xsec_agenda_checked as input. (abs_speciesSet): Change abs_species output type from generic to specific and rename the function accordingly. In almost all cases this method is called with abs_species. By changing it to a specific output, it can be left out in the call. The rare case of setting abs_nls directly can be easily done by calling: abs_speciesSet( abs_species=abs_nls, species=["H2O-PWR98"] ) * src/agenda_class.{cc,h} (Agenda::has_method): Added. * src/workspace.cc: Add abs_xsec_agenda_checked and propmat_clearsky_agenda_checked. * src/abs_species_tags.cc (get_tagindex_for_Strings): Removed. * doc/uguide/absorption.tex: SpeciesSet -> abs_speciesSet. * controlfiles/*/*/*.arts: Use keywords in SpeciesSet, abs_speciesAdd and abs_speciesDefineAllInScenario. Insert abs_xsec_agenda_checkedCalc, propmat_clearsky_agenda_checkedCalc where needed. 2013-03-21 Patrick Eriksson * arts-2-1-557 * Big cleaning, to finish the transition to new way for handling Faraday and storing free electrons. * doc/uguide/faraday.tex: Updated to new approach for Faraday rotation. * doc/uguide/rte_basics.tex: * doc/uguide/atmosphere.tex: Removed refences to unknown WSVs. * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Venus.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Jupiter.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Mars.arts: * controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Earth.arts: Added Tensor3Create( edensity_field ) to keep the cfiles OK. * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: * controlfiles/general/agendas.arts: * controlfiles/general/general.arts: Removed everything around edensity. * src/m_refraction.cc (refr_indexFreeElectrons): Now using rtp_vmr instead of rtp_edensity. * src/montecarlo.h: * src/montecarlo.cc (mcPathTraceGeneral): * src/m_montecarlo.cc (MCGeneral): * src/m_rte.cc: * src/refraction.cc: * src/m_atmosphere.cc (basics_checkedCalc): * src/ppath.cc: * src/m_doit.cc: * src/rte.cc: * src/m_cloudradar.cc: * src/doit.h: * src/doit.cc: Removed everything around edensity_field. * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): * src/m_rte.cc (iyEmissionStandard): * src/m_cloudradar.cc (iyCloudRadar): Adopted to changes in rte.cc. * src/rte.cc (get_ppath_atmvars): Removed part around ppath_ne. (get_ppath_trans, get_ppath_trans2): Removed everything around Faraday rotation. * src/agendas.cc: Removed rtp_edensity as input for refr_index_agenda. And edensity_field from both ppath agendas. * src/workspace.cc (define_wsv_data): Removed rtp_edensity. This is now part of rtp_vmr. And removed edensity_field. Now part of vmr_field. 2013-03-20 Patrick Eriksson * arts-2-1-556 * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Updated. Faraday rotation handled by the changes below. Perfect match to old reference data. * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): The auxiliary Faraday quantities now filled by data taken from propmat_clearsky. * src/m_abs.cc (propmat_clearskyAddFaraday): Included input checks and physics. Completed. 2013-03-20 Oliver Lemke * arts-2-1-555 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag): Get the species index before handling the free_electrons tag. (SpeciesTag::Name): Use name from species_data for free_electrons. * src/species_data.cc (define_basic_species_data): Add tag 'free_electrons'. 2013-03-20 Patrick Eriksson * arts-2-1-554 * doc/uguide/atmosphere.tex: * doc/uguide/absorption.tex * doc/uguide/concept.tex: As below, but inside AUG. * src/m_abs_lookup.cc: * src/mc_interp.h: * src/m_optproperties.cc: * src/mc_interp.cc: * controlfiles/general/agendas.arts: * src/m_refraction.cc: * src/refraction.cc: * src/doit.cc : * src/m_abs_o2_models.cc: * src/m_zeeman.cc: * src/montecarlo.cc: * src/mc_NotUsed.cc: * src/disort.cc: * src/montecarlo.h: * src/methods.cc: Changed all rte_temperature, rte_pressure, rte_mag * src/agendas.cc: rte_doppler and rtp_abs_species, to new rtp- * src/m_abs.cc: correspondance. * src/workspace.cc: Renamed rtp_abs_species to rtp_vmr. 2013-03-20 Patrick Eriksson * arts-2-1-553 * controlfiles/testdata/tropical.expanded.t.xml: * controlfiles/testdata/tropical.expanded.z.xml: Grids still lacked name. 2013-03-20 Oliver Lemke * arts-2-1-552 * doc/uguide/concept.tex, uguide/development.tex, doc/uguide/scattering.tex: Update docs about test cases. * tests/: Removed. 2013-03-15 Oliver Lemke * arts-2-1-551 * src/m_doit.cc, src/methods.cc (doit_i_fieldUpdate1D): Remove doit_i_field_old from inputs. Instead, use a local variables that's initialized from doit_i_field. * src/physics_funcs.cc (invplanck): Convert assertion for radiance < 0 to runtime_error. 2013-03-13 Oliver Lemke * arts-2-1-550 * src/absorption.cc, src/continua.cc, src/m_abs.cc, src/m_abs_lookup.cc, src/m_atmosphere.cc, src/m_batch.cc, src/m_rte.cc: Revise all OpenMP loops. Make sure loops have enough iterations before parallelizing them. Otherwise it can really hurt performance. Basically now all loops require the number of iterations to be greater or equal to the maximum number of threads (some exceptions such as ybatchCalc). Here are some benchmarks: make check (TEST_JOBS=4) ubuntu5 before: 29 sec ubuntu5 after : 18 sec ubuntu1 before: DNF (stuck in fast.doit) ubuntu1 after: 13 sec ctest -j4 -R xmldata -E isoratios ubuntu5 before: 43 sec ubuntu5 after: 17 sec ubuntu1 before: 22 sec ubuntu1 after: 15 sec ubuntu5 uses gcc 4.4.4, ubuntu1 gcc 4.6.3 * src/m_abs.cc (abs_xsec_per_speciesAddLines, abs_xsec_per_speciesAddLines), src/m_cia.cc (abs_xsec_per_speciesAddCIA): Only output to out3/2 if visible. 2013-03-13 Oliver Lemke * arts-2-1-549 * This commit breaks backwords-compatibility: All occurences of abs_mat_per_species have been renamed to propmat_clearsky. This includes all Workspace methods that have abs_mat_per_species in their name and the abs_mat_per_species_agenda. * src/agendas.cc, src/disort.cc, src/disort.h, src/doit.cc, src/doit.h, src/m_abs.cc, src/m_abs_lookup.cc, src/m_cloudradar.cc, src/m_doit.cc, src/m_montecarlo.cc, src/m_optproperties.cc, src/m_rte.cc, src/m_transmitter.cc, src/m_zeeman.cc, src/methods.cc, src/montecarlo.cc, src/montecarlo.h, src/optproperties.cc, src/optproperties.h, src/rte.cc, src/rte.h, src/workspace.cc, doc/uguide/absorption.tex, doc/uguide/concept.tex, controlfiles/*/*/*.arts, controlfiles/general/agendas.arts, controlfiles/general/agendasDOIT.arts, controlfiles/planetary_toolbox/includes/common/AbsLookup.arts, controlfiles/planetary_toolbox/includes/common/AbsOnTheFly.arts, controlfiles/planetary_toolbox/validation/common/spectroscopy/SpecCat_Consistency_Perrin-vs-HITRAN.arts: s/abs_mat_per_species/propmat_clearskypropmat_clearsky/g 2013-03-12 Oliver Lemke * arts-2-1-548 * src/mystring.h (my_basic_string): Add trim method to remove whitespace from Strings. Remove cruft. * src/abs_species_tags.{cc,h} (SpeciesTag): Add support for 'free_electrons' tag. (species_index_from_species_name): Use new String.trim. * src/m_abs_lookup.cc (SpeciesSet): Make sure 'free_electrons' is not used with other tags in the same group and not more than once overall. * src/methods.cc, src/m_abs.cc: Add stub for abs_mat_per_speciesAddFaraday. 2013-03-12 Oliver Lemke * arts-2-1-547 * src/m_transmitter.cc: Use NAN instead of 0/0. The latter can produce an exception on some compilers. 2013-03-12 Patrick Eriksson * arts-2-1-546 * doc/uguide/rte_basics.tex: Modified following new discussions about new WSV and their names. Hopefully final ... 2013-03-11 Oliver Lemke * arts-2-1-545 * src/m_append.h: Several fixes. Properly handle appending to or appending an empty variable. Allow appending a variable to itself. Don't run into an endless loop and eat all memory when appending an ArrayOf to itself. * src/mystring.h: Fix bug in constructor that produced an assertion when trying to create an arts String from an empty C++ string. 2013-03-11 Oliver Lemke * arts-2-1-544 * src/m_basic_types.cc, src/methods.cc: Add ArrayOfIndexLinSpace. 2013-03-11 Oliver Lemke * arts-2-1-543 * controlfiles/CMakeLists.txt: Add cia testcases to check-xmldata. * controlfiles/artscomponents/cia/TestCIA.arts, controlfiles/artscomponents/cia/TestRTwithCIA.arts: Adapt path to arts-xml-data. 2013-03-08 Stefan Buehler * arts-2-1-542 * src/m_basic_types.cc: Added Compare for ArrayOfMatrix. * src/methods.cc: Added Compare for ArrayOfMatrix. * controlfiles/artscomponents/cia/TestCIA.arts: Added. Calculate absorption cross sections for all CIA continua and compare to reference calculation. Path to arts-xml-data needs adjustment, and must still be added to suitable test target. * controlfiles/artscomponents/cia/TestCIA.abs_xsec_per_species_reference.xml: Reference result for the above. * controlfiles/artscomponents/cia/TestRTwithCIA.arts: Added. Calculate RT simulation with mixed CIA and other absorption tags. Compare to reference calculation. Path to arts-xml-data needs adjustment, and must still be added to suitable test target. * controlfiles/artscomponents/cia/TestRTwithCIA.iy_reference.xml: Reference result for the above. 2013-03-08 Jana Mendrok * arts-2-1-541 * src/methods.cc: Updated doc of AtmFieldsCalc and pnd_fieldCalc regarding zeropadding. * src/workspace.cc: Added info on requirement that outer points of pnd_field in each dim have to have pnd=0. * src/m_cloudbox.cc (cloudbox_checkedCalc): Improved a couple of error messages. (pnd_fieldCalc): Removed Oliver's recent grid name fix. * src/cloudbox.cc (chk_pnd_field_raw_only_in_cloudbox): Allow pnd to have non-zero values below lower cloudbox limit, if this is at the lowerest pressure level. Also reject cases, where pnd has non-zero values AT the cloudbox_limits and print info on which entry of pnd_field_raw array is problematic. * controlfiles/artscomponents/[doit/pnd_field_1D,montecarlo/pnd_field_raw].xml: Add names for grids of GriddedField (now required by pnd_fieldCalc). 2013-03-07 Oliver Lemke * arts-2-1-540 * src/m_abs_lookup.cc (abs_lookupCalc): Adapt OpenMP loop. 2013-03-07 Stefan Buehler * arts-2-1-539 * Quite a big absorption part overhaul. Not completely finished, there will be some polishing in the next days. All check-all targets run (except for something with the userguide that was already broken). I did not try to fix other controlfiles that are not part of check-all. In generally, just including the following should make your controlfile work again: # Agenda for scalar gas absorption calculation Copy(abs_xsec_agenda, abs_xsec_agenda__noCIA) * src/absorption.h (abs_n2Set, abs_h2oSet): Moved declarations here, since these are no longer WSMs. * src/gas_abs_lookup.h (GasAbsLookup): Updated friend function declarations. * src/m_abs.cc (abs_h2oSet): Removed fancy treatment if no H2O is found. Instead, throw runtime error directly, just as abs_n2Set does. (abs_coefCalc): Removed this method, which is no longer needed. (abs_coefCalcSaveMemory): Ditto. (abs_xsec_per_speciesInit, abs_xsec_per_speciesAddLines) (abs_xsec_per_speciesAddConts): Added input variable abs_species_active to all of these methods. Absorption is calculated only for the active species. (This feature is needed when abs_xsec_agenda is executed for absorption lookup table generation.) (abs_xsec_per_speciesAddConts): Now set h2o_abs and n2_abs internally (using the dedicated helper functions). (abs_mat_per_speciesAddOnTheFly): Use new agenda abs_xsec_agenda. Removed input variables that are specific to certain absorption methods, such as the line list, etc.. Eliminated call of abs_coefCalc. * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Added input variable abs_species_active. Absorption is calculated only for the active species. * src/methods.cc (abs_coefCalc, abs_coefCalcSaveMemory) (abs_h2oSet, abs_n2Set): Eliminated these WSMs. * src/m_abs_lookup.cc (abs_lookupCalc): Use new agenda abs_xsec_agenda, which considerably simplifies things. Removed input variables that are specific to certain absorption methods, such as line list, continuum models, etc.. (calc_lookup_error, abs_lookupTestAccuracy, abs_lookupTestAccMC): Use new agenda abs_xsec_agenda. * src/agendas.cc (abs_xsec_agenda): Added input variable abs_species_active. * src/workspace.cc (abs_h2o, abs_n2): Eliminated these WSVs. * controlfiles/*: Added Copy(abs_xsec_agenda, abs_xsec_agenda__noCIA) to most controlfiles. Removed calls of abs_h2oSet and abs_n2Set. 2013-03-07 Patrick Eriksson * arts-2-1-538 * src/methods.cc: GIN defocus_method was spelled as defocos_method 2013-03-06 Oliver Lemke * arts-2-1-537 * cmake/modules/ArtsTestcases.cmake: Raise the report level for test cases from -r002 to -r022. Then one can see useful information on the screen when manually running testcases with, e. g. 'ctest -V -R fast.faraday' * src/messages.h: (sufficient_priority_agenda): Move the in_main_agenda check into here. (sufficient_priority): New method. Returns true if current output priority is sufficient for either screen or file. (ArtsOut::operator<<): Remove in_main_agenda check. * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Correct output value to vmrs[this_species]+broad_spec_vmr_sum in warning. Use out2.sufficient_priority(). * src/arts.h: Add convenience macro DEBUG_COUNTER(n). This will create a static variable and output the name of the counter and its value everytime that code is reached. 2013-03-05 Oliver Lemke * arts-2-1-536 * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Only send the warning about the total VMR being more than 10% different from 1. to out2 if the user can actually see it (verbosity>=2). Speeds up arts.ctlfile.xmldata.surf.mars by a factor of 2 because the warning happens 11.8 million times. This output is unlikely to be ever seen because it only appears inside an agenda. Only running arts with -r202 will make this warning visible (and produce a 1.3 GB rep file). I think we'll have to rethink our logging strategy. 2013-03-05 Oliver Lemke * arts-2-1-535 * src/m_abs.cc (abs_xsec_per_speciesAddConts): Remove check_continuum_model calls. These have already been checked earlier and cost a lot of time. * src/continua.cc (check_continuum_model): Correct example tag in docs. 2013-03-05 Stefan Buehler * arts-2-1-534 * src/m_abs_lookup.cc (abs_lookupSetupWide) Set all plain VMRs (except N2, O2, H2O) to a default value of 1e9 (was 0 before). Zero works for LBL absorption, but may be problematic for continua. 2013-03-05 Stefan Buehler * arts-2-1-533 * src/gas_abs_lookup.cc (GasAbsLookup::Extract): Commented out runtime error check that reference VMR is not zero. * src/workspace.cc (abs_f_interp_order): Added this WSV. (Not yet used anywhere.) * controlfiles/general/general.arts: Initialize abs_f_interp_order to zero (no frequency interpolation). 2013-03-05 Oliver Lemke * arts-2-1-532 * src/m_cloudbox.cc, src/methods.cc: (pnd_fieldCalc): Add flag to enable zeropadding. Implemented only for 1D. Reimplemented the 1D case to reuse the existing GriddedFieldPRegrid method instead of duplicating the interpolation code. 2013-03-05 Oliver Lemke * arts-2-1-531 * src/docserver.cc (Docserver::insert_title): Add space between literal and identifier as required by C++11. 2013-03-04 Oliver Lemke * arts-2-1-530 * README: Add info on how to compile with LLVM/Clang. 2013-03-04 Oliver Lemke * arts-2-1-529 * Having fun with compiler bugs. * src/rte.cc (get_ppath_trans): The OpenMP loops in this function fail randomly with GCC on Mac OS X. This appears to be a compiler bug. The code looks fine and they work fine with GCC on Linux and with the Intel Compiler on Mac. Also tested to remove the OpenMP statements from our loops and instead add a dummy OpenMP loop that does nothing. This still leads to crashes which indicates there's nothing wrong with our loops but with the compiler implementation. Apple GCC 4.2 works fine but self-compiled GCC 4.4, 4.6, 4.7 and 4.8dev all experiences this issue. Added #if !(__APPLE__) || (__INTEL_COMPILER) for those loops. * Fix compilation with the Intel Compiler (tested with 12.1.0, 13.0.1): * src/m_xml.{h.cc}: Move non-template implementations into new .cc file. * src/absorption.cc: Always make species_data visible as const. * src/absorption.cc, src/m_abs_lookup.cc, src/m_batch.cc, src/m_doit.cc, src/m_rte.cc: Workaround for Intel Compiler (13.0.1) OpenMP issue. Loops that use firstprivate variables segfault if the number of iterations is 0. The Intel Compiler correctly skips the loop in that case, but still tries to call the destructors of the variables defined as firstprivate which haven't even been created in this scenario. * src/rte.cc (get_ppath_abs): Workaround for Intel Compiler (13.0.1) optimization bug. Remove the continue statement from within the catch block. Otherwise compilation will never finish. * src/m_abs.cc, src/m_ppath.cc: Include m_xml.h for WriteXML. * src/xml_io_compound_types.cc (xml_read_from_stream): Initialize n to 0 to avoid compiler warning. * src/CMakeLists.txt: Use set_source_files_properties for all compilers. Add m_xml.cc to artscore. * CMakeLists.txt: Add compiler flags -fvisibility=hidden -fvisibility-inlines-hidden. 2013-03-01 Oliver Lemke * arts-2-1-528 * WARNING! Zeropadding of VMRs in AtmFieldsCalc and AtmFieldsCalcExpand1D has to be enabled explicitly now! * src/m_atmosphere.cc, src/methods.cc (AtmFieldsCalc, AtmFieldsCalcExpand1D): Add flag vmr_zeropadding that is off by default to avoid accidental padding without the user noticing. Move description of interp_order from the general method description into GIN_DESC. * controlfiles/artscomponents/ppath/TestRefractPlanets.arts: Enable vmr_zeropadding in AtmFieldsCalc for Venus and Jupiter. * controlfiles/artscomponents/helpers/TestHSE.arts, controlfiles/artscomponents/faraday/TestFaradayRotation.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScen_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScen_Jupiter.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Earth.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Venus.arts, controlfiles/artscomponents/arts-xml-data/TestAtmScenSup_Jupiter.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts, controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts: Enable vmr_zeropadding in AtmFieldsCalc and AtmFieldsCalcExpand1D. 2013-03-01 Oliver Lemke * arts-2-1-527 * src/xml_io_compound_types.cc (xml_read_from_stream): Throw an error if a tag is defined twice in input file. * src/absorption.{cc,h} (SpeciesAuxData::ReadFromStream): Return the name of the current tag. * src/workspace_ng.{h,cc} (Workspace): Add some debugging code. 2013-02-27 Jana Mendrok * arts-2-1-526 * controlfiles/artscomponents/absorption/TestIsoRatios.arts, IsoRatios_H2Oorig.xml, IsoRatios_H2Omani.xml: Fixed isoratio test case (broken by slightly changed requirements on which isoratios have to be present). 2013-02-27 Jana Mendrok * arts-2-1-525 * controlfiles/artscomponents/arts-xml-data/TestAtmScen_Mars.arts, TestAtmScenSup_Mars.arts: Bugfix (get data from arts-xml-data, not from Jana's homedir!). * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: Removed leftover Print calls. 2013-02-27 Jana Mendrok * arts-2-1-524 * CMakeLists.txt: Introduced a target check-xmldata (which does exactly that - executing the arts-xml-data tests) and adapted make check setup such that xmldata tests are NOT executed with this one. * controlfiles/CMakeLists.txt: Introduced further tests, particular xmldata tests. * controlfiles/artscomponents/helpers/TestForloop.arts, TestHSE.arts, TestRegridding.arts, TestAgendaCopy.arts: Added. Tests of some ARTS helper methods. * controlfiles/artscomponents/arts-xml-data/TestIsoRatios.arts, TestSpectro*.arts, spectrotest.py: Added. Tests of toolbox spectroscopic and isotopologue ratio data. CAUTION: TestSpectro*.arts require HITRAN data, hence are not included in the make check target. Also, they need quite a bit of runtime. Nevertheless, they are part of the ESA planetary toolbox test cases, hence we want to have them in the repository. * controlfiles/artscomponents/ppath/TestRefractPlanets.arts: Added. Testing MWgeneral refraction method. * controlfiles/artscomponents/arts-xml-data/TestAtmScen*.arts, TestAtmScenSup*.arts, TestSurf*.arts: Minor modifications. * AUTHORS: Added myself. * src/methods.cc: Spellfix. * controlfiles/planetary_toolbox/validation/common/spectroscopy/ SpecCat_Consistency_Perrin-vs-HITRAN.arts: Corrected f_grid setup. * doc/uguide/absorption_theory.tex: Minor layout fix. 2013-02-27 Mathias Milz * arts-2-1-523 * controlfiles/testdata/chevallierl91_all_extract.xml: included information of the source of these profiles. 2013-02-21 Richard Larsson * arts-2-1-522 * src/m_zeeman.cc: Now takes manual angles given the right GIN. Useful with Oliver's named argument implementation to make simplistic magnetic field calculations without having to recompile the code or having to specifically customize the magnetic field. * src/methods.cc: manual_zeeman_angles_on, manual_zeeman_theta and manual_zeeman_eta are added as GIN to abs_mat_per_speciesAddZeeman. The first is a tag that will set eta and theta to the other two accordingly. 2013-02-21 Oliver Lemke * arts-2-1-521 * New controlfile feature: Named arguments! Besides calling a workspace method with positional arguments, it is now possible to use named arguments. Omitted arguments will be set to their defaults. For specific inputs/outputs the default WSV will be used and for generic in/out the default value. For example, calling a method with all the default arguments and only pass in two custom values for the generic input required this code before: doit_i_fieldUpdateSeq1D( doit_i_field, doit_scat_field, cloudbox_limits, abs_mat_per_species_agenda, vmr_field, spt_calc_agenda, scat_za_grid, scat_aa_grid, pnd_field, opt_prop_part_agenda, ppath_step_agenda, ppath_lraytrace, p_grid, z_field, refellipsoid, t_field, edensity_field, f_grid, f_index, surface_rtprop_agenda, doit_za_interp, 1, 0.05 ) now one can simply write: doit_i_fieldUpdateSeq1D( normalize=1, norm_error_threshold=0.05 ) * src/parser.{h,cc}: Add named argument support. * src/sourcetext.h (SourceText): Add new member functions LineRaw, ColumnRaw and SetPosition. * src/methods.cc: Make generic input/output variables names more consistent. Generic output in ...Set... WSMs is called 'out', generic input that is usually given as a literal is called 'value' (e.g. in VectorSet or MatrixSetConstant), otherwise 'in'. Add docs for FieldFromGriddedField. Set default value for userparam to [] in abs_cont_descriptionAppend. * controlfiles/general/continua.arts, controlfiles/general/general.arts, controlfiles/artscomponents/doit/TestDOIT.arts: Updated to use named arguments. * doc/uguide/concept.tex: Add paragraph about named arguments. 2013-02-24 Patrick Eriksson * arts-2-1-520 * Doppler shift now also included in call of blackbody_radiation_agenda, as well as when calculating particle extinction. However, for efficiency reasons, for particles only the mean shift along the path is considered. This as it is time consuming to extract the data from scat_data_raw. So this is done assuming a constant shift along the path. This allows to at least include big shifts caused by e.g. satellite velocity. The smaller shifts are here of less importance as the particle extinction is quite smooth with frequency. * doc/uguide/winds.tex: Chapter revised. * doc/uguide/atmosphere.tex (section{Wind and magnetic vector fields}): * doc/uguide/rte.tex (section{Dispersion}): Some smaller changes related to revision of the Doppler chapter. * controlfiles/artscomponents/wfuns/TestWfuns.arts: * controlfiles/artscomponents/groundbased/TestGbased.arts: Removed some obselete stuff related to jacobians. * doc/uguide/matrix_vector.tex: Added that the mean function is defined for vector and matrix. Also added a small note that min. max and mean for matrices is for the complete matrix. * controlfiles/artscomponents/absorption/TestIsoRatios.arts: Changed rte_ to rtp_, where necessary. * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): * src/m_cloudradar.cc (iyCloudRadar): * src/m_rte.cc (iyEmissionStandard): Adopted to changes in rte.cc. * src/rte.cc (get_ppath_f): get_ppath_doppler renamed, as now shifted f_grid is returned, and not only the shift. (get_ppath_abs): Temporary solution for rtp_doppler, until settled how to handle frequency shifts for abslookup. (get_ppath_blackrad,get_ppath_ext): Now takes ppath_f as input. 2013-02-22 Richard Larsson * arts-2-1-519 * src/workspace.cc,methods.cc: Updated the documentation. * controlfiles/artscomponents/zeeman/TestZeeman.arts: Was broken by my last update. 2013-02-22 Stefan Buehler * arts-2-1-518 * src/methods.cc (SpeciesPartitionLookupOnthefly): Added. * src/m_abs_lookup.cc (SpeciesPartitionLookupOnthefly): Added. * src/agendas.cc (abs_xsec_agenda): Renamed from abs_xsec_per_species_agenda. * src/workspace.cc (abs_species_active): Added. (abs_species_lookup): Added. (abs_species_onthefly): Added. (abs_xsec_agenda): Renamed from abs_xsec_per_species_agenda. * controlfiles/general/agendas.arts (abs_xsec_agenda): Renamed from abs_xsec_per_species_agenda. 2013-02-21 Patrick Eriksson * arts-2-1-517 * Treatment of Doppler shifts streamlined. Now possible to include sensor movement (but so far only on iyCalc level), and prepared for frequency dependent shift. * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: Adopted call of iyRadioLink. * src/make_array.h: Had to add define MakeArray for 37 arguments. (iyRadioLink appearently has this record for input arguments). * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): * src/m_rte.cc (iyEmissionStandard): * src/m_cloudradar.cc (iyCloudRadar): Adopted to changes below. And now also taking rte_alonglos_v as input (passed on to get_ppath_doppler). * src/rte.cc (get_ppath_xxxx): Now winds and mag-field stored as vectors even for ppath_wind and ppath_mag. (get_ppath_doppler): New. Returns frequency dependent Doppler shift. (calc_doppler): Removed (replaced by function above). (get_ppath_abs): Now using ppath_doppler. 2013-02-21 Oliver Lemke * arts-2-1-516 * src/make_auto_md_cc.cc: Bug fix: Workspace method parameters that are defined to be exclusively used as output are initialized to a specific values in debug mode. Due to the bug, always the default variable was initialized, not the variable that was actually passed to the WSM, e.g.: IndexCreate(i) AtmosphereSet1D(i, lat_grid, lon_grid) Print(i) Print(atmosphere_dim) This code should throw an error in the 2nd Print statement that atmosphere_dim is uninitialized. Instead, although i was initialized correctly to 1, also atmosphere_dim was set to -1. Added initialization code for Tensor4-7. 2013-02-21 Stefan Buehler * arts-2-1-515 * src/m_abs.cc (abs_linesReadFromSplitArtscat): Use SpeciesTag::Type() to decide on type of species tag. * src/absorption.cc (checkIsotopologueRatios): Rewritten. Use abs_species only to decide what species to check. For the check itself, rely only on the built in species data and the external isotopologue ratio data. * src/species_data.cc: Corrected outdated H2O comment. * src/agendas.cc (abs_xsec_per_species_agenda): Added. Name may still change. * src/workspace.cc (abs_xsec_per_species_agenda): Added. Name may still change. * controlfiles/general/agendas.arts: Added defaults for abs_xsec_per_species_agenda. 2013-02-21 Patrick Eriksson * arts-2-1-514 * src/m_surface.cc: Changed rte_pos and rte_los to rtp_pos and rtp_los, following renaming of WSVs. * src/ppath.cc (plevel_slope_3d): Nadir cases exactly at upper longitude end, with 360 deg lon-coverage, failed. Found be Richard. This special case now fixed. Fixed also the parallel case of nadir measurements exactly at the North pole. (No change should be required for lower lon end and South pole.) Note that nadir measurements exactly at end points are in gernal not allowed. But the two cases above are exceptions. 2013-02-20 Richard Larsson * arts-2-1-513 * src/m_zeeman.cc: My last update broke Zeeman. 2013-02-20 Patrick Eriksson * arts-2-1-512 * Quite a lot of changes, but should for most simulations not require any changes of your cfile. The exception is of you define some agendas without using the pre-defined ones. You can then need to change some rte_xyz to rtp_xyz. Ask me if you are in doubt. * src/rte.cc (calc_doppler): Created. * controlfiles/general/general.arts * controlfiles/general/agendas.arts * controlfiles/general/agendas_surface.arts * controlfiles/artscomponents/surface/TestSurface.arts * controlfiles/artscomponents/transmission/TestTransmission.arts * controlfiles/artscomponents/groundbased/TestGbased.arts * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts * controlfiles/artscomponents/faraday/TestFaradayRotation.arts * controlfiles/artscomponents/radiolink/TestRadioLink.arts * controlfiles/artscomponents/radiolink/TestRadioLink2.arts * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: Adopted to new WSV names. * src/methods.cc: Adopted to WSV changes below + fixed some incorrect doc-text. * src/workspace.cc: Tried to introduce a clearer distinction between variables defining a calculation to solve the radiative transfer equation (rte_xyz), and variables at a point along the path needed to calculate radiative transfer properties (rtp_xyz). "rtp" can also stand for radiative transfer point, select the full name you prefer This means that several variables before starting with rte now starts with rtp, for example, we now have rtp_temperature. Note that ppath_los is renamed to rtp_los for consistency. Totally new WSV: rte_alonglos_v, rtp_pos In addition, rte_vmr_list renamed to rtp_abs_species 2013-02-20 Richard Larsson * arts-2-1-511 * src/absorption.cc (xsec_species): Returns both phase and attenuation line shape. This halves the time spent in line shape functions for Zeeman and it is in preparation for the addition of first order line mixing (which still will require an additional database). * src/rte.cc (get_ppath_trans): Halves the time spent on Faraday rotation for special cases by moving matrix definition and adding parallellisation. * src/m_abs.cc,m_abs_lookup.cc (several places): Changed to allow for phase and attenuation shapes. Also prepared for line mixing. * src/workspace.cc: abs_lineshape_zeeman_phase is now gone. abs_xsec_per_species is replaces by abs_xsec_per_species_attenuation and abs_xsec_per_species_phase. * src/lineshapes.cc: Line shapes now accept and returns a phase line shape. Only algorithm 916 returns phase so far. * src/absorption.h,m_abs_lookup.cc: Changed necessary parts. * src/m_rte.cc: Slight speed improvement for special cases. 2013-02-20 Oliver Lemke * arts-2-1-510 * CMakeLists.txt: Account for bugfix in cmake 2.8.10 [1]. They now enable NDEBUG also in RelWithDebInfo configuration which turns off assertions. We don't want that. [1] http://public.kitware.com/Bug/view.php?id=11366 2013-02-20 Patrick Eriksson * arts-2-1-509 * doc/uguide/surface.tex: Now using symbol_defs more heavily. Some changes to be consistent with rte_basic.tex. * src/methods.cc: Gin-variable of refellipsoidOrbitPlane had a name inconsistent with header text. * doc/uguide/rte.tex: Revised. Made consistent with rte_basic.tex and using symbol_defs throughout. * doc/uguide/symbol_defs.tex: Introduced emission soure and general source vectors, and transmission matrix. And changed the symbol for the Stokes vector to small i, to be consistent with all other vectors. * doc/uguide/rte_basics.tex: Now strictly following symbol_defs. * doc/uguide/rte_basics.tex: * doc/uguide/complete_calcs.tex: * doc/uguide/atmosphere.tex: Smaller fixes after a quick reading of these chapters. 2013-02-19 Patrick Eriksson * arts-2-1-508 * src/workspace.cc (define_wsv_data): Removed old (now incorrect) comment for wind_v_field. * doc/uguide/atmosphere.tex: Changed to the Ionopsheric section to instead treat vector fields, as a common discussion area for wind and magnetic fields. Chapter also updated with respect to abs_species_field. * doc/uguide/common.tex: The text was poorly centered on page. Decreased \voffset with 0.5 cm, and increased \textheight to 23cm (+1cm). * doc/uguide/CMakeLists.txt: * doc/uguide/arts_user.tex: Included chapter below. * doc/uguide/complete_calcs.tex: New chapter. Fileld with some new text and stuff from rte.tex. 2013-02-18 Patrick Eriksson * arts-2-1-507 * doc/uguide/rte_basics.tex: Revised. 2013-02-15 Oliver Lemke * arts-2-1-506 * src/check_input.cc (chk_atm_field): Increase epsilon by factor of 2 to account errors propagating from weigths in interpolation. Might still be too low for some cases. 2013-02-14 Oliver Lemke * arts-2-1-505 * src/parser.{cc,h}: Reindent before upcoming changes. 2013-02-13 Stefan Buehler * arts-2-1-504 * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Improved runtime error message. Now give tag name if there is an interpolation error. 2013-02-13 Oliver Lemke * arts-2-1-503 * src/m_abs.cc (WriteMolTau): Use a Tensor4 instead of a plain C array for tau. Static arrays are limited by the stack size and we can easily break that barrier leading to a segfault. Fixes bug reported by Xingjuan Wang. Also fix the loop variables over stokes_dim. 2013-02-12 Patrick Eriksson * arts-2-1-502 * doc/uguide/rte_basics.tex: Completed a first version of the chapter (with tentative WSV names). 2013-02-12 Patrick Eriksson * arts-2-1-501 * doc/uguide/rte.tex: Section on Stokes vector moved to rte_basics.tex. * doc/uguide/CMakeLists.txt: Added file below. * doc/uguide/rte_basics.tex: New chapter. Just started. * doc/uguide/arts_user.tex: Intrododuced parts. The sections rearranged to obtain an OK part structure. And included the new chapter above. 2013-02-12 Patrick Eriksson * arts-2-1-500 * controlfiles/artscomponents/wfuns/TestWfuns.arts: Added a comment. * src/methods.cc: Corrected and improved text for jacobianAddWind. For jacobianAddTemperature, changed default for hse to "on" as this option now works also for "analytical". And changed default for "dt" to 0.1. * src/workspace.cc: Removed rte_do_t and rte_do_vmr_jacs. Obselete since looong ago. 2013-02-11 Oliver Lemke * arts-2-1-499 * src/disort.cc (dtauc_ssalbCalc): Remove dodgy if statement. 2013-02-11 Oliver Lemke * arts-2-1-498 * Add support for testcases that depend on arts-xml-data. cmake will look for a-x-d in the same path as the arts source or at a custom location specified by the user with: cmake -DARTS_XML_DATA_PATH=/home/myname/arts-xml-data .. If a-x-d is not found, tests depending on it will not be run. Look at the bottom of controlfiles/CMakeLists.txt for an example on how to define testcases that need a-x-d. * CMakeLists.txt: Add support for ARTS_XML_DATA_PATH. * cmake/modules/ArtsTestcases.cmake: Add -D option to arts call if arts-xml-data path is defined. * controlfiles/CMakeLists.txt: Add example for a-x-d dependency. * README: Updated with info about ARTS_XML_DATA_PATH. 2013-02-11 Oliver Lemke * arts-2-1-497 * src/file.cc (file_exists): Was falsely returning true if the given file was a directory. Led to a segfault if controlfile contained e.g. INCLUDE "general" 2013-02-09 Oliver Lemke * arts-2-1-496 * src/continua.cc (CKD_mt_100_self_h2o, CKD_mt_100_foreign_h2o, CKD_mt_co2, CKD_mt_co2, CKD_mt_CIAfun_o2): Use Vector instead of Numeric C-style arrays. O2-CIAfunCKDMT100 was suffering from the same indexing bug as N2-CIAfunCKDMT100, leading to a negative peak right at the upper end of the valid range of the continua. 2013-02-07 Patrick Eriksson * arts-2-1-495 * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: Changed as cfile below. * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Last commit gave error for this test, on Hudson. I also tried three different platform/compiler combinations and got three different results! (though one looked to match Hudson). My only conclusion is that compiler differences give slightly different link paths, which cause significant errors for the estimation of defocusing. The bending angle sensitivity to the compiler differences seems to be below 1e-4 deg, but this is not sufficient! Now changed to a shorter ray tracing length. And using second defocus method (that appears to be more stable). Relative difference for defocus between compilers seems to be about 0.5% with these settings. High to be just a compiler issue, but OK. * src/methods.cc (iyRadioLink): Changed default for defocus_shift to 1e-3. Old value too low considering the problems discussed above. 2013-02-07 Patrick Eriksson * arts-2-1-494 * controlfiles/artscomponents/faraday/test_faraday.m: A small file for further testing of the obtained rotation. The result was found to deviate with less than 0.002 deg to the calculation done in this file. * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Sharpened the compare accuracy for the rotation part. * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: Revised, comparsion added, and included as a slow check. * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Changed settings somewhat and activated comparison to references. 2013-02-07 Oliver Lemke * arts-2-1-493 * src/methods.cc, src/m_doit.cc (doit_i_fieldUpdateSeq1D), src/doit.{h,cc} (doit_scat_fieldNormalize): Temporarily add a debug flag that can be set to 1 to always output the max. DOIT normalization factor for the current iteration to out0 instead of out2. 2013-02-07 Oliver Lemke * arts-2-1-492 * src/m_general.{cc,h} (Print): Implement Print for ArrayOfCIARecord. Same output format as CIAInfo. * src/m_cia.cc (CIAInfo): Use new Print() for output. 2013-02-07 Oliver Lemke * arts-2-1-491 * src/m_cia.cc (abs_cia_dataReadFromCIA): Check both combinations for the two CIA species when looking for input files (e.g. Ar-CH4.cia and CH4-Ar.cia). 2013-02-07 Stefan Buehler * arts-2-1-490 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag(String def)): Fixed runtime error message when second species is unknown. * src/species_data.cc: Added species Ar, which is needed for HITRAN CIA continua. * src/partition_function_data.cc: Added species Ar, which is needed for HITRAN CIA continua. 2013-02-06 Oliver Lemke * arts-2-1-489 * Bug fixed in N2-CIAfunCKDMT100 continuum reported by Josef Gasteiger. This indexing bug caused wrong values of different magnitude depending on frequency range, operating system and compiler version. * src/continua.cc: (XINT_FUN): Add second implementation that takes a ConstVectorView as input. (CKD_mt_CIArot_n2): Replace C-type Numeric arrays with Vectors to enable boundary checks. (CKD_mt_CIAfun_n2): Replace C-type Numeric arrays with Vectors to enable boundary checks. Fix array-index-out-of-bounds access by extending the size of the coefficient array k by one 0-value. * Bounds-checking for the other continua will be added next to see if any of them are affected by similar bugs. 2013-02-06 Patrick Eriksson * arts-2-1-488 * doc/uguide/transmission.tex: Chapter revised and updated. Now synced with the source code. * doc/uguide/CMakeLists.txt: transmission.tex was not included. * controlfiles/artscomponents/faraday/farrot_totalREFERENCE.xml: Converted data from rad to deg. * doc/uguide/faraday.tex (section{Practical usage}): Units updated, follwoing the changes below. * src/m_transmitter.cc (iyTransmissionStandard, iyRadioLink): Changed output unit for Faraday rotation variables fro rad to deg. This to be consistent with the fact that degrees is used elsewhere for input and output angles. That is, we are not using the SI unit for angles (but better being consistent, than partly doing this) !!! * src/rte.cc (get_ppath_trans): Fixed bad spelling in header text. * src/methods.cc: Wrote on-line doc for iyRadioLink. Updated text for ppathFromRtePos2. 2013-02-05 Patrick Eriksson * arts-2-1-487 * src/rte.cc (defocusing_general_sub): Now also returning radiative background. (defocusing_general): Now also handling the case if the lower of the calculations hits the ground. * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: Adopted to change below. * src/m_transmitter.cc (iyRadioLink): Now "method 1" is the more general defocus algorithm. Realised that size of some aux vars could be made even more compact. Also started to write documentation in methods.cc. 2013-02-04 Patrick Eriksson * arts-2-1-486 * src/rte.cc (defocusing_general): Now taking dza from calling function (before hard-coded). (defocusing_sat2sat): As above + fixed error in calculation (impact paramater was mixed up with geometrical ztan) + now not crashes if any of the two extra calculations hits the surface. * src/m_transmitter.cc (iyRadioLink): Made angular shift to use for defoc-calculations a method input. 2013-02-04 Oliver Lemke * arts-2-1-485 * src/xml_io_array_types.cc, src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Implement XML reading/writing of CIARecord and ArrayOfCIARecord. * src/methods.cc, src/m_cia.cc: Add abs_cia_dataReadFromXML. Reads CIA data from XML file and checks that all CIA species from abs_species are defined in that file. * src/cia.h (CIARecord): Change runtime errors to assertions in getters. Add getter for const reference to mdata. Be friend with xml_read_from_stream. 2013-02-01 Patrick Eriksson * arts-2-1-484 * src/m_ppath.cc (ppathFromRtePos2): Fixed and tuned the criterion for determining that a ground-intersection is found (there was a sign error in the logical expression). 2013-02-01 Stefan Buehler * arts-2-1-483 * src/species_data.cc (H): Added missing species H, needed for CIA continua. * src/partition_function_data.cc (H): Ditto. 2013-02-01 Jana Mendrok * arts-2-1-482 * controlfiles/artscomponents/arts-xml-data/TestSurf_Mars.arts: Added. Data testing controlfile for Mars surface data. * controlfiles/artscomponents/arts-xml-data/TestSurf_[Earth,Venus].arts: Cosmetics. 2013-01-30 Jana Mendrok * arts-2-1-481 * controlfiles/artscomponents/arts-xml-data/TestSurf_Venus.arts: Added. Data testing controlfile for Venus surface data. * controlfiles/artscomponents/arts-xml-data/TestSurf_Earth.arts: Polished that one (testing of Earth surface characterization data) a little. 2013-01-30 Oliver Lemke * arts-2-1-480 * src/m_atmosphere.cc (GriddedFieldLatLonRegrid): Fix copy/paste error in loop for GriddedField4. 2013-01-30 Patrick Eriksson * arts-2-1-479 * src/ppath.cc (ppath_start_stepping): Made a small change that should allow the sensor longitude and lon_grid to have different lon-ranges. For example, a lon_grid between -100 and 0 and a sensor longitude of 310 should now work. Before it was a bit random if such cases were OK or not, as pointed out by Jana. (Not heavily tested, I leave this to Jana!) 2013-01-30 Patrick Eriksson * arts-2-1-478 * controlfiles/general/planet_earth.arts: * controlfiles/general/planet_venus.arts: * controlfiles/general/planet_mars.arts: * controlfiles/general/planet_jupiter.arts: g0_agenda now defined locally. * controlfiles/general/agendas.arts: Removed all definitions of g0_agenda-s. This to make the planet files totally independent of this file. 2013-01-30 Patrick Eriksson * arts-2-1-477 * src/ppath.cc (do_gridcell_3d_byltest): My fix yesterday was not OK. The call of resolve_lon now made at an earler stage. 2013-01-30 Oliver Lemke * arts-2-1-476 * src/logic.{cc,h} (is_lon_cylic): New function to check for a cyclic longitude grid. * src/interpolation_poly.cc: Use new is_lon_cyclic. * src/m_atmosphere.cc (GriddedFieldLatLonRegrid): Check that data values at 0 and 360 degrees agree in cyclic lon grids. 2013-01-29 Stefan Buehler * arts-2-1-475 * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Throw runtime error if VMR of second species in CIA collision pair does not exist. (Instead of simply crashing.) 2013-01-29 Patrick Eriksson * arts-2-1-474 * src/ppath.cc (do_gridcell_3d_byltest): The last point of the steps was not passed through resolve_lon. (Jana, the case you sent now runs OK.) 2013-01-29 Jana Mendrok * arts-2-1-473 * src/m_atmosphere.cc (z_fieldFromHSE): Downgraded missing-H2O-error to a warning (when no H2O tag setting h2o_vmr=0. of course.). Deviations between including and excluding H2O in tropical atmo are <30m for z<100km and <50m for z<1500km (so, H2O not that relevant at all :-O ). * src/[m_basic_types,methods].cc (Compare): Added Tensor3 capability. 2013-01-29 Oliver Lemke * arts-2-1-472 * src/interpolation_poly.cc (gridpos_poly_longitudinal): Add missing call to chk_interpolation_grids for the case when the lons don't have to be shifted. Fixes bug reported by Jana. 2013-01-29 Jana Mendrok * arts-2-1-471 * controlfiles/artscomponents/arts-xml-data/*.arts: Added. Controlfiles for testing the data (format, functionality on rather crude level, ...). Currently restricted to data added for the planetary toolbox. For the moment includes tests of basic and suppl. atm fields data for all 4 planets, surface fields for earth; more to come). Currently not part of a check target (but shall become, once a target for cases applying arts-xml-data package is created - Oliver!?!) * controlfiles/general/agendas_surface.arts: Another predefined surface agenda added (lambertian refl. with surface_skin_t from t_field). * src/[methods,workspace].cc: some spellfixes. 2013-01-28 Patrick Eriksson * arts-2-1-470 * src/m_transmitter.cc (iyRadioLink): The setting of iy_aux for "fatal" cases did not work. * src/rte.cc (iyb_calc): More stringent check of iy_aux_array. 2013-01-28 Patrick Eriksson * arts-2-1-469 * controlfiles/general/agendas.arts: Adopted definition of ppath_agenda__TransmitterReceiverPath. * src/m_ppath.cc (ppathFromRtePos2): Now switched to use new version of the method. (Old version deleted) * src/m_transmitter.cc (iyRadioLink): Now also accepting "unvalid" ppaths. This gives iy=NaN. * src/ppath.cc (ppath_set_background,ppath_what_background): Defined string for case 0 to be "unvalid" (before just ""). * src/lin_alg.cc: Added type casting where dividing with an integer number. 2013-01-27 Patrick Eriksson * arts-2-1-468 * src/m_ppath.cc (ppathFromRtePos2V2): Work in progress ... * controlfiles/artscomponents/doit/TestDOIT.arts: Adopted call of doit_i_fieldUpdateSeq1D. * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: Adopted call of iyRadioLink. * controlfiles/general/general.arts: ppath_lraytarce now set (to 1 km). * src/rte.cc (defocusing_general_sub, defocusing_general) (defocusing_sat2sat): * src/m_montecarlo.cc (MCGeneral): * src/montecarlo.cc (mcPathTraceGeneral): * src/m_transmitter.cc (iyRadioLink, iyTransmissionStandard): * src/m_rte.cc (iyEmissionStandard, iyMC): * src/m_doit.cc (doit_i_fieldUpdate1D, doit_i_fieldUpdateSeq1D) (doit_i_fieldUpdateSeq3D): * src/m_cloudradar.cc (iyCloudRadar): * src/doit.cc (cloud_ppath_update1D, cloud_ppath_update1D_noseq) (cloud_ppath_update3D): * src/m_ppath.cc: * src/ppath.cc (ppath_calc): Adopted calls of ppath_agenda and ppath_step agenda. Had to add ppath_lraytrace as input to most of the functions. * src/agendas.cc: Added ppath_lraytrace as input to ppath_agenda and ppath_step agenda, to allow algorithms to adjust this variable. * src/lin_alg.cc (linreg): Made a bit more robust regarding numerical problems, by instead making fit for x' = (x-mean(x)). * src/m_transmitter.cc (iyRadioLink): Impact parameter now set through ppath.constant. Now also handling the case of surface intersections (iy retiunred as 0 and iy_aux empty). * doc/uguide/ppath.tex: Improved description of ppath.constant, and fixed dead section reference. 2013-01-25 Patrick Eriksson * arts-2-1-468 * src/lin_alg.cc (linreg): Created. 2013-01-25 Patrick Eriksson * arts-2-1-467 * src/m_ppath.cc (ppathFromRtePos2V2): Trying to make a better version of the method. Not yet reached the critical part. 2013-01-24 Patrick Eriksson * arts-2-1-466 * src/m_transmitter.cc (iyRadioLink): Added impact parameter as aux variable. 2013-01-24 Oliver Lemke * arts-2-1-465 * src/m_atmosphere.cc (AtmRawRead): Bug fix. Resize vmr_field_raw to 0 before starting to append to it. * src/cia.cc (CIARecord::AppendDataset): Fix temperature grid index. 2013-01-22 Jana Mendrok * arts-2-1-464 * src/check_input.cc (chk_atm_field, chk_atm_surface): Replaced all checks for fabs(a-b)>0 (in checking constancy at poles and cyclicity at longitudes) by is_same_within_epsilon(a,b,2*DBL_EPSILON) to avoid number accuracy issues. * src/logic.cc (is_same_within_epsilon): Minor bug fix (correct handling of negative numbers) * src/methods.cc,workspace.cc: Cosmetics. * src/m_atmosphere.cc (basics_checkedCalc): Cosmetics. 2013-01-21 Stefan Buehler * arts-2-1-463 * src/cia.{h,cc}: Introduced robust option for CIA extraction. If set to 1, then being outside the temperature range of the data will not give a runtime error, only return NAN. The default is 0, which means that there will be a runtime error. * src/m_cia.cc: Ditto. * src/test_cia.cc: Adapted to robust option. * src/methods.cc (abs_xsec_per_speciesAddCIA): Added the robust option. * src/m_basic_types.h (nelemGet): Implemented for group ArrayOfArrayOfSpeciesTag. 2013-01-21 Stefan Buehler * arts-2-1-462 * src/cia.cc (cia_interpolation): Fixed (last?) bug. Validation ongoing. * src/matpackI.cc (VectorView::operator MatrixView): Cosmetic changes to my fix from last Friday. (ConstVectorView::operator ConstMatrixView): Ditto. * src/test_matpack.cc (test42): Expanded the test. 2013-01-21 Oliver Lemke * arts-2-1-461 * src/test_cia.cc: Fix compile error. 2013-01-20 Patrick Eriksson * arts-2-1-460 * controlfiles/artscomponents/clearsky/TestClearSky2.arts: Corrected header text. Last ChangeLog message for this file is wrong. This file tests particularly ySimpleSpectrometer. 2013-01-18 Stefan Buehler * arts-2-1-459 * src/cia.{h,cc}: Debugging. But the CIA data as read from the HITRAN files right now seem strange: Mostly negative values! Perhaps still a bug in the reading routine? * src/m_cia.cc: Cosmetics. * src/matpackI.cc (VectorView::operator MatrixView): This function contained a bug that was triggered in the case that the original VectorView had a non-zero start. Fixed now. (ConstVectorView::operator ConstMatrixView): Ditto. * src/test_matpack.cc (test42): Test the matpack bugfixes. * controlfiles/artscomponents/cia/TestCIA.arts: Work in progress. 2013-01-18 Oliver Lemke * arts-2-1-458 * src/cia.cc (CIARecord::ReadFromCIA): Reuse istringstream. Better input error checking. * src/methods.cc: Update docs for CIAInfo. 2013-01-18 Oliver Lemke * arts-2-1-457 * src/cia.{h,cc}: (CIARecord::ReadFromCIA): Fix bug in parsing. (DatasetCount, TemperatureGrid, FrequencyGrid, Dataset): New members for CIARecord to access the datasets. * src/m_cia, src/methods.cc: Add CIAInfo. Remove abs_cia_dataInit. 2013-01-18 Stefan Buehler * arts-2-1-456 * src/gas_abs_lookup.cc (Extract): Implemented feature requested by Jana: Throw a runtime error if one of the reference VMR profiles is zero, but abs_vmrs is not. (This means that the lookup table was calculated with a reference profile of zero for that gas.) Not yet tested, since I don't have a suitable test case. 2013-01-18 Oliver Lemke * arts-2-1-455 * src/abs_species_tags.{h,cc} (SpeciesTag): mcia -> mcia_second, Cia() -> CIASecond, CiaDataset -> CIADataset * src/cia.{h,cc} (cia_get_index): Helper to find index in CIA data. (Extract): Add parameter dataset index. Use index instead of loop. * src/m_cia (abs_xsec_per_speciesAddCIA, abs_cia_dataReadFromCIA): Adapt for changed type of abs_cia_data. * src/nc_io_types.h, src/xml_io_instantiation.h, src/xml_io_types.h, src/workspace.cc, src/nc_io_array_types.cc, src/xml_io_array_types.cc, src/groups.cc: Change type of abs_cia_data to ArrayOfCIARecord. Remove ArrayOfArrayOfCIARecord as a group and add ArrayOfCIARecord instead. 2013-01-18 Patrick Eriksson * arts-2-1-454 * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: Missed to do svn add on the file. * src/m_ppath.cc (ppathFromRtePos2): Init ip to dummy value of -999, to avoid compiler warning. And changed defualt for dl_ok to 0.5. Seems to cover the worst case for TestRadioOccultation.arts (tried 500 angles). 2013-01-17 Patrick Eriksson * arts-2-1-453 * controlfiles/artscomponents/radiolink/TestRadioOccultation.arts: A control file simulating a complete occultation. * src/m_ppath.cc (ppathFromRtePos2): The method now operates with a target and OK level for the "miss distance". This to allow for aimimg at a high acccuracy but not getting an error directly when that accuracy can not be achived. To achieve this, variables and code added so that the previous ppath can be selected as the solution. * src/methods.cc: Some further polishing of the text for Append. * src/m_ppath.cc (TangentPointPrint): Extended the output somewhat. 2013-01-17 Stefan Buehler * arts-2-1-452 * src/abs_species_tags.{h,cc} (SpeciesTag::CiaDataset): Added this function (and associated private member) to store the index of the dataset to use (inside the CIA file), which is also now appended at the end of the CIA species tag. (SpeciesTag::SpeciesTag): Parse also the new dataset index at the end of the CIA tag. It must be present! (SpeciesTag::Name): Fixed broken CIA tag name output. Not testet! * src/cia.{h,cc} (cia_interpolation): Continued to work on this. * src/m_cia.cc: Cosmetics. * controlfiles/artscomponents/cia/TestCIA.arts: Updated for new CIA tag names with dataset index. 2013-01-17 Richard Larsson * arts-2-1-451 * licenses/*: Added various license agreements to this folder so that it is clear what code is reusable with ARTS. * src/lineshapes.cc: Added Algorithm 916 (see code for details) to calculate the Faddeeva function. The Faddeeva function offers a solution to both the Voigt and Faraday-Voigt lineshapes. The current implementation is very slow, as it calculates the line shapes twice even though one calculation is mathematically sufficient. I suggest a complex_xsec function returning two vectors in a future update instead of returning the real and complex values as separate line shapes. The line shapes were tested within the limit of the Zeeman model paper and deemed OK. * src/Faddeeva.{cc,hh}: Added. The bulk of the new line shape code is in here. These files fall under the MIT/X11 licence. More in the files. * src/CMakeLists.txt: Faddeeva should be in list in list. * src/workspace.cc: Added a phase lineshape variable. * src/methods.cc: Require another lineshape variable for m_zeeman.cc. * src/m_zeeman.cc: Split phase from attenuatiion polararization matrices. Requires another line shape without caring which type, though for physical reason this line shape should be Faraday-Voigt. * controlfiles/artscomponents/zeeman/*: Changed necessary bits to work since a new line shape changes results. Change in reference is on order of 0.02 K. 2013-01-17 Oliver Lemke * arts-2-1-450 * src/m_append.h, src/methods.cc (Append): Clarify built-in docs and add support for appending Vectors row- or column-wise to Matrices. 2013-01-17 Oliver Lemke * arts-2-1-449 * ChangeLog: Part of a sentence got lost. 2013-01-17 Oliver Lemke * arts-2-1-448 * src/doit.{cc,h} (doit_scat_fieldNormalize): New function to scale doit_scat_field with correction factor derived from difference between scattered field and scattered extinction field. * src/methods.cc, src/m_doit.cc (doit_i_fieldUpdateSeq1D): Add parameters scat_aa_grid, normalize and norm_error_threshold. Make doit_scat_field input and output. Call doit_scat_fieldNormalize if turned on. (doit_i_fieldUpdate1D, doit_i_fieldUpdateSeq1DPP): Set doit_i_field also as input. * src/doit.{cc,h} (doit_scat_fieldNormalize): Add new function for calculate the scattered extinction field and apply correction factor to doit_scat_field. * controlfiles/artscomponents/doit/TestDOIT.arts: Turn on new normalization in doit_i_fieldUpdateSeq1D. * controlfiles/general/agendasDOIT.arts: Add comment with example code to turn on new normalization in DOIT. * src/workspace.cc: Fix typo. * README: Add missing =1. 2013-01-16 Stefan Buehler * arts-2-1-447 * src/cia.{h,cc} (CIARecord::Species): Added this function, which returns the contents of mspecies. (CIARecord::Extract): Started on implementation of this, but realized that guessing the right dataset is too difficult, we have to make this a user choice. (CIARecord::ReadFromCIA): Now converts the binary absorption cross-sections to ARTS SI units. * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Implemented this. (abs_cia_dataReadFromCIA): To decide whether this is a CIA species, Use SpeciesTag.Type() function instead of SpeciesTag.Cia() * src/methods.cc (abs_cia_dataReadFromCIA): Added built-in documentation on units. * src/workspace.cc (abs_cia_data): Revised built-in documentation. 2013-01-15 Stefan Buehler * arts-2-1-446 * src/abs_species_tags.{h,cc} (SpeciesTag): Removed member mzeeman, instead added member mtype, which can be TYPE_PLAIN, TYPE_ZEEMAN, TYPE_PREDEF, TYPE_CIA. Added also public member function Type() for this and removed public member function Zeeman(). Adapted member functions to this change. (is_zeeman): Added this function for ArrayOfSpeciesTag, which can be used if a tag group is a Zeeman group. This has to be checked for the whole group, not just for the first tag, since the Zeeman tags could be in the middle. They could be mixed with continuum tags (but not with normal line-by-line tags.) * src/absorption.cc: Cosmetics. * src/m_abs.cc (abs_xsec_per_speciesAddLines): Adapted to new is_zeeman function. (abs_xsec_per_speciesAddConts): Adapted to new SpeciesTag::Type() function. * src/m_abs_lookup.cc (abs_lookupCalc): Adapted to new is_zeeman function. * src/m_zeeman.cc (abs_mat_per_speciesAddZeeman): Adapted to new is_zeeman function. * controlfiles/artscomponents/cia: Added. For CIA testing. * controlfiles/artscomponents/cia/TestCIA.arts: Added. * controlfiles/artscomponents/cia/README.txt: Added. 2013-01-15 Jana Mendrok * arts-2-1-445 * src/partition_function_data.cc: Replaced infunctional data: O and He were constant -1, which triggers a runtime error. CH3OH was constant 0, which would have caused an uncaught bug (division by 0) if ever used. For CH3OH and O TIPS provides constant 0, which is rubbish. Replaced those by JPL data instead. He set to constant 1. * src/absorption.h (CalculatePartitionFctRatio): Make sure qtemp==0 throws a runtime error, too, avoiding div0. * 3rdparty/partFct/partition_functions.py: Added functionality for deriving partition function coefficients from JPL for CH3OH and O. 2013-01-11 Patrick Eriksson * arts-2-1-444 * src/m_transmitter.cc (iyTransmissionStandard): As below. * src/m_rte.cc (iyEmissionStandard): Added else{ assert(0); }, for extra safety and to avoid warning regarding dkdx1/2. 2013-01-11 Oliver Lemke * arts-2-1-443 * src/cia.{cc,h}: (CIARecord::ReadFromCIA): Implemented. (CIARecord::AppendDataset): Added private helper function. (CIARecord::MoleculeName, CIARecord::SetMoleculeName, CIARecord::Extract): Renamed. * src/m_cia.cc (abs_cia_dataReadFromCIA): Renamed. Removed output. * src/methods.cc: Renamed abs_cia_dataReadFromCIA. * src/cia.cc, src/cia.h, src/groups.cc, src/m_cia.cc, src/nc_io_array_types.cc, src/nc_io_types.h, src/workspace.cc, src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: CiaRecord -> CIARecord. 2013-01-11 Stefan Buehler * arts-2-1-442 * src/abs_species_tags.{h,cc} (species_name_from_species_index): Added this new helper function. * src/m_cia.cc (abs_xsec_per_speciesAddCIA): Added stubb for this method. * src/make_auto_md_h.cc: Cosmetics. * src/make_auto_workspace_h.cc: Cosmetics. * src/methods.cc (abs_xsec_per_speciesAddCIA): Added. (abs_xsec_per_speciesAddConts): Added missing abs_xsec_per_species in input list. (abs_xsec_per_speciesAddLines): Added missing abs_xsec_per_species in input list. * src/cia.{h,cc}: More members for CiaRecord: get_molecule_name, set_molecule_name. * src/CMakeLists.txt: Added m_cia.cc to target test_cia. * src/workspace.cc (abs_cia_data): More extensive built-in documentation. 2013-01-10 Jana Mendrok * arts-2-1-441 * src/species_data.cc: Updated HC3N data with latest HITRAN info. 2013-01-10 Jana Mendrok * arts-2-1-440 * doc/uguide/absorption.tex: Added a subsection on absorption lookup table format. * src/methods.cc,workspace.cc: Improved documentation around abs_coef and abs_mat_field. * controlfiles/planetary_toolbox/validation/common/spectroscopy/ SpecCat_Consistency_Perrin-vs-HITRAN.arts: Improved spectroscopy-consistency validation case. 2013-01-10 Oliver Lemke * arts-2-1-439 * Intermediate commit of work in progress. * src/cia.{h,cc}, src/test_cia.{cc}: Add dummy output operator for CiaRecord. typedef for ArrayOfArrayOfCiaRecord. cia_record -> CiaRecord. Fix doxygen macros. (CiaRecord::ReadFromCia, SetSpecies): Added. Rename member variables for to mspecies and mdata. * src/file.{cc,h} (list_directory): Add function to get a list of files in directory. * src/methods.cc: Add abs_cia_dataInit and abs_cia_dataReadFromCia. * src/groups.cc: Add ArrayOfArrayOfCiaRecord. * src/make_auto_md_h.cc, src/make_auto_workspace_h.cc: Include cia.h in generated code. * src/workspace.cc: Add WSV abs_cia_data. * src/src/abs_species_tags.{cc,h}: Add mcia member to SpeciesTag. (SpeciesTag::SpeciesTag): Parse CIA tags. * src/m_cia.cc: New file. * src/nc_io_array_types.cc, src/nc_io_types.h, src/xml_io_array_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add ArrayOfArrayOfCiaRecord. No implemententations, just skeleton. * src/CMakeLists.txt: Add cia.cc and m_cia.cc to artscore. 2013-01-10 Jana Mendrok * arts-2-1-438 * controlfiles/planetary_toolbox/PassiveMW.arts: Removed. * controlfiles/planetary_toolbox/includes/[common,jupiter/]*.arts: Added. Folders for collections of functional include controlfiles for the planetary toolbox. Several controlfiles added, documentation still to be done. * controlfiles/planetary_toolbox/validation/[common,passive]/: Added. Structure for validation cases (controlfiles & output(?)). 2013-01-10 Jana Mendrok * arts-2-1-437 * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Set in effect catch for broad_spec_vmr_sum==0 with additional catch of vmr_self==0 simultaneously (that can happen now that we apply zero-padding in AtmFieldsCalc when p_grid exceeds range of all gas profiles of the atm scenario). !!! In the latter case, xsec will be 0 - needs to be confirmed whether this is consistent with the general use of LUT (in general, abscoefs=xsec*vmr are 0 for vmr=0, but xsec are defined to be independent of vmr. that is, with the current solution we could get problems when trying to use this LUT for non-zero vmr) !!! * src/m_abs_lookup.cc (abs_lookupInit): Proper initialization of (empty) abs_lookup. * src/workspace.cc (abs_lookup): Corrected reference to corresponding section in AUG. 2013-01-07 Jana Mendrok * arts-2-1-436 * src/check_input.[cc,h] (chk_atm_vecfield_lat90): Nicer error message when problems at poles. Increased (temporarily?) deviation threshold to 1 per mille. We might need a better lon-regridding routine here (as vector fields do not vary linearily, but sinusoidal), but current issues anyway seem to already be in the original data (AI JM: check that data!). * src/m_atmosphere.cc (basics_checkedCalc): minor layout fix. 2013-01-03 Stefan Buehler * arts-2-1-435 * src/test_cia.cc (test01): Some basic testing of the interpolation. Seems to work fine. * src/cia.{h,cc}: Debugging. 2013-01-02 Stefan Buehler * arts-2-1-434 * src/cia.{h,cc}: First draft of CIA data interpolation. Not yet tested at all. Should next be tested in test_cia.cc. 2012-12-23 Patrick Eriksson * arts-2-1-433 * doc/uguide/transmission.tex: Fixed a typo. 2012-12-23 Patrick Eriksson * arts-2-1-432 * controlfiles/artscomponents/clearsky/TestClearSky2.arts: New test, mainly to test iyReplaceFromAux. Added as a slow one. * src/m_sensor.cc (ySimpleSpectrometer): New. * doc/uguide/transmission.tex: Added reference to iyReplaceFromAux. * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: iyReplaceFromAux now used. * src/m_rte.cc (iyReplaceFromAux): New. 2012-12-22 Patrick Eriksson * arts-2-1-431 * doc/uguide/surface.tex: Some editing to incorporate a sub-section moved to this chapter. This removed one of the existing FIXME. * doc/uguide/wfuns.tex: A smaller extension of polyfit section. Added section on sinefit. 2012-12-20 Patrick Eriksson * arts-2-1-430 * src/m_jacobian.cc: (jacobianCalcPointingZaInterp): Added check that length of mblock_za_grid allows an interpolation. * src/constants.cc: Removed FREQUENCY_SUBTAG_A and FREQUENCY_CALCMODE_A, not used anymore. 2012-12-19 Patrick Eriksson * arts-2-1-429 * controlfiles/artscomponents/wfuns/TestWfuns.arts: Added a call of jacobianAddWind. * src/m_transmitter.cc (iyTransmissionStandard): Added handling of wind jacobians. * src/m_rte.cc (iyEmissionStandard): Added handling of wind jacobians. No detailed test performed yet.q * src/jacobian.cc (get_pointers_for_analytical_jacobians): Extended to cover winds. * src/m_jacobian.cc (jacobianAddWind) (jacobianCalcWindAnalytical): New WSMs. 2012-12-19 Patrick Eriksson * arts-2-1-428 * doc/uguide/wfuns.tex: Some small fixes. Updated frequency section. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Switched to use new WSMs for frequency. * controlfiles/artscomponents/groundbased/TestGbased.arts: Removed all WF calculations. Now covered by Wfuns case. * src/m_jacobian.cc (jacobianAddFreqShiftAndStretch) (jacobianCalcFreqShiftAndStretchInterp): Replaced by methods listed below. (jacobianCalcFreqShift, jacobianAddFreqStretch) (jacobianCalcFreqStretch, jacobianAddFreqShift): New WSMs. 2012-12-18 Patrick Eriksson * arts-2-1-427 * src/montecarlo.cc (cloudy_rt_vars_at_gp, clear_rt_vars_at_gp): * src/m_abs_lookup.cc (abs_mat_fieldCalc): * src/doit.cc (cloud_RT_no_background) (cloud_ppath_update1D_planeparallel): * src/disort.cc (dtauc_ssalbCalc): rte_mag now set to [0 0 0] * src/m_zeeman.cc (abs_mat_per_speciesAddZeeman): Option rte_mag=[-1] removed. Instead, the case of rte_mag=[0 0 0] catched. Built-in doc changed accordingly. 2012-12-18 Patrick Eriksson * arts-2-1-426 * controlfiles/artscomponents/wfuns/TestWfuns.arts: Now also testing sine fit. * src/m_jacobian.cc (jacobianAddPolyfit): sensor_response_f_grid no longer input argument (only used in a removed check). (jacobianInit): Now setting jacobian_indices to be empty. Before jacobian_indeces did not match the other variables if jacobianInit was called several times. (jacobianCalcSinefit): (jacobianAddSinefit): Added these WSMs, introducing sinusoidal baseline fits. 2012-12-18 Patrick Eriksson * arts-2-1-425 * controlfiles/artscomponents/groundbased/yREFERENCE.xml: Forgot to do svn-add on this file. 2012-12-18 Patrick Eriksson * arts-2-1-424 * Revison and extension of wind RT part. * doc/uguide/winds.tex A clean-up and update of this section. Including comments around planet rotation and dotprod_with_los. * controlfiles/artscomponents/groundbased/TestWinds.arts: Settings changed, and reference data added and used. * src/rte.cc (get_ppath_abs): Wind part updated. Main calculation now done by the general function dotprod_with_los. * src/m_atmosphere.cc (wind_u_fieldIncludePlanetRotation): New WSM. * controlfiles/general/planet_jupiter.arts: * controlfiles/general/planet_venus.arts: * controlfiles/general/planet_mars.arts: * controlfiles/general/planet_earth.arts: planet_rotation_period now defined. * src/workspace.cc: Updated text for wind variables. And introduced planet_rotation_period. 2012-12-17 Patrick Eriksson * arts-2-1-423 * All around Faraday rotation should now hopefully be in place. The result of the test case checked by integrating(Ne*B) in Matlab. So it looks OK. * controlfiles/artscomponents/faraday/TestFaradayRotation.arts: Changed min pressure, and now using HSE to recreate altitudes for IRI and IGRF, by "incverting" what Jana did. Reference data updated. * controlfiles/testdata/tropical.expanded.t.xml: Changed ionopsheric temperature to 200, to be closer to what Jana used when calculating p for IRI and IGRF. * doc/uguide/cloudradar.tex: Changed status in history from Started to Written. * doc/uguide/transmission.tex: Removed the old Faraday section stub, and some small fixes. Status now set to "Written" * doc/uguide/faraday.tex (chapter{Faraday rotation}): Added some references for additional support, and a comment about that a numerical value on the Wikipedia page on "Faraday effect" is slightly wrong. 2012-12-17 Patrick Eriksson * arts-2-1-422 * controlfiles/testdata: Added a number of 1D files to also cover the ionosphere. Ne and magnetic field extracted from IRI and IGRF. For T and Z just a simple extension of Fascod tropical. Should be replaced with better data. * controlfiles/artscomponents/faraday/: New test case. * src/methods.cc: Added description of Farday aux vars, for iyTransmissionStandard. * doc/uguide/faraday.tex (section{Theory}): Some polishing. * doc/uguide/atmosphere.tex (section{Description of the ionosphere}): Slightly extended. 2012-12-16 Patrick Eriksson * arts-2-1-421 * Not sure if all changes captured below. Anyhow, Faraday rotation now implemented in a general way (only lacking from DOIT and MC). Some documentation is lacking, and test case will be created. * doc/uguide/faraday.tex: A new chapter. * doc/uguide/atmosphere.tex: Wrote a small section on ionospheric variables. Reintroduced a figure, as a new odd page was created. * src/m_rte.cc: Stuff moved to other files, see below. * src/m_cloudradar.cc (iyCloudRadar): Added use_mean_scat_data as input argument, for consistency with other methods. Adopted call of get_ppath_trans2. * src/jacobian.cc: Some (previously local) functions moved here from m_rte. * src/m_transmitter.cc: New file. Placed iyRadioLink, iyTransmissionStandard and iy_transmitterCloudRadar here. (iyTransmissionStandard): Adopted call of get_ppath_trans2, and added hamndling of Faraday rotation aux vars. (iyRadioLink): Adopted call of get_ppath_trans2. (iy_transmitterSinglePol): New WSM. (iy_transmitterMultiplePol): iy_transmitterCloudRadar renamed. * src/rte.cc (get_ppath_trans2): Added handling of Faraday rotation, following get_ppath_trans. 2012-12-14 Patrick Eriksson * arts-2-1-420 * src/m_rte.cc (iyRadioLink): Removed core Faraday code, and adopted call of get_ppath_trans throughout the file. * src/m_cloudradar.cc (iyCloudRadar): Adopted call of get_ppath_trans. * src/rte.cc (get_ppath_trans): Faraday rotation now implemented as part of this function. 2012-12-14 Patrick Eriksson * arts-2-1-419 * src/m_rte.cc: For several functions, adopted call of get_ppath_atmvars. (iyRadioLink): Complete treatment of Faraday rotation (at least correct order of magnitude results). But thinges wil be rearranged to be more general, for incorporation in other WSMs as well. * src/m_cloudradar.cc (iyCloudRadar): Adopted to change below. * src/rte.cc (get_ppath_atmvars): Added treatement of free electrons. 2012-12-14 Oliver Lemke * arts-2-1-418 * src/continua.cc (MPM85O2AbsModel, MPM87O2AbsModel, MPM89O2AbsModel, MPM92O2AbsModel, MPM93O2AbsModel, PWR93O2AbsModel, MPM93_O2_continuum): If vmr for current pressure level is exactly zero, set pxsec also to zero instead of failing with a runtime error. 2012-12-14 Patrick Eriksson * arts-2-1-417 * src/m_rte.cc (iyRadioLink): More work on Faraday rotation. Overall code is in place, but Ne not yet included in the calculation. * src/check_input.cc (chk_rte_pos): Check of rte_pos2 demanded 1D latitudes to be inside +-90. Higher values are needed when working with links to GPS datellites. Limit now set at 180 deg. * src/rte.cc (defocusing_sat2sat): Had to change the way correct usage is checked, as with ionopshere a satellite can be inside the model atmosphere. * src/m_basic_types.cc (Tensor4AddScalar): Created, following the corresponding WSM for Tensor3. 2012-12-13 Patrick Eriksson * arts-2-1-416 * src/m_rte.cc (iyRadioLink): Some more work on Faraday rotation. Mainly to figure out the correct combination of basic constants (e, m, c etc.) when using SI units. The factor 2.34e4 given in several places, is now calculated from fundamental constants. 2012-12-12 Patrick Eriksson * arts-2-1-415 * src/m_rte.cc (iyRadioLink): Started on Faraday rotation. * src/rte.cc (get_ppath_abs): Adopted to below. The [-1] option would never happen. * src/workspace.cc: Changed description if rte_mag, mainly removing the option of [-1]. 2012-12-12 Patrick Eriksson * arts-2-1-414 * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: Adopted, selecting defocusing method 2. * src/m_rte.cc (iyRadioLink): The method considers now also particle extinction, including aux vars. Defocusing method can be selected by the user. * doc/uguide/transmission.tex (subsection{Extra path delay}): Removed the idea about returning dn/c. 2012-12-07 Patrick Eriksson * arts-2-1-413 * doc/uguide/transmission.tex: Fixed types found at a quick reading, and removed obselete parts of the additional defocusing section. 2012-12-07 Patrick Eriksson * arts-2-1-412 * doc/uguide/transmission.tex: More writing (including stuff not yet implemented!). 2012-12-07 Jana Mendrok * arts-2-1-411 * src/m_cloudbox.cc (pnd_fieldExpand1D): Bugfix - lon-dim calc of expanded cloudbox had a typo. Remove cloudbox_checked as input - that didn't deliver any additional security (cloudbox_checkedCalc should anyway be done on the expanded fields again), but required some else unnecessary, messy settings before (e.g. cloudbox_checkedCalc requires basics_checked, which requires z_surface to be set, i.e., requires to set 1D z_surface and update/change to 2/3D later on.) * src/methods.cc: Adapted pnd_fieldExpand1D according to above. Additional minor fixes (cross-links, ...) on doc in a number of methods. 2012-12-07 Patrick Eriksson * arts-2-1-410 * doc/uguide/transmission.tex: A first complete version of 14.2.2-4 written. 2012-12-04 Patrick Eriksson * arts-2-1-409 * doc/uguide/transmission.tex: Some more writing ... 2012-12-04 Patrick Eriksson * arts-2-1-408 * Attacked some compiler warnings. (Don't know how to handle the one appearing in m_cloudbox.cc.) * src/m_surface.cc (surfaceFlatReflectivity): Removed input rte_los, as now not used. (surfaceFlatScalarReflectivity): As above. * src/m_sensor.cc (sensor_checkedCalc): sensor_response_za was used where it should be sensor_response_aa. And antenna_dim was not considered properly when checking sensor_response_aa. * src/m_rte.cc (iyRadioLink): Setting defocusing attenuation to a dummy value (to avoid compilation warning). 2012-12-04 Patrick Eriksson * arts-2-1-407 * doc/uguide/transmission.tex: Started to revise and extend this section. 2012-12-03 Stefan Buehler * arts-2-1-406 * src/cia.{h,cc}: Added. Implementation files for HITRAN-based Collision Induced Absorption (CIA) continua. Only starting on this, please ignore compiler warnings. * src/CMakeLists.txt: Added CIA targets. * src/test_cia.cc: Added. For testing of CIA functions. 2012-12-02 Patrick Eriksson * arts-2-1-405 * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: Added more aux variables. Changed to distance bettween transmitter and reciever to get more defocusing. * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Some cleaning. * src/m_rte.cc (iyRadioLink): Added Free space attenuation. * src/m_ppath.cc (ppathFromRtePos2): Background set to 9. * src/ppath.cc (ppath_set_background): (ppath_what_background): Added "transmiter" with 9 as code. 2012-11-26 Stefan Buehler * arts-2-1-404 * src/m_abs_lookup.cc (abs_lookupCalc): Made this work correctly with artscat4 (fixed bug reported by Jana). Now calls xsec_species directly for the line absorption calculation, instead of through abs_xsec_per_speciesAddLines. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Added a test with lookup table. 2012-11-26 Oliver Lemke * arts-2-1-403 * src/agenda_class.cc (Agenda::execute): Catch std::bad_alloc. This is not perfect, because it only gives us the workspace method where the allocation failed, not the exact function in the code. But better than before without any clues. * src/rte.cc (get_ppath_abs): Add try catch around Tensor5.resize(). As this is large it is prone to fail. By catching the std::bad_alloc exception here, we can give as much information as possible about where the problem is to the user. This should be done in other places where potentially large data is allocated too. * src/doit.cc (cloud_RT_no_background): Tweak comments. 2012-11-26 Patrick Eriksson * arts-2-1-402 * src/ppath.cc (ppath_step_geom_3d): Removed some obsolete code related to tangent points. * src/ppath.cc (raytrace_3d_linear_basic): Call do_gridcell_3d_byltest with lraytrace as start value for length search, to make sure that it safes to take a path step of this length. Before -1 was used, and the length lraytrace was not necessarily probed. 2012-11-24 Patrick Eriksson * arts-2-1-401 * src/ppath.cc (do_gridcell_3d_byltest): resolve_lon was applied too late for final points, that could cause an assert when starting the next step. Code restructured to fix this. 2012-11-24 Oliver Lemke * arts-2-1-400 * src/doit.cc (cloud_RT_no_background): Change averaging between the ppath steps to be consistent with the clearsky part. Previously, averaging between ppath points was done for temperature, pressure and vmrs. Now abs_mat_per_species is calculated on each ppath point and then averaged. Here are the differences between the old way and the new way: TestDOIT: y_0-y_old OK (maximum difference = -0.0505823). y_1-y_old OK (maximum difference = 0.00250382). TestDOITBatch: ybatch[0]-ybatch_old[0] OK (maximum difference = 0.00277304). ybatch[1]-ybatch_old[1] OK (maximum difference = 0.00306167). ybatch[2]-ybatch_old[2] FAIL (maximum difference = -0.0143527). ybatch[3]-ybatch_old[3] OK (maximum difference = 0.00944391). ybatch[4]-ybatch_old[4] OK (maximum difference = -0.00804398). ybatch[5]-ybatch_old[5] FAIL (maximum difference = 0.03268). * controlfiles/artscomponents/doitbatch/TestDOITBatch.ybatch.ref.xml: Updated reference values. * src/m_basic_types.cc (Compare): Don't fail immediately when comparing arrays. Instead, collect all errors and throw an exception at the end. 2012-11-24 Jana Mendrok * arts-2-1-399 * src/m_abs.cc (abs_speciesDefineAllInScenario): Don't add a dot between basename and species if basename ends in '/', i.e. is a directory. (abs_h2oSet): Don't throw an error, but set abs_h2o to [-1], if H2O is not in abs_species (we need abs_h2o only for selected continua. so we should at least be able to make lbl calculations without H2O). (abs_coefCalc,abs_coefCalcSaveMemory): First call abs_xsec_per_speciesAddConts, then abs_xsec_per_speciesAddLines. In case continuum calc throws an error due to missing abs_h2o, we want to avoid having done a heavy lbl calc before. * src/m_abs_lookup.cc (abs_lookupCalc): as for abs_coefCalc (see above). * src/absorption.cc (calc_gamma_and_deltaf_artscat4): - Instead of throwing an error when broad_spec_vmr_sum <0.9, only send a warning to out2 (it's anyway rescaled to vmr=1, hence we don't make big errors) - catch case that broad_spec_vmr_sum==0 (applying gamma_self for full vmr=1). Not in effect yet as after fixing the abs_lookup-wit-artscat4 bug might make it obsolete (though, a catch of possible div0 seems preferable anyways.) * src/m_atmosphere.cc (AtmRawRead): Don't add a dot between basename and name of atmfield if basename ends in '/', i.e. is a directory. * controlfiles/artscomponents/catalogue/TestReadCataloguePerrin.arts: Use abs_speciesDefineAllInScenario (instead of manually setting abs_species) to catch ALL species with line files to test. * controlfiles/artscomponents/clearsky/TestClearSky.arts: Fixed typo. 2012-11-23 Patrick Eriksson * arts-2-1-398 * src/methods.cc: Added missing \n. 2012-11-23 Oliver Lemke * arts-2-1-397 * src/parser.cc (ArtsParser::parse_generic_output): Fix bug reported by Patrick. Wrong logic in if-statement lead to non-existent output variables being automatically created for WSMs with names shorter than 7 chars. * src/m_atmosphere.cc (AtmFieldsCalc): Turn off zeropadding for t_field in 3D case (was already off for 1D). 2012-11-23 Oliver Lemke * arts-2-1-396 * controlfiles/artscomponents/catalogue/TestReadCataloguePerrin.arts: Add simple testcase to read the whole Perrin catalogue. 2012-11-23 Oliver Lemke * arts-2-1-395 * src/absorption.cc (LineRecord::ReadFromArtscat4Stream): Fix for crash when reading catalog files where n and j are missing. 2012-11-22 Patrick Eriksson * arts-2-1-394 * src/ppath.cc (do_gridcell_3d_byltest): Added test also with respect to upper pressure level, for r_v[j]. This after getting an assert also in this direction. The z_field was quite crazy, but still formerly correct. 2012-11-22 Jana Mendrok * arts-2-1-393 * src/m_planets.cc,methods.cc (g0Jupiter, g0Mars, g0Venus): Added. Methods for getting z=0 gravity for other planets. They don't consider ellipsoid shape of the z=0 body (for now they only set a Numeric), but could be added. * src/agendas.cc (iy_cloudbox_agenda, surface_rtprop_agenda): A bit of polishing of the online documentation. * controlfiles/general/planet_[jupiter,mars,venus].arts: Added. Helper-includes corresponding to planet_earth.arts for other planets. Sets a couple of planet-specific constants/parameters. * controlfiles/general/agendas.arts: Added iy_cloudbox_agenda predefinitions, and g0_agenda predefinitions for other planets. Renamed ppath_agenda__PassiveSensorPath to ppath_agenda__FollowSensorLosPath according to Patrick's suggestion. * controlfiles/general/agendasDOIT.arts: replace iy_cloudbox_agenda setting by copied predefined agenda. * controlfiles/[artscomponents,instruments]/*/*.arts: Replaced ppath_agenda__PassiveSensorPath -> ppath_agenda__FollowSensorLosPath. * controlfiles/artscomponents/doit/TestDOIT.arts: Adapted compare-to-reference message to actual reference value used. * controlfiles/general/general.arts: Minor cleaning/re-sorting. 2012-11-22 Patrick Eriksson * arts-2-1-392 * src/ppath.cc (do_gridcell_3d_byltest): Check of r_v[j] when surface inside grid cell was not complete. 2012-11-22 Richard Larsson * arts-2-1-391 * src/m_zeeman.cc: Added different Landé constants, gs, for various molecules to make the frequency shifts closer to measurements (previously only free electron case was resolved, though gs tend toward 2 the 'less free' the electron is from the nuclear angular momentum). * controlfiles/testdata/isoquantum.xml: Should be read together with all AddZeeman since it contains the values above. Changed test-file to make it compatible with this new scheme. * src/absorption.cc: Now reads HITRAN quantum numbers differently for various Zeeman species. NO should be possible to Zeeman split in ARTS as is, whereas OH and ClO still need some work. * src/methods.cc,src/workspace.cc,src/absorption.h: Small changes. 2012-11-22 Oliver Lemke * arts-2-1-390 * doc/uguide/references.bib: Add thayer74_improved_rs. 2012-11-21 Jana Mendrok * arts-2-1-389 * Continued setting up predefined agendas. Removed all AgendaSet and INCLUDE from general.arts - the user is forced now to explicitly set all agendas needed. Adapted Test*.arts accordingly. * controlfiles/general/agendas.arts: Revised completely. Containing agenda predefinitions, no agenda settings(!). * controlfiles/general/agendas_surface.arts: Added. INCLUDE to agendas.arts containing predefinitions for surface_rtprop_agenda. * controlfiles/general/agendas_new.arts: Removed. Now all of this in agenda.arts. * controlfiles/general/general.arts: Removed any INCLUDEs. Removed setting of refr_index_agenda. * controlfiles/general/planet_earth.arts: Some refurbishing. * controlfiles/[artscomponents,instruments]/*/Test*.arts: Adapted to general.arts changes - explicit setting of agendas that previously were set by agenda.arts is now WITHIN the arts controlfiles. * src/m_surface.cc,methods.cc(surfaceLambertianSimple),workspace.cc: Made number of streams in lambertain calculation (formerly: np, now: lambertian_nza) a WSV. 2012-11-21 Jana Mendrok * arts-2-1-388 * doc/uguide/refr_index.tex,rte.tex,ppath.tex: Expanded documentation on refraction and (gas) refractive index. 2012-11-21 Patrick Eriksson * arts-2-1-387 * src/montecarlo.cc (mcPathTraceGeneral): termination_flag was before set even if the other stop criterion (evol_op<=r) had been reached during the path step. This gave an undersampling of points just above the surface. A test case had before an bias of about 0.7 K. This bias is now removed (tested to a precision of 1 sigma= 0.05 K). After this no obvious bias in any of my test calculations :-) 2012-11-20 Patrick Eriksson * arts-2-1-386 * New version mcPathTraceGeneral now activated. That is, MCGeneral now considers ppath_step_agenda, and gives warnings if tau of any path step is higher than 4. In addition, other MC methods moved to mc_NotUSed.cc. These methods could be activated on demand (then to be revised and tested). * src/workspace.cc: mc_z_field_is_1D removed. * src/montecarlo.cc (cum_l_stepCalc,): * src/montecarlo.cc (iwp_cloud_opt_pathCalc): * src/montecarlo.cc (mcPathTraceIPA): * src/m_montecarlo.cc (mc_IWP_cloud_opt_pathCalc): * src/m_montecarlo.cc (MCIPA): * src/m_montecarlo.cc (pha_matExtractManually): All moved to mc_NotUsed. * src/montecarlo.cc (mcPathTraceGeneral): "Test version" has now replaced old version. * controlfiles/artscomponents/montecarlo/ TestMonteCarloGeneralGaussian.arts: * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: ppath_lmax set to 3km (needed to avoid warnings about tau > 4). Setting of mc_z_field_is_1D removed. New reference values: * controlfiles/artscomponents/montecarlo/ TestMonteCarloGeneralGaussian.arts: I: 198.8 -> 198.6 Q: 8.0 -> 7.6 * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: I: 199.1 -> 198.3 Q: 7.6 -> 7.8 * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: I: I: 199.5 -> 199.4 2012-11-20 Patrick Eriksson * arts-2-1-385 * Version number here in ChangeLog was not updated. * controlfiles/artscomponents/montecarlo/ TestMonteCarloGeneralGaussian.arts: A stupid last minute typo! 2012-11-20 Patrick Eriksson * arts-2-1-384 * For documentation purposes, before changing MC, the reference values for the MC tests were checked. For two of the tests, the reference I values were found to be too high, with about 2.5K (precision of test calculations about 0.35K). This change in reference value could have been caused in arts-2-1-347, when the cloudbox was enlarged to cover all non-zero pnd_field. The sign of the change in I is consistent with more particles along the path. But third test had already OK value. Changed without comment here? No time to investigate this further. The changes: * controlfiles/artscomponents/montecarlo/ TestMonteCarloGeneralGaussian.arts: I: 201.0 -> 198.8 Q: 7.6 -> 8.0 * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: I: 201.8 -> 199.1 Q: 7.6 (no change) * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: I: 199.5 K (Not changed, as the significant difference to new calculations. And this quite close to the new values above.) 2012-11-20 Patrick Eriksson * arts-2-1-383 * src/montecarlo.cc (mcPathTraceGeneralTEST): A warning is now given if the optical thickness of the path step exceeeds 4. * src/m_montecarlo.cc (MCGeneral): New rejects the "path trace" if g=0, with a warning to out0. That is, this trace does not contribute to I_sum. 2012-11-18 Patrick Eriksson * arts-2-1-382 * src/m_doit2.cc (CloudboxGetIncoming2): Completed? (code, not documentation) (iyInterpCloudboxField2): Work in progress. 2012-11-17 Patrick Eriksson * arts-2-1-381 * controlfiles/instruments/odinsmr/odin_bchannel.m: * controlfiles/instruments/odinsmr/odin_antenna.m: Two functions to set up Odin-SMR simulations. In contrast to old setup_input.m, these functions are stand-alone (ie. Qsmr not needed). 2012-11-17 Patrick Eriksson * arts-2-1-380 * src/montecarlo.cc (mcPathTraceGeneralTEST): Code cleaned up. Now completely adapted to ppath calculated with lmax. Seems to work, but more tests needed. * src/m_montecarlo.cc (MCGeneral): A bit of cleaning of error messages, as well as code indentation. 2012-11-16 Patrick Eriksson * arts-2-1-379 * doc/uguide/ppath_theory.tex: Revised 3D part. Resurrected text and figure for lengt-search algorithm. * src/ppath.cc: Functions now not used moved to ppath_NotUsed.cc. * doc/uguide/rte.tex (section{Calculation accuracy}): Moved one paragraph to ppath.tex. * doc/uguide/ppath.tex: Updated. Two new sub-sections, describing spacing between additional points and discussing tangent points. 2012-11-16 Jana Mendrok * arts-2-1-378 * started setting up predefined agendas, the user can chose than from by just copying them to the respective required agenda. WORK IN PRROGRESS. commit mainly in order to have synced code on my notebook. * controlfiles/general/agendas_new.arts: Added. Current place for predefined agendas. For now, used as an include to agendas.arts. * controlfiles/general/agendas.arts: include agendas_new.arts. 2012-11-16 Jana Mendrok * arts-2-1-377 * doc/uguide/rte.tex, ppath.tex: Removed/adapted references to explicit tangent point inclusion in ppath. 2012-11-16 Patrick Eriksson * arts-2-1-376 * Tangent points are now never included in a special manner. This has gradually disappeared, and now also removed from geom. 1D and 2D. This to be more consistent, makes the code cleaner, and (marginally) faster. Note that with a non-spherical ellipsiod there are two possible tangent altitudes, min radius and min vertical distance to geoid. It is the later that is most interesting, but it was the first one that was included. Anyhow, if you run with lmax <= 10 km the difference is really small between present and old results. At least for passive observations (e.g. no reference values not changed for passive). * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Deactivated "compare" as results have changed somehwat: 0.00011 deg (out of 0.6921) for bending angle and 0.3 ns (out of 637 ns) for extra path delay. Will re-activate when the radio link part is revised. * src/ppath.cc (geompath_r_at_l): Removed assert for negative l, as l anyhow squared. (geompath_from_r1_to_r2): Now handles that r1 and r2 can be on different side of a (r-based) tangent point. An extra input argument added for this. (do_gridrange_1d): Adopted to change in geompath_from_r1_to_r2, and hence always return complete step through grid cell. (ppath_step_geom_1d): Removed special handling of tangent points. (raytrace_1d_linear_basic): Adopted to changes above. (ppath_step_geom_2d): Removed special handling of tangent points. (do_gridcell_2d): Adopted to change in geompath_from_r1_to_r2. (raytrace_2d_linear_basic): Adopted to changes above. * src/ppath.cc (do_gridcell_3d_byltest): Removed old version and renamed the test version (ie. now the active function). 2012-11-16 Oliver Lemke * arts-2-1-375 * ChangeLog: Remove leftover conflict marker from r7969. 2012-11-16 Oliver Lemke * arts-2-1-374 * src/m_basic_types.cc (Compare): Output the names of the variables being compared. Keep the sign around for final difference output. Make input parameter names consistent over all Compare functions. * src/methods.cc: Enable passing of WSV names for Compare WSM. 2012-11-15 Patrick Eriksson * arts-2-1-373 * src/ppath.cc (do_gridcell_3d_byltest2): Completed. Now the active version. 2012-11-15 Patrick Eriksson * arts-2-1-372 * src/ppath.cc (do_gridcell_3d_byltest2): Start on alternative version of the function. 2012-11-15 Patrick Eriksson * arts-2-1-371 * Input angle to interpolation in surfaceFlatReflectivity and similar methods was zenith angle. This shall now be incidence angle. That is, the angle to the surface normal, not zenith. This to decouple specification of surface RT properties from topography. The incidence angle should be <= 90 even with topography. (Not an issue for 1D, testing ongoing for 3D.) * src/m_rte.cc (yCalc): Removed a leftover cout-s. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/instruments/mhs/mhs_fast.arts: * controlfiles/instruments/mhs/mhs.arts: * controlfiles/instruments/amsu/amsub_fast.arts: * controlfiles/instruments/amsu/amsub.arts: * controlfiles/artscomponents/clearsky/TestClearSky.arts: * controlfiles/artscomponents/surface/TestSurface.arts: Adopted to changes below. * src/surface.cc (surface_specular_los): Removed. Replaced by specular_losCalc. * src/m_surface.cc (complex_nFromGriddedField4): Removed rte_los as input. Not used. (surfaceFlatScalarReflectivity): (surfaceFlatReflectivity): (surfaceFlatRefractiveIndex): Now using specular_los and calc_incang. (specular_losCalc): Created. * src/surface.cc (calc_incang): Created. * src/workspace.cc: Added surface_normal and specular_los. 2012-11-14 Patrick Eriksson * arts-2-1-370 * src/montecarlo.cc (mcPathTraceGeneralTEST): Some more work on this new version of the function. Still inactive * controlfiles/general/agendasDOIT.arts: Removed Ignore for rte_pos and rte_los in iy_cloudbox_agenda, as not needed. 2012-11-13 Jana Mendrok * arts-2-1-369 * src/m_sensor.cc,methods.cc,workspace.cc,m_rte.cc: Introduced WSM sensor_checkedCalc and WSV sensor_checked in analogy to [basics,cloudbox]_checked and moved all sensor-related checks previously done at the beginning of yCalc to this WSM. Like [basics,cloudbox]_checkedCalc, sensor_checkedCalc now needs to be called before executing yCalc. * src/m_doit.cc(CloudboxGetIncoming): Now requires sensor_checked as input. * controlfiles/*/*/Test*.arts: Adapted controlfiles to the above changes. 2012-11-13 Patrick Eriksson * arts-2-1-368 * A bug fix for m_surface! (Bug created in 2-1-363) * A bug fixed for opt_propExtract (very old one). * (Work on introducing ppath_step_agenda into MCGeneral. Nothing new active, beside bug fix in opt_propExtract. ) * src/m_cloudradar.cc (iyCloudRadar): tr_rev should not be updated for ip=np-1. Fixed. * src/m_surface.cc (surface_reflectivityFromGriddedField6): Mixed up old and new grid when doing "lon-shift". (surface_scalar_reflectivityFromGriddedField4): As above. * src/montecarlo.cc (opt_propExtract): PARTICLE_TYPE_HORIZ_AL did not work for za=90! Copied solution already added in ext_matTransform. BIG NOTE: Very similar code is found in opt_propExtract and ext_matTransform. If you find any problem in any of these functions, check also carefully if the same problem is found the other one!!! * src/ppath.cc (ppath_copy): Some typos in comments * src/m_montecarlo.cc (MCGeneral): Added ppath_step_agenda and edensity_field as input and passed on to mcPathTraceGeneral. * src/m_rte.cc (iyMC): Added ppath_step_agenda and edensity_field as input and passed on to MCGeneral. 2012-11-13 Oliver Lemke * arts-2-1-367 * src/m_rte.cc (iyMC): Parallelize frequency loop. 2012-11-13 Jana Mendrok * arts-2-1-366 * src/m_doit.cc(DoitCloudboxFieldPut): Bugfix. Sensor-in-cloudbox check needs to run over measurements block = the rows of sensor_pos matrix. 2012-11-11 Patrick Eriksson * arts-2-1-365 * Forgot to make add on the new file. 2012-11-11 Patrick Eriksson * arts-2-1-364 * src/m_doit2.cc (CloudboxGetIncoming2): Started work on allowing sensor and surface inside cloudbox. So far making parallel methods and variables, named by adding a 2 at the end. And keep it in a separate, temporary, file. * src/m_doit.cc (CloudboxGetIncoming): For 3D, the if-statement for "end points of scat_za_index" was wrong for lat and lon parts. It had been fixed for pressure! Copied this to the lat and lon parts. A bug but (if I get it right) only one za-aa combination got wrong value (and just for 3D). 2012-11-11 Patrick Eriksson * arts-2-1-363 * src/m_surface.cc (surface_reflectivityFromGriddedField6) (surface_scalar_reflectivityFromGriddedField4) (complex_nFromGriddedField4): Checks of before interpolation were not complete. Also added shifting of longitudes to handle mapping from e.g. [-180,180] to [0 360]. * doc/uguide/scattering.tex: * doc/uguide/rte.tex: * doc/uguide/cloudradar.tex: Fixed the \wsmindex errors reported when running make check-all * src/m_cloudbox.cc (cloudbox_checkedCalc): Added check that the upper vertical limit is above the surface. 2012-11-09 Patrick Eriksson * arts-2-1-362 * controlfiles/artscomponents/surface/create_gfields.m (create_gfields): Not all grid names were correct. Created data (used as test input) updated. * src/m_surface.cc (surface_scalar_reflectivityFromGriddedField4): Added checks of name of grids. * src/check_input.cc (chk_griddedfield_gridname): Slight modification of error message. * src/m_surface.cc (surface_reflectivityFromGriddedField6): Added checks of name of grids. * src/methods.cc: Fixed some typos for surface_reflectivityFromGriddedField6. Stating expected name of grids for complex_nFromGriddedField4 and surface_*FromGriddedField4/6. 2012-11-09 Richard Larsson * arts-2-1-361 * src/m_zeeman.cc: Added another scheme for calculating relative strength of the split components. Made it compatible with the rational class in order to make half-quantum number operations easier to implement in the future. (RelativeStrengthSMMBerdyugina) Easy to use scheme that now is the standard scheme for determining relative strength. See the reference in the text for more information. (Lande_RusselSaunders) Another way to get g. I am currently trying to find a way for g of Hund a) transitions that works in (FrequencyChangeDirect) and this g might be helpful. * src/rational.h/.cc: Made a rational class. There are still some operators missing in this class so it cannot be considered complete. It works with src/m_zeeman.cc as far as I can tell. 2012-11-08 Patrick Eriksson * arts-2-1-360 * doc/uguide/cloudradar.tex: A basic documentation of the addition, quickly written, needs revision. * doc/uguide/symbol_defs.tex: Added defintion of "transmission matrix". 2012-11-08 Jana Mendrok * arts-2-1-359 * src/cloudbox.h, m_atmosphere.cc, m_cloudbox.cc, cloudbox.cc, workspace.cc: replaced 'prof_type' -> 'partfield_name' and 'profile type' -> 'particle field name' 2012-11-08 Jana Mendrok * arts-2-1-358 * src/m_cloudbox.cc(particle_massesSet): Added. Method to derive particle_masses from scat_data_meta, in order to be able to consistently use particle_masses with ARTS internal pnd_field calculation methods. * src/methods.cc: Added particle_massesSet, some layout and formulation fixes to other methods. * src/workspace.cc: some cross-link fixes. 2012-11-08 Patrick Eriksson * arts-2-1-357 * doc/uguide/cloudradar.tex: So far just an empty chapter. * doc/uguide/transmission.tex (section{Pure transmission calculations}): Jsut fixed one bad sentence. * doc/uguide/rte.tex (section{Auxiliary data}): Updated with respect to iy_auxFillParticleVariables. * src/methods.cc: Finished updates of built-in doc for cloud radar methods and other recent changes. 2012-11-08 Patrick Eriksson * arts-2-1-356 * src/methods.cc: Started to document the cloud radar methods and other recent changes. Not ready. 2012-11-07 Oliver Lemke * arts-2-1-355 * src/m_doit.cc (doit_i_fieldUpdateSeq1D): Remove unnecessary loop over za in limb conversion test. Change type of doit_i_field_limb from Tensor6 to Matrix. 2012-11-07 Oliver Lemke * arts-2-1-354 * src/m_doit.cc: (doit_i_fieldUpdateSeq1D): Adaptively perform additional iterations for the limb case (90 < za < theta_lim) to improve overall convergence. Clean up redundant if statements. (doit_conv_flagAbsBT): Output diff_bt with sign. * src/optproperties.{cc,h}, src/doit.cc, src/montecarlo.cc: Rename opt_prop_add_abs_mat_per_species to opt_prop_sum_abs_mat_per_species * src/cloudbox.cc (chk_scattering_data): Add _U_ to suppress warning. 2012-11-07 Oliver Lemke * arts-2-1-353 * src/matpackVI.h: Add missing CHECK(v) to Tensor6View::operator(). 2012-11-07 Patrick Eriksson * arts-2-1-352 * src/m_cloudradar.cc (iyCloudRadar): Updated names and error messages, to be consistent with changes below. * src/m_rte.cc (iy_auxFillParticleVariables): New. Intended to be a help function to iyEmissionStandard, to fill "PND, type X" and "Mass content, X". (iyEmissionStandard): Now accepts "PND, type X" and "Mass content, X", but just sets the iy_aux element to be empty. (iyTransmissionStandard): "PND, type X" and "Mass content, X" added as aux variables. 2012-11-05 Patrick Eriksson * arts-2-1-351 * src/m_cloudradar.cc (yCloudRadar): range_bins can now also be given in time. 2012-11-05 Patrick Eriksson * arts-2-1-350 * src/m_cloudradar.cc (iyCloudRadar): Now considering that the vector transmission is direction dependent. That is, there is now a transmission matrix for the propagation from the transmitter to the scattering point, and another matrix for the reversed propagation. (Needed as T1*T2 != T2*T1, where T1 and T2 are transmission matrices). Added round-trip time as aux var. * src/m_cloudradar.cc (yCloudRadar): Better handling of aux vars. 2012-11-05 Jana Mendrok * arts-2-1-349 * src/cloudbox.cc: Several documentation fixes (particularly units of LWC&IWC). 2012-11-05 Patrick Eriksson * arts-2-1-348 * src/m_cloudradar.cc (iyCloudRadar): Added Bacscattering and particle field as aux variables. 2012-11-04 Patrick Eriksson * arts-2-1-347 * src/m_cloudradar.cc: Further work. * doc/uguide/ppath_theory.tex: Removed references to ppath_array, changed to \funcindex for ppath_calc. * doc/uguide/rte.tex: Changed reference to ppath_cal to ppath_agenda. * doc/uguide/ppath.tex: \builtindoc was used for ppath_calc. Changed to \funcindex. * doc/uguide/winds.tex: doppler_shift -> rte_doppler. * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts: * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: cloudbox_checkedCalc called with explicit arguments, as for these MC-WSMs scat_data_mono replaced scat_data_raw. * particle_masses is now a mandatory "cloudbox variable", to complement pnd_field and scat_data_raw. However, can be left empty if particle mass is not used. * controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts: pnd_field was non-zero at lat and lon limits of the cloudbox (catched by extension of cloudbox_checkedCalc). Changed lat and lon extension of cloudbox from +-1.8 to +-1.9 deg (following the grid of used raw pnd_field). * controlfiles/general/general.arts: Added particle_masses, set to be empty. * src/m_atmosphere.cc (basics_checkedCalc): Added check for negative values in edensity_field. * src/cloudbox.cc (chk_pnd_field_raw_only_in_cloudbox): Moved from check_input.cc, to be placed beside some very similar functions. * src/m_cloudbox.cc (cloudboxOff): Now also returning an empty particle_masses. (cloudbox_checkedCalc): Now also performing checks on pnd_field and particle_masses. Note that pnd_field is allowed to be >0 for lower altitude limit of the cloudbox, if this point is at or below the suface altitude. * src/montecarlo.cc (iwp_cloud_opt_pathCalc): particle_masses passed on to this function. Also adopted. * src/m_montecarlo.cc (mc_IWP_cloud_opt_pathCalc): Only WSM that used particle_masses. Adopted. Demands that particle_masses has a single column. * src/workspace.cc: Redefined the WSV particle_masses. The scope is now larger and the type is changed from Vector to Matrix. 2012-11-04 Jana Mendrok * arts-2-1-346 * src/methods.cc: Fix. 2012-11-04 Jana Mendrok * arts-2-1-345 * src/m_refraction.cc (refr_indexMWgeneral): Fixed. Newell&Baird method considers refractivity, not refractive index (exactly as, e.g. Thayer) - fix this in TN1 (or at least the upcoming reports). Gives now pretty similar results to Thayer. (refr_indexThayer): Replaced requiring of H2O by assuming H2O-vmr=0 in case of no H2O in abs_species, i.e., reducing it to dry air contribution in these cases. * src/methods.cc: Added description for refr_indexMWgeneral. * controlfiles/artscomponents/[doit/TestDOIT,wfuns/TestWfuns, montecarlo/TestMonteCarloGeneralGaussian, montecarlo/TestMonteCarloGeneral].arts: Spell fixes. 2012-11-02 Jana Mendrok * arts-2-1-344 * src/m_refraction.cc(refr_indexMWgeneral): Added. General, planetary applicable method for refr. index calculation following Newell&Baird, 1965. Reference refr. indices valid for microwave (also from Newell&Baird, 1965) currently hardcoded therein. * src/methods.cc(refr_indexMWgeneral): Added. Proper Doc TBD. * src/absorption.cc(xsec_species): Typo fixed. 2012-11-01 Patrick Eriksson * arts-2-1-343 * src/m_cloudradar.cc (iy_transmitterCloudRadar): Created. (yCloudRadar): Now also handling y_aux. 2012-11-01 Patrick Eriksson * arts-2-1-342 * src/m_sensor.cc: Some code moved to function below. And now instead that function is called. * src/sensor.cc (stokes2pol): Created. * src/workspace.cc: Added sensor_pol_array and range_bins. * src/CMakeLists.txt: Added m_cloudradar.cc. * src/m_cloudradar.cc: Started this file, and moved the new functions from m_rte.cc. Still work in progress. 2012-10-31 Patrick Eriksson * arts-2-1-341 * src/m_rte.cc (iyCloudRadar): Changed order of data inside iy. Work in progress. Do not use! (iyBackCoeff2Ze): Just started. Got stuck due to bug fix below. * controlfiles/artscomponents/doit/TestDOIT.arts: I did not get a good fit with the target/reference values, neither before or after bug fix below. The values seems to be old. Updated the target values, and decreased tolerance from 1.0 to 0.2 K. * src/m_physics.cc (complex_nWaterLiebe93): A bug! sqrt was not applied and the method returned the dielectric constant (eps) instead of refractive index (n), with n = sqrt(eps). 2012-10-29 Patrick Eriksson * arts-2-1-340 * src/m_rte.cc (iyCloudRadar): Started. So far just experimental. * src/m_rte.cc (iyTransmissionStandard): Adopted call of get_ppath_ext. * src/rte.cc (get_ppath_ext): Added ppath_pnd as output argument. 2012-10-29 Oliver Lemke * arts-2-1-339 * README: Was still containing a URL to the SAT server from Bremen times. 2012-10-25 Jana Mendrok * arts-2-1-338 * src/m_cloudbox.cc (ParticleSpeciesSet,ScatteringParticlesSelect,pnd_fieldSetup): Introduced part_species delimiter as generic (defaulted) input parameter (in future maybe make it a preset WSV, cause currently there's quite a bit of room for messing up by using different delimiter strings in the different WSM calls), pass delimiter on into parse_XXX and pnd_fieldXXX functions. Added check of part_species validity in ParticleSpeciesSet. * src/methods.cc (ParticleSpeciesSet,ScatteringParticlesSelect,pnd_fieldSetup): Introduced part_species delimiter as generic input parameter. * src/cloudbox.cc,cloudbox.h (chk_part_species): Introduced. Check function for part_species strings. (chk_scattering_meta_data): Removed obsolete particle type check (this is free from now (except for containing the part_species delimiter string)!). (pnd_FieldXXX,parse_XXX): Added part_species delimiter as input parameter. * src/m_atmosphere.cc(AtmFieldsFromCompact): Adapted to parse_XXX now requiring delimiter as input. * controlfiles/testdata/chevallierl91_all_extract.xml: Moved to global testdata location from controlfiles/artscomponents/doitbatch/. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, doit/TestDOIT.arts: Increased number of azimuth angles from 10 to 37 (no significant impact for these cases, but as they also act as demo...). Atmfield location adapted according to above change. 2012-10-24 Oliver Lemke * arts-2-1-337 * doc/uguide/check_refs.py: Agenda check was broken. * doc/uguide/absorption.tex, doc/uguide/ppath.tex, doc/uguide/scattering.tex, doc/uguide/surface.tex: Naming fixes. 2012-10-24 Jana Mendrok * arts-2-1-336 * src/m_optproperties.cc (scat_data_rawCheck): Revised. Now throws an error, when deviation of C_sca from Z11 and from K-a gets to large (user defined threshold). Explicit warning that method only works for p20. More informative output on out2. * src/methods.cc,workspace.cc: Updated and improved(?) online-doc for ScatteringParticlesSelect, scat_data_rawCheck; part_species, scat_data_nelem. * controlfiles/artscomponents/doit/TestDOIT.arts, doitbatch/TestDOITBatch.arts, montecarlo/TestRteCalcMC.arts: Apply scat_data_rawCheck. 2012-10-24 Oliver Lemke * arts-2-1-335 * src/methods.cc: Add doit_i_field as output to doit_conv_flag* WSMs. Change name of throw_nonconv_error flag to nonconv_return_nan. * src/m_doit.cc (doit_conv_flag*): Return NaNs in non-convergence case instead of throwing a runtime error. 2012-10-24 Oliver Lemke * arts-2-1-334 * src/m_doit.cc (doit_conv_flag*): Fix compilation with clang. (os << out -> os << out.str() ) 2012-10-24 Jana Mendrok * arts-2-1-333 * src/m_doit.cc (doit_conv_flagAbs, doit_conv_flagAbsBT, doit_conv_flagLsq): Bugfixed iteration counter incrementation. 2012-10-24 Jana Mendrok * arts-2-1-332 * src/m_doit.cc (doit_conv_flagAbs, doit_conv_flagAbsBT, doit_conv_flagLsq): Fix hard-coded number of max. iterations in DOIT - made it a user- controllable parameter (with the previously hard-coded value of 100 as the default value). Also make it a user choice, whether to throw an error in case of non-convergence (this seems to be the logical consequence) or to accept the latest (but non-converged) scattering field as result (keeping this option and making it the default in order to avoid opening a can of worms NOW: a number of earlier calcs might suffer from that and failing at a single freq grid point would cause the whole calc to fail. we need a better fix for that!) * src/methods.cc: adapted accordingly * controlfiles/instruments/avhrr/avhrr_sensor_common.arts, avhrr_sensor_fast.arts, avhrr_sensor_reference.arts: Properly set names for a couple of datafiles to read - failed when used those arts files as includes outside the arts controlfiles folder. 2012-10-23 Oliver Lemke * arts-2-1-331 * doc/uguide/check_refs.py: Update doc. * doc/uguide/CMakeLists.txt: Make check-uguide depend on pdfs directly instead of custom arts_docs target for compatibility with older cmake. 2012-10-23 Oliver Lemke * arts-2-1-330 * doc/uguide/check_refs.py: Add check for wsa_index macro. * doc/uguide/CMakeLists.txt: Make check-uguide depend on arts_docs. * doc/uguide/absorption.tex, doc/uguide/atmosphere.tex, doc/uguide/rte.tex, doc/uguide/batch.tex: Fix some low hanging fruit. 2012-10-23 Oliver Lemke * arts-2-1-329 * doc/uguide/check_refs.py, doc/uguide/CMakeLists.txt: Add script to check if non-existent WSMs or WSVs are referred in latex macros wsmindex, wsvindex and builtindoc. Can be run with 'make check-uguide'. * src/absorption.h (BroadSpecName): Add empty string return value in addition to the assert to avoid warning in release mode compilation. 2012-10-22 Patrick Eriksson * arts-2-1-328 * The minimum number of photons applied in MC can now be controlled. It was before hard-coded to 100. * controlfiles/general/general.arts: mc_min_iter set to 100 (that is, consisient with older hardcoded value). * src/m_montecarlo.cc (MCGeneral,MCIPA): Now using mc_min_iter (demanding that the value is >= 100). * src/m_rte.cc (iyMC): Added mc_min_iter. * src/workspace.cc: Added mc_min_iter. 2012-10-21 Patrick Eriksson * arts-2-1-327 * src/ppath.cc (raytrace_3d_linear_basic, ppath_step_geom_3d): Going back (hopefully temporarily) to old 3D ray tracing scheme. Still safer than new one! 2012-10-19 Patrick Eriksson * arts-2-1-326 * src/ppath.cc: A warning! Found a case where new 3D ray tracing code failed and not yet fixed. * src/m_ppath.cc (ppathWriteXMLPartial): Using Oliver's new code, it was easy to test that it is only the grid positions that make the Matlab importing so slow for ppath. For this reason, reintroduced nreal and ngroup. (In my present test, importing the partial ppath takes about just 1% of the time for imprting the complete one!) 2012-10-19 Oliver Lemke * arts-2-1-325 * src/m_ppath.cc, src/methods.cc: Add ppathWriteXMLPartial. Writes only essential ppath data fields for better performance when needed. 2012-10-16 Richard Larsson * arts-2-1-324 * src/m_zeeman.cc: Added another scheme for calculating relative strength of the split components. Also added another scheme to get the extinction matrices that take into account dispersion. (RelativeStrengthLindauAndLifshitz) seem to agree perfectly with the tables used previously at applicable lines. It should also work for the more general cases and regardless of particle, though this has yet to be tested. For more information on this, see Lindau and Lifshitz QED (volume 4). (KMatrixRees) seems reasonable, though it needs to be tested more before I say anyone should trust it. Changed names of some functions and added some new (#Define) for ease of using the various schemes. The current setup does not fail the TestZeeman.arts controlfile. Need to make some better way to switch between the different Zeeman splitting schemes in the future. 2012-10-15 Oliver Lemke * arts-2-1-323 * src/absorption.{h,cc} (LineRecord::ARTSCAT4FromARTSCAT3): Don't fail for lines already in ARTSCAT4 format, just skip those. Move implementation to cc file. 2012-10-15 Oliver Lemke * arts-2-1-322 * src/m_batch.cc (ybatchCalc): Correct error message. Since ybatch is now an ArrayOfVector, y for failed batch cases is simply empty, not -1. Add informational output to out1 that we're aborting if a batch case fails and robust==0. Gives feedback to the user that something went wrong and that we will bail out of the batch loop when all the currently running cases have finished (which may take a bit of time). * src/m_basic_types.cc (Compare): Add newline in error message. 2012-10-12 Oliver Lemke * arts-2-1-321 * src/src/methods.cc: ybatchCalc now also returns ybatch_aux. * src/m_batch.cc (ybatchCalc): Add ybatch_aux as output. Move definition of y and jacobian inside the batch loop. * src/agendas.cc: Add y_aux as output to ybatch_calc_agenda. * src/groups.cc: Add group ArrayOfArrayOfVector. * src/workspace.cc: Add new WSV ybatch_aux. * src/xml_io_types.h, src/xml_io_instantiation.h, src/xml_io_array_types.cc, src/nc_io_array_types.cc: Add ArrayOfArrayOfVector support. 2012-10-11 Patrick Eriksson * arts-2-1-320 * src/m_atmosphere.cc (basics_checkedCalc): Made an error message a bit clearer. * src/methods.cc: Fixed some typos for surface methods. 2012-10-12 Oliver Lemke * arts-2-1-319 * Two changes in this commit that break backwards-compatibility: ybatch WSV group changed from Matrix to ArrayOfVector. WSMs {Matrix,Numeric,Vector,Tensor7}Compare merged into one supergeneric Compare function. * src/src/m_batch.cc (ybatchCalc): Change type of ybatch to ArrayOfVector. Remove code for separate calculation of first batch job. Batch calculations are now run in parallel immediately, not only after the first job is done. (ybatchMetProfiles, ybatchMetProfilesClear): Change type of ybatch to ArrayOfVector. * src/methods.cc: Merge all TYPECompare WSMs into one supergeneric Compare function. {Matrix,Numeric,Vector,Tensor7}Compare -> Compare * src/workspace.cc: Change type of ybatch from Matrix to ArrayOfVector. * src/m_basic_types.cc: Change name of Compare functions and gather them in one place. Add Compare implementation for ArrayOfVector. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts, controlfiles/artscomponents/absorption/TestIsoRatios.arts, controlfiles/artscomponents/clearsky/TestClearSky.arts, controlfiles/artscomponents/doit/TestDOIT.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts, controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts, controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts, controlfiles/artscomponents/radiolink/TestRadioLink.arts, controlfiles/artscomponents/surface/TestSurface.arts, controlfiles/artscomponents/transmission/TestTransmission.arts, controlfiles/artscomponents/wfuns/TestWfuns.arts, controlfiles/artscomponents/zeeman/TestZeeman.arts, controlfiles/instruments/amsu/TestAMSUB.arts, controlfiles/instruments/amsu/TestAMSUB_fast.arts, controlfiles/instruments/mhs/TestMHS.arts, controlfiles/instruments/mhs/TestMHS_fast.arts: Adapt for type change of ybatch from Matrix to ArrayOfVector. Adapt for merge of Compare WSMs. * controlfiles/artscomponents/doitbatch/TestDOITBatch.ybatch.ref.xml, controlfiles/instruments/amsu/TestAMSUB.ybatch.ref.xml, controlfiles/instruments/mhs/TestMHS.ybatch.ref.xml: Convert ybatch references from Matrix to ArrayOfVector. 2012-10-04 Stefan Buehler * arts-2-1-318 * doc/uguide/absorption_theory.tex (Pressure broadening and shift calculation): Fixed wrong parentheses in broadening and shift formulas. 2012-10-02 Jana Mendrok * arts-2-1-317 * controlfiles/artscomponents/absorption/TestIsoRatios.arts, src/physics_funcs.cc, README: minor fixes. * src/methods.cc (GriddedFieldLatLonRegrid, GriddedFieldPRegrid): updated/clarified documentation. 2012-10-02 Patrick Eriksson * arts-2-1-316 * The core DOIT part is hard-coded to return radiance (frequency based, blackbody_radiation_agenda is not used). This puts a demand on that CloudboxGetIncoming returns radiances. You could imagine to use CloudboxGetIncoming for other things than DOIT, where other units could be of interest. But as recent changes made it more difficult to use DOIT for batch calculations, I have added some checks in CloudboxGetIncoming to help the users. So, CloudboxGetIncoming can now only return radiance data. * src/m_doit.cc (CloudboxGetIncoming): Now also checks iy_unit and blackbody_radiation, to ensure that frequency based radiance data are obtained. (CloudboxGetIncoming1DAtm): As above. In addition, now also considering basics_checked and cloudbox_checked (as done in the method above). * src/m_rte.cc (iyEmissionStandard): Now uses the function below (that is based on code from this method). * src/check_input.cc (chk_if_std_blackbody_agenda): New function. The function tests if blackbody_radiation_agenda returns frequency based radiance, as assumed in some places. 2012-09-26 Richard Larsson * arts-2-1-315 * src/m_zeeman.cc: Fixed (FrequencyChangeDirect). My hope is this function better describe the general problem and will thus work for more species. Also, the Lenoir tables used did not describe cases with DN != 0 when DJ == 0. Will have to construct quantum transition rules first, then this should allow more general Zeeman effect calculations. The quantum electron spin number is currently defined constant but it should be a species property. * src/constants.cc: Added Bohr magneton and lande_gs. 2012-09-24 Patrick Eriksson * arts-2-1-314 * src/m_rte.cc (iyEmissionStandard): Referred incorrectly to MatrixPlanck in an error message. * doc/uguide/rte.tex: Algorithms updated with respect to where iy_unit is picked up. Output unit section extended to also treat n2-law. * doc/uguide/rte.tex: Flow chart updated (diy_dx now not output of iyCalc). * doc/uguide/rte_theory.tex: Changed the Planck function to use v (instead of c). This is commented, with a reference to Thomas and Stamnes. Made a section on the n2-law (based on Bengt's text from the ESA study TN1 report). * doc/uguide/references.bib: Added mobley:light:94, matlzer:radia:06 and thomas2002radiative. 2012-09-24 Gerrit Holl * arts-2-1-313 * src/m_atmosphere.cc(basics_checkedCalc): - Bugfix: throw runtimeerror if min(f_grid)<=0. 2012-09-24 Oliver Lemke * arts-2-1-312 * src/m_batch.cc (ybatchCalc): Throw a runtime error instead calling arts_exit directly if there is a mismatch in the Jacobian dimension. Will bypass robust and terminate the run. 2012-09-24 Oliver Lemke * arts-2-1-311 * Completed most of the OpenMP cleanup. The program is never exited directly from inside parallel loops anymore. All exceptions are passed up until they're caught in the main function. This should always give a clear error stack. * If you still encounter errors that look like the messy example below, please file a bug report with me!!!!! You should always see the 'Stopping ARTS' and 'Goodbye' line. If not, that's a bug too. Note that is does not apply to assertions. Before, error messages could look like this example when runtime errors occured in parallelised parts of the code: Executing Arts { .... - ybatchCalc Method abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_speciesMethod abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_speciesMethod abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_species Method abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_speciesMethod abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_species terminate called after throwing an instance of 'std::ios_base::failure' what(): basic_ios::clear Abort trap: 6 Now they (should) look like they this: ====================================== Executing Arts { .... - ybatchCalc } This run took 0.35s (0.32s CPU time) Run-time error in controlfile: doitbatch/TestDOITBatch_test.arts Run-time error in method: ybatchCalc Run-time error at ybatch_index 0: Run-time error in agenda: ybatch_calc_agenda Run-time error in method: CloudboxGetIncoming Run-time error in agenda: iy_main_agenda Run-time error in method: iyEmissionStandard Run-time error in agenda: abs_mat_per_species_agenda Run-time error in method: abs_mat_per_speciesAddOnTheFly Method abs_mat_per_speciesAddOnTheFly needs input variable: abs_lines_per_species Stopping ARTS execution. Goodbye. * src/absorption.cc (xsec_species), src/m_abs_lookup.cc (abs_lookupCalc, abs_mat_fieldCalc), src/m_abs.cc (abs_linesArtscat4FromArtscat3), src/m_rte.cc (yCalc), src/rte.cc (iyb_calc), m_atmosphere.cc (batch_atm_fields_compactFromArrayOfMatrix, batch_atm_fields_compactAddSpecies): Don't exit from inside parallelized loops. Instead set a failed flag, save the error and rethrow the exception after the loops. * src/agenda_class.cc (give_up): Remove function. We never give up!!! * src/arts.{cc.h} (exit_or_rethrow): Remove function. We always throw up (the exceptions that is....) * src/rte.cc (get_ppath_abs), src/m_batch.cc (ybatchCalc): Rename vars for consistency. (LineRecord::ReadFromHitranStream, LineRecord::ReadFromMytran2Stream): Don't exit if unknown molecule is found. Now consistent with LineRecord::ReadFromHitranStream2004. * src/m_general.cc (Error): Throw runtime_error instead of calling arts_exit. 2012-09-21 Oliver Lemke * arts-2-1-310 * OpenMP cleanup, work in progress. * src/m_batch.cc (ybatchCalc), src/rte.cc (get_ppath_abs): Never exit from inside the parallel loop. Instead set an abort flag that skips remaining iterations, collect runtime error messages (from all threads if necessary) and rethrow them after the loop. Work in progress. This should be done for all parallel loops. I'll continue with that in the next commits. * src/agenda_class.cc (Agenda::execute): Tweak log output to play nicer with multiple threads. Don't call arts_exit inside here because we might be run inside multiple threads. Throw a runtime_error instead. Calling the C library exit function from multiple thread gives random errors (assertions, terminate called twice message, or even core dumps) at program exit. To be done in the next commits: Make sure we only have a single exit point out of the program. All exceptions should be passed upwards until they're dealed with in the main function. * src/continua.cc (PWR98H2OAbsModel): Parallelize pressure loop. (PWR93O2AbsModel): Parallelize pressure loop. Handle exception inside loop and rethrow it after the loop. * src/m_abs_lookup.cc (abs_lookupCalc): Remove omp nested. Handled properly by the loop condition. (abs_mat_fieldCalc): Tweak pressure loop parallel condition. * src/m_abs_lookup.cc, src/m_batch.cc, src/messages.h, src/rng.cc, src/m_abs_lookup.cc, src/rte.cc: Replace all unnamed critical regions with named regions. All unnamed critical directives map to the same unspecified name. That means only one thread at a time will be allowed to enter one of those regions throughout the whole program at any time. * src/absorption.cc (xsec_species): Tweak parallel condition. * src/m_general.cc (Print): Move output of newline to the right place. (SWITCH_OUTPUT): Use ostringstream for nicer multithreaded output. (Print): Remove overload for ArrayOfIndex to use the output operator directly. * src/main.cc: Don't turn on omp nested. Usually not necessary and might have bad side effects (thread explosion). Should only be turned on in places that really need it. * src/m_atmosphere.cc, src/m_doit.cc, src/m_rte.cc: Remove commented out omp code. 2012-09-23 Patrick Eriksson * arts-2-1-309 * src/m_rte.cc (iyApplyUnit, yApplyUnit): n set to 1 in call of apply_iy_unit functions. (iyEmissionStandard): apply_iy_unit functions called with n. * src/rte.cc (apply_iy_unit): Added refractive index as input, and n2-law included in used expressions. (apply_iy_unit2): As above. 2012-09-23 Patrick Eriksson * arts-2-1-308 * Main change is that unit conversion is moved from iyb_calc down to methods for iy_main_agenda. This solves several issues: - Not all unit conversions make sense everywhere. For example, radiance conversions should not be applied on active signals. The selection of units can now be implemented on method level. - Now more clear when iy_unit makes sense (if not, not an input argument!"). - Back-conversion in iyMC now not needed. - The n2-law can be implemented without a lot of overhead (but not yet done). * controlfiles/*: About 20 controlfiles adopted renaming of iy_unit and ApplyUnit methods. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: A special case among the cfiles. For DOIT the unit must now be "1" when calling CloudboxGetIncoming. Final unit can first be set afterwards. So definition of iy_unit had to be moved into the batch agenda. * src/m_rte.cc (iyEmissionStandard): Adopted removed parts from iyb_calc, thus iy_unit is new input. Built-in doc corrected and extended. (iyApplyUnit): iyApplyYunit renamed. jacobian_do removed as input. Documentation adopted and extended. (iyCalc): Removed diy_dx as output. Jacobians are only partly supported on iy-level (perturbations made at yCalc level), and safest to remove diy_dx here. (iyMC): Removed back-conversion to radiance. Updated doc. * src/m_jacobian.cc: Removed y_unit from all methods (where it was passed on to iyb_calc). * src/rte.cc (apply_iy_unit): Renamed from apply_y_unit. (apply_iy_unit2): Renamed from apply_y_unit2. (iyb_calc): Removed everything associated with unit conversion. * src/workspace.cc: y_unit renamed to iy_unit, to reflect where the conversion now will be applied. Most of documentation moved to iyEmissionSteandard (as not generarly valid). * doc/uguide/ppath.tex: end_lstep was called start_lstep in structure table. 2012-09-21 Stefan Buehler * arts-2-1-307 * doc/uguide/absorption_theory.tex (Pressure broadening and shift calculation): Added caveats on VMR selection after discussion with Jana. 2012-09-21 Richard Larsson * arts-2-1-306 * src/m_zeeman.cc: Added another way to calculate frequency change. Will try to make it more useful soon. Fixed abs_species treatment error. * Updated Zeeman test file: to catch abs_species treatment error if it ever reoccurs. * src/messages.h: Will now flush output independent of user interface (I think). * src/m_abs_lookup.cc: Removed a FIXME, since I think the original implementation works. 2012-09-21 Stefan Buehler * arts-2-1-305 * doc/uguide/absorption_theory.tex (Pressure broadening and shift calculation): Added this section. 2012-09-21 Patrick Eriksson * arts-2-1-304 * doc/uguide/transmission.tex: Completed a version of the transmission section. * doc/uguide/rte.tex: Adeded missing labels for some equations. 2012-09-21 Patrick Eriksson * arts-2-1-303 * doc/uguide/transmission.tex: More work transmission section. 2012-09-21 Patrick Eriksson * arts-2-1-302 * doc/uguide/transmission.tex: Wrote an introduction, and got a bit into pure transmission section. 2012-09-19 Oliver Lemke * arts-2-1-301 * ChangeLog: Grr... fix typo 'is not called' -> 'is now called'. 2012-09-19 Oliver Lemke * arts-2-1-300 * I apologize beforehand for breaking controlfiles. * abs_lookupCreate is now called abs_lookupCalc. The original name wasn't that great because it is not actually creating the variable. Calc is more in line with all the other ...Calc functions we already have. * controlfiles/artscomponents/absorption/TestAbs.arts, controlfiles/artscomponents/absorption/TestAbsDoppler.arts, controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/groundbased/TestGbased.arts, controlfiles/artscomponents/montecarlo/TestMonteCarloDataPrepare.arts, controlfiles/artscomponents/wfuns/TestWfuns.arts, controlfiles/instruments/amsu/TestAMSU_generic.arts, controlfiles/instruments/avhrr/TestAVHRR.arts, controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/mhs/TestMHS_generic.arts, controlfiles/instruments/odinsmr/TestOdinSMR.arts, controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts, doc/uguide/absorption.tex, src/gas_abs_lookup.h, src/m_abs.cc, src/m_abs_lookup.cc, src/methods.cc, src/workspace.cc: abs_lookupCreate -> abs_lookupCalc. 2012-09-19 Oliver Lemke * arts-2-1-299 * This commit fixes the behaviour of the TYPECreate methods. After creating a new variable, instead of being initialized with 0 or empty, its state is now uninitialized. This is the same as for the builtin workspace variables. * src/agenda_class.h (MRecord): Add minternal flag. Is set to false if the method is from the controlfile and true if it was added by the engine. For example, Create and Delete calls for automatically generated variables (for literals) are flagged as internal. * src/agenda_class.cc (Agenda::execute): Use the new isInternal flag to determine output level instead of some funky string comparisons on the method and variables names. * src/methods.cc (define_md_data_raw): Update docs for the Create methods. * src/parser.cc (ArtsParser::parse_agenda): Insert a Delete after TYPECreate methods to make the new variable appear uninitialized. (ArtsParser::tasklist_insert_set_delete): Set the internal flag for MRecord to true for the automatically inserted Set and Delete methods. 2012-09-18 Patrick Eriksson * arts-2-1-298 * src/methods.cc: Updated and corrected the doc for ppathFromRtePos2. * doc/uguide/transmission.tex: Added some sections, to be filled ... * doc/uguide/ppath.tex: ppath_agenda is now mentioned. Added a comment about radio links, referrring to a special section. * doc/uguide/references.bib: Added rybicki:radia:79 and ippolito:satco:08. * doc/uguide/arts_user.tex: Changed order of the chapters. Hard to find a clear logically order, but a try. * doc/uguide/common.tex: FIXMEs now written in gray, to visually end up a bit in the background. * doc/uguide/refr_index.tex: started this chapter. (If anyone plans to add a chapter, do it now so section references from ESA study DDD do not change.) 2012-09-18 Oliver Lemke * arts-2-1-297 * README: Update prerequisites to be in line with the webpage. 2012-09-17 Oliver Lemke * arts-2-1-296 * src/mystring.h (split): Fix crash if the string contains several occurrences of the delimiter right next to each other. Bug found by Mathias. 2012-09-17 Oliver Lemke * arts-2-1-295 * src/absorption.cc: Remove debug code. 2012-09-17 Oliver Lemke * arts-2-1-294 * src/absorption.{cc,h} (checkIsotopologueRatios): Add function to validate isotopologue ratios. * src/m_abs.cc (abs_mat_per_speciesAddOnTheFly), src/m_abs_lookup.cc (abs_lookupCreate), src/m_zeeman.cc (abs_mat_per_speciesAddZeeman): Call checkIsotopologueRatios. Probably not the best places to call it, because it is called more often than needed. Other option is to make a workspace method that has to be called by the user. At least this way, the check is automatic. Something to be discussed. 2012-09-15 Oliver Lemke * arts-2-1-293 * src/methods.cc (define_md_data_raw): Clarify docs for Create and Delete. * src/continua.cc: (PWR93O2AbsModel): Cleanup code. (threej2_): Remove unused function. Would only lead to a null pointer dereference anyway... (MPM93_N2_continuum, n2n2tks_, bound32_, bound54_, spline_0_, artsckd_, fwv_mpmf87s93__, fwv24_, swv24_, swv_mpmf87s93__, conti_n2__): Remove unused variables and redundant assignments. (bound54_): Remove unused static array. * src/lineshapes.cc: (lineshape_voigt_kuntz6, lineshape_voigt_kuntz3, lineshape_voigt_kuntz4): Remove redundant assignments. (lineshape_voigt_drayson): Remove code with no effect and variable TRU. * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Slightly rearrange code. Initialize gamma with gamma_self. Remove temp variable. 2012-09-14 Jana Mendrok * arts-2-1-292 * controlfiles/artscomponents/absorption/TestIsoRatios.arts, IsoRatios_H2Oorig.xml, IsoRatios_H2Omani.xml, tropical.H2O_50%.xml, controlfiles/CMakeLists.txt: Added isotopologue ratio consistency test case. * src/species_data.cc: Fixed some isotopologue ratio bugs. Docu updated on built-in vs. read-from-file isotopologue ratios. * src/absorption.[cc,h]: extended output operator for SpeciesRecord. 2012-09-14 Oliver Lemke * arts-2-1-291 * src/absorption.cc (SpeciesAuxData::ReadFromStream): Remove leftover debug output. 2012-09-14 Oliver Lemke * arts-2-1-290 * src/xml_io_compound_types.cc: Use xml_set_stream_precision instead of setting it manually. 2012-09-14 Oliver Lemke * arts-2-1-289 * src/ppath.cc (ppath_step_refr_{1,2,3}d): Fire up an assertion if called with an unknown raytrace method. Because rtrace_method is a string, this can easily happen by a typo. Without this sanity check, the calculation will just continue with uninitialized variables. * src/libmicrohttpd/connection.c (try_ready_chunked_body): Catch possible NULL function pointer dereference. * src/m_abs.cc (WriteMolTau): Store sizes in variables. * src/absorption.cc (xsec_species): Make some variables const. 2012-09-14 Oliver Lemke * arts-2-1-288 * src/montecarlo.cc (mcPathTraceIPA): Add an assertion on istep to make sure we ran at least once through the while loop. If not, several variables are used uninitialized. * src/cloudbox.cc (scale_H11): Move definition of ratio into the block where it's actually used and remove unnecessary assignment. (pnd_fieldMP48): Init lambda with nan and add an assertion to make sure it was properly initialized inside the while loop. Otherwise it's possible that it is used uninitialized. * src/ppath.cc (ppath_start_2d, do_gridcell_2d): Remove unnecessary assignments to variables whose value is never read again. * src/m_atmosphere.cc (z_fieldFromHSE): Remove unnecessary assignment of g1=g0 by moving it inside the for-loop where it is actually used (and initialized with g2). 2012-09-14 Oliver Lemke * arts-2-1-287 * src/xml_io_compound_types.cc: Increase precision when writing SpeciesAuxData. 2012-09-14 Oliver Lemke * arts-2-1-286 * src/file.{cc,h}: Add an input manipulator class to support parsing of inf and nan values from input streams. The standard is not clear about support for this (some newer compilers like clang do it by default, others like gcc don't). With this class, we can handle it consistently across different compilers. * src/absorption.cc (SpeciesAuxData::ReadFromStream): Use double_imanip(). 2012-09-12 Richard Larsson * arts-2-1-285 * src/m_zeeman.cc: Fixed sign error in frequency shift routine. Also gives more information in the error message if a LineRecord that contains unexpected quantum numbers is encountered. * Updated Zeeman reference file: to fix for the sign error. 2012-09-12 Oliver Lemke * arts-2-1-284 * doc/uguide/absorption.tex: Fix typo. 2012-09-12 Oliver Lemke * arts-2-1-283 * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts, controlfiles/artscomponents/groundbased/TestWinds.arts, controlfiles/artscomponents/zeeman/TestZeeman.arts, controlfiles/general/agendas.arts, doc/uguide/absorption.tex, doc/uguide/concept.tex, src/m_abs.cc, src/m_abs_lookup.cc, src/m_zeeman.cc, src/methods.cc: Rename abs_mat_per_speciesAddLBL -> abs_mat_per_speciesAddOnTheFly and abs_mat_per_speciesAddZeemanLBL -> abs_mat_per_speciesAddZeeman. 2012-09-11 Stefan Buehler * arts-2-1-282 * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Modified the broadening calculation: Normalize only the foreign broadening, so that it scales with the total foreign pressure (1-p_self). In other words, we do no scaling for the self part. In this way, results are even closer to what we got with artscat-3. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Make test fail if Artscat-3 and Artscat-4 absorption differ by more than 1e-18 1/m (was 1e-7). 2012-09-10 Richard Larsson * arts-2-1-281 * src/m_zeeman.cc: Changed program flow to not call higher level functions. (Absorption is now handled locally instead of calling m_abs.cc functions). Also have a lower tollerance for database errors. * Updated Zeeman testfiles. 2012-09-10 Oliver Lemke * arts-2-1-280 * Add support for reading and writing of isotopologue_ratios to an XML file. The file format is similar to the ARTSCAT format. Default values for isotopologue ratios can be extracted from the built-in species_data (this is done by default in general.arts) and then be written to a file: isotopologue_ratiosInitFromBuiltin WriteXML("ascii", isotopologue_ratios, "isos.xml") Instead of intializing isotopologue_ratios from species_data, they can then simply be read: ReadXML(isotopologue_ratios, "isos.xml") Note that all ratios are initialized with NAN. If species are missing from the input file, those values will stay NAN. * src/absorption.{cc,h}: New class SpeciesAuxData. Used to hold runtime values for IsotopologueRatios at the moment, but can be used for other parameters in the future. Reading routine is also in here. (write_lines_to_stream): Remove declaration of non-existent function. * src/species_data.cc: Replace all -1. ratio and mass values for continua with NAN. * src/groups.cc: New group SpeciesAuxData. * src/workspace.cc, src/gas_abs_lookup.h, src/m_abs.cc, src/m_abs_lookup.cc, src/m_zeeman.cc: Change type of isotopologue_ratios from ArrayOfVector to SpeciesAuxData. * src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Add reading/writing for SpeciesAuxData. * src/nc_io_compound_types.cc, src/nc_io_instantiation.h, src/nc_io_types.h: Add dummy for SpeciesAuxData type. 2012-09-08 Oliver Lemke * arts-2-1-279 * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts, controlfiles/artscomponents/wfuns/TestWfuns.arts, controlfiles/instruments/hirs/TestHIRS.arts, controlfiles/instruments/odinsmr/TestOdinSMR_1D.arts: Add more Ignore(ppath_los) to non-Zeeman absorption agenda definitions in remaining check-all tests. 2012-09-07 Richard Larsson * arts-2-1-278 * General: Fixed a major miss in treatment of Zeeman regarding what los vector to use. Used to take sensor los instead of point path los. * Controlfiles/*: Added Ignore( ppath_los ) to non-Zeeman absorption agenda definitions. * src/rte.cc: Sends ppath.los at ip into abs_mat_per_species_agenda in relevant functions. * src/doit.cc, src/montecarlo.cc, src/disort.cc, src/m_abs_lookup.cc: Sends in dummy ppath_los to absorption agenda. Did not check if these had ppath defined and could us the real los instead since they already send in dummy magnetic field. * src/methods.cc: abs_mat_per_speciesAddZeemanLBL now takes ppath_los instead of rte_los. Also takes atmosphere_dim for use of mirror_los. * src/workspace.cc: Added ppath_los. * src/agendas.cc: Updated abs_mat_per_species_agenda to take ppath_los. * src/m_zeeman.cc: In effect mirror_los(*) of ppath_los replaces rte_los. 2012-09-07 Jana Mendrok * arts-2-1-277 * controlfiles/instruments/hirs/hirs_fast.arts: Bugfix. 2012-09-07 Jana Mendrok * arts-2-1-276 * controlfiles/CMakeLists.txt: Fixed atmosphere_data/ renaming. 2012-09-07 Jana Mendrok * arts-2-1-275 * controlfiles/atmosphere_data/: Renamed to testdata/ * controlfiles/testdata/abs_lines_IR.xml.gz: Added. ARTS catalogue data for HIRS/AVHRR test cases. * controlfiles/[artscomponents,instruments]/*/*.arts: Adapted to atmosphere_data/ renaming. * controlfiles/instruments/avhrr/avhrr_reference.arts, hirs/hirs_fast.arts,hirs/hirs_hitran.arts: Replace use of HITRAN by ARTSCAT-version of HITRAN. * controlfiles/CMakeLists.txt: switch on TestHIRS again (TestAVHRR also running, but computational expensive and need not that different from TestHIRS). * src/absorption.cc(calc_gamma_and_deltaf_artscat4): VMR-"Warning" throws an error, hence -> "Error". 2012-09-07 Oliver Lemke * arts-2-1-274 * controlfiles/CMakeLists.txt: Fix case. 2012-09-07 Oliver Lemke * arts-2-1-273 * controlfiles/CMakeLists.txt: Add TestCompareArtscat3and4. * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Set atmosphere to 1D and stokes_dim to 1. * src/absorption.cc (calc_gamma_and_deltaf_artscat4): Remove variable name from unused parameter to avoid warning. 2012-09-07 Stefan Buehler * arts-2-1-272 * controlfiles/artscomponents/absorption/TestCompareArtscat3And4.arts: Added. Makes sure that absorption calculated from ARTSCAT-4 and ARTSCAT-3 is the same. * src/m_basic_types.cc (Tensor7Compare): Added. Similar to the other ...Compare methods. * src/methods.cc (Tensor7Compare): Added. * src/absorption.cc (find_broad_spec_locations): Fixed bug in function parameters. (calc_gamma_and_deltaf_artscat4): Ditto. * src/absorption.h (ARTSCAT4FromARTSCAT3): Bugfixes. 2012-09-07 Patrick Eriksson * arts-2-1-271 * doc/uguide/rte.tex: Added flowchart. Some language fixes. Made the "Compulsory sensor ..." section a bit shorter, by removing less important discission. This hopyfully completes the revision of the chapter. * doc/uguide/sensor.tex: Extended with two paragrapghs from rte.cc. 2012-09-07 Jana Mendrok * arts-2-1-270 * controlfiles/CMakeLists.txt: outcomment tests that currently use HITRAN (to be fixed before switching on again). 2012-09-07 Jana Mendrok * arts-2-1-269 * controlfiles/general/general.arts: fix INCLUDE file name. * controlfiles/CMakeLists.txt: Oops, bugfix - NOW all tests switched ON. 2012-09-07 Jana Mendrok * arts-2-1-268 * src/partition_function_data.cc: Added links to partition function comparison data&tools archive. * doc/uguide/concept.tex: couple of fixes of spelling and formulations. 2012-09-07 Jana Mendrok * arts-2-1-267 * starting cleaning & reorganizing of general.arts: * controlfiles/general/agendas.arts,planet_earth.arts: Added. INCLUDE files supposed to hold agenda predefinitions & default settings and planet specific default settings. For the moment just everything falling into those categories moved from general.arts to those. Need further development/structuring/cleaning. * controlfiles/general/general.arts: Clean up. Keeping only "real" defaults, i.e., settings that are basic and usually not reset. * controlfiles/[artscomponents,instruments]/*/Test*.arts: Adapted all test cases to above general.arts changes (particularly moved setting of atm_dim, stokes_dim, cloudboxOff, jacobianOff into the Test ctrl-files. user shall be forced to explicitly set those parameters). * controlfiles/instrument/amsu/TestAMSUA.arts: Removed. Except for the amsua.arts include, which does not exist, and the MatrixCompare of the output this is identical to TestAMSUB.arts. So no need to keep it. * controlfiles/CMakeLists.txt: switch on ALL existing test cases (except TestDisort, which needs to be fixed. or removed.) * controlfiles/instruments/hirs/garand_profiles.xml.gz: Moved to controlfiles/atmosphere_data/. 2012-09-06 Stefan Buehler * arts-2-1-266 * src/m_abs.cc (abs_linesArtscat4FromArtscat3): Added, converts lines from version 3 to version 4 format. * src/methods.cc: (abs_linesArtscat4FromArtscat3): Added. * src/absorption.cc: Minor changes in broadening calculations. * src/absorption.h (BroadSpecSpecIndex): Added. (ARTSCAT4FromARTSCAT3): Added, internal function that does the work for WSM abs_linesArtscat4FromArtscat3. (ARTSCAT4UnusedToNaN): Added. 2012-09-06 Patrick Eriksson * arts-2-1-265 * src/m_sensor.cc (sensorOff): Removed atmosphere_dim as input. Was just passed to sensor_responseInit, that needs for some checks of no relevance in this case. So dim now set internally to 1. This unlogical dependency of atmosphere_dim was pointed out by Jana. Thanks. 2012-09-06 Oliver Lemke * arts-2-1-264 * src/workspace.cc: New WSV isotopologue_ratios. * src/methods.cc: New WSM isotopologue_ratiosInitFromBuiltin. (abs_lookupCreate, abs_lookupTestAccuracy, abs_lookupTestAccMC, abs_mat_per_speciesAddZeemanLBL): Add isotopologue_ratios as input. * controlfiles/general/general.arts: Initialize isotopologue_ratios. * src/absorption.{h,cc} (xsec_species): Add param isotopologue_ratios. Use those for calculation instead the ones from species_data. * m_abs.cc (abs_coefCalc, abs_coefCalcSaveMemory, abs_xsec_per_speciesAddLines, abs_mat_per_speciesAddLBL): Add param isotopologue_ratios. (isotopologue_ratiosInitFromBuiltin): New function. * src/m_abs_lookup.cc (abs_lookupCreate, calc_lookup_error, abs_lookupTestAccuracy, abs_lookupTestAccMC), src/m_zeeman.cc (abs_mat_per_speciesAddZeemanLBL): Add param isotopologue_ratios. * gas_abs_lookup.h (GasAbsLookup): Update friend declarations. 2012-09-06 Oliver Lemke * arts-2-1-263 * src/m_atmosphere.cc (GriddedFieldLatLonRegridHelper): Give clear error message if latitude or longitude grid is empty. * src/check_input.cc (chk_interpolation_grids, chk_interpolation_grids_loose_no_data_check, chk_interpolation_grids_loose_check_data): Throw runtime error if new grid is empty. 2012-09-06 Jana Mendrok * arts-2-1-262 * 3rdparty/partFct/*.*: Added. Tools and data for derivation of partition function polynomial coefficients. For details see README. * 3rdparty/partFct/TIPS/: Added. Latest version of the TIPS program (slightly modified for all-species tabulated Q(T) output). 2012-09-05 Jana Mendrok * arts-2-1-261 * doc/uguide/absorption.tex: Updated. Separate subsec for absorption-with-no-RT. Refer to ATG for details on isotop. ratios and partition function data. * doc/uguide/absorption_theory.tex: Updated. Added info on ARTSCAT-4 and its format. Redone and completed part on partition function implementation & derivation. * src/workspace.cc (abs_coef,abs_coef_per_species: Concretized documentation. * src/methods.cc: (abs_mat_per_speciesAddFromLookup) linkname fix, (GriddedFieldLatLonExpand) documentation corrected. * src/absorption.h: Fixed layout of line format tables. 2012-09-05 Stefan Buehler * arts-2-1-260 * General: First implementation of explicit broadening calculation for all broadening species from Agnes catalogue. Not yet tested! * src/absorption.cc (LineRecord): Changed the way the foreign broadening and shift parameters are stored. Leads to changes in output operator and catalogue reading routines. (operator<<): Updated. (ReadFromArtscat4Stream): Updated. (find_broad_spec_locations): Updated. (calc_gamma_and_deltaf_artscat4): Added. This is the internal function that does the actual broadening calculation. (xsec_species): Updated. * src/absorption.h (LineRecord): Changed the way the foreign broadening and shift parameters are stored. Modified associated member functions and added new member functions to handle these parameters. (Gamma_foreign): Added. (N_foreign): Added. (Delta_foreign): Added. (BroadSpecName): Added. (NBroadSpec): Added. * src/abs_species_tags.h: Removed old #defines for SPECIES_INDEX_XX, since they were not used. 2012-09-05 Oliver Lemke * arts-2-1-259 * src/m_atmosphere.cc (GriddedFieldLatLonExpand): Properly handle the case if only one dimension (lat or lon) has only 1 element. 2012-09-05 Richard Larsson * arts-2-1-258 * doc/uguide/absorption_theory.tex: Moved the Zeeman text farther down place and updated parts of the text * src/m_zeeman.cc: Updated sligthly. 2012-09-04 Patrick Eriksson * arts-2-1-257 * doc/uguide/rte.tex: A bit more on dispersion and wrote a section on auxiliary data. 2012-09-04 Stefan Buehler * arts-2-1-256 * src/absorption.cc (find_broad_spec_locations): Added. It finds the positions of the broadening species (N2, O2, etc.) in abs_species. (xsec_species): Modified call parameters. Added: all_vmrs (instead of vmr), abs_species, this_species. Removed: abs_h2o_orig. We now have all species descriptions and VMRs available, so that we can calculate the broadening by the different gases explicitly. (The broadening calculation itself is not yet implemented.) * src/m_abs.cc (abs_coefCalc): Adapted to change in xsec_species. (abs_coefCalcSaveMemory): Ditto. (abs_xsec_per_speciesAddLines): Ditto. * src/m_abs_lookup.cc (abs_lookupCreate): Ditto. * src/m_zeeman.cc (abs_mat_per_speciesAddZeemanLBL): Adapted to changes in xsec_species. Commented out call to calculation of continua, since I believe it should not be here. This makes also several input arguments unnecessary, removed them. * src/methods.cc (abs_mat_per_speciesAddZeemanLBL): Updated. (abs_xsec_per_speciesAddLines): Updated. * src/absorption.h: Added enum for position indices of broadening species in abs_species (SPEC_POS_N2, SPEC_POS_O2, SPEC_POS_H2O, SPEC_POS_CO2, SPEC_POS_H2, SPEC_POS_He). * src/lineshapes.cc (Rosenkranz_Voigt_Kuntz6): Removed. (Rosenkranz_Voigt_Drayson): Ditto. 2012-09-04 Richard Larsson * arts-2-1-255 * src/m_abs.cc: Minute change. * src/m_zeeman.cc: For now the temporary abs_species only carry the "O2" tag. All other tag information is lost. 2012-09-03 Jana Mendrok * arts-2-1-254 * controlfiles/planetary_toolbox/: Added folder for collection of controlfiles for ESA planetary toolbox. * src/partition_function_data.cc: correction of C3H8 part.fct. and documentation. 2012-09-03 Patrick Eriksson * arts-2-1-253 * doc/uguide/rte.tex: Completed comments and section dealing with dispersion. * doc/uguide/winds.tex: Added reference to dispersion section, to apply a frequency specific shift. 2012-09-03 Patrick Eriksson * arts-2-1-252 * doc/uguide/rte.tex: To be continued ... * src/m_rte.cc (iyEmissionStandard): Code for RT step with polarised absorption changed. Usage of mult avoided for emission part, to make use of the fact that the b-vector contains zeros. * doc/uguide/wfuns.tex: Added fixme to explain diy_dx. 2012-09-03 Jana Mendrok * arts-2-1-251 * src/species_data.cc: Added new HITRAN species&isotopologues and other species required for ESA planetary study. Updated/revised documentation. Corrected isotopologue abundancies from JPL (such that have IR(main isoptope) given as 1). * src/partition_function_data.cc: Added partition function coefficients for new species/isotopologues. Updated documentation (FIXME: re-add code to derive polynomial coefficients from TIPS and JPL partition function data! It's a hassle trying to reproduce existing and consistently derive new coefficients, when this is gone!). Re-enacted use of ceoff tags for documenting data source. * src/absorption.[cc,h]: added output operator for SpeciesRecord (currently only outputs the species name tag. extend as needed.) * src/agendas.cc(iy_surface_agenda), src/workspace.cc(transmitter_pos): spellfixes in doc. 2012-09-03 Oliver Lemke * arts-2-1-250 * src/agendas.cc, src/methods.cc, src/workspace.cc: Restore alphabetical order of WSMs, WSVs and Agendas. 2012-09-03 Patrick Eriksson * arts-2-1-249 * doc/uguide/rte.tex: Extended, but not yet finished. * doc/uguide/*.tex: Some general cleaning. Removed some double-defined labels. Updated to new names of some WSV and WSM (blackbody_radiation_agenda, iyTransmissionStandard ...). Some agendas ended up in Index under WSV. * doc/uguide/reduction.tex: * doc/uguide/wfuns_sensor.tex: * doc/uguide/measerr.tex: * doc/uguide/wfuns_atm.tex: All removed, obselete (the content can be picked up from AUG-1). * doc/uguide/symbol_defs.tex: Removed the command SAbVec (not used, and probably just confusing). Changed the symbol for identity matrix to 1. This to avoid confusion where the identity matrix and the stokes vector appear in the same equation (I used for Stokes). 2012-08-31 Patrick Eriksson * arts-2-1-248 * doc/uguide/rte.tex: More updating: To reflect e.g.: upward observations outside the atmosphere is now accepted, iy_surface_agenda and ppath_agenda introduced. Work in progress. Surface sub-section moved to the surface chapter. 2012-08-31 Patrick Eriksson * arts-2-1-247 * doc/uguide/rte.tex: Started to revise this chapter. * doc/uguide/transmission.tex: New chapter, just started. 2012-08-31 Oliver Lemke * arts-2-1-246 * doc/uguide/absorption_theory.tex, src/abs_species_tags.cc, src/abs_species_tags.h, src/absorption.cc, src/absorption.h, src/continua.cc, src/m_abs.cc, src/m_abs_lookup.cc, src/methods.cc, src/nc_io_array_types.cc, src/nc_io_compound_types.cc, src/nc_io_instantiation.h, src/nc_io_types.h, src/partition_function_data.cc, src/species_data.cc, src/workspace.cc, src/xml_io_array_types.cc, src/xml_io_compound_types.cc, src/xml_io_instantiation.h, src/xml_io_types.h: Change terminology as proposed by Stefan. Isotope -> Isotopologue 2012-08-31 Stefan Buehler * arts-2-1-245 * GENERAL: Removed WSV abs_scalar_gas and the last remaining WSMs that had to do with it. * src/workspace.cc (abs_scalar_gas): Removed. * src/methods.cc (abs_scalar_gasCalcLBL): Removed. (abs_mat_per_speciesAddFromAbsCoefPerSpecies): Added. This method is similar to the old method abs_scalar_gasFromAbsCoef that has been removed. Used internally by abs_mat_per_speciesAddLBL. * src/m_abs.cc (abs_xsec_per_speciesAddLines): Do not calculate for Zeeman species. (They are ignored in the same way as species with empty line list are ignored.) (abs_mat_per_speciesAddFromAbsCoefPerSpecies): Added. (abs_scalar_gasFromAbsCoef): Removed. (Replaced by the above method.) (abs_scalar_gasCalcLBL): Removed. (Content is now part of abs_mat_per_speciesAddLBL.) (abs_mat_per_speciesAddLBL): Removed special handling (ignoring) of Zeeman species (now done in abs_xsec_per_speciesAddLines). * src/m_abs_lookup.cc (calc_lookup_error): Use abs_mat_per_speciesAddLBL instead of abs_scalar_gasCalcLBL. * src/m_optproperties.cc: Fixed errors in comments. * src/disort.h (dtauc_ssalbCalc): Fixed wrong absorption agenda name. * src/disort.cc: Fixed errors in comments. * src/montecarlo.h (mcPathTraceGeneral): Fixed wrong absorption agenda name. 2012-08-31 Patrick Eriksson * arts-2-1-244 * doc/uguide/atmosphere.tex: Updated. Added a short section on geo-location by lat_true and lon_true. Nothing about polarised absorption now mentioned in cloudbox section. Commented out second 3D figure (no additional information and chapter then fits into 6 pages). * doc/uguide/in_and_out.tex: New chapter. So far just treating data formats. * doc/uguide/concept.tex: Changed name of chapter to "Introduction". A few language fixes. Some short updates, such that radio links can be treated. Moved section on data formats to new chapter. Added three FIXME: \FIXME{Control file structure changed, update this section!} \FIXME{Revise this section after general.arts has been changed.} \FIXME{The tests are now structured differently. Update the text.} * controlfiles/general/general.arts: Changed abs_mat_per_speciesExtractFromLookup to abs_mat_per_speciesAddFromLookup (in a comment). 2012-08-31 Oliver Lemke * arts-2-1-243 * src/absorption.h (isContinuum): Use isdigit instead of isnumber to fix build on Linux. 2012-08-31 Oliver Lemke * arts-2-1-242 * src/absorption.h (IsotopeRecord): Add isContinuum(). Instead of demanding the abundance being -1 for continua, this test relies on the name of the continua tags not starting with a number like normal isotopes. * src/m_abs.cc (abs_xsec_per_speciesAddConts), src/continua.cc (check_continuum_model), src/absorption.h (abs_linesReadFromSplitArtscat), src/m_abs_lookup.cc (find_nonlinear_continua): Use isContinuum to detect continua. 2012-08-30 Richard Larsson * arts-2-1-241 * Naming and documentation of Zeeman and absorption: Changed some method names to be more consistent with intentions and removed abs_scalar_gas from documentation. * controlfiles/general/general.arts: Reflects new names. * controlfiles/artscomponents/zeeman/TestZeeman.arts: Reflects new names. * controlfiles/artscomponents/groundbased/TestWinds.arts: Reflects new names. * doc/uguide/polarization.tex: Changed sign on equation (4.80) to true sign (I think). * doc/uguide/Figs/abs_theory/Selection_Rule.pdf: Added Zeeman related explanatory figure. * doc/uguide/concept.tex: Changed from scalar to mat as example workspace variable. * doc/uguide/absorption.tex: Preliminary change from abs_scalar_gas to abs_mat_per_species. * doc/uguide/absorption_theory.tex: Preliminary Zeeman theory added. Please let me know if something is explained in a bad manner... * src/methods.cc: Name changes. * src/m_abs.cc: Name changes. * src/m_zeeman.cc: Name changes and slight code cleaning. 2012-08-29 Patrick Eriksson * arts-2-1-240 * controlfiles/artscomponents/transmission/TestTransmission.arts: Case expanded to also test iyLoopFrequencies. * src/m_rte.cc (iyLoopFrequencies): Finished and tested. Seems that we now have a general mechanism to handle dispersion and similar issues. 2012-08-29 Stefan Buehler * arts-2-1-239 * GENERAL: All test controlfiles work again. Warning: One method renamed (see below). * src/methods.cc (abs_mat_per_speciesAddFromLookup): Renamed from abs_mat_per_speciesExtractFromLookup. Updated documentation. Now takes f_grid as input instead of f_index. * src/m_abs_lookup.cc (abs_mat_per_speciesAddFromLookup): Now takes f_grid as input instead of f_index. Uses gridpos to find right index in frequency grid if called with only one frequency. * controlfiles/artscomponents/doit/TestDOIT.arts: Renamed abs_mat_per_speciesAddFromLookup. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: Ditto. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Ditto. * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneralGaussian.arts: Ditto. * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: Ditto. * controlfiles/artscomponents/montecarlo/TestMonteCarloGeneral.arts: Ditto. * controlfiles/artscomponents/groundbased/TestGbased.arts: Ditto. * controlfiles/instruments/amsu/TestAMSU_generic.arts: Ditto. * controlfiles/instruments/mhs/TestMHS_generic.arts: Ditto. * controlfiles/instruments/odinsmr/TestOdinSMR.arts: Ditto. 2012-08-28 Patrick Eriksson * arts-2-1-238 * src/doit.cc (iy_interp_cloudbox_field): Added a check that should catch if DOIT would be used together with iyLoopFrequencies (which would fail). * src/m_rte.cc (iyLoopFrequencies): Created (not tested, below called iyRunMonochromatic). * src/m_doit.cc (CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Adopted call of get_iy. * src/rte.cc (get_iy): As below, but had here to add f_grid as input. * src/m_surface.cc (iySurfaceRtpropAgenda): * src/rte.cc (iyb_calc): * src/m_rte.cc (iyCalc): Adopted call of iy_main_agenda. * src/m_rte.cc (iyTransmissionStandard, iyRadioLink): Adopted call of iy_transmitter_agenda. * src/agendas.cc: Added f_grid to iy_main_agenda and iy_transmitter_agenda. Introduced iy_sub_agenda. 2012-08-28 Oliver Lemke * arts-2-1-237 * WARNING!!!!!! WORK IN PROGRESS, removing f_index: All test cases that use abs_mat_per_speciesExtractFromLookup are currently not working! * src/methods.cc: (abs_scalar_gasCalcLBL, abs_mat_per_speciesCalcLBL, abs_mat_per_speciesInit, abs_mat_fieldCalc, abs_mat_per_speciesAddZeeman): Remove f_index. * src/agendas.cc: Change f_index to f_grid in abs_mat_per_species_agenda. Add f_grid to doit_mono_agenda, should be replaced by an f_mono WSV later. * src/optproperties.{cc,h} (opt_prop_add_abs_mat_per_species): Remove f_index. * src/doit.cc (cloud_RT_no_background, cloud_ppath_update1D_planeparallel): Change f_index to f_grid[Range(f_index, 1)] in abs_mat_per_species_agendaExecute call. Remove f_index from opt_prop_add_abs_mat_per_species. * src/m_abs.cc (abs_scalar_gasCalcLBL, abs_mat_per_speciesCalcLBL): Remove f_index. * src/m_abs_lookup.cc (abs_mat_fieldCalc): Adapt call to abs_mat_per_species_agendaExecute. Remove parameter f_index. (calc_lookup_error): Remove f_index argument (was -1) in call to abs_scalar_gasCalcLBL. * src/disort.{cc,h} (dtauc_ssalbCalc): Change f_index to f_mono. * src/m_disort.cc (ScatteringDisort): Pass f_grid[Range(f_index,1)] instead of f_index to dtauc_ssalbCalc. * src/m_zeeman.cc (abs_mat_per_speciesAddZeeman): Remove f_index. * src/m_montecarlo.cc (mc_IWP_cloud_opt_pathCalc): Pass f_mono to iwp_cloud_opt_pathCalc. (MCGeneral): Pass f_mono instead of f_index to mcPathTraceGeneral. * src/montecarlo.{cc,h} (clear_rt_vars_at_gp, cloudy_rt_vars_at_gp, mcPathTraceGeneral, mcPathTraceIPA): Replace f_index with f_mono. (iwp_cloud_opt_pathCalc): Replace f_grid+f_index by f_mono. * controlfiles/artscomponents/absorption/TestAbsDoppler.arts: Remove f_index. 2012-08-28 Patrick Eriksson * arts-2-1-236 * src/m_rte.cc (iyRunMonochromatic): Just started. * src/doit.cc (cloud_RT_surface): Added a comment. * src/m_montecarlo.cc (MCGeneral): Introduced f_mono (to avoid forming this vector repeatedly). * src/rte.cc (get_iy_of_background): Removed outdated comments. 2012-08-27 Patrick Eriksson * arts-2-1-235 * src/m_surface.cc (iySurfaceRtpropAgenda): * src/m_montecarlo.cc (MCGeneral, MCIPA): Adopted call of surface_rtprop_agendaExecute. * src/doit.cc (cloud_RT_surface, cloud_ppath_update1D) (cloud_ppath_update1D_noseq): f_grid now input to cloud_RT_surface. * src/rte.cc (get_iy_of_background): Adopted call of agendas listed below. * src/agendas.cc: Added f_grid as input to iy_cloudbox_agenda, iy_surface_agenda and surface_rtprop_agenda. 2012-08-27 Patrick Eriksson * arts-2-1-234 * transmitter_pos now input to yCalc and converted to rte_pos2, following sensor_pos/rte_pos. This allowed that mblock_index now is completely invisible for the user. In addition, rte_pos2 is now defined throughout the rt part and more complex set-ups are possible (such as considering surface reflections of transmitted signals). * controlfiles: Many cfiles had to be adopted. * src/m_doit.cc: Adopted to changes below. rte_pos2 consistently set to an empty vector (no transmitter can be involved for DOIT). * src/m_ppath.cc (ppathCalc): * src/m_rte.cc (iyCalc, iyEmissionStandard, iyRadioLink) (iyTransmissionStandard): Basically replaced mblock_index with rte_pos2. * src/m_jacobian.cc (jacobianCalcAbsSpeciesPerturbations) (jacobianCalcPointingZaRecalc) (jacobianCalcTemperaturePerturbations): Added transmitter_pos as input argument and passed on to iyb_calc. * src/rte.cc (iyb_calc): Now using transmitter_pos. * src/m_rte.cc (yCalc): Now using transmitter_pos (and checks that size is empty or match sensor_pos). * src/agendas.cc: Replaced mblock_index with rte_pos2 for iy_main_agenda and ppath_agenda. And added rte_pos2 for iy_surface_agenda. * src/workspace.cc: Updated/extended text for transmitter_pos and rte_pos2. 2012-08-27 Patrick Eriksson * arts-2-1-233 * Removed everything associated with the idea of having senesor_response_array. * src/m_sensor.cc (sensor_responseFromArrayData): Removed. (sensor_response_arraySingle): Removed. * src/workspace.cc (define_wsv_data): Removed all WSV with sensor_response_array. 2012-08-27 Patrick Eriksson * arts-2-1-232 * controlfiles/artscomponents/ppath/TestPpath1/2/3D.arts: Adopted. * src/montecarlo.cc (iwp_cloud_opt_pathCalc): As below + added f_grid as input argument. * src/m_montecarlo.cc (MCIPA): * src/doit.cc (cloud_ppath_update1D, cloud_ppath_update1D_noseq) (cloud_ppath_update3D): Adopted call of ppath_step_agenda. * src/rte.cc (get_ppath_blackrad, get_ppath_abs) (get_ppath_trans, get_ppath_trans2): Now not using f_index. * src/m_rte.cc (iyEmissionStandard, iyRadioLink) (iyTransmissionStandard): f_index totally removed. * src/rte.cc (defocusing_general_sub, defocusing_general) (defocusing_sat2sat): f_index changed to f_grid. * src/m_ppath.cc: * src/ppath.cc: * src/refraction.cc: f_index changed to f_grid everywhere used. * src/m_refraction.cc (refr_indexFreeElectrons): Now not using f_index. On-line doc updated accordingly. * src/agendas.cc: Replaced f_index with f_grid as input to ppath_agenda, ppath_step_agenda and refr_index_agenda. 2012-08-23 Patrick Eriksson * arts-2-1-231 * TODO: Some points fixed and removed. 2012-08-23 Patrick Eriksson * arts-2-1-230 * New version of transmission WSM appears ready. The approach has been changed. Treatment of cloudbox built-in. This should be more efficient calculation-wise, and also makes the iy_aux feature more useful (as data for the complete path through the atmosphere are returned). * src/m_rte.cc (iyTransmissionStandard): The method handles now also paths going through the cloudbox. Added particle extinction as aux var. (iyTransmissionStandardCloudbox): Code has been inactive. Now completely removed. * src/cloudbox.cc (is_gp_inside_cloudbox): atmosphere_dim is now an input argument. Default is 3, as previously assumed by the function. (is_inside_cloudbox): Also this function assumes 3D (without any warning). Added comment in header and assert to warn about this. * src/m_cloudbox.cc (cloudboxOff): The method now also "touches" pnd_field, use_mean_scat_data and scat_data_raw (to handle all cloud variables that can be input to a iy_main_agenda-method). * src/rte.cc (get_ppath_trans2): New. * src/rte.cc (get_ppath_pnd, get_ppath_cloudrtvars): Both functions replaced by other methods. Removed. 2012-08-23 Jana Mendrok * arts-2-1-229 * src/absorption.h (LineRecord): Added info on ARTSCAT-4 format. 2012-08-21 Patrick Eriksson * arts-2-1-228 * src/rte.cc (get_ppath_partext): Started (not finished, not yet used). * src/special_interp.cc (interp_cloudfield_gp2itw): Changed function to operate on GridPos, instead of ArrayOfGridPos. * src/physics_funcs.cc (barometric_heightformula): Moved the function from cloudbox.cc. This function has hard-coded parameters that also are defined in constants.cc. Should be fixed! 2012-08-21 Jana Mendrok * arts-2-1-227 * src/m_atmosphere.cc (AtmFieldsCalc): remove zeropadding for temperature profile (zeropadding still done for VMR and only VMR). * src/methods.cc (AtmFieldsCalc): Documented zeropadding/extrapolation behaviour. * src/absorption.h (CalculatePartitionFctRatio): Improved error message (runtime error when partition function negative). 2012-08-21 Patrick Eriksson * arts-2-1-226 * src/m_atmosphere.cc (basics_checkedCalc): Added check that all temperatures > 0. A zero temperature not catced elsewhere. For example, I got a segementation fault for MC! 2012-08-21 Patrick Eriksson * arts-2-1-225 * controlfiles/artscomponents/radiolink/TestRadioLink2.arts: A version using iyCalc. All aux vars included. So far just used for manual tests. * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Adopted and header slightly expanded. * src/m_rte.cc (iyRadioLink): Dispersion functionality removed. Added handling of pressure, temperature, VMR and absorption aux data. * src/rte.cc (iyb_calc): Corrected error messagge around iy_aux. * src/workspace.cc: Removed dispersion_do (the idea is to later add dispersion in a general way (if possible?)). 2012-08-20 Patrick Eriksson * arts-2-1-224 * controlfiles/artscomponents/radiolink/TestRadioLink_Old.arts: To temporary get a copy of old version of file below. * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Partly rewritten to use yCalc and check some aux vars. * src/m_rte.cc (iyRadioLink): Fixed two bugs associated with dispersion. 2012-08-20 Oliver Lemke * arts-2-1-223 * src/absorption.cc (xsec_species): Initial hack to support calculation with an artscat version 4. Air broading is currently calculated by weighting N2 and O2 by 0.79/0.21. The weighting is applied to width, temperature exponent and pressure shift. Most likely not the correct way to do it, but results are surprisingly close to calculations based on Hitran (ClearSky test case within 0.004 K). 2012-08-20 Oliver Lemke * arts-2-1-222 * src/absorption.cc (LineRecord::ReadFromArtscat4Stream): Read quantum numbers from artscat4 files. Set Tgam to same value as in Hitran for now. 2012-08-20 Patrick Eriksson * arts-2-1-221 * src/rte.cc (get_ppath_rtvars): Obselete and removed. * src/m_rte.cc (iyRadioLink): Now using new get_ppath_XX functions. Some features reactivated. No proper tests performed. * controlfiles/artscomponents/transmission/TestTransmission.arts: Demonstration of iy_aux added. * src/m_rte.cc (iyTransmissionStandard): Code now synced with last changes in iyEmissionStandard. Set of aux vars extended. * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: Check of radiance reactivated, now using error extracted from y_aux. * src/m_rte.cc (iyMC): Error now exported as part of iy_aux. This done by setting iy_aux_vars to: [ "Error (uncorrelated)" ] (yCalc): Uncorrelated error in y_aux detected automatically and sensor response applied correspondingly. 2012-08-17 Patrick Eriksson * arts-2-1-220 * Some unfinished work around aux vars and y_unit. * src/rte.cc (iyb_calc): Extended. * src/m_rte.cc (iyMC): iy_aux introduced. Only one option: Error. (iyApplyYunit): Extended. * src/methods.cc: Added text for MCGeneral around y_unit and mc_error. For yCalc some explanation around y_unit and y_aux. 2012-08-17 Richard Larsson * arts-2-1-219 * src/absorption.{h,cc} and src/m_zeeman.cc: Quantum numbers are now stored as Index(s) in LineRecord. 2012-08-17 Patrick Eriksson * arts-2-1-218 * controlfiles/artscomponents/clearsky/TestClearSky.arts: Added "Radiative background" as aux var. * controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts: Added some new variables to iy_aux_vars. * src/m_rte.cc (iyEmissionStandard): Added special code for vector unpolarised case (only for radiance, no change for jac.). * src/rte.cc (trans_step_std): Removed (was not used). * src/lin_alg.cc (matrix_exp): Extended header text (to make clear that diagonal case is handled efficiently). (rte_step_std): In header text, removed suggestion to use for "clearsky" (following test by Richard). 2012-08-16 Oliver Lemke * arts-2-1-217 * src/rte.cc (get_ppath_abs): Use l_ws and l_abs_mat_per_species_agenda to fix OpenMP crash. 2012-08-16 Patrick Eriksson * arts-2-1-216 * src/m_rte.cc (iyEmissionStandard): Extensive changes, following modifications in rte.cc. Jacobians should now be fully OK again (but only for unpol. absorption, there is a runtime error if absorption is polarised). * src/rte.cc: Cleaning and restructuring of get_ppath_XXX and iy_transmission_XXX: (iy_transmission_mult): Now only function of this type. (iy_transmission_for_scalar_tau, iy_transmission_mult_scalar_tau): Removed. (get_ppath_abs, get_ppath_trans, get_ppath_blackrad): New functions, that will replace get_ppath_rtvars. * src/logic.cc: A few cosmetic changes. 2012-08-16 Oliver Lemke * arts-2-1-215 * Tweaking parallelization. TestClearSky ~1.8x faster. * src/rte.cc (get_ppath_rtvars): Parallelize over pressure levels. * src/m_rte.cc (yCalc): Only parallelize if nmblock >= numthreads. 2012-08-16 Richard Larsson * arts-2-1-214 * src/workspace.cc, src/agendas.cc and src/methods.cc: Updated documentation regarding the abs_mat_per_species implementation. 2012-08-15 Oliver Lemke * arts-2-1-213 * src/lineshapes.cc: Remove redundant parameter nf from lineshape and normalization functions. Add const to input parameters of lineshape and normalization functions. Make local variables const where possible. Might help the compiler to do better optimizations. (lineshape_norm_no_norm): Remove unnecessary loop. * src/absorption.h: Make input parameters of lsf_type and lsnf_type const. Remove redundant argument nf from lsf_type and lsnf_type. * src/absorption.cc (xsec_species): Remove redundant parameter nfls. 2012-08-15 Richard Larsson * arts-2-1-212 * src/lin_alg.cc (matrix_exp): Optimized for diagonal matrices. 2012-08-15 Patrick Eriksson * arts-2-1-211 * src/m_surface.cc (iySurfaceRtpropAgenda): * src/rte.cc: * src/m_rte.cc: In short, changed iy_aux to be a ArrayOfTensor4 (to allow storage of complete extinction matrices). (iyEmissionStandard): Changed iy_aux_vars Radiance and Transmission to iy and Optical depth, respectively. * src/array.h: Defined ArrayOfArrayOfTensor4. 2012-08-14 Richard Larsson * arts-2-1-210 * Changes to remove abs_scalar_gas_agenda, and opt_prop_add_gas_agenda. Replaced these by internal function and abs_mat_per_species_agenda. This in turn means changes in several test cases. * src/doit.cc, src/montecarlo.cc, src/disort.cc: Unresolved issue: How to handle magnetic fields in these methods? Current solution: rte_mag = [-1], i.e. [Ignore flag]. * src/m_rte.cc: Changes how the extinction matrix is handled in the radiative transfer equation. Unresolved issues: (1) Jacobians are in this version treated as per the scalar case. (2) Some aux-variables are ignored due to changes in how iy is calculated --- and because I do not fully understand how to handle iy_aux. * src/rte.cc: get_ppath_atmvars now demands and returns magnetic field variables. In get_ppath_rtvars ppath_abs, ppath_tau, total_tau replaces their scalar counterparts. Dimensions are also changed so that ppath_abs have dimensions: [ppath_vmr.nrows(), f_grid.nelem(), stokes_dim, stokes_dim, ppath.np]. In get_ppath_cloudrtvars the magnetic field is treated as for wind and rte_mag = [Ignore flag]. iy_transmission_for_scalar_tau → iy_transmission_for_tensor3_tau. iy_transmission_mult_scalar_tau → iy_transmission_mult_tensor3_tau. Warning: naming convention is confusing with both iy_transmission_mult and iy_transmission_mult_tensor3_tau taking arguments (Tensor3, ConstTensor3View, ConstTensor3View). * src/workspace.cc: added "abs_mat_field" for lookup and "abs_mat_per_species" because it is important for all other changes made. * src/methods.cc: Added "abs_mat_per_speciesAddZeeman". Changed relevant things from scalar absorption to matrix absorption. * src/agendas.cc: Removed opt_prop_add_gas_agenda. Changed abs_scalar_gas_agenda to abs_mat_per_species_agenda. * src/optproperties.cc: Added opt_prop_add_abs_mat_per_species to replace pot_prop_add_gas_agenda. * src/m_abs.cc: abs_mat_per_speciesInit method to initiate abs_mat_per_species to the correct size with values of 0. abs_mat_per_speciesCalcLBL now gets the extinction matrix for all non-Zeeman species. Warning: using this and only this method for absorption when Zeeman species are present will result in ignorance of all Zeeman species. * src/m_zeeman.cc: abs_mat_per_speciesAddZeeman works just like abs_mat_per_speciesCalcLBL though only for Zeeman species. If rte_mag = [Ignore flag], the Zeeman species will be treated as per the scalar case. * src/m_abs_lookup.cc: Changed abs_lookupCreate to completely ignore Zeeman species for now. Added abs_mat_per_speciesExtractFromLookup to extract scalar absorption and fit it with abs_mat_per_species for now. Changed abs_fieldCalc to use the new agenda. This file completely ignores the Zeeman effect for now with rte_mag = [Ignore flag]. * Small changes in: src/gas_abs_lookup.cc, src/m_doit.cc, src/m_montecarlo.cc and m_optproperties.cc. * doc/uguide/polarization.tex: Changed e_v in theory chapter to reflect Mishchenko. 2012-08-13 Patrick Eriksson * arts-2-1-209 * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Call of VectorCompare commented out temporarily. * src/m_rte.cc (iyRadioLink): Started to update this method with respect to iy_aux. Not ready. 2012-08-13 Patrick Eriksson * arts-2-1-208 * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/transmission/TestTransmission.arts: * src/m_rte.cc (iyTransmissionStandard, iyRadioLink): iy_space_agenda replaced by iy_transmitter_agenda. * src/agendas.cc: Added iy_transmitter_agenda. * controlfiles/instruments/odinsmr/TestOdinSMR_119ghz.arts: Removed. * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: * controlfiles/artscomponents/doit/TestDOIT.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: * controlfiles/artscomponents/surface/TestSurface.arts: * controlfiles/general/general.arts: * src/workspace.cc: * src/rte.cc: * src/m_surface.cc: * src/m_rte.cc: * src/m_fos.cc: * src/m_jacobian.cc: * src/m_doit.cc: Adopted to changes below. * src/m_rte.cc (iyTransmissionStandard): iyBeerLamberStandard renamed and extended to handle new iy_aux. * src/m_rte.cc (iyEmissionStandard): Removed Clearsky from name, following change of iy_clearsky_agenda. * src/agendas.cc: Renamed iy_clearsky_agenda to iy_main_agenda. This as not all WSM for this agenda are striclty clearsky, and to indicate that this is "the entry point" for RT calculations. 2012-08-10 Patrick Eriksson * arts-2-1-207 * Basic changes for extraction of additional data ready, and iyEmissionStandardClearsky modified accordingly. Aux feature presently lacking for other iy_clearsky_agenda methods. * controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts: Updated. Includes new aux variables and shows that ppath is directly avaliable for saving. * src/m_jacobian.cc: Adopted several methods to change of iyb_calc. * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: * controlfiles/artscomponents/surface/TestSurface.arts: * src/m_surface.cc (iySurfaceRtpropAgenda): * src/rte.cc (iyb_calc): Adopted to change of iy_clearsky_agenda. * src/m_rte.cc: Adopted several methods to change of iy_clearsky_agenda. (iyEmissionStandardClearsky): Added VMR, absorption and radiative background as auxilary variables. * src/agendas.cc: For iy_clearsky_agenda, added ppath as output and iy_aux_vars as input. 2012-08-09 Patrick Eriksson * arts-2-1-206 * Core functionality for new iy_aux in place, as well as basic documentation and control file examples. * controlfiles/instruments/avhrr/TestAVHRR.arts: * controlfiles/instruments/hirs/TestHIRS.arts: y_unitApply -> yApplyYunit. * controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts: Updated. Includes demonstration of new iy_aux. * controlfiles/artscomponents/clearsky/TestClearSky.arts: Extended to also test new y_aux functionality. * src/array.h: Defined ArrayOfArrayOfVector. * controlfiles/general/general.arts: iy_aux_vars set to be empty. * src/rte.cc (iyb_calc): Now handles new version of iy_aux. * src/m_rte.cc (yFromIy): Removed. Realised that this method implies strong restrictions for y_aux, which makes the method of little interest. The users need to learn the distinction between y and iy variables ;-) (iyEmissionStandardClearsky): Modified version of the method. Handling some first aux variables. (yCalc): Now handles new version of y_aux. (yApplyYunit): y_unitApply renamed. (iyApplyYunit): New WSM. * src/workspace.cc (define_wsv_data): Changed y_aux_vars to iy_aux_vars. 2012-08-08 Patrick Eriksson * arts-2-1-205 * src/m_fos.cc: FOS WSM deactivated. Will later be revised and re-activated. * src/m_doit.cc (CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Now using get_iy. * src/rte.cc (get_iy): New. A replacement for iy_clearsky_basic_agenda. * src/m_surface.cc (iySurfaceRtpropAgenda): Removed part associated with iy_clearsky_basic_agenda. * src/m_rte.cc (iyEmissionStandardClearskyBasic): Removed. * src/agendas.cc: Removed iy_clearsky_basic_agenda. * src/rte.cc (iyb_calc): Now calling iy_clearsky_agenda directly, instead if using iyCalc (gives better overview of code). 2012-08-08 Patrick Eriksson * arts-2-1-204 * Changes in many files around iy_aux. Largely removed/de-activated, to simplify the introduction of a new approach. Also some cleaning around diy_dx. * src/workspace.cc: Type of iy_aux and y_aux changed, y_aux_vars introduced. * src/agendas.cc: jacobian_y_agenda removed (obselete since some time!). 2012-08-07 Patrick Eriksson * arts-2-1-203 * src/workspace.cc: iy_variable and iy_aux_variable removed. * src/m_rte.cc (iyRadioLink): * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Adopted to change above. 2012-08-07 Patrick Eriksson * arts-2-1-202 * controlfiles/artscomponents/doit/TestDOIT.arts: * controlfiles/artscomponents/montecarlo/TestRteCalcMC.arts: * controlfiles/instruments/odinsmr/TestOdinSMR.arts: * controlfiles/artscomponents/surface/TestSurface.arts: * src/rte.cc: * src/m_rte.cc: * src/m_doit.cc: * src/m_fos.cc: * src/m_surface.cc: * src/methods.cc: * src/agendas.cc: Adopted to removal of iy_error, iy_error_type and y_error. * src/workspace.cc: Removed iy_error, iy_error_type and y_error. The error will be part of iy_aux and y_aux. 2012-07-31 Jana Mendrok * arts-2-1-201 * src/m_atmosphere.cc (p_gridFromZRaw): Downgraded do-not-include-negative-altitudes to only be an option (for backward consistency, default: DO exclude). (FieldFromGriddedFieldCheckLatLonHelper): bugfix in chk_if_equal calls. * src/methids.cc (p_gridFromZRaw): Documentation adapted. 2012-07-27 Oliver Lemke * arts-2-1-200 * src/m_atmosphere.cc (AtmFieldsCalc): Use new regridding functions for 3D case. 2012-07-27 Oliver Lemke * arts-2-1-199 * controlfiles/atmosphere_data/tropical.*.xml: Add grid names. * src/m_atmosphere.cc (AtmFieldsCalc): Use new regridding functions for 1D case. 2012-07-27 Oliver Lemke * arts-2-1-198 * controlfiles/artscomponents/clearsky/TestClearSky.arts: Compare to reference calculation. * controlfiles/artscomponents/clearsky/yREFERENCE_{1,2,3}D.xml: Add reference values for y. 2012-07-27 Oliver Lemke * arts-2-1-197 * src/abs_species_tags.cc (SpeciesTag::SpeciesTag): Fix parsing bug. 2012-07-26 Oliver Lemke * arts-2-1-196 * src/methods.cc: Change lat_true/lon_true to lat_grid/lon_grid for WSM FieldFromGriddedField. * src/m_atmosphere.cc: (FieldFromGriddedField): Take cases into account where lon_grid.nelem()==0 || (lon_grid.nelem()==0 && lat_grid.nelem()==0). The gridded field should then have exactly size 1 in those dimensions. (FieldFromGriddedFieldCheckLatLonHelper): Added. * src/check_input.cc (chk_size): Use singular in error message for VectorView. 2012-07-26 Oliver Lemke * arts-2-1-195 * src/m_atmosphere.cc (GriddedFieldPRegrid): Turn off 0 boundary condition for zeropadding. Fix bug in condition for selection of interpolation loop. 2012-07-25 Oliver Lemke * arts-2-1-194 * check_input.{h,cc}: (chk_interpolation_grids_loose), (chk_interpolation_grids_loose_no_data_check): No extrapolation for zeropadded case. * src/m_atmosphere.cc (GriddedFieldPRegridHelper,GriddedFieldPRegrid): Fix grid length off-by-one bug. 2012-07-25 Oliver Lemke * arts-2-1-193 * src/abs_species_tags.{cc,h} (SpeciesTag): Add Zeeman flag. To turn on Zeeman calculation for a species, "-Z" can be appended to it's name: "O2-Z" or "O2-Z-66". (SpeciesTag::Name): Add Z to name if Zeeman is true. * src/methods.cc: Update doc for SpeciesSet. 2012-07-24 Patrick Eriksson * arts-2-1-192 * src/special_interp.cc (rte_pos2gridpos): Added checks removed below. * src/m_atmosphere.cc (InterpAtmFieldToRtePos): Removed checks of interpolation grids. * This fixes a bug identified by Jana. 2012-07-24 Jana Mendrok * arts-2-1-191 * src/m_abs.cc: - Renamed abs_linesReadFromHitran -> abs_linesReadFromHitranPre2004, abs_linesReadFromHitran2004 -> abs_linesReadFromHitran - (abs_speciesDefineAllInScenario): Allow file extensions [.xml,.xml.gz,.gz]. Search also in include paths. * src/m_atmosphere.cc: - Renamed p_gridFromAtmRaw -> p_gridFromZRaw (as z_field_raw is the actual data p_grid is expected to be taken from). Bugfixed (extract correct extend) and made robust (also allow z_field_raw with decreasing z values). open issue: why are levels with z<0 removed, is that necessary for any module of ARTS? * src/methods.cc: Updated/corrected according to above. * src/workspace.cc: spell fixes reciever->receiver. * doc/uguide/gridded_field_gridnames.txt: some additions. 2012-07-24 Oliver Lemke * arts-2-1-190 * src/lin_alg.{cc,h} (matrix_exp): Add default value 10 for q. Add special case for n == 1. 2012-07-24 Oliver Lemke * arts-2-1-189 * src/check_input.{cc,h} (chk_interpolation_grids): Add bool flag to indicate that this interpolation is in log space. In case of error, also output the original non-log values for user-friendliness. (chk_interpolation_pgrids): Pass true for log flag to chk_i_g. 2012-07-24 Oliver Lemke * arts-2-1-188 * src/m_atmosphere.cc (GriddedFieldLatLonExpand,GriddedFieldPRegrid, GriddedFieldLatLonRegrid), src/methods.cc: Handle situation correctly if gfraw_in and gfraw_out are the same variable. 2012-07-20 Patrick Eriksson * arts-2-1-187 * src/m_surface.cc (surfaceLambertianSimple): Can now only be used for 1D. Anyhow quite strange for 2D and 3D. And not obvious how to consider surface topography for 3D. (This finishes this revision of the surface part.) 2012-07-18 Patrick Eriksson * arts-2-1-186 * src/m_surface.cc (surfaceFlatRefractiveIndex) (surfaceFlatReflectivity, surfaceFlatScalarReflectivity): Added some input variables, needed to call extended version of surface_specular_los. * src/surface.cc (surface_specular_los): Now consider surface topography in calculation of specular direction. * src/m_surface.cc (iySurfaceRtpropAgenda): Removed everything connected to calculation of surface normal. 2012-07-18 Oliver Lemke * arts-2-1-185 * src/math_funcs.{cc,h}, src/matpackI.{cc,h} (cross3): Promote cross3 to matpackI as it is quite general. Adapt argument types to fit with the other functions. 2012-07-18 Oliver Lemke * arts-2-1-184 * src/methods_aux.cc, src/methods.h (MdRecord): msuppress_header -> muses_templates SupressHeader() -> UsesTemplates() (MdRecord::MdRecord): Throw runtime_error if supergeneric methods use type "Any" but muses_templates is set to false. * src/make_auto_md_h.cc (write_method_header): mdd.SuppressHeader() -> mdd.UsesTemplates() * src/methods.cc: SUPPRESSHEADER > USES_TEMPLATES (define_md_data_raw): Remove unnecessary arguments from methods that use the defaults anyway such as SETMETHOD(false), AGENDAMETHOD(false), USES_TEMPLATES(false) 2012-07-17 Richard Larsson * arts-2-1-183 * src/matpackIII.{h,cc} (mult): Elementwise vector multiplied with Matrix to create Tensor 3. Useful, e.g., for frequency gridded absorption vector multiplied by normalized Stokes extinction matrix to get extinction matrix as a function of frequency. 2012-07-16 Patrick Eriksson * arts-2-1-182 * src/m_surface.cc (iySurfaceRtpropAgenda): Some further work on including surface tilt in calculation of specular direction. The code has still no practical impact. * src/math_funcs.cc (cross3): Renamed the function also in header text. * src/ppath.cc (do_gridcell_3d): Now using LACC for comparison between l and ltan. This solved a case that failed. The problem was linked to the fact that the tangent point was exactly on top of a lat/lon crossing. This change fixed it. 2012-07-12 Oliver Lemke * arts-2-1-181 * absorption.cc: Add quantas to output operator of LineRecord. Make the output operator of LineshapeSpec a bit more useful. * src/math_funcs.{cc,h}: Rename cross to cross3 because it's limited to Vectors with 3 elements. 2012-07-12 Oliver Lemke * arts-2-1-180 * src/methods.cc: Add WSM documentation to GriddedFieldLatLonExpand, GriddedFieldPRegrid and GriddedFieldLatLonRegrid. * src/m_atmosphere.cc (GriddedFieldPRegridHelper): Add missing parameters to doxygen docs. 2012-07-12 Oliver Lemke * arts-2-1-179 * src/m_atmosphere.cc (GriddedFieldLatLonExpand): Implement for GriddedField2, GriddedField3, GriddedField4 and ArrayOfGriddedField3. 2012-07-12 Oliver Lemke * arts-2-1-178 * src/m_atmosphere.cc (FieldFromGriddedField): Implement for GriddedField2->Matrix, GriddedField3->Tensor3, GriddedField4->Tensor4 and ArrayOfGriddedField3->Tensor4. 2012-07-12 Oliver Lemke * arts-2-1-177 * src/methods.cc, src/m_atmosphere.cc: No GriddedFieldPRegrid for GriddedField2, of course... * src/m_atmosphere.cc: Implement GriddedFieldPGrid for GriddedField4 and ArrayOfGriddedField3. (GriddedFieldLatLonRegrid): Fix typo bug in implementation for GriddedField4. Simplify the implementation for ArrayOfGriddedField3. 2012-07-11 Oliver Lemke * arts-2-1-176 * src/check_input.{cc,h}: Add chk_interpolation_pgrids* functions for pressure grids. When p2gridpos_poly is used for log conversion, the prior checks have to be done in log scale, too. (chk_interpolation_grids_loose): Split into two functions: chk_interpolation_grids_loose_no_data_check and chk_interpolation_grids_loose_check_data. * interpolation_poly.cc (gridpos_poly_longitudinal): Change boundary checks to include outer points of new_grid. * src/m_atmosphere.cc: (GriddedFieldPRegridHelper, GriddedFieldPRegrid): Add support for zeropadding. (AtmFieldsCalc): Use chk_interpolation_pgrids for pressure grids. 2012-07-10 Patrick Eriksson * arts-2-1-175 * src/rte.cc (los3d): New. (vectorfield2los): New. (None tested practically) 2012-07-10 Oliver Lemke * arts-2-1-174 * src/m_atmosphere.cc: Add GriddedFieldPRegridHelper for pressure grid interpolations. Implement GriddedFieldPRegrid for GriddedField3. Implement GriddedFieldLatLonRegrid for ArrayOfGriddedField3. * CMakeLists.txt: Add GCC_WARN_SHADOW and CLANG_WARN_SUSPICIOUS_IMPLICIT_CONVERSION flags for Xcode. 2012-07-09 Oliver Lemke * arts-2-1-173 * src/m_atmosphere.cc: (GriddedFieldLatLonRegridHelper): Add common function for calculation of gp_lat, gp_lon and interpolation weights shared among all GriddedFieldLatLonRegrid functions. (GriddedFieldLatLonRegrid): Add overloaded versions for GriddedField2 and GriddedField4. Use new helper for GriddedField3 version. 2012-07-09 Oliver Lemke * arts-2-1-172 * CMakeLists.txt: Always set Wno-unknown-pragmas. 2012-07-09 Oliver Lemke * arts-2-1-171 * src/interpolation_poly.{cc,h}: Add gridpos_poly_longitudinal and gridpos_poly_cyclic_longitudinal for longitude interpolation with support for shifting the original grid by +360 / -360 if necessary and cyclic interpolation for global grids. * src/m_atmosphere.cc (GriddedFieldLatLonRegrid): Use gridpos_poly_longitudinal. * CMakeLists.txt: Set Xcode compiler flags via attribute. Remove unnecessary mark_as_advanced. 2012-07-05 Oliver Lemke * arts-2-1-170 * src/absorption.{cc,h}: Fix comments. 2012-07-05 Oliver Lemke * arts-2-1-169 * src/absorption.{cc,h}: Store lower/upper state global/local quanta in LineRecord. (LineRecord::ReadFromHitran2004Stream): Store the quantas. 2012-07-05 Oliver Lemke * arts-2-1-168 * CMakeLists.txt, README: Add option WITH_XCODE_LIBCPP to enable C++11 and libc++ in Xcode. Use dwarf-with-dsym debug format in Xcode to get the static libraries properly symbolized for debugging. 2012-07-03 Oliver Lemke * arts-2-1-167 * doc/doxygen/CMakeLists.txt: Rebuild of the documentation was not triggered after source changes. Add dependencies to all source files. Remove target apidoc_forced. Remove latex related code because we don't build it anyway. * doc/doxygen/Doxyfile.in: Update config file to doxygen 1.7. Add MARKDOWN_SUPPORT=NO. On doxygen 1.8, the tags on the mainpage are not substituted properly. Currently commented out because it generates a warning on earlier doxygen versions. 2012-07-02 Oliver Lemke * arts-2-1-166 * ChangeLog: Cleanup. Remove arts-2-1-162 attributed to me (but not done by me) which was a duplicate entry of arts-2-1-164. Restore version number arts-2-1-162 of Patrick's last commit which was falsely changed to arts-2-1-163. Restore the commit date for arts-2-1-161 to 2012-06-24. Add a dummy entry for the now non-existent arts-2-1-163 to get the version numbering back in line. 2012-07-01 Jana Mendrok * arts-2-1-165 * src/check_input.h (chk_atm_field): Corrected default value of chk_lat90 flag (of course, as default we DO want to check consistency at poles!). 2012-06-30 Jana Mendrok * arts-2-1-164 * src/check_input.[cc,h] (chk_atm_field): Added flag to switch off no-variation-with-longitude- at-poles check (cause this requirement does not apply for fields that are part of a vector fields with N&E components). (chk_atm_vecfield_lat90): Added. Does no-variation-with-longitude- at-poles check for total vector length of fields with N&E components. Allows some deviation (1e-2%) to avoid numerics causing a failed check. * src/m_atmosphere.cc (basics_checkedCalc): Adapted atm_field checks for wind and magnetic field fields to above changes. 2012-07-02 Oliver Lemke * arts-2-1-163 * Bump. 2012-06-29 Patrick Eriksson * arts-2-1-162 * controlfiles/artscomponents/clearsky/TestClearSky.arts: A complete test designed. The "compare" calls not activated as radiances will change when surface tilt will be considered in surface part. * src/ppath.cc (do_gridcell_2d,do_gridcell_3d): For surface crossing part, changed to lt * arts-2-1-161 * src/agenda_class.cc (Agenda::check): Delay check for custom-defined agendas. (Agenda::execute): Adapt runtime error message if the user tries to execute an agenda that was created by AgendaCreate. * methods.cc (define_md_data_raw): Set PASSWSVNAMES to true for Copy. * src/m_copy.cc (Copy): When copying an agenda set the name of the output agenda to its variable name. * ChangeLog: Reconstruct missing entry for arts-2-1-160 from svn log. 2012-06-28 Jana Mendrok * arts-2-1-160 * src/m_surface.cc (complex_nFromGriddedField4): More checks (GF grid names, requested lat/lon covered), use grid position indices, shift field.lon by +/-360deg if requested lon is off. * src/geodetic.[cc,h] (lon_shiftgrid): Added function for shifting longitude grid to cover the 'space' of a given longitude (providing a fix to the issue that lon and lon+360 refer to same meridian, but both can occur as valid values in ARTS) * controlfiles/artscomponents/surface/complex_n_field.xml: Adapted to changed requirements on grid names. 2012-06-28 Patrick Eriksson * arts-2-1-159 * controlfiles/artscomponents/clearsky/TestClearSky.arts: Started to reformulate this test. Before it did a bit of everything, including some jacobians and absorption lookup table. The aim now is to make a basic general test of yCalc for for 1D, 2D and 3D. Work in progress. * controlfiles/artscomponents/pencilbeam/TestPencilBeam.arts: Extended the header text somewhat, to better express the aim of the cfile. * controlfiles/artscomponents/surface/TestSurface.arts: Adopted to cnew input of iySurfaceRtpropAgenda. * src/m_surface.cc (iySurfaceRtpropAgenda): Started to implement calculation of surface normal. Had re-introduce some input arguments. * src/ppath.cc (plevel_slope_2d): Calculation of upward argument for gridpos2gridrange was incorrect. Always generated true! However, this could in fact have been an OK definition. So nothing was terribly wrong. 2012-06-27 Jana Mendrok * arts-2-1-158 * src/m_surface.cc (complex_nFromGriddedField4): misspelling corrected. 2012-06-27 Jana Mendrok * arts-2-1-157 * doc/uguide/gridded_field_gridnames.txt: Added Complex. 2012-06-27 Patrick Eriksson * arts-2-1-156 * src/m_montecarlo.cc (MCGeneral): A bug originating from when I added f_grid as input to iy_space_agenda. Did happen only if f_grid.nelem() > 1. Catched by an assert, so no risk that you have done incorrect calculations. 2012-06-27 Oliver Lemke * arts-2-1-155 * src/m_atmosphere.cc: (GriddedFieldLatLonRegrid): First try for GriddedField3. (AtmFieldsCalc): Fix bug in 2D and 3D interpolation. ^ is not power. 2012-06-27 Oliver Lemke * arts-2-1-154 * src/methods.cc, src/m_atmosphere.cc: GriddedFieldLatLonPRegrid -> GriddedFieldPRegrid 2012-06-27 Oliver Lemke * arts-2-1-153 * src/methods.cc, src/m_atmosphere.cc: Add skeleton FieldFromGriddedField, GriddedFieldLatLonExpand, GriddedFieldLatLonPRegrid, GriddedFieldLatLonRegrid. 2012-06-26 Oliver Lemke * arts-2-1-152 * cmake/modules/ArtsTestcases.cmake, src/CMakeLists.txt: Remove the _CACHE from version check. Otherwise fix from arts-2-1-135 requires a second cmake run to work. Add arts_test_cmdline macro for commandline option tests. * CMakeLists.txt: Some Xcode fixes: Set CMAKE_OSX_SYSROOT to empty so we don't have to manually reset the current SDK every time the project is regenerated. Set LIBRARY_OUTPUT_PATH and EXECUTABLE_OUTPUT_PATH to have all executables end up in the same build directory. 2012-06-26 Jana Mendrok * arts-2-1-151 * controlfiles/general/general.arts: initialize mag_[u,v,w]_field. 2012-06-26 Jana Mendrok * arts-2-1-150 * src/workspace.cc: Introduced magnetic field components (mag_[u,v,w]_field). * src/m_atmosphere.cc, src/methods.cc (basics_checkedCalc): Added mag_[u,v,w]_field to checks. 2012-06-26 Oliver Lemke * arts-2-1-149 * doc/uguide/gridded_field_gridnames.txt: Add file with grid naming conventions. * doc/uguide/concept.tex: Add section Data formats with subsections XML files, NetCDF files and Gridded fields. Include the grid naming conventions here. * doc/uguide/CMakeLists.txt: Add dependency on g_f_gn.txt. 2012-06-26 Oliver Lemke * arts-2-1-148 * ChangeLog: Too many typos in previous log message to let it slide. 2012-06-26 Oliver Lemke * arts-2-1-147 * src/make_auto_md_h.cc: Temporary fix for automatic header generation for supergeneric methods with explicit type. Proper fix is to get rid of the SUPPRESSHEADER macro in methods.cc completely and automatically determine which headers to generate. Will implement this as soon as time permits. 2012-06-26 Oliver Lemke * arts-2-1-146 * src/check_input.cc (chk_griddedfield_gridname): Add check to verify the name of a grid in a GriddedField. 2012-06-25 Patrick Eriksson * arts-2-1-145 * This commit finishes what I plan regarding inputting and restructuring around surface RT-properties. (To fix handling of surface topography remains. That is, surface roughness can be incorporated, but overall angular tilt of the surface is not considered.) * controlfiles/artscomponents/surface/create_gfields.m: Data for test below had incorrect dimensions. * controlfiles/artscomponents/surface/TestSurface.arts: Now includes test of WSM below. * src/m_surface.cc (surface_reflectivityFromGriddedField6): New WSM. * src/xml_io_instantiation.h: * src/xml_io_types.h: * src/groups.cc (define_wsv_group_names): Added definition for GriddedField5/6 and ArrayOfGriddedField2. 2012-06-25 Patrick Eriksson * arts-2-1-144 * controlfiles/artscomponents/surface/create_gfields.m: Created. Generates test data for TestSurface.arts. * controlfiles/artscomponents/surface/TestSurface.arts: Extended to cover more cases, including the new WSM below. * src/m_surface.cc (complex_nFromGriddedField4): Created. 2012-06-25 Oliver Lemke * arts-2-1-143 * src/CMakeLists.txt: Better fix for arts-2-1-142. Help some linkers to properly resolve dependencies between the static libs by adding agenda_record.cc to the methods library. * src/agenda_class.cc: Revert workaround from arts-2-1-142. * src/file.cc (find_file): If search paths are empty, at least check if the file exists before failing... Fixes test_binaryio testcase. 2012-06-25 Oliver Lemke * arts-2-1-142 * src/agenda_class.cc: Add temporary workaround to (hopefully) fix crazy linker errors in test_binaryio and friends on Ubuntu. 2012-06-25 Oliver Lemke * arts-2-1-141 * src/agenda_class.cc, src/m_general.cc: Fix Print for agendas. Was outputting the whole documentation for each used WSM instead of just their names. Also fix indentation of output. 2012-06-24 Oliver Lemke * arts-2-1-140 * src/gridded_fields.{cc,h} Add GriddedField5+6 and ArrayOfArrayOfGriddedField2. * src/xml_io_compound_types.cc: Add GriddedField5+6. * src/xml_io_array_types.cc: Add ArrayOfArrayOfGriddedField2. 2012-06-24 Patrick Eriksson * arts-2-1-139 * Further work on the surface. emission_agenda renamed to blackbody_radiation_agenda. Sufrace methods now use this agenda. This means that clearsky calculations now really work with the emission source term set to T (instead of B), or alternative version of Planck. (Standard Planck still hard-coded inside DOIT and MC). * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/instruments/mhs/mhs.arts: * controlfiles/instruments/mhs/mhs_fast.arts: * controlfiles/instruments/amsu/amsub.arts: * controlfiles/instruments/amsu/amsub_fast.arts: Call of surfaceFlatScalarReflectivity adopted (by removing all arguments, not needed as standard WSVs are used). * controlfiles/CMakeLists.txt: Added surface test. Moved absorption to top as most basic test (among Components). * controlfiles/artscomponents/surface/TestSurface.arts: New. (Testing without any real atmospheric RT calculations!) * src/workspace.cc: Fixed typo for complex_n. * src/m_surface.cc (iySurfaceRtpropAgenda): Added check that iy for down-welling radiation has correct size. * src/m_surface.cc (surfaceBlackbody, surfaceFlatRefractiveIndex, surfaceFlatReflectivity, surfaceFlatScalarReflectivity, surfaceLambertianSimple): * src/surface.cc (surface_specular_R_and_b): Now using blackbody_radiation_agenda. * controlfiles/instruments/odinsmr/TestOdinSMR_119ghz.arts: * src/m_physics.cc (blackbody_radiationPlanck): * src/m_fos.cc: * src/m_rte.cc: * src/rte.cc: * src/methods.cc: Adopted to changes below. * src/agendas.cc: emission_agenda renamed to blackbody_radiation_agenda. * src/workspace.cc: emission renamed to blackbody_radiation. 2012-06-24 Patrick Eriksson * arts-2-1-138 * src/m_rte.cc: Adopted call of get_iy_of_background inside several methods. * src/rte.cc (get_iy_of_background): Now using iy_surface_agenda, instead of surface_rtprop_agenda. 2012-06-24 Patrick Eriksson * arts-2-1-137 * controlfiles/general/general.arts: Now includes a definition of iy_surface_agenda. * src/agendas.cc: Several input WSVs were missing, to handle perturbation jacobians. * src/m_surface.cc (iySurfaceRtpropAgenda): Completed. 2012-06-23 Patrick Eriksson * arts-2-1-136 * Backup commit for work in progress (but checks run OK). * src/m_surface.cc (iyFromSurfaceRtpropAgenda): Created (but not tested or active). * src/agendas.cc: Added iy_surface_agenda. * src/interpolation.cc (is_gridpos_at_index_i): Added the strict argument. * src/ppath.cc: Adopted call of chk_rte_pos * src/ppath.cc (ppath_start_stepping): Code replaced by rte_pos2gridpos. * src/m_ppath.cc: Adopted call of chk_rte_pos * src/m_ppath.cc (ppathFromRtePos2): Code replaced by rte_pos2gridpos. * src/check_input.cc (chk_rte_pos): Converted is_rte_pos2 to bool and set false to default. * src/special_interp.cc (interp_gfield3): Removed. Not used. And used special definitions. In addition, should have been implemented as a class function. (rte_pos2gridpos): Created. * src/interpolation.cc (gridpos_1to1): Created. * src/m_doit.cc (iyInterpCloudboxField): (iyInterpCloudboxPolyField): Adopted to removal of rte_gp_p/lat/lon. * controlfiles/instruments/odinsmr/TestOdinSMR_119ghz.arts: * controlfiles/instruments/mhs/mhs.arts: * controlfiles/instruments/hirs/TestHIRS.arts: * controlfiles/instruments/amsu/amsub.arts: * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/artscomponents/doit/TestDOIT.arts: * controlfiles/general/general.arts: Adopted to changes below. * src/m_surface.cc (InterpSurfaceFieldToRteGps): Removed. (InterpSurfaceFieldToRtePos): New method. * src/m_atmosphere.cc (InterpAtmFieldToRteGps): Removed. (InterpAtmFieldToRtePos): New method. * src/doit.cc: * src/m_jacobian.cc: * src/m_doit.cc: * src/m_montecarlo.cc: * src/m_rte.cc: * src/rte.cc: * src/methods.cc: * src/workspace.cc: * src/agendas.cc: surface_prop_agenda renamed to surface_rtprop_agenda. And rte_gp_p, rte_gp_lat and rte_gp_lon removed as input. The later also done for iy_cloudbox_agenda. * src/workspace.cc: Removed rte_gp_p, rte_gp_lat and rte_gp_lon. 2012-06-22 Oliver Lemke * arts-2-1-135 * cmake/modules/ArtsTestcases.cmake: Add fix for compatibility with cmake 2.6.4. Test dependency declaration failed. 2012-06-21 Patrick Eriksson * arts-2-1-134 * src/workspace.cc: Added that lon_grid can max span 360 deg. 2012-06-21 Patrick Eriksson * arts-2-1-133 * src/m_atmosphere.cc (z_fieldFromHSE): Improved a comment. 2012-06-21 Patrick Eriksson * arts-2-1-132 * src/m_surface.cc (surface_scalar_reflectivityFromGriddedField4): Almost complet version (not tested practically). * src/m_atmosphere.cc (z_fieldFromHSE): Modified, adopted to pos2true_latlon. * src/rte.cc (pos2true_latlon): Created. * src/workspace.cc: Tried to improve description of refellipsoid, lat_true and lon_true. * src/check_input.cc (chk_latlon_true): Check for lon_true and 2D was incorrect. Now just perform checking (output arguments removed). 2012-06-18 Oliver Lemke * arts-2-1-131 * src/methods.cc Add generic input 'dimension' to append functions. Passing in 'leading' means to append to the leftmost dimension (e.g. rows for Matrix), 'trailing' to the rightmost (==cols). Add support to append single elements to arrays. Add support for Matrix. * src/groups.cc, src/wsv_aux.h (get_array_groups_as_string): Extend to return only Arrays whose basetype is a group and to return names of the basetypes of arrays only. * src/m_append.h: Implement append for Matrix. 2012-06-20 Oliver Lemke * arts-2-1-130 * src/gridded_fields.h: Add checksize_strict member function that throws a runtime error with additional information on the grid and data sizes. Make checksize pure virtual in abstract base class. Remove redundant function documentation from subclasses. Doxygen automatically uses the docs from the base class. * src/gridded_fields.{cc,h}: Fix copyright header. Formatting. * src/xml_io_compound_types.cc (xml_read_from_stream): Use checksize_strict for GriddedFields. 2012-06-19 Patrick Eriksson * arts-2-1-129 * src/m_surface.cc (InterpSurfaceEmissivityFieldIncLatLon): Removed. (surface_scalar_reflectivityFromGriddedField4): Just a start ... * src/m_surface.cc: Removed .h-files and "extern const" not used. 2012-06-18 Patrick Eriksson * arts-2-1-128 * A first step in revising the surface RT properties part. Main change here is that methods taking emissivity as input are removed. * src/m_surface.cc (surfaceFlatReflectivity): Old method renamed, see below. This version ghanldes a general reflectivity matrix. Not yet tested practically. * controlfiles/artscomponents/doitbatch/TestDOITBatch.arts: * controlfiles/instruments/amsu/amsub.arts: * controlfiles/instruments/amsu/amsub_fast.arts: * controlfiles/instruments/mhs/mhs.arts: * controlfiles/instruments/mhs/mhs_fast.arts: Replaced surfaceFlatReflectivity with surfaceFlatScalarReflectivity. * src/m_surface.cc (surfaceFlatScalarReflectivity): Renamed surfaceFlatReflectivity. Now only stokes_dim = 1 accepted. (surfaceFlatSingleEmissivity): (surfaceFlatVaryingEmissivity): Both removed. Use instead surfaceFlatScalarReflectivity. * src/workspace.cc (define_wsv_data): Added surface_reflectivity. Changed text for complex_n, to always demand two columns. Some polishing of text for core surface RT variables. 2012-06-14 Oliver Lemke * arts-2-1-127 * src/parameters.cc: Fix baseurl parameter. 2012-06-14 Oliver Lemke * arts-2-1-126 * src/xml_io_compound_types.cc: Reading of GriddedField2 was broken. 2012-06-13 Oliver Lemke * arts-2-1-125 * src/messages.h: Remove ; from the end of the CREATE_OUT* macros. This forces a ; to be added when the macro is used to make it look like a statement (which it is). Also fixes automatic indentation in some editors that get confused if a statement doesn't end with a semicolon. * src/*.{cc,h}: Add semicolons to CREATE_OUT* calls. * src/agenda_{class,record}.{cc,h}: Reindent. * src/arts.cc (arts_exit_with_error_message): Remove extra block. 2012-06-01 Patrick Eriksson * arts-2-1-124 * src/ppath.cc (rslope_crossing3d): The function now allows that both c1 and c2 to be zero. 2012-06-01 Oliver Lemke * arts-2-1-123 * src/parameters.{cc,h}: Add outdir parameter and commandline option -o/--outdir. Change commandline argument -B to -U. * src/file.{cc,h}: Add add_basedir function. (open_output_file): Catch file exceptions and rethrow as runtime_error with additional info about the filename. * src/main.cc: No need to catch ios_base exception anymore. Handled in open_output_file now. * src/xml_io.cc, src/nc_io.cc: Use add_basedir in writing functions. * src/arts.cc (arts_exit): Use add_basedir for report file path. 2012-05-30 Patrick Eriksson * arts-2-1-122 * doc/uguide/ppath_theory.tex: Updated. Now treating the new 3D scheme (old scheme commented out). 2012-05-29 Patrick Eriksson * arts-2-1-121 * src/ppath.cc: New 3D code now made active. Now yet fully tested for non-spherical conditions (but no known loophole as for old scheme). Tell me if you run into some problems. * src/ppath.cc (ppath_step_refr_3d): Finally managed to track down another bug. Again a stupid typo. r16a and and r16b were written as r15a and r15b. 2012-05-29 Patrick Eriksson * arts-2-1-120 * src/ppath.cc (do_gridcell_3d): Fixed a typo. Had written lat in one function call where it should have been lon. 2012-05-28 Patrick Eriksson * arts-2-1-119 * doc/uguide/ppath_theory.tex: Fixed some typos, and updated to recent changes for refraction. * src/ppath.cc (plevel_crossing_2d): Zenith and nadir cases handled completly seperately (more effecient and more clear code). (plevel_crossing_3d): Changed to mimic 2D version as far as possible. * controlfiles/artscomponents/ppath/TestPpath3D.arts: Last part of test reactivated. Changes below fixed the bug. * src/ppath.cc (raytrace_3d_linear_basic): Handling of out-of-bounds za and aa angles was not correct. Now using adjust_los for this task. * src/rte.h: Added adjust_los. * src/rte.cc (adjust_los): Typo in header text. 2012-05-24 Oliver Lemke * arts-2-1-118 * src/*, doc/uguide/arts*.tex: Update copyright year. 2012-05-24 Oliver Lemke * arts-2-1-117 * src/docserver.* src/nc_io*, src/xml_io*: Reindent. Align & and * with type instead of variable. 2012-05-23 Oliver Lemke * arts-2-1-116 * CMakeLists.txt: Handle compiler options more gracefully. Instead of hardcoding them for different compilers, check if the current compiler supports the flag. If not, just ignore it. Set and check flags separately for C and C++ compiler. For Xcode project, pass active configuration name to ctest so it can select the correct executable. * cmake/modules/ArtsAddCompilerFlag.cmake: Added. * src/libmicrohttpd/CMakeLists.txt, src/CMakeLists.txt: Little tweak for clang. 2012-05-18 Oliver Lemke * arts-2-1-115 * src/gas_abs_lookup.h, src/nc_io_compound_types.cc, src/m_abs.cc, src/nc_io_types.h, src/nc_io.h, src/nc_io_basic_types.cc, src/m_nc.h, src/nc_io_instantiation.h, src/nc_io_array_types.cc, src/nc_io.cc: Change prefix of arts netcdf related functions from nc_ to nca_ to avoid confusion with functions from the netcdf library. * src/nc_io.{cc,h}: Add more helper functions. Add docs. * src/nc_io_compound_types.cc (nca_write_to_file): Clean up GasAbsLookup function. * doc/doxygen/Doxyfile.in: Add ENABLE_NETCDF to PREDEFINED macros. 2012-05-16 Patrick Eriksson * arts-2-1-114 * src/poly_roots.cc (gsl_poly_complex_solve): Removed screen message when bad convergence. This should be handled by calling function. Message left for the other (basic) errors. * src/ppath.cc (rslope_crossing2d): Increased standard n value to 6. The function now adopts to poor poly_root-convergence. If this happens, n is decreased until convergence is achieved. * src/ppath.cc (do_gridcell_2d): Before did not check upper pressure level if a hit with the surface had been found, to save time. Found not OK with high surface radial slope. Fixed. (plevel_crossing_2d): Removed assert at end, that checked consistency with geompath. Why compare to a poorer calculation? 2012-05-16 Oliver Lemke * arts-2-1-113 * src/nc_io.cc (nc_read_from_file, nc_write_to_file): Add a try-catch-block to the template functions around the actual type-specific read/write function call. Catch exceptions, add current filename and re-throw. * src/nc_io_compound_types.cc (nc_read_from_file): Throw runtime_error if no species are found in the GasAbsLookup input file. (nc_write_to_file): Throw runtime_error no species are in the current GasAbsLookup table. * src/gas_abs_lookup.h, src/nc_io_compound_types.cc, src/nc_io_types.h, src/nc_io_basic_types.cc, src/nc_io_array_types.cc, src/nc_io.cc: Add Verbosity argument to nc_read_from_file and nc_write_to_file. 2012-05-16 Oliver Lemke * arts-2-1-112 * src/nc_io_compound_types.cc: Add NetCDF reading/writing for GasAbsLookup. * src/methods.cc: Add GasAbsLookup to Read/WriteNetCDF. * src/gas_abs_lookup.h: Some love for abs_lookup by adding friends. * src/nc_io.{cc,h}: Add helper functions. 2012-05-14 Patrick Eriksson * arts-2-1-111 * src/check_input.cc (chk_atm_surface): Checks for 3D cases covering North and South pole were missing. Added. * src/ppath.cc (plevel_crossing_2d): Output l was not calculated correctly if the level crossing is on other side of a tangent point. This seems not to happen inside the atmosphere, but can happen with a highly tilted surface. So this bug appeared only if the tangent point is just above a surface with high radial slope. Accordingly, showed up first after +300k of test cases! 2012-05-11 Patrick Eriksson * arts-2-1-110 * src/ppath.cc (rslope_crossing2d): Changed dza from 10 to 15 deg as limit for when going down from n=5 to n=4. Found one case of bad convergence for dza=10.7 (after running about 80000 cases). 2012-05-08 Oliver Lemke * arts-2-1-109 * controlfiles/CMakeLists.txt: Install controlfiles/ into CMAKE_INSTALL_PREFIX/share/arts/ * CMakeLists.txt: Remove tests/ from subdirectories. 2012-05-08 Patrick Eriksson * arts-2-1-108 * src/ppath.cc (do_gridcell_3d): Had commited with new test 3D code active. 2012-05-06 Patrick Eriksson * arts-2-1-107 * src/ppath.cc (rslope_crossing2d): Now n=5 default (with both terms included), and no special treatment of za=90 needed. Now going down to n=1 for za [89.9,90]. 2012-05-01 Patrick Eriksson * arts-2-1-106 * src/ppath.cc (rslope_crossing2d): Setting of dmin adjusted. Added comments to document the selection of some settings. (plevel_crossing_2d): Changed back to set r as rpl+cpl*dlat. Bad decision to change. Further tests showed that the numerical problems were on the other side, in geompath. 2012-04-28 Patrick Eriksson * arts-2-1-105 * controlfiles/artscomponents/ppath/TestPpath3D.arts: * controlfiles/artscomponents/ppath/TestPpath2D.arts: Added several pos/los combinations, particularly for testing ray tracing along lat and lon grid positions. Also, now run with both spherical and non-spherical ellipsoid. 3D non-spherical ellipsoid + refraction not active as it fails! * controlfiles/artscomponents/ppath/TestPpath1D.arts: Added a nadir from space case. * src/ppath.cc (ppath_init_structure): Start pos and los set to -999, to more clearly indicate non-valid data. (rslope_crossing2d): Now the polynomial degree is selected according to the zenith angle, to avoid (different) numerical problems around 0, 90 and 180. 2012-04-27 Patrick Eriksson * arts-2-1-104 * doc/uguide/ppath_theory.tex: Updated with respect to change in rslope_crossing2d (now three terms in Taylor expansion of cos and sin). 2012-04-26 Patrick Eriksson * arts-2-1-103 * doc/uguide/atmosphere.tex: Some typos fixed. * doc/uguide/surface.tex: Part on geodetic latitude shortened. Spell-checking. * doc/uguide/ppath.tex (section{The propagation path data structure}): Updated with ngroup, start_lstep and end_lstep. * src/ppath.cc (rslope_crossing3d): Now using 2D version if c2=0. Required by poly_root_solve. * src/ppath.cc (rslope_crossing2d): Taylor expansion of cos and sin now includes also the third term. Was found to improve the accuracy significantly with non-spherical ellipsoid. (plevel_crossing_2d): New r now calculated by geompath function, instead as r+c*dlat. This looks the path to ppc, which improves the accuracy. 2012-04-24 Patrick Eriksson * arts-2-1-102 * src/ppath.cc (rslope_crossing3d): New function. (plevel_crossing_3d): Now using rslope_crossing3d. * src/rte.cc (get_iy_of_background): Adopted to changes below. * src/ppath.cc: Changes in several functions to adopt to the changes below. (plevel_slope_2d): Converted c1 from return to out parameter. (plevel_slope_3d): Now fitting local radius as a second order polynomial. Results now returned by reference. 2012-04-24 Patrick Eriksson * arts-2-1-101 * src/ppath.cc: Introduced the terms r0s etc. to avoid repeating calculations. 2012-04-23 Patrick Eriksson * arts-2-1-100 * src/ppath.cc: Restarted the postponed work to finish the new 3D code. The relevant parts copied back from ppath_NotUsed.arts. Added code to handle zanith&/nadir cases seperately. Some tests. Seems like that accuracy of plevel_crossing_3d must be improved. * src/geodetic.cc (latlon_at_aa): New function. * src/m_cloudbox.cc (cloudbox_checkedCalc): Added missing space in error message. 2012-04-20 Patrick Eriksson * arts-2-1-99 * controlfiles/general/general.src: refr_index_group initiated to 1. * arts/m_rte.cc (iyRadioLink): Extra path delay now calculated with ppath.ngroup (all below to fix this). * src/refraction.cc: * src/m_refraction.cc: * src/ppath.cc: Changes throughout the files to handle refr_index_group. * src/m_ppath.cc (ppathFromRtePos2): * src/m_ppath.cc (ppath_stepRefractionBasic) (VectorZtanToZaRefr1D): Changes associated with refr_index_group. * src/m_general.cc (Print): * src/xml_io_compound_types.cc: Adopted to new Ppath field (again!). * src/ppath.h (struct Ppath): Added ngroup. * src/agendas.cc: refr_index_agenda has now also refr_index_group as output. * src/workspace.cc: Added refr_index_group. 2012-04-18 Patrick Eriksson * arts-2-1-98 * src/m_refraction.cc (refr_indexFreeElectrons): Now including a test with respect to the plasma frequency. And now returning the "proper" refractive index (here a value below 1), corresponding to the phase speed which is required for the ray tracing. How to handle path delays is an open question? 2012-04-17 Patrick Eriksson * arts-2-1-97 * src/m_refraction.cc (refr_indexFreeElectrons): It was just sqrt(...). Corrected to 1/sqrt(...) * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Now finer p_grid and cubic interpolation in AtmFieldsCalc. * src/m_ppath.cc:(ppathFromRtePos2): Azimuth angle now also stored in H. Fine-tuning of settings for surface intersections. * src/refraction.cc: Full WSV of t_field and vmr_field now used inside functions for refraction (for consistency + to handle empty vmr_field). * src/rte.cc (defocusing_sat2sat): Removed a cout. * src/check_input.cc (chk_atm_field): Now also handling the case when the Tensor4 is/shall be empty. * src/m_atmosphere.cc (basics_checkedCalc): Call chk_atm_field even if abs_species is empty. 2012-04-16 Oliver Lemke * arts-2-1-96 * ChangeLog, ChangeLog-archived: Move all pre 2-0-0 entries to ChangeLog-archived. * ChangeLog-20071207: Renamed to ChangeLog-archived. 2012-04-16 Oliver Lemke * arts-2-1-95 * controlfiles/instruments/smr: Moved from includes/smr/. * includes/: Removed. 2012-04-13 Patrick Eriksson * arts-2-1-94 * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Now using iy_variable and iy_aux_variable. * src/m_ppath.cc (TangentPointExtract): New WSM. (TangentPointPrint): Renamed PrintTangentPoint. * src/m_rte.cc (iyRadioLink): Now using iy_variable and iy_aux_variable, instead of removed, corresponding, gin-variables. * src/workspace.cc: Introduced iy_variable and iy_aux_variable. 2012-04-13 Oliver Lemke * arts-2-1-93 * This commit concludes the consolidation of controlfiles and includefiles into the controlfiles/ directory. Only open issue is the includes/smr directory. These files do not seem to be used anywhere. I left them in their original location for now. * src/file.{h,cc} (find_file): Don't go through search paths if filename already contains a full path. * src/xml_io.cc (xml_read_from_file,xml_read_arts_catalogue_from_file): Throw runtime error immediately when we know the file doesn't exist instead of later when trying to actually open it. * src/parameters.cc (get_parameters): Add . to include and data paths. * src/parser.cc (ArtsParser::parse_agenda): When including a file with a path, we have to add the file's path temporarily at the beginning of the include path. This is necessary because the included file can include files from the same directory without specifying further path information. This mimics the behaviour how C/C++ compilers deal with include files. Problem is that we have to permanently add this path also to the data search path because include files can contain ReadXML etc. methods which are only executed later on. Not sure what a clean solution for that would be. #49 * Missed to move two remaining controlfiles from tests/ in previous commit: * controlfiles/instruments/hirs: Moved from tests/HIRS. * controlfiles/instruments/avhrr: Moved from tests/AVHRR. * Moving include files into controlfiles/ sub-directories: * includes/amsu/*: Moved to controlfiles/instruments/amsu/. * controlfiles/instruments/amsu/*.arts: Remove amsu/ prefix for include and data files. * includes/mhs/*: Moved to controlfiles/instruments/mhs/. * controlfiles/instruments/mhs/*.arts: Remove mhs/ prefix for include and data files. * includes/odin/*: Moved to controlfiles/instruments/odinsmr/. * controlfiles/instruments/odinsmr/*.arts: Remove odin/ prefix for include and data files. * includes/hirs/*: Moved to controlfiles/instruments/hirs/. * controlfiles/instruments/hirs/*.arts: Remove hirs/ prefix for include and data files. * includes/avhrr/*: Moved to controlfiles/instruments/avhrr/. * controlfiles/instruments/avhrr/*.arts: Remove hirs/ prefix for include and data files. Change prefix to hirs includes to instruments/hirs/. * controlfiles/instruments/avhrr/TestAVHRR.ybatch.xml: Remove output file. * controlfiles/artscomponents/wfuns/TestWfuns.arts: Change prefix for odin include to instruments/odinsmr/. * include/CMakeLists.txt: Remove subdirs. * CMakeLists.txt: ${CMAKE_SOURCE_DIR}/includes from ARTS_DEFAULT_INCLUDE_DIR. Remove subdirectory includes/. 2012-04-13 Patrick Eriksson * arts-2-1-92 * controlfiles/artscomponents/transmission/TestTransmission.arts: * controlfiles/artscomponents/radiolink/TestRadioLink.arts: Euler -> Basic. * controlfiles/artscomponents/ppath/TestPpath1D.arts: * controlfiles/artscomponents/ppath/TestPpath2D.arts: * controlfiles/artscomponents/ppath/TestPpath3D.arts: As above. And now also making a set of calculations with refraction. * src/methods.cc: Improved text for ppath_stepRefractionBasic. * src/m_ppath.cc (ppath_stepRefractionBasic): Changed Euler to Basic in WSM name. This as "Euler" is not a totally correct description of the algorithm. * src/ppath.cc (ppath_start_stepping): For 3D, "ppath.end_lstep=lt;" was ppath.start_lstep = lt; Changed "euler" to "basic in some function names and variables. 2012-04-13 Oliver Lemke * arts-2-1-91 * Completed moving of testcases from tests/ to controlfiles/. Next up is moving the include files into the appropriate directories in controlfiles/. * controlfiles/artscomponents/wfuns: Moved from tests/Wfuns. * controlfiles/artscomponents/radiolink: Moved from tests/RadioLink. * controlfiles/instruments/amsu: Moved from tests/AMSU. * controlfiles/instruments/mhs: Moved from tests/MHS. * controlfiles/instruments/odinsmr: Moved from tests/OdinSMR. * controlfiles/CMakeLists.txt: Add moved testcases. * tests/CMakeLists.txt: Remove moved testcases. 2012-04-12 Oliver Lemke * arts-2-1-90 * Migrating controlfiles from tests to controlfiles/. Starting with controlfiles related to artscomponents. * CMakeLists.txt: Add subdirectory controlfiles. * tests/CMakeLists.txt: Remove testcases that are now in controlfiles/. * controlfiles/CMakeLists.txt: Added. Add testcase definitions. * controlfiles/artscomponents/absorption: Moved from tests/Abs. * controlfiles/artscomponents/doit: Moved from tests/DOIT. * controlfiles/artscomponents/montecarlo: Moved from tests/MonteCarlo. * controlfiles/artscomponents/ppath: Moved from tests/Ppath. * controlfiles/artscomponents/pencilbeam: Moved from tests/PencilBeam. * controlfiles/artscomponents/clearsky: Moved from tests/ClearSky. * controlfiles/artscomponents/groundbased: Moved from tests/GroundBased. * controlfiles/artscomponents/disort: Moved from tests/DISORT. * controlfiles/artscomponents/doitbatch: Moved from tests/DOITBatch. * controlfiles/artscomponents/transmission: Moved from tests/Transmission. 2012-04-12 Oliver Lemke * arts-2-1-89 * controlfiles/atmosphere_data/: Moved here from tests. We might read those from arts-xml-data directly later. * tests/Transmission/TestTransmission.arts, tests/GroundBased/TestFgrid.arts, tests/GroundBased/TestWinds.arts, tests/GroundBased/TestGbased.arts, tests/PencilBeam/TestPencilBeam.arts, tests/DOIT/TestDOIT.arts, tests/Wfuns/TestWfuns.arts, tests/MonteCarlo/TestMonteCarloDataPrepare.arts, tests/Abs/TestAbsDoppler.arts, tests/Abs/TestAbs.arts, tests/OdinSMR/TestOdinSMR.arts, tests/OdinSMR/TestOdinSMR_119ghz.arts, tests/OdinSMR/TestOdinSMR_1D.arts, tests/Ppath/TestPpath1D.arts, tests/Ppath/TestPpath2D.arts, tests/Ppath/TestPpath3D.arts, tests/RadioLink/TestRadioLink.arts, tests/ClearSky/TestClearSky.arts: Remove ../ prefix from atmosphere_data path. 2012-04-12 Oliver Lemke * arts-2-1-88 * Starting to move and rearrange controlfiles from tests/ to controlfiles. I'll do that in several steps to avoid mayhem. * CMakeLists.txt: Temporarily use includes/ and controlfiles/ as default include path. * controlfiles/general/general.arts, controlfiles/general/continua.arts, controlfiles/general/agendasDOIT.arts: Moved to here from includes/. * controlfiles, controlfiles/artscomponents, controlfiles/general, controlfiles/instruments: Added. * src/parameters.cc (get_parameters): Temporarily add support for having more than one path in ARTS_DEFAULT_INCLUDE_DIR. * tests/AVHRR/TestAVHRR.arts, tests/MHS/TestMHS.arts, tests/MHS/TestMHS_fast.arts, tests/Transmission/TestTransmission.arts, tests/GroundBased/TestFgrid.arts, tests/GroundBased/TestWinds.arts, tests/GroundBased/TestGbased.arts, tests/DOIT/TestDOIT.arts, tests/PencilBeam/TestPencilBeam.arts, tests/DOITBatch/TestDOITBatch.arts, tests/MonteCarlo/TestMonteCarloDataPrepare.arts, tests/MonteCarlo/TestMonteCarloGeneralGaussian.arts, tests/MonteCarlo/TestRteCalcMC.arts, tests/MonteCarlo/TestMonteCarloGeneral.arts, tests/DISORT/TestDISORT.arts, tests/HIRS/TestHIRS.arts, tests/Abs/TestAbsDoppler.arts, tests/Abs/TestAbs.arts, tests/AMSU/TestAMSUB.arts, tests/AMSU/TestAMSUB_fast.arts, tests/Ppath/TestPpath1D.arts, tests/Ppath/TestPpath2D.arts, tests/Ppath/TestPpath3D.arts, tests/RadioLink/TestRadioLink.arts, tests/ClearSky/TestClearSky.arts, includes/odin/odinsmr_544.arts, includes/odin/odinsmr_501_1D.arts, includes/odin/odinsmr_501.arts: Prepend general includes with general/. 2012-04-12 Oliver Lemke * arts-2-1-87 * src/parser.cc (ArtsParser::parse_method_args): Bug fix. When the controlfile contained a call to a WSM that has generic output but all arguments were omitted, all hell broke lose. Try this controlfile with an older version ;-): Arts2 { ReadXML } Change exception type from UnexpectedChar to ParseError for missing generic inputs. (ArtsParser::parse_main): Instead of calling arts_exit directly in case of errors, rethrow the exception. * src/main.cc (main): Add a try catch block inside the main controlfile loop and add the current controlfile name to the error output. 2012-04-12 Oliver Lemke * arts-2-1-86 * README: Updated. Add section headings. Add ctest documentation. * CMakeLists.txt: 'make check' only runs quick controlfiles now. 'make check-all' runs all tests. Add cmake option TEST_JOBS to let user specify how many tests to be run in parallel. (cmake -DTEST_JOBS=4 ..) * cmake/modules/FindNetCDF.cmake: Netcdf library might also be called netcdf4/netcdf_c++4. 2012-04-12 Jana Mendrok * arts-2-1-85 * src/cloudbox.cc: - use SI units with all pnd calculation functions. - remove (use of) scale_H11. let chk_pndsum do the work, which anyway did the same plus some warnings. - corrected (?!) scaling in MP48 (we don't have a direct way to check scaling based on precip rate. need to derive and use mass density instead). - removed hard coded density of particles in cloud liquid PSD (H98). * src/cloudbox.h: adapted. 2012-04-11 Patrick Eriksson * arts-2-1-84 * tests/RadioLink/TestRadioLink.arts: Now checking atmospheric loss and extra path delay. * src/rte.cc (defocusing_general_sub): 1D calculations around zenith/nadir requires special treatment. * src/ppath.cc (raytrace_1d_linear_euler): The law of cosines was used to calculate new latitude, which wasfound to be numerically unstable around zenith and nadir. Now using combination of geompath functions, that seems to work much better. (raytrace_2d_linear_euler): As above. * src/rte.cc (iyb_calc): Code replaced by call of adjust_los. 2012-04-11 Patrick Eriksson * arts-2-1-83 * src/m_rte.cc (iyRadioLink): Prepared for using defocusing_general but so far inactive. * src/ppath.h: Added declaration of cart2zaaa and cart2zaaa. * src/rte.cc: Replaced a number of "const Xxxxx&" with "ConstXxxxxView" where Xxxx is Vector etc. (adjust_los): New function. (defocusing_general): (defocusing_sat2sat): Complete. The two version give somewhat different results but a perfect agreement can not be expected. So OK right now. More detailed tests later on. Fails at least for 1D cases corresponding to za=0. * src/ppath.cc (raytrace_1d_linear_euler): Added an if-statement to handle poor accuracy for latitude when zenith angle = 0 or 180. 2012-04-09 Patrick Eriksson * arts-2-1-82 * src/m_rte.cc (iyRadioLink): Defocusing was not correctly iniated and applied. * src/rte.cc (defocusing3d, defocusing_limb1d): Started on two different aproaches to calculate defocusing. Not working and not active. * src/m_general.cc (Print): * src/xml_io_compound_types.cc (xml_read_from_stream) (xml_write_to_stream): Adopted to end/start_lstep. * src/m_ppath.cc (PrintTangentPoint): Now using find_tanpoint. (ppathFromRtePos2): Adopted to end/start_lstep. * src/ppath.cc: Adopted to end/start_lstep. (find_tanpoint): New function. * src/ppath.h (struct Ppath): lspace removed. start_lstep and end_lstep introduced. (lspace was the sum of the two new fields, but this is not sufficient information for calculating defocusing). 2012-04-06 Patrick Eriksson * arts-2-1-81 * src/m_rte.cc (iyRadioLink): Now calculating the bending angle correctly (for 1D, approximative for 2D and 3D). Now the quantity for both iy and iy_aux can be selected. * src/workspace.cc: Description of refr_index polished. * src/absorption.cc (refr_index_BoudourisDryAir) (refr_index_Boudouris): Removed. Old. Not used. Should not be in this file. * src/rte.cc (bending_angle1d): New function. * src/geodetic.cc: double was still hard-coded in this function! (sphdist): New function. 2012-04-05 Jana Mendrok * arts-2-1-80 * src/m_cloudbox.cc (pnd_fieldSetup): - moved all specific PSD calculation functionality into individual functions. - added Marshall&Palmer PSD for rain (also intended for use with snow, graupel/hail). - changed errors due to 'incorrect' profile or particle type into warnings, giving more freedom to the user how to name and combine things. * src/cloudbox.cc,cloudbox.h: added individual function for each implemented PSD type (currently: MH97, H11, H98_STCO, MP48). 2012-04-05 Oliver Lemke * arts-2-1-79 * Switching to ctest! * CMakeLists.txt: Use ctest as the default for the check/check-fast targets. * tests/testall.py: Remove all tests that moved to the ctest interface. Only one left that was currently not used due to a dependency on PyARTS. I'll leave the code here for now. * cmake/modules/ArtsTestcases.cmake: Remove deprecated macros. * tests/CMakeLists.txt: Add last missing test Wfuns. Remove deprecated testing code. 2012-04-05 Oliver Lemke * arts-2-1-78 * tests/testall.py, tests/MonteCarlo/TestMonteCarloGeneralGaussian.arts, tests/MonteCarlo/TestRteCalcMC.arts, tests/MonteCarlo/TestMonteCarloGeneral.arts: Move tests into the controlfiles. * tests/CMakeLists.txt: Add fast.odinsmr test. * cmake/modules/ArtsTestcases.cmake: Set arts screen output level for tests to 0 to only output the error in case of failure instead of the whole method log. 2012-04-04 Patrick Eriksson * arts-2-1-77 * src/m_rte.cc (iyRadioLink): Extended. Now handling dispersion and iy_aux set. Auxiliary variable to return can be selected (as a temporary solution?). * src/rte.cc (get_ppath_rtvars): Now using f_index. (get_iy_of_background): Adopted to agenda changes. * src/m_montecarlo.cc: Adopted call of iy_space_agenda. * src/agendas.cc: f_grid new input for emission_agenda and iy_space_agenda. Needed to handle dispersion (and could be used to consider Doppler shift also for these terms). * src/workspace.cc: Introduced dispersion_do. 2012-04-04 Patrick Eriksson * arts-2-1-76 * tests/Ppath/TestPpath3D.arts: * tests/Ppath/TestPpath2D.arts: * tests/Ppath/TestPpath1D.arts: Some changes. The files test different options for f_index = -1. * src/m_atmosphere.cc (basics_checkedCalc): Now also checking edensity_field. * includes/general.arts: edensity_field set to be empty. Adopted definition of ppath_step_agenda. * src/montecarlo.cc (iwp_cloud_opt_pathCalc): * src/m_rte.cc: * src/m_montecarlo.cc (MCIPA): * src/m_fos.cc: * src/m_doit.cc: * src/doit.cc: * src/ppath.cc: * src/m_ppath.cc: Numerous changes due to changes below (but all basically only to hand over variables to next function in the chain). * src/agendas.cc: Added edensity_field and f_index as input to ppath_agenda and ppath_step_agenda (edensity_field is presently not needed as agenda input, just in case if we want edensity jacobians in the future. To finish this, edensity_field must be added as input to iy_clearsky_agenda.). Reverted change for ppath_agenda. rte_los now only input. Not needed as output now with end_los added to Ppath structure. * src/refraction.cc: All functions consider now f_index and edensity_field. 2012-04-04 Patrick Eriksson * arts-2-1-75 * src/refraction.cc (get_refr_index_1/2/3d): Adopted call of refr_index_agenda, but so far just using local variables. * src/m_refraction.cc (refr_indexThayer): Now also doing the calculation (code moved from refr_index_thayer_1974). Works now in an additive way; refr_index is increased instead of set. (refr_indexIR): As above (but code from refr_index_ir). (refr_indexFreeElectrons): New WSM. (refr_indexUnit): Removed. Cfile even clearer if done as NumericSet( refr_index, 1.0 ) * Src/refraction.cc (refr_index_thayer_1974,refr_index_ir): Removed. * tests/Ppath/TestPpath1D.arts: * tests/Ppath/TestPpath2D.arts: * tests/Ppath/TestPpath3D.arts: Removed definition of refr_index_agenda (was same as in general.arts). * includes/general.arts: Adopted definition of refr_index_agenda. * src/agendas.cc: Added f_index and rte_edensity to the input of refr_index_agenda. * src/workspace.cc: Introduced edensity_field and rte_edensity. 2012-04-03 Jana Mendrok * arts-2-1-74 * src/methods.cc, workspace.cc: updating entries related to part_species redefinition. 2012-04-03 Jana Mendrok * arts-2-1-73 * CAREFUL! THIS COMMIT BREAKS BACKWARD COMPATIBILITY! redefinition of part_species tag structure: third element now part_type (the material/phase of the individual particle as given in ScattMetaData, e.g., "Ice"), size selection shifted backwards. first element renamed part_type->prof_type (the type of particle bulk profile, e.g. "IWC"). * src/m_cloudbox.cc, cloudbox.cc, src/cloudbox.h, m_atmosphere.cc: renamed (parse_)part_type -> (parse_)prof_type. * src/m_cloudbox.cc: (cloudboxSetAutomatically): removed hardwired prof_type-to-position-in- massdensity_field relation. (ScatteringParticlesSelect): removed hardwired prof_type-to-part_type relation. (pnd_fieldSetup): allow "H98_STCO" and "STCO" as more appropriate PSD selection tags for the current liquid cloud psd (which is continental stratus from Hess98). currently used "liquid" to be removed in future. * src/cloudbox.cc: (parse_prof_type): removed hard-wired restrictions on allowed prof_type names. (parse_part_type): added. function to parse part_species for part_type, the material/phase of the individual particle (e.g., "Ice"). * src/cloudbox.h: adapted acc. to cloudbox.cc changes * src/methods.cc, workspace.cc: descriptions of several particle related methods updated. * tests/DOITBatch/TestDOITBatch.arts: adapted to new part_species structure. 2012-04-03 Patrick Eriksson * arts-2-1-72 * tests/RadioLink/TestRadioLink.arts: Updated. New target values include free space loss. Accuracy not effectively is fractional, as threshold set based on the reference value. * src/m_ppath.cc (ppathFromRtePos2): ppath.end_pos/los set to match the transmitter. * src/ppath.cc (ppath_calc): Changes in several functions to handle and set new Ppath fields. * src/m_general.cc (Print): * src/xml_io_compound_types.cc (xml_write_to_stream) (xml_read_from_stream): Added handling of new Ppath fields. * doc/uguide/ppath.tex: Described new fields of Ppath. * src/ppath.h: For Pppath struct, added fields start_pos, start_los, end_pos and end_los. 2012-04-03 Oliver Lemke * arts-2-1-71 * src/mystring.h: Include algorithm for transform. * src/m_atmosphere.cc: Include algorithm no longer needed here. 2012-04-03 Oliver Lemke * arts-2-1-70 * tests/CMakeLists.txt: Revert accidentally committed line that broke the clean target. Add TestMHS and TestMHS_fast to new tests. * tests/DOITBatch/TestDOITBatch.ybatch.xml: Renamed to TestDOITBatch.ybatch.ref.xml. * tests/DOITBatch/TestDOITBatch.arts, tests/MHS/TestAMSUB.arts, tests/MHS/TestAMSUB_fast.arts, tests/MHS/TestMHS.arts, tests/MHS/TestMHS_fast.arts: Compare results against reference. * tests/MHS/TestMHS.ybatch.ref.xml, tests/AMSU/TestAMSUB.ybatch.ref.xml: Add reference values. * tests/testall.py: Comment out test2 of DOITBatch. Now done inside the controlfile. Comment out test{2,3} of MHS. Now done inside the controlfiles. Comment out test{2,3} of AMSUB. Now done inside the controlfiles. * src/mystring.h: Implement toupper and tolower in my_basic_string. * src/m_atmosphere.cc (atm_fields_compactFromMatrix): Use toupper. 2012-04-03 Patrick Eriksson * arts-2-1-69 * src/m_rte.cc (iyRadioLink): Free space loss and path lengths now calculated (internally only). 2012-04-02 Patrick Eriksson * arts-2-1-68 * tests/RadioLink/TestRadioLink.arts: Somewhat more demanding for limb sounding. * src/m_ppath.cc (ppathFromRtePos2): One of the tuning parameters had slipped back to an earlier, bad, value in the commit. 2012-04-02 Jana Mendrok * arts-2-1-67 * CAREFUL! THIS COMMIT BREAKS BACKWARD COMPATIBILITY! 'ChevalAll' batch routines removed (functionality merged into basic batch routines). Also impacts: - setup of part_species (number, order, and naming needs to fit particle field names passed to batch_atm_fields_compactFromArrayOfMatrix - equivalent to abs_species philosophy.) * src/m_atmosphere.cc (atm_fields_compactFromMatrix): - proper implementation of "ignore" (any columns, not only from the back, can be ignored now.) - now also to be used with batch atmospheres that include particle profiles. replaces atm_fields_compactFromMatrixChevalAll. (batch_atm_fields_compactFromArrayOfMatrix): - added catch when batch atmosphere arrayofmatrix is empty (e.g., cause reading-in accidentially removed from control file). - now also to be used with batch atmospheres that include particle profiles. replaces batch_atm_fields_compactFromArrayOfMatrixChevalAll. (AtmFieldsFromCompact): - adapted such that now also to be used with batch atmospheres that include particle profiles. replaces AtmFieldsFromCompactChevalAll. - added massdensity_field and part_species as input parameters. - non-hardwired handling of particle profiles (number, order, naming have to correspond to part_species definition. like vmr profiles to abs_species). (atm_fields_compactFromMatrixChevalAll, batch_atm_fields_compactFromArrayOfMatrixChevalAll, AtmFieldsFromCompactChevalAll): removed. * src/methods.cc (atm_fields_compactFromMatrixChevalAll, batch_atm_fields_compactFromArrayOfMatrixChevalAll, AtmFieldsFromCompactChevalAll): removed. (atm_fields_compactFromMatrix, batch_atm_fields_compactFromArrayOfMatrix, AtmFieldsFromCompact): adapted. * src/m_cloudbox.cc (ScatteringParticlesSelect): - throw error, when particle profile given, but no corresponding ScattData in selection. - replace error when no ScattData selected by a warning (should only occur when part_species empty, which occurs when using batch atmospheres, but having/wanting no particle profiles). - commented out check, whether all ScattData got selected (meaning of check unclear as well as whether it at all works as intended). (pnd_fieldSetup): - remove hardwiring of position of certain hydrometeor in massdensity_field and fixed link between particle profile type (IWC, LWC, etc.) and PSD. it's responsibility of the user to ensure profile type and PSD fit together (i.e., user here can now apply MH97 on LWC - not tested throughout, though. there might be further places hardwiring profile type and PSD relations.)! - catch case with no actual particles/ScattData linked to the particular part_species (though should never occur anymore, since already catched in ScatteringParticlesSelect - throw error, when given PSD is unknown * src/cloudbox.cc (chk_pndsum): added particle type (first part of part_species string) as input parameter, write clearer error message when pnd==0, but xwc!=0. (parse_psd_param): proper handling of incomplete part_species strings. remove check PSD validity here (now done in pnd_fieldSetup). * src/cloudbox.h (chk_pndsum): added part_type as passed parameter. * includes/general.arts: added part_species default setting (empty). required for AtmFieldsFromCompact for no-particle (i.e., clear-sky) batch cases. * tests/DOITBatch/TestDOITBatch.arts: adapted to new requirements (removed *ChevalAll calls, resorted part_species acc. to new requirements, ignore snow and rain). 2012-04-02 Patrick Eriksson * arts-2-1-66 * tests/CMakeLists.txt: Added RadioLink case. Placed transmission type cases (Transmission+RadioLink) between basic emission cases and the scattering cases. * tests/RadioLink/TestRadioLink.arts: Complete. (But calculations seems unstable, something is wrong. So far limb sounding case set to be simple.) * tests/Transmission/TestTransmission.arts: * tests/PencilBeam/TestPencilBeam.arts: * tests/Ppath/TestPpath3D.arts: * tests/Ppath/TestPpath2D.arts: * tests/Ppath/TestPpath1D.arts: Header text extended. 2012-04-02 Patrick Eriksson * arts-2-1-65 * tests/CMakeLists.txt: Added Transmission test (as fast). * tests/Transmission/TestTransmission.arts: New test. * tests/PencilBeam/TestPencilBeam.arts: Updated. 2012-04-02 Oliver Lemke * arts-2-1-64 * cmake/modules/ArtsTestcases.cmake: Add convenience macros to create controlfile based tests. * tests/CMakeLists.txt: Add more new tests and use new macro to create them. MC test cases still need the check against reference values implemented. * src/xml_io.cc (xml_read_from_file,xml_read_arts_catalogue_from_file): Make sure we read the .bin file from the same path as the .xml file. * CMakeLists.txt: Tweak newcheck-fast. 2012-04-01 Patrick Eriksson * arts-2-1-63 * src/m_rte.cc (iyRadioLink): New WSM. So far just calculating the transmission (jacobians and iy_aux not yet handled). But first complete radio link calculations! * src/m_ppath.cc (ppathFromRtePos2): A complete version. * src/ppath.cc: Several functions adopted to change of ppath_copy. (ppath_copy): Handles now also partial copying of ppath2. (ppath_calc): Now completely silent. The output just makes it hard to get good reports from the WSM using this function. So moving the reporting to the WSMs. 2012-04-01 Jana Mendrok * arts-2-1-62 * src/cloudbox.cc: some formatting for better readability. (IWCtopnd_MH97): MH97 PSD with noisy distribution parameters (gaussian noise according to error statistics given in MH97 paper). untested for stability, correct output etc. (but not breaking existing setups), so use with care. (scale_pnd): bugfix. for monodisperse case (no integration) set pnd=dN. * src/cloudbox.h (IWCtopnd_MH97): adapted for noisy MH97 (see above). * src/m_cloudbox.cc: some formatting for better readability. (pnd_fieldSetup): adapted for noisy MH97 (see above). * src/mc_antenna.cc (ran_gaussian): fixed typo. 2012-03-31 Patrick Eriksson * arts-2-1-61 * src/ppath.cc (ppath_calc): Combined check of cloudbox_on and ppath_inside_cloudbox_do lacked a !. Added some assert for extra safety when running with ppath_inside_cloudbox_do set to true. (ppath_start_stepping): Also points on the cloudbox boundary are now flagged as inside cloudbox. That is, no start poinst can end up as "cloudbox boundary". This made the code shorter and avoids unsafe calculations of pressure levels tilts (the code was not complete on this point). Thos closed one point in TODO. 2012-03-30 Patrick Eriksson * arts-2-1-60 * tests/PencilBeam/TestPencilBeam.arts: mblock_index now needed to run iyCalc. Fixed. 2012-03-30 Oliver Lemke * arts-2-1-59 * CMakeLists.txt, src/CMakeLists.txt, tests/CMakeLists.txt: Started utilizing the ctest facility of cmake. Should make it much easier to integrate tests in the future. Also, the output looks very clean compared to now. If you want to give it a try, run 'make newcheck' in the toplevel of the build directory. Note that only one controlfile is run at the moment. More to come. 2012-03-30 Patrick Eriksson * arts-2-1-58 * src/m_ppath.cc (ppathFromRtePos2): Still not complete, but a core algorith now established (after several tries). * src/geodetic.cc (line_circle_intersect,line_sphere_intersect): New functions. * src/check_input.cc (chk_rte_pos): What now is rte_pos[2] was rte_pos[1]. 2012-03-30 Oliver Lemke * arts-2-1-57 * tests/DOIT/TestDOIT.arts, tests/ClearSky/TestClearSky.arts, tests/testall.py: Started to move tests for verifying calculation results against reference values directly into the controlfiles. Removed corresponding tests from testall.py. * src/m_basic_types.cc, src/methods.cc: Add WSM NumericCompare. * src/parameters.cc (get_parameters): Fix crash for arts calls with no controlfile. 2012-03-29 Oliver Lemke * arts-2-1-56 * src/file.{cc,h}: Add function get_dirname. * src/parameters.cc (get_parameters): Use get_dirname. 2012-03-29 Oliver Lemke * arts-2-1-55 * src/parameters.cc (get_parameters): Fix indexing bug introduced accidentally right before committing. 2012-03-29 Oliver Lemke * arts-2-1-54 * src/parameters.cc (get_parameters): If the controlfile is not in the current directory, add its location to the includepath. 2012-03-29 Oliver Lemke * arts-2-1-53 * src/main.cc (main): Bugfix: If arts was called with a relative or full path to a controlfile, report files and output data with default filenames were written into the directory of the controlfile instead of the current directory. 2012-03-29 Oliver Lemke * arts-2-1-52 * src/m_atmosphere.cc (AtmFieldsCalc): Add 1D support for VMR input profiles that do not cover the whole range of the target grid. Boundary values in the partial input profile must be 0. * src/check_input.{cc,h} (chk_interpolation_grids_loose): Add new check used by AtmFieldsCalc to determine the range of the new grid that is covered by the old grid. Also checks that boundary values are 0 in the input data. * src/m_basic_types.cc, src/methods.cc (VectorCompare, MatrixCompare): Make implementation and error output of both methods consistent. Add an optional String argument for passing a custom error message. 2012-03-28 Patrick Eriksson * arts-2-1-51 * src/m_ppath.cc (ppathFromRtePos2): Complete, but not always converging :-( Will be fixed ... (rte_losGeometricFromRtePosToRtePos2): Now using pos2refell_r (making the function much shorter). (PrintTangentPoint): New WSM. * src/geodetic.cc (pos2refell_r): Was not OK for 3D. Had to add check with respect to lon_grid. * src/montecarlo.cc (mcPathTraceIPA): * src/rte.cc (get_iy_of_background): * src/refraction.cc (get_refr_index_3d, get_refr_index_2d): Replaced call of refell2r with refell2d (to be fully conistent with model definitions). * src/m_atmosphere.cc (z_fieldFromHSE): * src/doit.cc (cloud_ppath_update3D): Added comments that using refell2r is OK. 2012-03-28 Patrick Eriksson * arts-2-1-50 * tests/RadioLink/TestRadioLink.arts: Start on a new test cfile. * src/m_ppath.cc (ppathFromRtePos2): Further work ... * src/geodetic.cc (pos2refell_r): New function. * src/geodetic.h: Declaration of distance2D was incorrect. 2012-03-27 Patrick Eriksson * arts-2-1-49 * Same changes as for arts-2-0-40: * tests/Wfuns/TestWfuns.arts: * tests/GroundBased/TestGbased.arts: * tests/ClearSky/TestClearSky.arts: Adopted call of jacobianAddFreqShiftAndStretch. * src/m_jacobian.cc (jacobianAddFreqShiftAndStretch): df now carefully checked, to not give rise to an assert in interpolation applied in function below. f_grid had to be added is input. (jacobianCalcFreqShiftAndStretchInterp): The extrapolation factor for gridpos_poly now set to 1 (default of 0.5 was used before). (jacobianAddPointingZa): Added check that dza is inside [0,0.1], to avoid that unnecessary large values are used. 2012-03-27 Patrick Eriksson * arts-2-1-48 * src/ppath.cc (raytrace_2d_linear_euler): Expression for dlat can return NaN. If isnan, then set 0. Added also an if-statement to brake what can be become an infinite loop at tangent points. (This fixes so that test cfiles TestPpath1/2/3D.arts also run OK) (with refraction.) 2012-03-27 Patrick Eriksson * arts-2-1-47 * tests/Ppath/TestPpath1/2/3D.arts: Updated. Now using ppathCalc. * src/m_ppath.cc (ppath_stepGeometric,ppath_stepRefractionEuler): The case when called just to get nreal catched and handled seperately. * src/ppath.cc (ppath_start_stepping, ppath_calc): nreal was not always set for ppath having a single point. (do_gridcell_2d): Reintroduced some code to set exact value for zenith angle and latitude (when known). A case where numerical problems moved the latitude 1e-13 deg (!) outside the grid box was found. * src/m_ppath.cc (ppathCalc): Reintroduced this WSM, but now calling ppath_agenda (instead of ppath_calc). 2012-03-26 Patrick Eriksson * arts-2-1-46 * src/check_input.cc (chk_atm_field): Added check that 3D fields are constant with longitude for latitudes of +-90 deg (N- and S-pole). * src/m_ppath.cc (rte_losGeometricFromRtePosToRtePos2): New WSM (not yet heaviliy tested). (ppathFromRtePos2): Started on this WSM. * src/ppath.cc (ppath_calc): Now using the two new functions below. * src/check_input.cc (chk_rte_pos,chk_rte_los): New functions. 2012-03-26 Patrick Eriksson * arts-2-1-45 * src/m_ppath.cc (ppathToTransmitter): Just moved the (unused) code from ppath.cc to this file. * src/geodetic.cc (los2xyz): New function. * tests/MonteCarlo/TestRteCalcMC.arts: Added Ignore(mblock_index) to definition of iy_clearsky_agenda. * includes/general.arts: Added Ignore(mblock_index) and Touch(rteLlos) to definition of ppath_agenda. * src/rte.cc: * src/m_fos.cc: * src/m_rte.cc: Adopted to new agenda input described below. mblock_index is applied only for first part of rt calculation. That is, not inside cloudbox or after surface reflection (iy_clearsky_agenda or ppath_agenda is here given -1). * src/agendas.cc: Added mblock_index as input to iy_clearsky_agenda and ppath_agenda. rte_los added as output for ppath_agenda (needed to obtain bending angles for radio links). * src/workspace.cc: Added transmitter_pos and rte_pos2. * src/m_rte.cc: * src/m_sensor.cc: * src/rte.cc: * src/methods.cc: * src/m_jacobian.cc: * src/agendas.cc: imblock -> mblock_index. * src/workspace.cc: Renamed imblock to mblock_index (to fit naming pattern of f_index ybach_index ...). * src/m_doit.cc (CloudboxGetIncoming): Re-reverted (not just a workaround, in fact also a bit safer with respect to ending up with asserts). 2012-03-23 Oliver Lemke * arts-2-1-44 * src/make_auto_md_cc.cc: Bugfix in auto-generated agendaExecute code. Even if a variable is only used as WSM output inside the current agenda, it is possible that it is used first as input further down by another nested agenda, which we can't see here. Therefore initialized variables have to be duplicated. Also, non-initialized WSM output-only variables were falsely flagged as initialized. Fixes bug reported by patrick. * src/methods.cc, src/m_doit.cc: Reverted patrick's workaround for the above bug from arts-2-1-42. * src/docserver.cc (Docserver::new_page): Fixed crash with new libc++. tokens.erase(tokens.end()) never did what it was meant to do (because end() is not a pointer to the last element, but behind it). Statement has no effect with the old libstdc++. Now replaced with the correct call tokens.pop_back(); 2012-03-23 Patrick Eriksson * arts-2-1-43 * src/m_jacobian.cc (jacobianCalcTemperaturePerturbations): molarmass_dry_air required for HSE calculations. * src/m_atmosphere.cc (z_fieldFromHSE): Now using molarmass_dry_air, and could potentially be used for planets beside Earth. The description (in methods.cc) updated. * includes/general.arts: molarmass_dry_air set to 28.966. * src/workspace.cc: Added molarmass_dry_air. * tests/PencilBeam: New folder with a simple test of monochromatic pencil beam calculations. * tests/Ppath/TestPpath1/2/3D.arts: Changed paths to files to work as (future) test cases. 2012-03-23 Patrick Eriksson * arts-2-1-42 * tests/DOITBatch/TestDOITBatch.arts: Moved up call of basics_checkedCalc and cloudbox_checkedCalc, to be placed before CloudboxGetIncoming. (This was already the case in TestDOIT.arts) * src/m_doit.cc (CloudboxGetIncoming): Now checking if basics_checked and cloudbox_checked are set to true. 2012-03-23 Patrick Eriksson * arts-2-1-41 * ppath_agenda introduced. With the exceptions: Not relevant for DOIT (inside cloudbox). Nothing changed for MC (as other ppath_step part is anyhow hard-coded inside MC). * Clean-up/bugfix regarding input to ppath_step_agenda and iy_clearsky_agenda. Caused changes in several files (list below probably not complete). If general.arts used, no changes should be needed. * src/m_ppath.cc (ppath_stepGeometricUpDown): Removed. More complete tests showed that for complete simulations the time gain is very small and then better to remove a method of such low generality. * src/ppath_NotUsed.cc (ppath_geom_updown_1d): Now placed here. * includes/general.arts: Now also defining ppath_agenda and ppath_inside_cloudbox_do. * src/workspace.cc: ppath_cloudbox_do was incorrectly declared as Numeric. Also renamed to ppath_inside_cloudbox_do, for better clarity. N.B., this is a variable that standard usage not need to consider. Just use value set in general.arts! * src/ppath.cc: Replaced outside_cloudbox with ppath_inside_cloudbox_do. * src/montecarlo.cc: * src/m_montecarlo.cc: * src/m_rte.cc: * src/m_jacobian.cc: * src/m_fos.cc: Adopted to agenda changes below. * src/agendas.cc (ppath_step_agenda): A bug found! Added t_field, z_field and vmr_field as agenda input. This is required for jacobian perturbation calculations, to allow that e.g. t-disturbances can affect the refractive index. (iy_clearsky_agenda): Removed p/lat/lon_grid as input. These variables were added to handle FOS-2D, but realises that these variables must be pushed own to ppath_step_agenda level to work. And also other variables must be passed on from agenda to agenda for totally correct results. How to handle this is a later issue! * src/m_atmosphere.cc (z2g): Removed another pow. 2012-03-23 Oliver Lemke * arts-2-1-40 * src/file.cc (find_file): ~ was not expanded properly for include paths passed by the -I commandline option. 2012-03-22 Patrick Eriksson * arts-2-1-39 * src/workspace.cc: Defined ppath_cloudbox_do. This WSV correponds to the ppath_calc input argument outside_cloudbox (but equals !outside_cloudbox). * src/agendas.cc: Defined ppath_agenda. * src/refraction.cc (refr_index_ir): As below + declared constants as static. * src/geodetic.cc (distance3D,distance3D): As below. * src/physics_funcs.cc: Replaced usage of pow with multiplications, eg. pow(f,3.0) -> f*f*f. To hopefully gain some calculation time. 2012-03-21 Patrick Eriksson * arts-2-1-38 * src/ppath.cc (ppath_to_transmitter): New function. Just started. 2012-03-21 Patrick Eriksson * arts-2-1-37 * src/physics_funcs.cc: Removed all hard-coding of double. 2012-03-21 Patrick Eriksson * arts-2-1-36 * src/geodetic.cc (cart2pol, ..., distance2D,distance3D): 2D version of existing 3D ones completed. And added functions for calculating the distance between two points. 2012-03-20 Patrick Eriksson * arts-2-1-35 * src/geodetic.cc: Started to make 2D versions of the functions, ie. pol2cart etc. * src/m_rte.cc (yCompareToReference): Renamed. See below. This as this version was unneceesarily tied to y, and to complement the existing matrixCompare WSM. * src/m_basic_types.cc (VectorCompare): The method above renamed and made more general (all input generic). * tests/Ppath/TestPpath1/2/3D.arts: ppathCalc replaced by ppathStepByStep. * src/m_ppath.cc (ppathCalc): Renamed (to make a better distinction to other ppath methods (to be created), calculating complete ppaths). (ppathStepByStep): New name of ppathCalc. 2012-03-19 Patrick Eriksson * arts-2-1-34 * src/workspace.cc: Stated dimension of diy_dx was wrong. * src/m_rte.cc (iyCalc, yFromIy,yCompareToReference): New WSMs. * src/rte.cc (iyb_calc,get_iy_of_background): Now placed in this file. (iyb_calc): Now using iyCalc. * src/m_atmosphere.cc (z_fieldFromHSE): Now using versions of the equations, and some changes to for efficiency. Chwecked to give same results as pt2z in atmlab. The only Earth specific setting now is average molecular weight of dry air. Shall this be a WSV or calculated from vmr_field (if constrain that sum up to 1 is introduced)? * src/m_ppath.cc: Removed EARTH_GRAV_CONST (not used). * src/constants.cc: Removed not used constants EARTH_GRAV_CONST, LOSCHMIDT_CONST, ATOMIC_MASS_UNIT, SUN_TEMP and PRES_STAND. Added GAS_CONST. Sorted alphabetically (beside when dependency demand other order). Set PI, DEG2RAD and RAD2DEG to value reported by matlab, with "format long". That gave for all three constants one digit more compared to old value (no change for already existing digits). 2012-03-16 Patrick Eriksson * arts-2-1-33 * tests/Wfuns/TestWfuns.arts: Updated according to changes in last commit. 2012-03-16 Patrick Eriksson * arts-2-1-32 * tests/GroundBased/TestGbased.arts: Added definition of lat_true. * src/m_jacobian.cc (jacobianCalcTemperaturePerturbations): Adopted call of z_fieldFromHSE, that required adding input vars. * includes/general.arts: Added definition of g0_agenda. * src/m_atmosphere.cc: Some methods moved to m_planets.cc. (z_fieldFromHSE): Now using g0_agenda, lat_true and lon_true. A first step to make the function more general. * src/m_planets.cc: New file, for planet specific workspace methods. Some WSM from m_atmosphere moved here. (g0Earth): New WSM. * src/agendas.cc: Added g0_agenda. * src/workspace.cc: New WSVs: g0, lat, lat_true, lon and lon_true. Text for lat_grid and lon_grid updated, now (again) saying that they must be set to be empty when not used. 2012-03-16 Patrick Eriksson * arts-2-1-31 * src/ppath.cc: Many changes. In summary: Several bug fixes. Tests removed from several functions, for things now handled by cart2XXX in a general way. Revision of refraction part finished. * src/ppath_NotUsed.cc (cart2poslos): Old version stored here. (cart2sph): Same here. * src/ppath.cc (plevel_slope_3d): cart2poslos was used when cart2pos suffices (where new version used). * src/montecarlo.cc (mcPathTraceIPA): Adopted to addition below. * src/geodetic.cc (cart2poslos,cart2sph): Made a version of the functions with additional input. The new input is information of the original position, used to improve the accuracy. * src/ppath.cc (plevel_crossing_2d): Now making use of absza also inside the function (as originally planned). DEBUG_ONLY then removed. 2012-03-15 Oliver Lemke * arts-2-1-30 * src/m_abs.cc (abs_lines_per_speciesWriteToSplitArtscat): Don't crash for species that have no lines. 2012-03-08 Oliver Lemke * arts-2-1-29 * src/methods.cc, src/m_abs.cc (abs_lines_per_speciesWriteToSplitArtscat): Add WSM to write a splitted ARTSCAT based on abs_lines_per_species. * src/xml_io_array_types.cc (xml_read_from_stream): Output some info to out2 about how many lines were actually read from the ARTSCAT. (read vs. total) * src/m_abs.cc (abs_linesReadFromArts): out2 output moved to xml_read_from_stream because there we have access to the total number of lines in the catalog. * src/parser.cc (ArtsParser::read_name_or_value): Throw a ParseError instead of plain runtime_error for unsupported parameter types. This way it outputs information about the line number in the controlfile. * src/ppath.cc (plevel_crossing_2d): Use DEBUG_ONLY macro for definition of absza. * src/math_funcs.cc (lgamma_func): Remove warning about value being floored to 1 if compiled with Numeric==float as we don't support float anymore. * src/arts.h, src/m_abs.cc, src/xml_io_array_types.cc: Change my "FIXME OLE:" to "FIXME: OLE:" so they're recognized by Xcode. 2012-03-14 Patrick Eriksson * arts-2-1-28 * src/ppath.cc (raytrace_2d_linear_euler): Correction for refraction got a negative length if abs(za) > 90. * doc/uguide/ppath_theory.tex: Removed some typos and sentences describing old stuff. Added a clarification about the unit used for the lat/lon gradient of refractive index. Better placement of figures. 2012-03-14 Patrick Eriksson * arts-2-1-27 * src/ppath.cc: Work on code for refraction. Now complete, and works in the case of n=1 with an accuarcy better than 1 mm. Not yet tested for n>1. 2012-03-13 Patrick Eriksson * arts-2-1-26 * src/ppath.cc: Code for refraction cleaned up and chenged. The old length interpolation removed as it deteriorates the accuracy and anyhow makes the code slower. A lot of changes caused by this. 3D with refraction not yet ready! (interpolate_raytracing_points) (from_raytracingarrays_to_ppath_vectors_1d_and_2d) (from_raytracingarrays_to_ppath_vectors_3d): (ppath_fill_1d, ppath_fill_2d, ppath_fill_3d): Removed or merged into other functions. (ppath_end_1d,ppath_end_2d,ppath_end_3d): Now also making "fill" and handles vector lstep and nreal. * src/ppath_NotUsed.cc (refr_gradients_1d): Now placed here. * src/refraction.cc (get_refr_index_1d, get_refr_index_2d) (get_refr_index_3d, refr_gradients_2d, refr_gradients_3d): Converted rte_pressure, rte_temperature and rte_vmr_list from in/out/arguments to local variables (reminiscent from old agenda functionality). 2012-03-13 Patrick Eriksson * arts-2-1-25 * doc/uguide/ppath_theory.tex: Updated geomtrical 3D text to last changes. * src/ppath.cc: Resorted order of functions, to better seperate code for geometrical and refraction calculations. * src/ppath_NotUsed.cc (za_geom2other_point): Now placed here. 2012-03-12 Patrick Eriksson * arts-2-1-24 * src/ppath.cc: Moved inactive parts to file below. * src/ppath_NotUsed.cc: New file. Storage for code from ppath.cc now not used. 2012-03-10 Patrick Eriksson * arts-2-1-23 * src/ppath.h: Moved RTOL and LATLONTOL to ppath.cc. * src/ppath.cc (do_gridcell_3d_byltest): Updated to new approach to handle tangent points. Then found a bug for path steps around tangent points for old code. "lstep" before and after tangent point not necessarily the same but function returned just a single value. Solved automatically by switch to new approach. Introduced LACC, and moved RTOL and LATLONTOL from ppath.h, as not used externally. * src/m_general.cc (Test): Removed old test code. 2012-03-09 Patrick Eriksson * arts-2-1-22 * src/rte.cc: * src/m_rte.cc: * src/m_general.cc (Print): * src/m_fos.cc: * src/doit.cc: * src/ppath.cc: * src/xml_io_compound_types.cc: Adopted to change below. * src/ppath.h: Changed back: l_step -> lstep and l_space -> lspace (to be consistent with the WSV ppath_lmax/raytrace). * doc/uguide/batch.tex: Updated the code example where ppath_stepGeometric is re-defined. * doc/uguide/rte.tex: Updated regarding that sensor_pos now holds altitude instead of radius. * doc/uguide/ppath.tex: A quick re-revision. Some less important comments removed. * doc/uguide/atmosphere.tex: Some text improvements and updates. * src/geodetic.cc: Geiod -> ellipsoid in header. * src/ppath.cc: Part around PTILTMAX changed. Some more work on 3D code. * src/ppath.h: Removed version of plevel_slope_3d not used outside of ppath.cc. Removed PTILTMAX. Was just used in one place. 2012-03-07 Patrick Eriksson * arts-2-1-21 * src/ppath.cc (lat_crossing_3d, r_crossing_3d): Yet another version for selection between l1 and l2. 2012-03-05 Patrick Eriksson * arts-2-1-20 * src/ppath.cc (ppath_step_geom_3d): Now handling tangent points in the same way as 1D and 2D functions. (r_crossing_3d): Added special handling of r_hit==r_start. 2012-03-05 Patrick Eriksson * arts-2-1-19 * src/ppath.cc (ppath_step_geom_3d): Forgot to switch back to old version of do_gridcell_3d. (Now checks run with OK.) 2012-03-05 Patrick Eriksson * arts-2-1-18 * src/ppath.cc (r_crossing_3d, lat_crossing_3d, lon_crossing_3d): Now complete versions. 2012-02-29 Patrick Eriksson * arts-2-1-17 * src/ppath.cc: Some work on new 3D code. (lat_crossing_3d,lon_crossing_3d): New functions. Not yet complete. 2012-02-28 Oliver Lemke * arts-2-1-16 * src/m_abs.cc (abs_linesReadFromSplitArtscat): If basename is a directory (path ends with '/'), don't append '.SPECIES.xml' but just 'SPECIES.xml'. * src/xml_io_array_types.cc (xml_read_from_stream): Fix regression for reading ArrayOfLineRecord from an ARTS catalog whose version number is just "3" instead of "ARTSCAT-3". (xml_write_to_stream): When writing an ArrayOfLineRecord, determine the required catalog version from the first LineRecord. If the array contains a mixture of different versions of lines, throw a runtime error. * src/xml_io.cc (xml_read_from_file, xml_read_arts_catalogue_from_file): Output the _full_ filename to out2. Gives better feedback to the user if the file is found somewhere in the path (ARTS_DATA_PATH) instead of the current directory. 2012-02-28 Patrick Eriksson * arts-2-1-15 * ChangeLog: Was not saved at last commit. 2012-02-28 Patrick Eriksson * arts-2-1-14 * doc/uguide/ppath_theory.tex: Revision and extending general part of 3D geometrical calculations. * src/ppath.cc (gridcell_crossing_3d): Extracted this function from arts-1-1-400, for later use (now inside /* */). * src/geodetic.cc (cart2poslos): Just rearrangement to get dy and dz terms in logical order. 2012-02-27 Patrick Eriksson * arts-2-1-13 * src/ppath.cc (do_gridcell_3d_byltest): Old do_gridcell_3d renamed. (plevel_crossing_3d): Started. (do_gridcell_3d): Started on this new version of the function. 2012-02-27 Patrick Eriksson * arts-2-1-12 * doc/uguide/ppath_theory.tex: General revision. Section on numerical precision removed. 2D geometrical section updated following changes in source code. * doc/uguide/ppath.tex: Even more sections moved to ATD. Text revised and updated. * src/xml_io_compound_types.cc: * src/m_general.cc: * src/ppath.cc (ppath_calc): Adopted to change below. * src/ppath.h (struct Ppath): Renamed lspace to l_space (to be consistent with l_space). 2012-02-24 Patrick Eriksson * arts-2-1-11 * A first step of moving all path equations to ATD. * doc/uguide/arts_theory.tex: * doc/uguide/CMakeLists.txt: ppath_theory.tex added. * doc/uguide/ppath_theory.tex: Holds the part removed below. Not yet adopted to ATD. * doc/uguide/ppath.tex: Last part having a lot of equations moved to ATD. * doc/uguide/surface.tex: First two section revised, and slightly changed. 2012-02-24 Patrick Eriksson * arts-2-1-10 * src/m_ppath.cc (ppath_stepGeometricUpDown): Now working with an active cloudbox (realised that this method can be used with DOIT 1D, if ppath-step_agenda is changed after the cloudbox radiation field is determined) * src/ppath.cc (ppath_geom_updown_1d): Core part of change above done here. * src/ppath.cc (plevel_crossing_2d): Removed old version of this function. * src/geodetic.cc (geomtanpoint,geomtanpoint2d): Deactivated, as not yet known if result is OK: * src/ppath.h: * src/ppath.cc: All special treatment of float removed. 2012-02-24 Oliver Lemke * arts-2-1-9 * aii, CMakeLists.txt: Remove outdated IDL routines. 2012-02-24 Oliver Lemke * arts-2-1-8 * CMakeLists.txt: Add a very clear warning if the user decides to compile with a custom Numeric type. 2012-02-24 Patrick Eriksson * arts-2-1-7 * src/ppath.h: Changed RTOL to 1e-3, LATLONTOL to 1e-8 and POLELAT to 90-1e-8. These all corresponds to an overall accuracy of about 1 mm (for Earth). 2012-02-23 Patrick Eriksson * arts-2-1-6 * tests/GroundBased/TestGbased.arts: The new WSM below is now used by this case. * src/m_ppath.cc (ppath_stepGeometricUpDown): New WSM. Provides much faster ppath calculations for 1D upward or downward cases. * src/ppath.cc (ppath_geom_updown_1d): New. * src/doit.cc: * src/m_doit.cc: z_surface removed as input to "update" methods, due to change below. * src/agendas.cc: Removed all input arguments beside ppath_step. 2012-02-23 Oliver Lemke * arts-2-1-5 * src/parameters.{cc,h}: Add datapath to class Parameters. (parse_path_from_environment): Add function to parse paths from an environment variable. (get_parameters): Add option --datapath. * src/parser.cc (ArtsParser::parse_agenda): Pass includepath to find_file * src/main.cc (main): Add datapath output to -v. * src/file.{cc,h} (find_file): Add parameter paths. * src/xml_io.cc (xml_read_from_file,xml_read_arts_catalogue_from_file): Pass includepath and datapath to find_file. 2012-02-23 Patrick Eriksson * arts-2-1-4 * src/ppath.cc (rslope_crossing): Changed some limits for dlat. Using atmlab's arts_rslope_crossing, the function is OK-ed again. (plevel_crossing_2d): Added more asserts. Tested the new two step algorithm using atmlab's arts_rslope_crossing. Could not find any case where the algorithm fails (considering that the maximum radius distance for rslope_crossing now is (lat3-lat1)*c). 2012-02-22 Patrick Eriksson * arts-2-1-3 * src/ppath.cc (ppath_step_geom_1d): Had to reinroduce handling of tangent points on this level. It was here for a good reason that I forgot (to also handle DOIT). Tangent points now flagged as endface 8. Same change for 2D. 2012-02-22 Oliver Lemke * arts-2-1-2 * src/libmicrohttpd/: Update to r19912 from https://gnunet.org/svn/libmicrohttpd. * CMakeLists.txt, src/libmicrohttpd/CMakeLists.txt: Tweak warning flags for Clang compiler, and libmicrohttpd. 2012-02-22 Oliver Lemke * arts-2-1-1 * Merge arts-dev branch r7344 into trunk. 2012-02-22 Oliver Lemke * arts-2-1-0dev1 * ChangeLog: Remove conflict marker. 2012-02-22 Oliver Lemke * arts-2-1-0dev0 * Merged from trunk r7341. 2012-02-22 Oliver Lemke * arts-2-1-0 * Increase minor version after branching. 2012-02-22 Patrick Eriksson * arts-2-0-38dev4 * src/ppath.cc (ppath_calc): lspace was not transfered to final ppath. Polishing of new code for 1D and 2D geomtric. * src/xml_io_compound_types.cc: Ppath constant was saved as lspace! 2012-02-20 Patrick Eriksson * arts-2-0-38dev3 * make check and make check-fast now run with OK. * tests/*/*.arts: * includes/*/*.arts: All control files adopted to changes made around refellipsoid and ppath. * tests/testall.py (TestClearSky.test3): Changed target Tb for ClearSky case. This was needed as the Earth radius in constants.cc has been changed. Verified that old target Tb was obtained with old radius (so no change in RT part). Down-looking cases less affected by the changed radius, but could now be a slight shift with respect to old target values (if za < 180). 2012-02-20 Patrick Eriksson * arts-2-0-38dev2 * src/ppath.cc (ppath_copy): Did not work for l_step if ppath2.np=1. * src/ppath.cc (ppath_calc): The case of single point ppaths now handled seperately when creating the final ppath. The merging of ppath_array could then be made somewhat more efficient, and solves a problem of getting nreal into the first point of final ppath. * src/m_ppath.cc (ppath_stepGeometric): Now sets nreal to 1. This solves nreal for geometrical calculations (after the changes above). 2012-02-19 Patrick Eriksson * arts-2-0-38dev1 * src/ppath.cc (ppath_calc): Added handling of Ppath.lspace and Ppath.nreal. lspace calculated, but nreal not yet set. * src/m_general.cc (Print): * src/xml_io_compound_types.cc (xml_write_to_stream): Added handling of Ppath.lspace, and adopted to changed field order. * src/ppath.h (struct Ppath): Added field lspace. Needed to keep track of complte ppath length/delay. Changed order of fields. * src/ppath.cc (rslope_crossing): New function. Just performing core task of old plevel_crossing_2d (finding the crossing with a level having radial slope). (plevel_crossing_2d): New version of this function, with extended scope. It now handles all tasks around checking if there is a crossing inside the latitude grid range. The accuracy also improved, as the Taylor expansion expression is now only used for a final smaller step. Exact expressions are used in a first step, moving the ppath as close as possible to the surface before the approximative expression is applied. (do_gridcell_2dv2): New version of do_gridcell_2d, making use of the functions above. All this recoding done with the aim to later use the same calculation approach, and function structures, for 3D. 2012-02-20 Oliver Lemke * arts-2-0-38dev0 * Merged from trunk r7321. 2012-02-20 Oliver Lemke * arts-2-0-38 * src/m_abs.cc (abs_linesReadFromSplitArtscat): Use species ids instead of strings. * src/xml_io.cc: Comment out unused variable. 2012-02-17 Gerrit Holl * arts-2-0-37 * src/m_cloudbox.cc (pnd_fieldSetup): bugfix - Fix fixed bug from arts-1-17-25, set pnd = dN if monodisperse 2012-02-17 Oliver Lemke * arts-2-0-36 * CMakeLists.txt: Turn off -Wno-sign-conversion for now. It's not supported by older GCCs. 2012-02-17 Oliver Lemke * arts-2-0-35 * CMakeLists.txt: Turn on -Wconversion warning by default. * src/m_cloudbox.cc: (cloudboxSetAutomatically): Change type of p_margin1 from Index to Numeric to avoid loss of precision in implicit cast. (ScatteringParticlesSelect): Change type of intarr_total from Numeric to Index. * src/docserver.cc (Docserver::launch): Cast port to uint16_t. * src/math_funcs.cc, src/m_abs_lookup.cc, src/m_surface.cc: Add some explicit casts from Index to Numeric to suppress conversion warning for cases where we know what we're doing. * src/nc_io_array_types.cc: Remove unused variables. * src/libmicrohttpd/daemon.c (send_param_adapter): Add explicit cast to avoid conversion warning. 2012-02-14 Oliver Lemke * arts-2-0-34 * src/m_abs.cc (abs_linesReadFromSplitArtscat): Use isdigit instead of isnumber for compatibility. 2012-02-14 Oliver Lemke * arts-2-0-33 * src/m_abs.cc (abs_linesReadFromSplitArtscat): First implementation. For abs_species with an isotope that's not a number or '*', no catalog is read. * src/methods.cc: Add WSM abs_linesReadFromSplitArtscat. 2012-02-14 Oliver Lemke * arts-2-0-32 * src/xml_io_array_types.cc: Combine the almost identical functions for reading an ArrayOfLineRecord with and without frequency limits into one function. Setting the limits fmin and/or fmax to NAN indicates to not filter by frequency. * src/parameters.cc (get_parameters): Use consistent conversion error checking on isstringstreams. 2012-02-13 Oliver Lemke * arts-2-0-31 * src/absorption.{cc,h}: Add new ARTSCAT-4 fields to LineRecord. Add support for ARTSCAT-4 in LineRecord output operator. (LineRecord::ReadFromArtscat4Stream): Implemented. 2012-01-30 Oliver Lemke * arts-2-0-30 * Preparations for ARTSCAT-4. * src/absorption.{cc,h}: Rename LineRecord::Version to LineRecord::VersionString. Version() now returns the version number as an Index. Rename LineRecord::ReadFromArtsStream to LineRecord::ReadFromArtscat3Stream and add LineRecord::ReadFromArtscat4Stream (copy of LR:RFA3S for now). * src/xml_io_array_types.cc (xml_read_from_stream): Adapt ArrayOfLineRecord reading routine to detect ARTSCAT version and call corresponding LR:ReadFromArtscatXStream function. * src/m_abs.cc (abs_linesReadFromArtsObsolete): Adapt for name changes. 2012-02-08 Jana Mendrok * arts-2-0-29 * src/ppath.cc: bugfix (cloudbox reaching to TOA -> first ppath instance sees background, don't try to iterate along path). 2012-02-18 Patrick Eriksson * arts-2-0-28dev15 * tests/Ppath/TestPpath3D.arts: Was not svn-added. 2012-02-18 Patrick Eriksson * arts-2-0-28dev14 * src/ppath.cc (r_crossing_2d): New function. * src/agendas.cc: p_grid now not input to ppath_step_agenda. Required adoption in several files. * src/m_ppath.cc (ppath_stepGeometric): Adopted calls of sub-functions. p_grid now not used. * src/doit.cc (ppath_step_in_cloudbox): Removed this function. Not used at all! * src/ppath.cc: Changes throughout the file with respect to tangent points. The ppath fields now not set. Tangent points now not handled as an "endface", but handled one level lower among the sub-functions (now at the level of do_gridrange_1d level). Requires less shuffling of data and cleaner code. * src/m_montecarlo.cc (MCIPA): Lat and lon of tangent point now determined from ppath.pos. * src/m_general.cc: * src/xml_io_compound_types.cc: Adopted to change of Pppath. * src/ppath.h (struct Ppath): Removed field tan_pos, geom_tan_pos and next_parts. * src/ppath.cc (ppath_start_stepping): More tests. Fixed one bug and now demanding that platform radius is > r_toa_max. Handling of 2D and 3D now even more similar. * tests/Ppath/TestPpath3D.arts: New. 2012-02-17 Patrick Eriksson * arts-2-0-28dev13 * src/ppath.cc (plevel_crossing_3d): Renamed to r_crossing_3d as task of function has been changed. Header text described the original version. * src/ppath.cc (ppath_start_stepping): Some improvements of the code for finding TOA entrance point for 2D. Complete new code for 3D. Not yet tested heavily. 2012-02-16 Patrick Eriksson * arts-2-0-28dev12 * tests/Ppath: Start on a set of new test control files. * src/ppath.cc: Corrected errors in several headers. Corrected/changed text for several errors. (geompath_za_at_r): Sign of za was not kept if r==ppc! (ppath_start_stepping): Code 2D now revised and using a new algorithm for finding entrance point at TOA. (Full 1D and 2D ppath calculations tested quite carefully.) * src/m_cloudbox.cc (cloudbox_checkedCalc): Polished error message. * src/m_basic_types.cc (IndexStepDown, IndexStepUp): New WSMs. (IndexStep): Replaced by IndexStepUp. 2012-02-15 Patrick Eriksson * arts-2-0-28dev11 * src/geodetic.cc (poslos2cart): Added assert for za. 2012-02-13 Patrick Eriksson * arts-2-0-28dev10 * src/geodetic.cc (geomtanpoint2d): New. Not yet complete. * src/ppath.cc (ppath_start_stepping): A complete revision of the function, to use same basic approach for 1D, 2D and 3D. And to add some missing parts (cloudbox in 2D, cloudbox reaching TOA ...). Code for 2D presently not complete. * src/geodetic.cc (poslos2cart): Now not calling sph2cart, to save some time (code instead copied and adopted). * src/geodetic.cc (geomtanpoint): New function. Calculates the geomtrical tangent altitude, also for non-spherical planets. * src/constants.cc: Changed EARTH_RADIUS from 6.378e6 to 6.3781e6, which seems to be the standard value. * src/math_funcs.cc (cross): A function for 3D cross product. (unitl): New function. Normalises a vector. 2012-02-10 Patrick Eriksson * arts-2-0-28dev9 * Change to a more common defintion of the cartesian coordinate system made. * src/ppath.cc: Functions listed below removed. (plevel_crossing_3d): Here y <-> z change needed. * src/geodetic.cc: cart2poslos, cart2sph, geompath_tanpos_3d, poslos2cart and sph2cart, now placed in this file. Cartesian y and z axes have changed place inside these functions, to follow a more standard cartesian coordinate system. 2012-02-10 Patrick Eriksson * arts-2-0-28dev8 * Code now updated following changes around refellipsoid and sensor_pos/rte_los. Made basic tests, but no heavy testing. This will be done after ppath_start_stepping is finished. * src/m_general.cc (Print): Adopted printing for Ppath. * src/ppath.h: Removed field z from Ppath structure. * src/montecarlo.cc (mcPathTraceIPA): Adopted to change for rte_pos (now holding altitude, not radius). Seems to be only needed change for all MC code, with respect to this point. * src/m_doit.cc (CloudboxGetIncoming, CloudboxGetIncoming1DAtm): Removed refellipsoid as input, now not used. * src/m_doit.cc (doit_i_fieldUpdateSeq1DPP): * src/doit.cc (cloud_ppath_update1D_planeparallel): Removed not used input arguments ppath_step_agenda and refellipsoid. Adopted to changes of pos definition. * src/ppath.cc (ppath_start_stepping): Now fixed and tested for 3D. 2012-02-10 Patrick Eriksson * arts-2-0-28dev7 * src/ppath.cc (ppath_start_stepping): Updated for 3D. 2012-02-09 Patrick Eriksson * arts-2-0-28dev6 * src/ppath.cc: 2D geomtric cases revised. 1D and 2D geometric tested. Started on 3D. * src/geodetic.cc (refell2d): New function. 2012-02-09 Patrick Eriksson * arts-2-0-28dev5 * Work in progress. Transfer from lap- to desktop. Does not compile! * src/ppath.cc: Being revised. * src/xml_io_compound_types.cc (xml_write_to_stream): ppath.z -> ppath.r. * src/ppath.h (struct Ppath): Field z renamed to r. * src/m_ppath.cc: File revised with respect to new WSV definitions. (VectorZtanToZa1D): Adopted to new definition of sensor_pos. (VectorZtanToZaRefr1D): As above. * tests/OdinSMR/TestOdinSMR.arts: * tests/OdinSMR/TestOdinSMR_119ghz.arts: Removed call of sensor_posAddRgeoid. * includes/general.arts: refellipsoid now set (instead of r_geoid). 2012-02-08 Patrick Eriksson * arts-2-0-28dev4 * src/: r_geoid and the term geoid wiped out from the source code! Numerous changes to make the change to refellipsoid, affecting a high number of files. The code compiles, but no test calculations yet made. * src/m_surface.cc (r_geoidSpherical, r_geoidWGS84): Removed. * src/workspace.cc: r_geoid removed. * src/m_ppath.cc (rte_posAddRgeoid): Removed. Sensor position will be given as altitude above ellipsoid (future change). (sensor_posAddRgeoid): As above. * src/m_ppath.cc (ppathCalc): Now considers basics_checked and cloudbox_checked. * src/m_atmosphere.cc (basics_checkedCalc): The method now checks refellipsoid instead of r_geoid. 2012-02-08 Patrick Eriksson * arts-2-0-28dev3 * doc/uguide/concept.tex: Rewrote item point including "geoid". * doc/uguide/surface.tex: Revised, following the change from r_geoid to refellipsoid. * doc/uguide/atmosphere.tex: Revised up to Sec. 2.5, following changes made/planned. The view of 1D and 2D atmospheres slightly changed. For 1D, the sensor is now consider to be placed at lat/lon=0, and be looking North. For 2D, the plane is now "locked" to pass above the poles, and lat=0 is at the Equator (but no upper or lower limit as before). This definition is needed for 2D to have a relationship to the reference ellipsoid. * src/check_input.cc (chk_atm_grids): Changed back to demand that lat_grid and lon_grid are empty when not used. Variables like "lat_true" and "lon_true" will be introduced to geographically place 1D and 2D cases. 2012-02-07 Patrick Eriksson * arts-2-0-28dev2 * src/geodetic.cc (refell2r): New function. * src/m_geodetic.cc (refellipsoidForAzimuth): New WSM. (refellipsoidOrbitPlane): New WSM. 2012-02-07 Patrick Eriksson * arts-2-0-28dev1 * src/m_geodetic.cc: (refellipsoidEarth, refellipsoidJupiter, refellipsoidMars) (refellipsoidSet, refellipsoidMoon, refellipsoidVenus): New WSMs. * src/surface.cc: Moved internal functions before placed in m_surface to this file. * src/CMakeLists.txt: Added the new files listed below. * src/geodetic.h: * src/geodetic.cc: * src/m_geodetic.cc: * src/surface.h: * src/surface.cc: New files. * src/*: Removed all remaining rss. in my email address. * src/workspace.cc: Added refellipsoid. * TODO: Will be using this file for notes. 2012-02-06 Oliver Lemke * arts-2-0-28dev0 Merged from trunk r7263. 2012-01-30 Oliver Lemke * arts-2-0-28 * Fix compilation against the new libc++ http://libcxx.llvm.org/ * src/xml_io.cc (xml_read_header_from_stream): Use ' ' as delimiter. * src/m_general.cc: Include arts.h before using TIME_SUPPORT. * src/src/file.cc: Include arts.h first and include unistd.h (for 'unlink' function) if available. 2012-01-26 Oliver Lemke * arts-2-0-27 * src/continua.cc: Add two missing throws for runtime errors. 2012-01-20 Oliver Lemke * arts-2-0-26 * src/m_optproperties.cc: Make all preprocessor macros UPPERCASE. Otherwise the code gets horribly unreadable. If they appear just as normal variables it's very hard to guess that they're actually macros. Macros changed: PART_TYPE F_DATAGRID T_DATAGRID ZA_DATAGRID AA_DATAGRID PHA_MAT_DATA_RAW EXT_MAT_DATA_RAW ABS_VEC_DATA_RAW PND_LIMIT 2012-01-09 Oliver Lemke * arts-2-0-25 * CMakeLists.txt: Add cmake option -DWITH_GUI=1. * src/CMakeLists.txt: Detect Qt libraries, link with artsgui lib and add gui subdirectory if enabled. * src/parameters.{cc,h}: Add -G (--gui) option to launch with GUI. * src/main.cc: Add GUI launch code. * src/gui/: Add subdirectory for arts GUI library code. * src/gui/CMakeLists.txt, src/src/gui/ag_main.{cc,h}, src/gui/mainwindow_qobj.{cc,h}: Simple main window with helloworld message. * config.h.cmake: Add ENABLE_GUI preprocessor flag. * src/continua.cc: Initialize jsum with 0 to avoid warning. 2011-12-07 Oliver Lemke * arts-2-0-24dev0 Merged from trunk r7223. 2011-12-07 Oliver Lemke * arts-2-0-24 * src/arts_omp.cc (arts_omp_in_parallel): No more special treatment needed for Intel Compiler. 2011-11-24 Oliver Lemke * arts-2-0-23 * CMakeLists.txt: Add an additional check right at the beginning to make sure that we never allow cmake to be called inside the source directory. NOTE: If you get an error after updating that you have to build arts outside the source tree although you are actually in a separate build directory, make sure that there is no file 'CMakeCache.txt' or directory 'CMakeFiles' in your toplevel arts source(!!) directory. * tests/testall.py: Fix path to arts for Xcode build. * src/docserver.cc (insert_breadcrumbs): Fix type of t, int -> size_t. 2011-11-23 Patrick Eriksson * arts-2-0-22 * doc/uguide/symbol_defs.tex: More definitions around refractive index. Some consistency changes. * doc/uguide/rte.tex: Planck function equation now uses symbol definitions throughout. 2011-11-22 Patrick Eriksson * arts-2-0-21 * doc/uguide/rte.tex: New symbol definitions used. * doc/uguide/symbol_defs.tex: Added definitions for Stokes elements I, Q, U and V, and speed. 2011-11-18 Oliver Lemke * arts-2-0-20dev0 * Created development branch from trunk r7212. 2011-11-11 Gerrit Holl * arts-2-0-20 * src/m_abs_lookup.cc (abs_lookupCreate): Improve error message. 2011-11-07 Patrick Eriksson * arts-2-0-19 * src/ppath.cc (ppath_start_stepping): Now also "upward" observations are allowed when the sensor is above the model atmosphere. The idea is to allow the cloudbox to include TOA. 2011-11-05 Jana Mendrok * arts-2-0-18 * src/cloudbox.cc: (IWCtopnd_MH97): for large IWC (obviously outside the original parameterization range) number densities in small particle mode got negative. now, if so, explicitly set to 0. though not specified by MH97, this should be fine, since even the small mode rather creates particles with Dm>100um, which should be covered by the large mode. 2011-11-05 Jana Mendrok * arts-2-0-17 * src/cloudbox.cc: (IWCtopnd_MH97): bugfix. cases with all ice in <100um mode (lowT & small IWC) lead to NaN at >100um mode lead to all pnd set to 0. now producing proper pnd_field (relevant more for IR than MW, I guess). (chk_pndsum): bugfixed interface, where vol and density where swapped. modified pnd scaling correction - don't let pnd==0 slip through, when xwc!=0, so rather test for xwc==0 instead of x.sum()==0. potentially caused huge deviations that went uncatched... * src/cloudbox.cc: corresponding chk_pndsum interface adaption. 2011-11-02 Daniel Kreyling * arts 2-0-16 * src/m_cloudbox.cc: (pnd_fieldSetup) Added new globally applicable particle size distribution for ice and snow particles, based on the work of A.J. Heymsfield (apparently not published yet). In ARTS terms the new PSD is called 'H11' and can be used for scattering calculations just like 'MH97'. * src/cloudbox.cc (pnd_H11): new function to evaluate the distribution at given scattering particle sizes (scale_H11): scaling the 'H11' PND values to total ice or snow massdensity. *src/methods.cc: updated doku for 'H11' *src/workspace.cc: updated doku for 'H11' 2011-10-27 Jana Mendrok * arts-2-0-15 * src/methods.cc,agendas.cc,workspace.cc: more broken doc links fixed 2011-10-27 Jana Mendrok * arts-2-0-14 * src/methods.cc: fixed some doxygen doc (references to workspace methods/variables) * includes/smr: added sensor definitions for ciwsir, cloudice, iss-smr, (jaxa-)smr 2011-10-17 Stefan Buehler * arts-2-0-13 * src/absorption.h (LineRecord): Updated doxygen documentation for this class. (Basically added information on the XML header and footer.) Triggered by Agnes asking about a description of the ARTS catalogue format. 2011-10-04 Oliver Lemke * arts-2-0-12 * src/agendas.cc: Ooops, don't fix it if it ain't broken. 2011-10-04 Oliver Lemke * arts-2-0-11 * src/docserver.{cc,h}: Mark broken *LINKS* red. Add a 'Doc check' page that lists all broken links. Add link to this page in footer. (insert_breadcrumb_token, insert_breadcrumbs): Fix broken breadcrumbs. (description_add_links): Also search through GIn and GOut to determine if *LINK* target exists. * src/methods.cc: Put space around * if used as multiplication operator in docs. * src/agendas.cc: Minor doc fix. 2011-09-11 Patrick Eriksson * arts-2-0-10 * src/m_rte.cc (yCalc2): Some bug fixes. Changes needed elsewhere before a switch to this version cen be made. 2011-09-15 Oliver Lemke * arts-2-0-9 * CMakeLists.txt: Provide some love for Cygwin users. 2011-09-15 Patrick Eriksson * arts-2-0-8 * src/m_basic_types.cc (ArrayOfIndexSetConstant): Created. * src/m_sensor.cc (sensor_responseFromArrayData): Created. (sensor_response_arraySingle): Created. * src/workspace.cc: Introduced sensor_response_array, sensor_response_index, sensor_response_f_array, sensor_response_pol_array, sensor_response_za_array and sensor_response_aa_array 2011-09-14 Gerrit Holl * arts-2-0-7 * src/m_montecarlo.cc(MCGeneral): Bugfix - Move check for g==0 to outside if...else block checking for different scenarios; this is problematic in any case. * src/montecarlo.cc(mcPathTraceGeneral): Bugfix - Don't calculate log(exp(very_negative_number)), result might become 0, causing problems later. Use the very_negative_number directly instead. 2011-09-11 Patrick Eriksson * arts-2-0-6 * src/agendas.cc: Added sensor_response_agenda. * src/m_rte.cc (yCalc2): A version of yCalc using sensor_response_agenda. Not yet activated (just backup of the coding so far). 2011-09-09 Oliver Lemke * arts-2-0-5 * src/matpackII.cc: Fix bug in Sparse copy constructor. Crashed when trying to copy empty Sparse matrices. * src/xml_io_instantiation.h, src/array.h, src/xml_io_array_types.cc, src/xml_io_types.h, src/groups.cc, src/nc_io_array_types.cc: Add ArrayOfSparse. 2011-09-08 Gerrit Holl * arts-2-0-4 * src/m_montecarlo.cc (MCGeneral): Bugfix - If the lowest layer has large extent and a thick cloud, g may be 0 due to underflow, but then I_i should be 0 as well. Don't turn it into nan for no reason! 2011-09-08 Patrick Eriksson * arts-2-0-3 * src/m_jacobian.cc (jacobianCalcPolyfit): Improved error message. 2011-09-05 Oliver Lemke * arts-2-0-2 * src/arts.{h,cc}: Add ArtsOut parameter to arts_exit_with_error_message and exit_or_rethrow. Fixes a bug reported by Gerrit where runtime error output only ended up on stderr but was missing from the rep file. * src/main.cc, src/m_atmosphere.cc (batch_atm_fields_compactFromArrayOfMatrix), src/m_agenda.cc (Arts, Arts2), src/absorption.{h,cc} (xsec_species), src/m_abs_lookup.cc (abs_lookupCreate), src/m_batch.cc (ybatchCalc): Pass out0 to arts_exit_with_error_message and exit_or_rethrow. * src/m_abs.cc (abs_xsec_per_speciesAddLines), src/absorption.{h,cc} (xsec_species), Add verbosity argument to xsec_species. * rte.{h,cc} (iyb_calc), src/m_jacobian.cc: Add verbosity argument to iyb_calc. * src/groups.cc (get_wsv_group_ids): Removed unused variable it. * doc/arts-splash.gif: Remove 'pre2.0'. 2011-09-05 Oliver Lemke * arts-2-0-1 * src/arts.h: Change ARTS-1-1-x -> ARTS-2 in doc header. * src/docserver.{cc,h}, src/main.cc: Refactor docserver into a class. * src/methods.h, src/methods_aux.cc: Add declarations for format_paragraph and get_short_wsv_description. 2011-09-02 Oliver Lemke * arts-2-0-0 * ChangeLog: ARTS-2 release!