From a1e5a512c63eb6bebad6a14f725aed887ea288b4 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Fri, 16 Oct 2026 12:13:53 +0900 Subject: [PATCH 01/11] fix: whole error messages and accurate diagnostics - Failure messages were cut off on their way to the user (a tensile_safety failure ended mid-advice): message buffers below 1024 characters are widened along every path, the C API keeps up to 4096 characters per handle (CableDyn_GetLastError still truncates to the caller's buffer), the driver's ErrMsg holds 4096 and the OpenFAST module uses ErrMsgLen. - A weightless line gets an accurate diagnosis: a finite-EI line longer than its span is reported as weightless, with no catenary and able to bow only in compression, instead of "net-heavy ... too long"; an EI = 0 line within a 1e-6 relative band of neutral buoyancy is rejected at its line type as weightless and slack (also in the Python reader), instead of failing later with a generic solver message. - A note when a static state stretches a line beyond maxStrain (10 % when unset); a note per section of at most four segments each longer than a tenth of the line. - The rejections of a shared line between two Coupled points, a finite-EI cable ending on a Connect/Free/Coupled point, a Coupled End A with Connect points, and deck waves/current on a mixed deck now name the unsupported capability and a workaround; an anchor below the seabed names the tolerance rule and the depth to use. Results are unchanged: every example and test deck writes byte-identical outputs, except a neutral EI = 0 deck now rejected at its line type. Signed-off-by: Jae Hoon Seo --- CHANGELOG.md | 35 ++ CMakeLists.txt | 43 ++ app/cabledyn.f90 | 2 +- doc/capi.rst | 4 +- doc/coupling_boundary.md | 2 +- doc/options.rst | 5 +- doc/troubleshooting.rst | 67 ++- python/cabledyn/deck_file.py | 14 +- python/cabledyn/model.py | 4 +- python/tests/test_deck_file.py | 11 + python/tests/test_native_model.py | 15 + src/CableDyn_Assemble.f90 | 8 +- src/CableDyn_CAPI.f90 | 4 +- src/CableDyn_CAPI.h | 2 +- src/CableDyn_CosseratAssemble.f90 | 10 +- src/CableDyn_CosseratDynamic.f90 | 6 +- src/CableDyn_CosseratEMC.f90 | 8 +- src/CableDyn_CosseratStatic.f90 | 4 +- src/CableDyn_CoupledPlatform.f90 | 6 +- src/CableDyn_DeckDriver.f90 | 539 ++++++++++++------ src/CableDyn_Driver.f90 | 4 +- src/CableDyn_Dynamic.f90 | 8 +- src/CableDyn_FiniteEIModel.f90 | 6 +- src/CableDyn_FiniteEIStatic.f90 | 4 +- src/CableDyn_HermiteArch.f90 | 2 +- src/CableDyn_HermiteCable.f90 | 6 +- src/CableDyn_HermiteCableDynamic.f90 | 68 +-- src/CableDyn_HermiteCableStatic.f90 | 40 +- src/CableDyn_HermiteTorsion.f90 | 8 +- src/CableDyn_Modal.f90 | 6 +- src/CableDyn_Model.f90 | 50 +- src/CableDyn_OpenFAST_Aggregate.f90 | 36 +- src/CableDyn_OpenFAST_FMF.f90 | 10 +- src/CableDyn_OpenFAST_HermiteFMF.f90 | 46 +- src/CableDyn_OpenFAST_Mesh.f90 | 4 +- src/CableDyn_RangeOutput.f90 | 2 +- src/CableDyn_Static.f90 | 24 +- src/CableDyn_StreamWave.f90 | 2 +- src/CableDyn_Syrope.f90 | 2 +- src/CableDyn_System.f90 | 64 +-- src/openfast/CableDyn_OF.f90 | 30 +- tests/data/msg_anchor_below_seabed.dat | 35 ++ tests/data/msg_coarse_section.dat | 37 ++ .../data/msg_mixed_connect_coupled_cable.dat | 64 +++ tests/data/msg_mixed_current.dat | 58 ++ tests/data/msg_pliant_connect_end_b.dat | 56 ++ tests/data/msg_shared_line.dat | 35 ++ tests/data/msg_static_strain.dat | 35 ++ tests/data/msg_tensile_safety_motion.txt | 346 +++++++++++ tests/data/msg_tensile_safety_truncated.dat | 35 ++ tests/data/msg_weightless_ei0.dat | 35 ++ tests/data/msg_weightless_finite_ei.dat | 37 ++ 52 files changed, 1559 insertions(+), 425 deletions(-) create mode 100644 tests/data/msg_anchor_below_seabed.dat create mode 100644 tests/data/msg_coarse_section.dat create mode 100644 tests/data/msg_mixed_connect_coupled_cable.dat create mode 100644 tests/data/msg_mixed_current.dat create mode 100644 tests/data/msg_pliant_connect_end_b.dat create mode 100644 tests/data/msg_shared_line.dat create mode 100644 tests/data/msg_static_strain.dat create mode 100644 tests/data/msg_tensile_safety_motion.txt create mode 100644 tests/data/msg_tensile_safety_truncated.dat create mode 100644 tests/data/msg_weightless_ei0.dat create mode 100644 tests/data/msg_weightless_finite_ei.dat diff --git a/CHANGELOG.md b/CHANGELOG.md index d1b295a8..449c32b7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -593,6 +593,41 @@ All notable changes to CableDyn are recorded in this file. The format follows turning by 2.3° per step and paid out at 0.05 m/s, the sub-stepped march equals one taken as given at a quarter of the step to 3e-8 N; applying the whole change in the first sub-step departs from it by 22 N. +- Failure messages are no longer cut off by fixed-size buffers. The tensile qualification + failure of a dynamic step ended mid-advice (`... at element 64, xi= 0.5000; increase`) because + the buffers that carried it from the Hermite cable through the OpenFAST module and the deck + driver held 200, 300 and 256 characters. Every message buffer of the solver chain, the + C API handle (now 4096 characters; `CableDyn_GetLastError` still truncates to the caller's + buffer, and the Python binding reads 4097 bytes), the standalone driver and the OpenFAST + glue is now long enough for the longest diagnostic. Results do not change. +- A neutrally buoyant line is named as such. A finite-EI line whose net weight is zero and that + is longer than its span was reported as "the net-heavy line is too long for its span to hang + as a catenary", which is not the cause; the message now says the line is weightless, has no + catenary, and could only bow under axial compression, and advises shortening it to its span + or giving it weight or tension. An `EI = 0` line type whose mass equals the displaced water + mass to seven digits passed the net-buoyant gate on rounding and then failed with a generic + non-convergence message; the gate now treats a relative 1e-6 band around the displaced mass as + neutral and rejects it at the line type with "weightless and slack: its static shape is + indeterminate". The Python deck reader applies the same band. A line type heavier than the band + is unaffected. +- A line stretched far beyond its elastic range now says so. A line 50 % shorter than its span + converged at 100 % strain and 1.2 GN with no message, because `maxStrain` guards only the + dynamics. The initialisation report notes the static fairlead strain (tension over the EA of + the End A section) above `maxStrain` when the option is given, and above 10 % when it is not. + Only a note: the equilibrium and the outputs are unchanged. +- A section too coarse for its line is warned about. The coarse-mesh warning fired only for a line + with fewer than three segments in all, so a 100 m one-segment top section on a 520 m line + (fairlead tension off by 50 %) passed silently. Every section of at most four segments whose + segments are longer than 10 % of the line now gets a warning, for `EI = 0` and finite-EI lines, + in the single-topology driver and in the standalone mixed route. +- Rejection messages name the unsupported capability and the workaround. A line between two + Coupled points suggests splitting it at a `Connect` point; a finite-EI cable ending on a + `Connect`/`Free`/`Coupled` point, or driven from a Coupled End A in a deck with `Connect`/`Free` + points, names the point and what the route supports; the "this coupled mode runs the mooring in + STILL WATER" message of a mixed deck with waves or current no longer implies a coupled run and + says which routes evaluate the deck fluid; an anchor below the seabed by more than the + tolerance gives the depth, the tolerance rule, and the Z to use. These messages change no + acceptance rule. - The development environment (`environment.yml`) excludes OpenBLAS 0.3.34, which caused the access violation in the modal analysis tests listed under Known issues for 0.1.1. On AMD Zen 4 and Zen 5 CPUs that expose AVX-512, OpenBLAS 0.3.34 enlarges the GEMM blocking, diff --git a/CMakeLists.txt b/CMakeLists.txt index 20a5e70a..60dd22e2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2195,6 +2195,49 @@ add_test(NAME driver_lazy_wave_planar_refined_att_quiet set_tests_properties(driver_lazy_wave_planar_refined_att_quiet PROPERTIES LABELS "fortran;driver;integration;static") +# Diagnostics that name the cause and the remedy. Each deck below was rejected by a message that +# named the wrong cause or none, or ran with no warning, before the message was written. +function(cabledyn_msg_test name deck rc must_match must_not) + add_test(NAME driver_msg_${name} + COMMAND ${CMAKE_COMMAND} -DDRIVER=$ -DEXPECT_RC=${rc} + "-DARGS=${CMAKE_CURRENT_SOURCE_DIR}/tests/data/${deck}|msg" + "-DMUST_MATCH=${must_match}" "-DMUST_NOT=${must_not}" + -DWORKDIR=${CMAKE_CURRENT_BINARY_DIR}/driver_msg_${name} + -P ${CMAKE_CURRENT_SOURCE_DIR}/tests/check_driver_output.cmake) + set_tests_properties(driver_msg_${name} PROPERTIES LABELS "fortran;driver;integration;static") +endfunction() +# A neutrally buoyant finite-EI line longer than its span has no catenary and no tension-only bow. +cabledyn_msg_test(weightless_finite_ei msg_weightless_finite_ei.dat 2 + "weightless .neutrally buoyant. line is longer than its span;shorten the line to its span, or give it net weight" + "net-heavy") +# An EI=0 line whose mass equals the displaced water mass to seven digits is weightless and slack. +cabledyn_msg_test(weightless_ei0 msg_weightless_ei0.dat 1 + "is net-buoyant to within 1e-6;weightless and slack: its static shape is indeterminate" "") +# A line half the length of its span converges at 100 % strain; the static solve says so. +cabledyn_msg_test(static_strain msg_static_strain.dat 0 + "Note: LINE 1 is stretched to a static strain of 100.0 % at the fairlead;the static default" "") +# A 100 m one-segment top section of a 520 m line. +cabledyn_msg_test(coarse_section msg_coarse_section.dat 0 + "WARNING: LINE 1 section of type \"chain\" .100.00 m in 1 segment.s.. has segments of 100.00 m, 19.2 %" "") +# A well-meshed line with a modest stretch raises neither. +cabledyn_msg_test(quiet_catenary ../../examples/chain_catenary_r3_100m.dat 0 "" + "static strain;too coarse to follow") +cabledyn_msg_test(shared_line msg_shared_line.dat 1 + "LINE 1 End B .NodeB, POINT 2, coupled. must be a Fixed .anchor. point;split it into two lines that meet at a Connect point" "") +cabledyn_msg_test(pliant_connect_end_b msg_pliant_connect_end_b.dat 1 + "finite-EI LINE 1 in a mixed-topology deck needs a Fixed End B;End B is POINT 2 .connect.;Anchor the cable on a Fixed point" + "") +cabledyn_msg_test(mixed_current msg_mixed_current.dat 1 + "the deck current OPTION is not supported on this route;a standalone mixed deck;runs the mooring in STILL WATER" + "this coupled mode") +cabledyn_msg_test(mixed_connect_coupled_cable msg_mixed_connect_coupled_cable.dat 1 + "finite-EI LINE 3: a Coupled/Vessel End A .POINT 1. is driven by a motionFile;Remove the Connect/Free points" "") +# The tensile qualification failure of a dynamic step names the remedy to the end (the message was +# cut at 256 characters: "... at element 64, xi= 0.5000; increase"). +cabledyn_msg_test(tensile_safety_whole msg_tensile_safety_truncated.dat 2 + "tensile qualification failed;at element 64, xi= 0.5000; increase tensile_strain_tolerance only with an engineering basis, or use warn mode" "") +cabledyn_msg_test(anchor_below_seabed msg_anchor_below_seabed.dat 1 + "POINT 2 .Fixed. lies below the seabed;by 1.00E-02 m, more than the 1.00E-03 m seabed tolerance;Set the anchor Z to -100.00000 m" "") if(WIN32 AND CABLEDYN_RUNTIME_DLLS) add_test( NAME windows_install_runtime diff --git a/app/cabledyn.f90 b/app/cabledyn.f90 index 8cf7357d..eb15bb75 100644 --- a/app/cabledyn.f90 +++ b/app/cabledyn.f90 @@ -66,7 +66,7 @@ PROGRAM cabledyn LOGICAL :: profile_cable_detail = .FALSE. ! Sized for the aggregate and deck-driver messages it relays (512-character buffers ! plus deck-line context), so no diagnostic is cut short. - CHARACTER(1024) :: ErrMsg + CHARACTER(4096) :: ErrMsg nargs = COMMAND_ARGUMENT_COUNT() diff --git a/doc/capi.rst b/doc/capi.rst index c0cafceb..76d247a5 100644 --- a/doc/capi.rst +++ b/doc/capi.rst @@ -382,7 +382,7 @@ A step that finishes without meeting the Newton tolerance still returns ``CD_C_O Diagnostics ~~~~~~~~~~~ -Each handle keeps the text of its last failure, up to 1024 characters. The message is set by a +Each handle keeps the text of its last failure, up to 4096 characters. The message is set by a failing call on a valid handle and cleared by a successful one. ``CableDyn_GetLastError`` does not change it, and neither does ``CableDyn_IsInitialized``. A call rejected with ``CD_C_BAD_HANDLE`` has no handle to store a message in. ``CableDyn_GetLastError`` on such a @@ -1688,7 +1688,7 @@ before the copy and stay zero if the call fails. The model is not changed. - -- - -- - buffer capacity in bytes. A value below 1 makes the call a no-op. A message is at most - 1024 characters, so a buffer of 1025 bytes always holds the full message and its + 4096 characters, so a buffer of 4097 bytes always holds the full message and its terminating ``NUL``. State and size queries diff --git a/doc/coupling_boundary.md b/doc/coupling_boundary.md index 5f4e36e4..14725a37 100644 --- a/doc/coupling_boundary.md +++ b/doc/coupling_boundary.md @@ -96,7 +96,7 @@ Rules shared by every entry point: xyz triples; connectivity and fixed-DOF indices are 1-based. - Calls with an `err_stat` argument return `CD_C_OK`, `CD_C_BAD_HANDLE`, `CD_C_ALLOC_FAIL`, `CD_C_BAD_INPUT`, `CD_C_SOLVE_FAIL`, or `CD_C_NOT_INITIALIZED`. Diagnostics are kept per handle - (up to 1024 characters) and copied by `CableDyn_GetLastError`. + (up to 4096 characters) and copied by `CableDyn_GetLastError`. - `CableDyn_NPoints` returns the column count expected by `CableDyn_UpdatePointFluidFields`; it can exceed `NCoupledDOF/3` when a deck has output-only fixed or coupled points. - Deck initialisation is transactional: a failed `CableDyn_InitDeck` or `CableDyn_InitDeckAt` diff --git a/doc/options.rst b/doc/options.rst index f01f4ee6..18d61528 100644 --- a/doc/options.rst +++ b/doc/options.rst @@ -317,7 +317,10 @@ rejected as unknown. The dynamic Newton controls are set with ``dynamic_solver`` strain of steel, polyester, and nylon lines), stops the run with exit code 2 and a message naming the line, element, strain, estimated elastic tension, and time. It catches a numerically unstable march whose Newton residual still converges; a physical run never - reaches the default. Finite-EI cables are guarded by ``tensile_safety`` instead + reaches the default. Finite-EI cables are guarded by ``tensile_safety`` instead. The static solve is not + stopped by it: when the static fairlead strain (tension over the EA of the End A section) + exceeds this value, or 10 % when the OPTION is not given, the run prints a ``Note`` and + continues - both (``EI = 0`` lines) - ``0.5 maxStrain`` * - ``dynamic_solver rel abs max_iter backtracks [rhoInf]`` diff --git a/doc/troubleshooting.rst b/doc/troubleshooting.rst index b7e0c42b..b469ff46 100644 --- a/doc/troubleshooting.rst +++ b/doc/troubleshooting.rst @@ -61,6 +61,10 @@ Auxiliary files use their own label in place of ``deck`` (for example ``motionFi instead: a duplicate or undefined id is quoted in the message (``duplicate POINT id 4``, ``LINE 2 references undefined POINT id 9``). +A solver failure message is not cut off by a fixed-size buffer: it can run to several hundred characters (the tensile +qualification failure of a dynamic step names the element, the force, its limit, and the remedy), +the driver prints it whole, and the C API retains up to 4096 characters per handle. + .. _deck-rejected: A deck is rejected (exit 1) @@ -253,10 +257,38 @@ Model data - End A is the fairlead/upper end. A stock anchor-first row (``Fixed`` NodeA, fairlead NodeB) is swapped automatically; this message means the fairlead point itself lies below the anchor. Check the point coordinates. - * - ``LINE End A (NodeA) must be Coupled/Vessel/Body ...`` / ``LINE End B (NodeB) must be a - Fixed (anchor) point`` - - in a deck without dynamic points every line runs from a fairlead to an anchor. Use - ``Connect``/``Free`` points for line-to-line junctions. + * - ``LINE End A (NodeA) must be Coupled/Vessel/Body ...`` / ``LINE End B (NodeB, POINT + , ) must be a Fixed (anchor) point`` + - in a deck without dynamic points every line runs from a fairlead to an anchor. A line + between two Coupled points (a shared line) is supported only between two ``Turbine`` + fairleads of a FAST.Farm deck. Split it into two lines that meet at a ``Connect`` point + in the middle; each line then ends on one Coupled point, and the deck becomes dynamic and + needs ``dtM`` and ``TMax``. + * - ``finite-EI LINE in a mixed-topology deck needs a Fixed End B ... End B is POINT + ()`` + - a deck with ``Connect``/``Free`` points, bodies or rods that also has finite-EI cables drives + each cable at End A, so End B must be a ``Fixed`` point. A cable that ends on a ``Connect``/``Free``/``Coupled`` + point (a junction with other lines, a buoy, a pliant-wave hang-off) is not supported in a + deck with ``Connect``/``Free`` points, bodies or rods, which is marched as one multibody + system. Anchor the cable on a Fixed point, or run the cable and the lines it joins as + separate decks. + * - ``finite-EI LINE : a Coupled/Vessel End A (POINT ) is driven by a motionFile`` + - a mixed-topology deck that has ``Connect``/``Free`` points or bodies is marched as one + multibody system, which does not take a finite-EI cable on a Coupled End A (that end + would need ``motionFile`` coupling). Remove the ``Connect``/``Free`` points so the deck + runs as a coupled mixed deck (the ``EI = 0`` lines on the Coupled point directly), or + attach the cable to a Rigid6 body, a rod end or a Fixed point. + * - ``the deck current OPTION is not supported on this route`` / ``the deck waves OPTION ...`` + - a mixed ``EI = 0``/finite-EI deck (run standalone, through the C API, OpenFAST or + FAST.Farm) runs the mooring in still water: no ambient fluid field covers its span, and + a coupled host supplies its own waves and current. Remove the ``waves``/``current`` + OPTION, run a deck whose lines are all ``EI = 0`` or all finite-EI (those standalone + routes evaluate the deck waves and current), or let the OpenFAST host supply them. + * - ``POINT (Fixed) lies below the seabed ... by m, more than the m seabed + tolerance`` + - a Fixed anchor within ``max(1 mm, 1e-5 |z_seabed|)`` of the seabed (``-WtrDpth``, or the + bathymetry surface) rests on it and is placed on it. A deeper anchor is never moved + silently: set its ``Z`` to the seabed elevation named in the message, or higher. * - ``finite-EI section (EI>0) requires a dynamic deck with dtM and TMax`` - a single-family finite-EI deck is solved by the dynamic finite-EI workflow. Add ``dtM``/``TMax`` (``TMax = 0`` gives the static configuration only). @@ -265,6 +297,12 @@ Model data route — a lazy-wave arch needs the finite-EI path. Give the buoyant section an ``EI > 0`` line type, or specify it by target submerged weight (the ``EQUIVALENT BUOYANCY`` block in :doc:`driver_format`). + * - ``is net-buoyant to within 1e-6 (neutrally buoyant ...)`` + - an ``EI = 0`` line type whose dry mass equals the displaced water mass (to a relative + 1e-6, the precision of a typed mass) has no net weight. A slack line of it is weightless + and its static shape is indeterminate (every slack shape balances). Give the line type + weight (a larger ``MassDenInAir``), or use a finite ``EI`` with a tension that holds the + line taut. * - ``the viscoelastic dynamic stiffness Ed (EA = Es|Ed) must be finite and exceed the static Es`` - ``Ed`` must be strictly greater than ``Es``; equal values make the series spring infinite. @@ -438,6 +476,14 @@ but a few geometries are genuinely hard: - **A large grounded touchdown on the** ``EI = 0`` **path.** A long, near-horizontal grounded run can make the linear-Lagrange tangent singular regardless of seed. If the case is a lazy-wave or bending-dominated cable, use the finite-EI path (``EI > 0``), which is built for it. +- **A weightless finite-EI line longer than its span.** ``the weightless (neutrally buoyant) + line is longer than its span`` means every element has zero net weight (to a relative 1e-6 of + its displaced weight, attachments included). Such a line has no catenary: with no weight a + tension-only line is straight, and a longer one could only bow by bending under axial + compression, which a cable does not carry. Shorten the line to its span, or give it net weight + (a larger ``MassDenInAir``, or clumps) or a tension that holds it taut. A line heavier than + water with the same symptom gets ``the net-heavy line is too long for its span to hang as a + catenary`` instead. - **A finite-EI lazy-wave cable at too coarse a mesh.** An under-resolved arch or touchdown carries a large element ``h·κ`` and can stall the dynamic Newton. The resolution metric flags this; the builder can auto-refine a fragile mesh when the deck opts in (``adaptive_mesh True``). @@ -557,6 +603,19 @@ Warnings and notes that do not stop a run raise ``NX``, ``NY``, ``NZ`` to keep the spacing. A SeaState file written for the platform alone, such as the r-test ``MD_Shared`` file, triggers it. See :ref:`openfast:SeaState grid` for sizes and memory. + * - ``Note: LINE is stretched to a static strain of ... % at the fairlead`` + - the fairlead tension over the EA of the End A section exceeds ``maxStrain`` (when the + OPTION is given) or 10 % (when it is not). A line far shorter than its span converges at + such a strain without failing, because the dynamic ``maxStrain`` guard does not apply to + the static solve. Check the line length against the span and the EA. Only a note: the + equilibrium and the outputs are unchanged. Types with a Syrope working curve or a + load-dependent stiffness are not assessed. + * - ``WARNING: LINE section of type "" (... m in segment(s)) has segments of ... + m, ... % of the line length`` + - a section of at most four segments whose segments are longer than 10 % of the line is too + coarse to follow the line shape there; a 100 m one-segment top section of a 520 m line shifts the fairlead tension + by tens of percent. Refine its ``NumSegs``. (A line with fewer than three segments in all + is reported whole.) * - ``WARNING: line type ... sinks ... m into the seabed ...; kBot is soft for this line`` - a grounded run of this type would sink deeper than its own diameter into the penalty seabed. Raise ``kBot``; the default ``1.0e5`` embeds a heavy chain by about half its diff --git a/python/cabledyn/deck_file.py b/python/cabledyn/deck_file.py index e2a92563..9c01bef0 100644 --- a/python/cabledyn/deck_file.py +++ b/python/cabledyn/deck_file.py @@ -300,6 +300,9 @@ _NATIVE_MAX_COORDINATE = 1.0e6 _NATIVE_MAX_COEFFICIENT = 1.0e15 _NATIVE_MAX_SMALL_COEFFICIENT = 1.0e3 +# Relative band around the displaced water mass within which a line type is neutrally buoyant +# (the native NEUTRAL_BUOYANCY_REL_TOL). +_NATIVE_NEUTRAL_BUOYANCY_REL_TOL = 1.0e-6 _NATIVE_MIN_EA = 1.0e-3 _NATIVE_MIN_DIAMETER = 1.0e-6 _NATIVE_MAX_GRAVITY = 1.0e3 @@ -3603,9 +3606,18 @@ def is_body_kind(kind: str, pinned: bool) -> bool: # Native net-buoyancy gate: an EI=0 route cannot build a buoyant # (lazy-wave) arch, so a used section whose dry mass does not exceed # its displaced water mass needs a dynamic finite-EI line type. - if mass <= water_density * (math.pi / 4.0) * diameter**2 and ( + displaced_mass = water_density * (math.pi / 4.0) * diameter**2 + if mass <= displaced_mass * (1.0 + _NATIVE_NEUTRAL_BUOYANCY_REL_TOL) and ( ei <= 0.0 or not (has_dtm or self.caller_driven or mixed_static) ): + if ei <= 0.0 and mass > displaced_mass * (1.0 - _NATIVE_NEUTRAL_BUOYANCY_REL_TOL): + raise DeckFormatError( + f"{self._label}: used LINE TYPE {line_type!r} is net-buoyant to within " + "1e-6 (neutrally buoyant: its dry mass equals the displaced water mass), " + "so an EI=0 line of it is weightless and slack: its static shape is " + "indeterminate (every slack shape balances). Give the line type weight " + "(a larger MassDenInAir), or a finite EI with a tension that holds it taut" + ) raise DeckFormatError( f"{self._label}: used LINE TYPE {line_type!r} is net-buoyant (dry mass <= " "displaced water mass): buoyant / lazy-wave sections require a dynamic " diff --git a/python/cabledyn/model.py b/python/cabledyn/model.py index 8cf17336..bc55aea1 100644 --- a/python/cabledyn/model.py +++ b/python/cabledyn/model.py @@ -37,8 +37,8 @@ FloatArray = npt.NDArray[np.float64] ArrayInput = npt.ArrayLike -# The C library retains up to 1024 characters per handle; +1 for the NUL. -_MESSAGE_BUFFER = 1025 +# The C library retains up to 4096 characters per handle; +1 for the NUL. +_MESSAGE_BUFFER = 4097 def _as_real_array(x: ArrayInput, name: str) -> FloatArray: diff --git a/python/tests/test_deck_file.py b/python/tests/test_deck_file.py index 62a65f6c..708990c5 100644 --- a/python/tests/test_deck_file.py +++ b/python/tests/test_deck_file.py @@ -4,6 +4,7 @@ from __future__ import annotations import json +import math import os import re from pathlib import Path @@ -2972,6 +2973,16 @@ def test_net_buoyant_ei0_line_type_fails_like_native(tmp_path, mass): DeckFile.read(path) +@pytest.mark.parametrize("scale", [1.0, 1.0 + 1.0e-7, 1.0 - 1.0e-7]) +def test_neutrally_buoyant_ei0_line_type_is_weightless_and_slack(tmp_path, scale): + # A mass typed to seven digits does not cancel the displaced mass exactly; the gate treats + # the 1e-6 band around it as neutral and says the slack line is indeterminate. + mass = 1025.0 * math.pi / 4.0 * 0.2466**2 * scale + path = _chain_variant(tmp_path, ("0.2466 373.5 ", f"0.2466 {mass:.9f} ")) + with pytest.raises(DeckFormatError, match="weightless and slack"): + DeckFile.read(path) + + @pytest.mark.parametrize(("weight", "buoyant"), [("100.0", False), ("-100.0", True)]) def test_net_buoyancy_uses_the_equivalent_buoyancy_conversion(tmp_path, weight, buoyant): section = ( diff --git a/python/tests/test_native_model.py b/python/tests/test_native_model.py index cc3a50fe..bb258212 100644 --- a/python/tests/test_native_model.py +++ b/python/tests/test_native_model.py @@ -370,3 +370,18 @@ def test_home_relative_deck_path_is_expanded(tmp_path, monkeypatch): monkeypatch.setenv("USERPROFILE", str(tmp_path)) with cabledyn.CableDyn("~/volturnus.dat") as m: assert m.deck == deck.resolve() + + +def test_long_failure_message_is_kept_whole(): + # The weightless-line diagnosis names the cause, three nested solver reasons, and the + # remedy; it is longer than the 1024 characters the handle once retained, and its closing + # advice must reach the caller. + deck = REPO / "tests" / "data" / "msg_weightless_finite_ei.dat" + with cabledyn.CableDyn() as m: + with pytest.raises(CableDynError) as caught: + m.init_deck(deck) + detail = caught.value.detail + assert len(detail) > 1024 + assert "weightless (neutrally buoyant) line is longer than its span" in detail + assert detail.endswith("or a tension that holds it taut") + assert "net-heavy" not in detail diff --git a/src/CableDyn_Assemble.f90 b/src/CableDyn_Assemble.f90 index 9e2e4f07..9f2561e1 100644 --- a/src/CableDyn_Assemble.f90 +++ b/src/CableDyn_Assemble.f90 @@ -99,7 +99,7 @@ SUBROUTINE CD_Assemble_Cable_Tangent_Force(nodes, elem_conn, l0, ea, & INTEGER :: n_nodes, n_elem, e, a, b, ia, ib, i, j, es REAL(wp) :: nodes6(6), Kt6(6, 6), fint6(6), Te - CHARACTER(120) :: em + CHARACTER(1024) :: em Kt = CD_ZERO fint = CD_ZERO @@ -277,7 +277,7 @@ SUBROUTINE assemble_elements(g2f) INTEGER, INTENT(IN) :: g2f(:) INTEGER :: e, a, b, i, j, fi, fj, row, gmap(6), elem_es REAL(wp) :: nodes6(6), Kt6(6, 6), fint6(6), Te - CHARACTER(120) :: em + CHARACTER(1024) :: em DO e = 1, n_elem a = elem_conn(1, e) @@ -342,7 +342,7 @@ SUBROUTINE CD_Assemble_Cable_Internal_Force(nodes, elem_conn, l0, ea, tension_on REAL(wp), ALLOCATABLE :: fe(:, :) INTEGER, ALLOCATABLE :: elem_es(:) INTEGER :: n_team - CHARACTER(120) :: em + CHARACTER(1024) :: em fint = CD_ZERO CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) @@ -428,7 +428,7 @@ SUBROUTINE CD_Compute_Cable_Tension(nodes, elem_conn, l0, ea, tension_only, & REAL(wp), ALLOCATABLE :: te_buf(:) INTEGER, ALLOCATABLE :: elem_es(:) INTEGER :: n_team - CHARACTER(120) :: em + CHARACTER(1024) :: em tension = CD_ZERO CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) diff --git a/src/CableDyn_CAPI.f90 b/src/CableDyn_CAPI.f90 index b2455028..ab228e3a 100644 --- a/src/CableDyn_CAPI.f90 +++ b/src/CableDyn_CAPI.f90 @@ -92,7 +92,7 @@ MODULE CableDyn_CAPI CD_C_LINE_DECLINATION = 7_C_INT, CD_C_LINE_AZIMUTH = 8_C_INT, & CD_C_LINE_SEGMENT_TENSION = 9_C_INT, CD_C_LINE_DECK_NODE = 10_C_INT !> Capacity of the per-handle diagnostic retained for CableDyn_GetLastError. - INTEGER, PARAMETER :: CD_C_MSG_LEN = 1024 + INTEGER, PARAMETER :: CD_C_MSG_LEN = 4096 ! Live-handle integrity. A handle is valid only if its C_PTR is in the registry of ! handles this module created and has not closed (so a foreign, stale, or @@ -2682,7 +2682,7 @@ END SUBROUTINE init_one_raw_model SUBROUTINE end_temp_models(models) TYPE(CD_ModelType), INTENT(INOUT) :: models(:) INTEGER :: i, es - CHARACTER(120) :: em + CHARACTER(1024) :: em DO i = 1, SIZE(models) CALL CD_End_Model(models(i), es, em) diff --git a/src/CableDyn_CAPI.h b/src/CableDyn_CAPI.h index ed888f9f..8c5de611 100644 --- a/src/CableDyn_CAPI.h +++ b/src/CableDyn_CAPI.h @@ -16,7 +16,7 @@ * indices are 1-based. The Jacobians written by * CableDyn_CalcOutputDerivatives are n-by-n column-major: * J[i + j*n] = d(load_i)/d(q_j). - * - Diagnostics are retained per handle (up to 1024 characters) and copied by + * - Diagnostics are retained per handle (up to 4096 characters) and copied by * CableDyn_GetLastError, truncated to message_len - 1 and NUL-terminated. * - Create and Close are thread-safe. InitDeck, InitDeckAt, InitLine, and * InitLines are serialised process-wide (they parse files through the Fortran diff --git a/src/CableDyn_CosseratAssemble.f90 b/src/CableDyn_CosseratAssemble.f90 index f6472df8..666cc4d0 100644 --- a/src/CableDyn_CosseratAssemble.f90 +++ b/src/CableDyn_CosseratAssemble.f90 @@ -56,7 +56,7 @@ MODULE CableDyn_CosseratAssemble REAL(wp), ALLOCATABLE :: fe(:, :) REAL(wp), ALLOCATABLE :: Ke(:, :, :) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(120), ALLOCATABLE :: elem_em(:) + CHARACTER(512), ALLOCATABLE :: elem_em(:) END TYPE CD_CosseratAssemblyWorkspace CONTAINS @@ -94,8 +94,8 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force(nodes_ref, elem_conn, ea, gas, ei, REAL(wp) :: Lam0(3, 3), L0, qe(12), Kte(12, 12), finte(12) REAL(wp), ALLOCATABLE :: fe(:, :), Ke(:, :, :) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(120), ALLOCATABLE :: elem_em(:) - CHARACTER(120) :: em + CHARACTER(512), ALLOCATABLE :: elem_em(:) + CHARACTER(1024) :: em CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -271,7 +271,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force_Banded_Free_Workspace(nodes_ref, e LOGICAL :: apply_chain INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), Kte(12, 12), finte(12) - CHARACTER(120) :: em + CHARACTER(1024) :: em CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -415,7 +415,7 @@ SUBROUTINE CD_Assemble_Cosserat_Internal_Force_Workspace(nodes_ref, elem_conn, e INTEGER :: n_nodes, n_elem, e, a, b, ndof, gmap(12), i, es INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), finte(12) - CHARACTER(120) :: em + CHARACTER(1024) :: em CD_COSASM_N_FORCE = CD_COSASM_N_FORCE + 1 CALL SYSTEM_CLOCK(c0, rate) diff --git a/src/CableDyn_CosseratDynamic.f90 b/src/CableDyn_CosseratDynamic.f90 index a600dedf..9e19f406 100644 --- a/src/CableDyn_CosseratDynamic.f90 +++ b/src/CableDyn_CosseratDynamic.f90 @@ -205,7 +205,7 @@ SUBROUTINE CD_Cosserat_Mechanical_Energy(nodes_ref, elem_conn, ea, gas, ei, gj, REAL(wp) :: Lam0(3, 3), L0, qe(12), Is(3, 3), om(3), w REAL(wp), ALLOCATABLE :: mv(:), v_trans(:) LOGICAL :: mult_e - CHARACTER(120) :: em + CHARACTER(1024) :: em strain_e = CD_ZERO; kinetic_e = CD_ZERO; ErrStat = CD_DYN_OK; ErrMsg = '' IF (SIZE(nodes_ref, 1) /= 3 .OR. SIZE(elem_conn, 1) /= 2) THEN ErrStat = CD_DYN_BADINPUT; ErrMsg = 'CD_Cosserat_Mechanical_Energy: nodes_ref (3,*) / elem_conn (2,*)' @@ -860,7 +860,7 @@ SUBROUTINE CD_Cosserat_Initial_Acceleration(nodes_ref, elem_conn, ea, gas, ei, g TYPE(CD_CosseratGenAlphaWorkspace), POINTER :: work INTEGER, POINTER :: free(:) REAL(wp), POINTER :: fint(:), rhs(:), M_band(:, :), support_accel(:), support_force(:) - CHARACTER(120) :: em + CHARACTER(1024) :: em a0 = CD_ZERO; ErrStat = CD_DYN_OK; ErrMsg = '' n_dof = SIZE(q) IF (MOD(n_dof, 6) /= 0 .OR. n_dof < 12 .OR. SIZE(f_ext) /= n_dof .OR. SIZE(a0) /= n_dof) THEN @@ -1023,7 +1023,7 @@ SUBROUTINE CD_Cosserat_Gen_Alpha_Step(nodes_ref, elem_conn, ea, gas, ei, gj, rho REAL(wp), ALLOCATABLE :: theta_n_abs(:, :) ! absolute t_n nodal rotations (multiplicative path) REAL(wp), ALLOCATABLE :: rot_chain(:, :, :) ! per-node consistent-tangent chain Jacobian J_c REAL(wp), ALLOCATABLE :: q_cand(:) ! composed end-of-step candidate pose (validation) - CHARACTER(120) :: em + CHARACTER(1024) :: em q_new = CD_ZERO; v_new = CD_ZERO; a_new = CD_ZERO converged = .FALSE.; stalled = .FALSE.; n_iter = 0 diff --git a/src/CableDyn_CosseratEMC.f90 b/src/CableDyn_CosseratEMC.f90 index 80df5df3..8ae47593 100644 --- a/src/CableDyn_CosseratEMC.f90 +++ b/src/CableDyn_CosseratEMC.f90 @@ -170,7 +170,7 @@ SUBROUTINE CD_Cosserat_EMC_Step(nodes_ref, elem_conn, ea, gas, ei, gj, rho_a, i_ REAL(wp) :: th(3), om(3), Om0(3), eps, rnorm, r0, denom INTEGER :: n3 LOGICAL :: cmass - CHARACTER(160) :: em2 + CHARACTER(1024) :: em2 LOGICAL :: ok ErrStat = CD_DYN_OK; ErrMsg = ''; converged = .FALSE.; n_iter = 0 @@ -440,7 +440,7 @@ SUBROUTINE emc_analytic_jacobian(Ptry, Jout, uout, vout, okout) REAL(wp) :: ph(3), pih(3), Oh(3), psi(3), dr(3), thn(3), thh(3), Rdn(3, 3), ejw(3) REAL(wp) :: Wn, W1, dWlin, dq2, corr, KG(6, 6), blk(6, 6), Gg(3, 3), I3(3, 3), I6(6, 6) INTEGER :: a, c, jj, es, k - CHARACTER(240) :: em + CHARACTER(1024) :: em okout = .TRUE.; I3 = diag3([CD_ONE, CD_ONE, CD_ONE]) I6 = CD_ZERO DO k = 1, 6 @@ -587,7 +587,7 @@ SUBROUTINE emc_residual(Ptry, okout, Rout) REAL(wp) :: dw3(n3), mdw(n3) INTEGER :: b, es LOGICAL :: okl - CHARACTER(160) :: em + CHARACTER(1024) :: em okout = .TRUE. ! velocity translational momentum balance uses M3 (w - v_n): assemble the increment matvec IF (cmass) THEN @@ -717,7 +717,7 @@ SUBROUTINE strain_energy(qq, W, okout) LOGICAL, INTENT(INOUT) :: okout REAL(wp) :: se, ke, vv(ndof) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em vv = CD_ZERO CALL CD_Cosserat_Mechanical_Energy(nodes_ref, elem_conn, ea, gas, ei, gj, rho_a, i_rho_t, i_rho_n, & reduced_shear, qq, vv, se, ke, es, em, multiplicative=.TRUE.) diff --git a/src/CableDyn_CosseratStatic.f90 b/src/CableDyn_CosseratStatic.f90 index 9e69ce00..2c88d550 100644 --- a/src/CableDyn_CosseratStatic.f90 +++ b/src/CableDyn_CosseratStatic.f90 @@ -58,7 +58,7 @@ SUBROUTINE CD_Static_Cosserat_Solve(nodes_ref, elem_conn, ea, gas, ei, gj, q0, f REAL(wp), ALLOCATABLE :: Kb(:, :), fint(:), R_free(:), dq(:) REAL(wp), ALLOCATABLE :: dq_global(:), q_trial(:), R_trial(:), fint0(:) REAL(wp) :: f_ext_base, conv_scale, rnorm, merit, merit_trial, alpha, scale_trial - CHARACTER(120) :: em + CHARACTER(1024) :: em converged = .FALSE.; stalled = .FALSE.; n_iter = 0 ErrStat = CD_COS_OK; ErrMsg = '' @@ -179,7 +179,7 @@ SUBROUTINE eval_residual(qe, Rf, sc) REAL(wp), INTENT(OUT) :: Rf(:), sc REAL(wp), ALLOCATABLE :: fint_e(:) INTEGER :: es_e - CHARACTER(120) :: em_e + CHARACTER(1024) :: em_e ALLOCATE (fint_e(n_dof)) CALL CD_Assemble_Cosserat_Internal_Force(nodes_ref, elem_conn, ea, gas, ei, gj, qe, & reduced_shear, fint_e, es_e, em_e) diff --git a/src/CableDyn_CoupledPlatform.f90 b/src/CableDyn_CoupledPlatform.f90 index 887e4ea2..8d82643c 100644 --- a/src/CableDyn_CoupledPlatform.f90 +++ b/src/CableDyn_CoupledPlatform.f90 @@ -68,7 +68,7 @@ SUBROUTINE CD_Fairlead_Solve(seed, elem_conn, l0, ea, tension_only, f_ext, ancho REAL(wp), ALLOCATABLE :: k_rr(:, :), k_rf(:, :), k_fr(:, :), xcol(:) REAL(wp) :: k_ff(3, 3) LOGICAL :: conv, stalled, at_floor - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_PLAT_OK; ErrMsg = '' q = CD_ZERO; g = CD_ZERO; k_fair = CD_ZERO @@ -191,7 +191,7 @@ SUBROUTINE CD_Solve_Platform_Mooring(n_lines, elem_conn, l0, ea, tension_only, f REAL(wp) :: forces(3, n_lines), trial_forces(3, n_lines) REAL(wp) :: merit, merit_trial, alpha, fscale, mscale LOGICAL :: ok, trial_ok - CHARACTER(200) :: em + CHARACTER(1024) :: em REAL(wp), PARAMETER :: ARMIJO_C1 = 1.0e-4_wp ErrStat = CD_PLAT_OK; ErrMsg = '' @@ -333,7 +333,7 @@ SUBROUTINE CD_Platform_Residual_Tangent(pose, n_lines, elem_conn, l0, ea, tensio REAL(wp) :: jac(3, 6), jt_kf(6, 3), geom(3, 3) REAL(wp), ALLOCATABLE :: qline(:) INTEGER :: li, es_l, n_dof - CHARACTER(200) :: em_l + CHARACTER(1024) :: em_l all_ok = .TRUE.; ErrStat = CD_PLAT_OK; ErrMsg = '' residual = CD_ZERO; k_sys = CD_ZERO diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index ed9ed449..7cf11493 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -163,6 +163,16 @@ MODULE CableDyn_DeckDriver INTEGER, PARAMETER :: INSTALLED_SEQUENCE_COARSE_FLOOR = 24 ! Deepest mesh hierarchy CD_HermiteCable_Sequence_* accepts (levels including the user mesh). INTEGER, PARAMETER :: SEQUENCE_MAX_LEVELS = 20 + ! A line type whose dry mass is within this relative band of the displaced water mass is + ! neutrally buoyant: its net weight is zero to within the precision of a typed mass + ! (a mass written to seven digits against a diameter does not cancel exactly). + REAL(wp), PARAMETER :: NEUTRAL_BUOYANCY_REL_TOL = 1.0e-6_wp + ! A section of at most COARSE_SECTION_MAX_SEGS segments, each longer than COARSE_SECTION_FRACTION of its + ! line, is warned about as too coarse (warn_coarse_sections). A static strain above + ! STATIC_STRAIN_NOTE_DEFAULT is noted (static_strain_note) when OPTION maxStrain is not given. + REAL(wp), PARAMETER :: COARSE_SECTION_FRACTION = 0.1_wp + INTEGER, PARAMETER :: COARSE_SECTION_MAX_SEGS = 4 + REAL(wp), PARAMETER :: STATIC_STRAIN_NOTE_DEFAULT = 0.1_wp PUBLIC :: CD_Run_Deck_Driver PUBLIC :: CD_Deck_Equilibrium_Jacobian_Check @@ -539,6 +549,7 @@ MODULE CableDyn_DeckDriver ! Per-step plausibility guard (OPTION maxStrain): a committed dynamic state with any ! element stretched beyond this strain (or non-finite) fails the run; 0 disables. REAL(wp) :: max_strain = 0.5_wp + LOGICAL :: has_max_strain = .FALSE. ! WaveKinMod-1 elevation history reduced once to its real Fourier components. ! These feed the same arbitrary-component Airy kernel used by reference-matched ! irregular seas; wave_eta_mean carries the zero-frequency waterline offset. @@ -1247,7 +1258,7 @@ SUBROUTINE init_deck_models_from_parsed(types, points, lines, sections, opts, mo TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: i, es - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -1295,7 +1306,7 @@ SUBROUTINE init_deck_system_from_parsed(types, points, lines, sections, opts, sy TYPE(CD_LineEndpointBinding), ALLOCATABLE :: bindings(:) TYPE(DeckPoint), ALLOCATABLE :: pts(:) INTEGER :: i, es, nres, maxid - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -1390,7 +1401,7 @@ SUBROUTINE init_finite_deck_models(types, points, lines, sections, opts, models, TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: i, es - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -1444,7 +1455,7 @@ SUBROUTINE init_one_finite_model(ln, sections, types, points, opts, deck_model, REAL(wp), ALLOCATABLE :: load_per_length(:, :), w(:) REAL(wp) :: anchor(3), fairlead(3) INTEGER :: pa, pb, es, nnode, ndof - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -1645,8 +1656,12 @@ RECURSIVE SUBROUTINE build_one_hermite_cable(ln, sections, types, points, opts, ! Elements of the mesh whose equilibrium failed the stability test before that refinement. INTEGER :: stability_from_ne LOGICAL :: tensile_error - CHARACTER(400) :: note_text - CHARACTER(512) :: limit_text + CHARACTER(1024) :: note_text + CHARACTER(1024) :: limit_text + ! The geometric cause of a line with no admissible planar equilibrium clear of the seabed: + ! too long to hang as a catenary (net-heavy), or weightless (no catenary exists at all). + LOGICAL :: weightless_line + CHARACTER(400) :: geom_cause, geom_advice ! Steady deck current for the static solve (unallocated: no current and no static friction). TYPE(CD_HermiteStaticCurrentType), ALLOCATABLE :: cur_obj, cur_exact ! Static seabed friction toward the as-laid position (static springs, continued by @@ -1867,6 +1882,19 @@ RECURSIVE SUBROUTINE build_one_hermite_cable(ln, sections, types, points, opts, CALL attachment_nodes(l0, ln%att(1, :), att_node, att_offset) CALL smear_attachments(w, l0, att_node, ln%att, opts%rhoW, opts%g) END IF + ! Zero net weight everywhere (to the neutral-buoyancy band, attachments included): the line has + ! no catenary, and the net-heavy diagnosis of a line too long for its span does not apply. + weightless_line = ALL(ABS(w) <= NEUTRAL_BUOYANCY_REL_TOL*opts%rhoW*opts%g*QUARTER_PI*diam**2) + IF (weightless_line) THEN + geom_cause = 'the weightless (neutrally buoyant) line is longer than its span, so it cannot hang as a '// & + 'catenary: with no net weight a tension-only line is straight, and a longer one could only bow '// & + 'by bending under axial compression' + geom_advice = 'shorten the line to its span, or give it net weight (MassDenInAir above the displaced '// & + 'water mass, or clumps) or a tension that holds it taut' + ELSE + geom_cause = 'the net-heavy line is too long for its span to hang as a catenary' + geom_advice = 'shorten the line or move the anchor' + END IF anchor_on_flat_bed = contact_enabled .AND. (.NOT. PRESENT(bathymetry) .OR. bathymetry_flat) .AND. & ABS(anchor(3) - contact_z) <= 1.0e-6_wp*MAX(CD_ONE, ABS(contact_z)) ! A net-buoyant section anywhere makes this a lazy-wave (buoyant-arch) line and needs @@ -2578,8 +2606,8 @@ RECURSIVE SUBROUTINE build_one_hermite_cable(ln, sections, types, points, opts, ! the anchor back (hermite_static_primary) gave no admissible equilibrium either; ! em says why (where the walk stopped, or what rejected its state). CALL fail_solve(ErrStat, ErrMsg, 'finite-EI cable static solve found no admissible planar '// & - 'equilibrium clear of the seabed: the net-heavy line is too long for its span to '// & - 'hang as a catenary ('//TRIM(em)//'); shorten the line or move the anchor'); RETURN + 'equilibrium clear of the seabed: '//TRIM(geom_cause)// & + ' ('//TRIM(em)//'); '//TRIM(geom_advice)); RETURN ELSE IF (.NOT. primary_done .AND. es /= CD_HCSTAT_OK) THEN primary_msg = em END IF @@ -2687,11 +2715,11 @@ RECURSIVE SUBROUTINE build_one_hermite_cable(ln, sections, types, points, opts, END IF IF (walk_rejected) THEN CALL fail_solve(ErrStat, ErrMsg, 'finite-EI cable static solve found no admissible planar equilibrium '// & - 'clear of the seabed: the net-heavy line is too long for its span to hang as a catenary, '// & + 'clear of the seabed: '//TRIM(geom_cause)//', '// & 'and the equilibrium held by its bending stiffness that the anchor walk reached is '// & 'rejected ('// & TRIM(short_message(primary_msg, 360))//'); mesh-sequenced route: '// & - TRIM(short_message(sequence_msg, 240))//'; shorten the line or move the anchor'); RETURN + TRIM(short_message(sequence_msg, 240))//'; '//TRIM(geom_advice)); RETURN END IF ! A current with no tension-only equilibrium is named first, in full: the nested ! route diagnostics below are bounded and would cut it. A line already compressed @@ -4162,7 +4190,7 @@ SUBROUTINE anchor_overshoot_note() REAL(wp), PARAMETER :: GROUNDED_TOL = 0.05_wp REAL(wp) :: e_h(2), span, past, floor_z, xg, yg, pos(3) INTEGER :: k, esb - CHARACTER(200) :: emb + CHARACTER(1024) :: emb span = NORM2(fairlead(1:2) - anchor(1:2)) IF (span <= 1.0e-9_wp*MAX(CD_ONE, SUM(l0))) RETURN e_h = (fairlead(1:2) - anchor(1:2))/span @@ -4313,7 +4341,7 @@ SUBROUTINE solve_with(scale, dq_max) REAL(wp), INTENT(IN) :: scale REAL(wp), INTENT(OUT), OPTIONAL :: dq_max INTEGER :: it, es - CHARACTER(512) :: em + CHARACTER(1024) :: em CHARACTER(48) :: num_buf f_drag = CD_ZERO IF (has_drag) THEN @@ -4368,7 +4396,7 @@ SUBROUTINE attachment_static_drag(q, node, att, opts, frame_cs, f, ErrStat, ErrM CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: k, base, es REAL(wp) :: ug(3), ul(3), fd(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' DO k = 1, SIZE(node) IF (.NOT. (att(4, k) > CD_ZERO .OR. att(6, k) > CD_ZERO)) CYCLE @@ -4517,16 +4545,16 @@ RECURSIVE SUBROUTINE hermite_static_primary(anchor, fairlead, l0, ea, ei, w, dia ! Anchor retreats tried for a line too long for its span (see seed_walk). INTEGER, PARAMETER :: WALK_MAX_TRIES = 6 LOGICAL :: walk_ok, fold - CHARACTER(400) :: walk_msg_c + CHARACTER(1024) :: walk_msg_c REAL(wp) :: walk_d, a_seed(3) - CHARACTER(512) :: walk_msg + CHARACTER(1024) :: walk_msg LOGICAL :: tensile, refine_all, planar_bed, walk_needed, laid REAL(wp) :: h_target REAL(wp) :: origin(2), a_l(3), f_l(3), seabed_z, seabed_slope, horizontal_tension, grounded_length REAL(wp) :: lambda0, ratio, span(2), span_len, t, xg, yg, zf, sx, sz, sxx, sxz, xl, yl REAL(wp) :: res_cont, cont_tol, phi, penetration, zfit(NFIT), fit_misfit, fine_limit, seed_bed, anchor_bed REAL(wp), ALLOCATABLE :: pos(:), q_seed(:), q_cont(:), curv_cont(:), knnode(:), tdir(:, :), stretch(:) - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' @@ -5036,7 +5064,7 @@ SUBROUTINE walked_compression(text) CHARACTER(*), INTENT(OUT) :: text TYPE(CD_HermiteBranchAuditType) :: audit_w INTEGER :: es_w, ios_w - CHARACTER(200) :: em_w + CHARACTER(1024) :: em_w text = '' CALL CD_HermiteCable_Branch_Audit(l0, q_cont, ea, audit_w, es_w, em_w) IF (es_w /= CD_HCSTAT_OK) RETURN @@ -5124,8 +5152,8 @@ SUBROUTINE walk_anchor() LOGICAL :: have_prev, energy, folded, fold_now REAL(wp) :: fit, path_len, r_td(2), p, up(3), tl, xb_w, yb_w, zb_w INTEGER :: k_td, kk, es_b - CHARACTER(512) :: em_b - CHARACTER(512) :: em_w + CHARACTER(1024) :: em_b + CHARACTER(1024) :: em_w ALLOCATE (q_try(6*nnode), q_new(6*nnode), q_prev(6*nnode), sref(nnode), curv_w(nnode)) sref(1) = CD_ZERO DO k = 2, nnode @@ -5328,7 +5356,7 @@ RECURSIVE SUBROUTINE graded_restart() LOGICAL :: planar, inadm_g, walked_sub INTEGER :: kend(2), iend, e_end, k, j, n_g, nf, es_g, slot REAL(wp) :: t_end, blayer - CHARACTER(512) :: em_g + CHARACTER(1024) :: em_g IF (PRESENT(refined_pass) .OR. fold) RETURN kend = 0 DO iend = 1, 2 @@ -5431,7 +5459,7 @@ RECURSIVE SUBROUTINE refined_restart() REAL(wp), ALLOCATABLE :: l0_r(:), q_r(:), q_ref_r(:), ea_r(:), ei_r(:), w_r(:), diam_r(:), dry_r(:) INTEGER, ALLOCATABLE :: fixed_r(:) INTEGER :: scale, scale_need, k, es_r, parent - CHARACTER(512) :: em_r + CHARACTER(1024) :: em_r LOGICAL :: inadm_r, walked_sub IF (PRESENT(refined_pass) .OR. fold) RETURN scale_need = bending_refine_scale(l0, ei, w) @@ -5630,7 +5658,7 @@ SUBROUTINE hermite_static_stable(l0_deck, l0, ea, ei, w, diam_deck, dry_deck, q, REAL(wp), ALLOCATABLE :: diam(:), dry(:), knnode(:), q_eval(:), curv(:) REAL(wp) :: res INTEGER :: i, ne, it, es - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -5763,7 +5791,7 @@ SUBROUTINE audit_hermite_static(l0, q, ea, ei, w, diam, endconn_mode, physical, REAL(wp) :: zone(2), qe(12), t_end, total, allowance, hl_max, excess, denom LOGICAL :: report_c INTEGER :: ne, iend, e, es - CHARACTER(200) :: em + CHARACTER(1024) :: em physical = .FALSE. message = '' @@ -6239,14 +6267,20 @@ SUBROUTINE CD_Init_Deck_Aggregate(deck_path, dt, agg, ErrStat, ErrMsg, env_gravi IF (PRESENT(forbid_deck_ambient)) THEN IF (forbid_deck_ambient) THEN IF (opts%has_wave) THEN - CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: this coupled mode runs the mooring in '// & - 'STILL WATER (no ambient fluid field covers the mooring span); remove the deck '// & - 'waves OPTION'); RETURN + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck waves OPTION is not supported on this '// & + 'route: a host-driven or mixed EI=0/finite-EI deck (a standalone mixed deck, the C API, '// & + 'OpenFAST or FAST.Farm) runs the mooring in STILL WATER, because no ambient fluid field covers '// & + 'its span. '// & + 'Remove the waves OPTION, or run a deck whose lines are all EI=0 or all finite-EI (those '// & + 'standalone routes evaluate the deck waves), or let the OpenFAST host supply them'); RETURN END IF IF (opts%has_current .OR. opts%has_current_profile) THEN - CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: this coupled mode runs the mooring in '// & - 'STILL WATER (no ambient fluid field covers the mooring span); remove the deck '// & - 'current OPTION'); RETURN + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck current OPTION is not supported on this '// & + 'route: a host-driven or mixed EI=0/finite-EI deck (a standalone mixed deck, the C API, '// & + 'OpenFAST or FAST.Farm) runs the mooring in STILL WATER, because no ambient fluid field covers '// & + 'its span. '// & + 'Remove the current OPTION, or run a deck whose lines are all EI=0 or all finite-EI (those '// & + 'standalone routes evaluate the deck current), or let the OpenFAST host supply it'); RETURN END IF END IF END IF @@ -6679,6 +6713,26 @@ SUBROUTINE CD_Init_Deck_Aggregate(deck_path, dt, agg, ErrStat, ErrMsg, env_gravi IF (ErrStat /= CD_DECKDRV_OK) THEN CALL CD_End_Deck_Aggregate(agg); RETURN END IF + ! A static strain above the note level is named in the line's initialisation note (every route that + ! prints the notes of this summary shows it), and the standalone mixed route -- the caller that + ! asks for the range graphs -- also warns about coarse sections, as the single-topology driver does. + BLOCK + INTEGER :: il + CHARACTER(1024) :: strain_note + DO il = 1, SIZE(agg%init_lines) + CALL static_strain_note(agg%init_lines(il)%line_id, agg%init_lines(il)%fair_tension, sections, types, opts, & + strain_note) + IF (LEN_TRIM(strain_note) == 0) CYCLE + IF (LEN_TRIM(agg%init_lines(il)%note) > 0) THEN + agg%init_lines(il)%note = TRIM(agg%init_lines(il)%note)//NEW_LINE('a')//TRIM(strain_note) + ELSE + agg%init_lines(il)%note = strain_note + END IF + END DO + IF (PRESENT(range_files)) THEN + IF (range_files) CALL warn_coarse_sections(lines, sections) + END IF + END BLOCK ! Per moving slot, the driving turbine (0 outside farm mode) -- the SAME ! enumeration the coupled_positions override uses: the system's BOUND @@ -7212,7 +7266,7 @@ SUBROUTINE CD_End_Deck_Aggregate(agg) !! `cables` deallocated here). TYPE(CD_DeckAggregateType), INTENT(INOUT) :: agg INTEGER :: c, es - CHARACTER(240) :: em + CHARACTER(1024) :: em IF (agg%has_sys) CALL CD_End_System(agg%sys, es, em) agg%has_sys = .FALSE. agg%n_turbines = 0 @@ -7297,7 +7351,7 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) CHARACTER(NAMELEN), ALLOCATABLE :: channels(:) REAL(wp), ALLOCATABLE :: q_all(:), ten_all(:), end_all(:, :), end_vec(:, :, :) INTEGER, ALLOCATABLE :: q_off(:), ten_off(:), nn(:), ne(:) - CHARACTER(512) :: fail_msg + CHARACTER(1024) :: fail_msg TYPE(CD_ModelType), ALLOCATABLE :: models(:) TYPE(FiniteDeckModel), ALLOCATABLE :: finite_models(:) TYPE(CD_HFMF_ModuleType), ALLOCATABLE :: hermite_models(:) @@ -7307,7 +7361,7 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) TYPE(CD_LineInitSummary), ALLOCATABLE :: init_summaries(:) INTEGER :: nl, li, es, j, n_finite LOGICAL :: line_conv, has_line_outputs, has_finite, has_dyn_points, has_rigid6, hermite_standalone_eligible - CHARACTER(512) :: em + CHARACTER(1024) :: em converged = .FALSE. ErrStat = CD_DECKDRV_OK @@ -7387,6 +7441,7 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) CALL CD_Profile_Enter(CD_PROF_INIT) END IF CALL print_static_input_warnings(types, points, lines, sections, opts) + CALL warn_coarse_sections(lines, sections) ! free Rigid6 bodies and rods (jointly with Free/Connect points) start at their static ! equilibrium on every route: static-only, TMax = 0 and the dynamic march (pinned rods turn ! about their pins, a rod pinned to a body with the body) @@ -7491,7 +7546,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (ErrStat == CD_DECKDRV_OK .AND. opts%n_modes > 0) & CALL write_deck_modes_hermite(out_root, lines, opts, hermite_models, ErrStat, ErrMsg) IF (ErrStat == CD_DECKDRV_OK) THEN - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) CALL write_hermite_dynamic_out(out_root, channels, lines, points, opts, hermite_models, & converged, ErrStat, ErrMsg, bathymetry=bathymetry) END IF @@ -7516,7 +7572,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (opts%has_bathymetry_file) CALL CD_End_Bathymetry(bathymetry) RETURN END IF - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) CALL write_finite_dynamic_out(out_root, channels, lines, points, opts, finite_models, & converged, ErrStat, ErrMsg, bathymetry=bathymetry) CALL end_finite_models(finite_models) @@ -7558,7 +7615,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (opts%has_bathymetry_file) CALL CD_End_Bathymetry(bathymetry) RETURN END IF - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) IF (opts%has_bathymetry_file) THEN CALL write_rod_dynamic_out(out_root, channels, rod_types, rods, lines, points, opts, point_system, & converged, ErrStat, ErrMsg, bathymetry=bathymetry) @@ -7591,7 +7649,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (opts%has_bathymetry_file) CALL CD_End_Bathymetry(bathymetry) RETURN END IF - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) IF (opts%has_bathymetry_file) THEN CALL write_rigid6_dynamic_out(out_root, channels, bodies, lines, points, opts, point_system, & converged, ErrStat, ErrMsg, bathymetry=bathymetry, rod_types=rod_types, & @@ -7624,7 +7683,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (opts%has_bathymetry_file) CALL CD_End_Bathymetry(bathymetry) RETURN END IF - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) CALL write_system_dynamic_out(out_root, channels, lines, points, opts, point_system, converged, & ErrStat, ErrMsg, failures=fails, bathymetry=bathymetry) CALL CD_End_System(point_system, es, em) @@ -7645,7 +7705,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (opts%has_bathymetry_file) CALL CD_End_Bathymetry(bathymetry) RETURN END IF - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) CALL write_dynamic_out(out_root, channels, lines, points, opts, models, converged, ErrStat, ErrMsg, & bathymetry=bathymetry) CALL end_models(models) @@ -7707,7 +7768,8 @@ SUBROUTINE run_deck_driver(deck_path, out_root, converged, ErrStat, ErrMsg) IF (converged) THEN CALL collect_raw_init_summaries(lines, points, ne, q_all, q_off, ten_all, ten_off, init_summaries, & end_ten=end_all, end_force=end_vec) - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, init_summaries, & + types=types, opts=opts) IF (.NOT. (opts%has_wtrdpth .OR. opts%has_bathymetry_file)) & CALL warn_line_below_anchor(lines, points, sections, q_all, q_off) END IF @@ -7811,7 +7873,7 @@ SUBROUTINE init_one_model(ln, sections, types, points, opts, model, ErrStat, Err REAL(wp), PARAMETER :: factors(4) = [0.25_wp, 0.5_wp, 0.75_wp, CD_ONE] INTEGER :: j, i, e, es LOGICAL :: want_wave_cfg - CHARACTER(200) :: em + CHARACTER(1024) :: em ! static seabed friction of this line: lay azimuth override [rad] (unallocated: the ! default, the chord direction from the line's lower end) and as-laid tension [N] REAL(wp), ALLOCATABLE :: lay_az_opt @@ -8164,7 +8226,7 @@ SUBROUTINE init_one_syrope_model(types, syt, ln, lts, secs, anchor, fairlead, l0 REAL(wp), ALLOCATABLE :: sslow(:), stmax(:), kn(:), diam(:), cn(:), t_static(:) REAL(wp) :: eps0, t_ref, secant, total_l0, t_hist, eps_bar, t_mean_static INTEGER :: ne, e, es, n_owc, iter - CHARACTER(200) :: em + CHARACTER(1024) :: em CHARACTER(24) :: s_eps, s_lo, s_hi ! static seabed friction of this line: lay azimuth override [rad] and as-laid tension REAL(wp), ALLOCATABLE :: lay_az_opt @@ -8468,7 +8530,7 @@ SUBROUTINE end_models(models) !! Best-effort cleanup for partially initialized model arrays. TYPE(CD_ModelType), INTENT(INOUT) :: models(:) INTEGER :: i, es - CHARACTER(80) :: em + CHARACTER(1024) :: em DO i = 1, SIZE(models) CALL CD_End_Model(models(i), es, em) END DO @@ -8478,7 +8540,7 @@ SUBROUTINE end_finite_models(models) !! Best-effort cleanup for finite-EI dynamic deck model arrays. TYPE(FiniteDeckModel), INTENT(INOUT) :: models(:) INTEGER :: i, es - CHARACTER(80) :: em + CHARACTER(1024) :: em DO i = 1, SIZE(models) CALL CD_End_FiniteEI_Model(models(i)%model, es, em) IF (ALLOCATED(models(i)%l0)) DEALLOCATE (models(i)%l0) @@ -8806,7 +8868,7 @@ SUBROUTINE finite_lazy_wave_reference_and_state(anchor, fairlead, l0, nodes_ref, REAL(wp) :: chord(3), chord_len, chord_dir(3), lift(3), lift_norm, tan_a(3), tan_b(3) REAL(wp) :: handle_scale INTEGER :: nnode, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -8920,7 +8982,7 @@ SUBROUTINE finite_bathymetry_contact_force(q, v, bathymetry, kn, cn, mu, f_ext, INTEGER :: nnode, i, ix, iy, iz, es REAL(wp), PARAMETER :: vreg = 1.0e-3_wp REAL(wp) :: z_floor, gap, normal, normal_tangent, gate, gate_tangent, denom - CHARACTER(160) :: em + CHARACTER(1024) :: em f_ext = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -9012,7 +9074,7 @@ SUBROUTINE finite_bathymetry_contact_load_banded(q, v, bathymetry, kn, cn, mu, f INTEGER :: nnode, i, ix, iy, iz, es REAL(wp) :: z_floor, dfdx, dfdy - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL init_finite_contact_band(q, v, kn, cn, mu, free, kl, ku, free_map, f_ext, jac_q_band, jac_v_band, & nnode, ErrStat, ErrMsg) @@ -9212,7 +9274,7 @@ SUBROUTINE finite_environment_force(model, opts, time, q, v, f_ext, ErrStat, Err INTEGER :: idx(6) REAL(wp) :: xa(3), xb(3), va(3), vb(3), eta_a, eta_b REAL(wp) :: fluid_a(3), fluid_b(3), accel_a(3), accel_b(3), f2(6) - CHARACTER(160) :: em + CHARACTER(1024) :: em f_ext = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -9280,7 +9342,7 @@ SUBROUTINE finite_environment_load_banded(model, opts, time, q, v, free, kl, ku, INTEGER :: idx(6) REAL(wp) :: xa(3), xb(3), va(3), vb(3), eta_a, eta_b REAL(wp) :: fluid_a(3), fluid_b(3), accel_a(3), accel_b(3), f2(6), jq2(6, 6), jv2(6, 6) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -9374,7 +9436,7 @@ SUBROUTINE finite_environment_node(opts, time, x, eta, fluid_velocity, fluid_acc CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: current_velocity(3) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em eta = CD_ZERO fluid_velocity = CD_ZERO @@ -9534,6 +9596,92 @@ SUBROUTINE print_static_input_warnings(types, points, lines, sections, opts) END IF END SUBROUTINE print_static_input_warnings + SUBROUTINE warn_coarse_sections(lines, sections) + !! Standard-output WARNINGS for a section too coarse for the line it belongs to: a section of at + !! most COARSE_SECTION_MAX_SEGS segments whose segments (section length / NumSegs) are longer + !! than COARSE_SECTION_FRACTION of the line's total length (a short line of eight segments is + !! a deliberate coarse model and is not reported). Each segment of an EI=0 line is + !! a straight chord and each element of a finite-EI line a cubic-Hermite span, so a one-element + !! 100 m top section on a 520 m line cannot follow the line shape there and shifts the fairlead tension by tens of percent. The + !! whole-line check of print_static_input_warnings (fewer than three segments) does not see a + !! coarse section inside a finely meshed line, and a line with fewer than three segments is + !! reported whole by that check, not here. + TYPE(DeckLine), INTENT(IN) :: lines(:) + TYPE(DeckSection), INTENT(IN) :: sections(:) + INTEGER :: i, j, nseg_line + REAL(wp) :: total, seg_len + CHARACTER(32) :: b1, b2, b3 + + DO i = 1, SIZE(lines) + total = CD_ZERO + nseg_line = 0 + DO j = 1, SIZE(sections) + IF (sections(j)%line_id /= lines(i)%id) CYCLE + total = total + sections(j)%length + nseg_line = nseg_line + sections(j)%nsegs + END DO + IF (.NOT. (total > CD_ZERO) .OR. nseg_line < 3) CYCLE + DO j = 1, SIZE(sections) + IF (sections(j)%line_id /= lines(i)%id .OR. sections(j)%nsegs < 1) CYCLE + seg_len = sections(j)%length/REAL(sections(j)%nsegs, wp) + IF (seg_len <= COARSE_SECTION_FRACTION*total .OR. sections(j)%nsegs > COARSE_SECTION_MAX_SEGS) CYCLE + WRITE (b1, '(F12.2)') sections(j)%length + WRITE (b2, '(F12.2)') seg_len + WRITE (b3, '(F6.1)') 100.0_wp*seg_len/total + WRITE (output_unit, '(A)') ' WARNING: LINE '//TRIM(int_to_str(lines(i)%id))//' section of type "'// & + TRIM(sections(j)%ltype_name)//'" ('//TRIM(ADJUSTL(b1))//' m in '//TRIM(int_to_str(sections(j)%nsegs))// & + ' segment(s)) has segments of '//TRIM(ADJUSTL(b2))//' m, '//TRIM(ADJUSTL(b3))// & + ' % of the line length: too coarse to follow the line shape there, which can shift the tensions '// & + 'by tens of percent; refine its NumSegs (aim for segments under 10 % of the line length)' + END DO + END DO + END SUBROUTINE warn_coarse_sections + + SUBROUTINE static_strain_note(line_id, tension, sections, types, opts, note) + !! The static initial state of a line stretched beyond STATIC_STRAIN_NOTE_DEFAULT (or OPTION + !! maxStrain when it is given): the fairlead tension over the EA of the section at End A. A + !! line far shorter than its span converges at such a strain without any message, because + !! the dynamic strain guard (maxStrain) does not apply to the static solve. Only a note -- + !! the equilibrium and every output are unchanged. Types whose tension is not EA times + !! strain (Syrope working curves, load-dependent stiffness) are not assessed. + INTEGER, INTENT(IN) :: line_id + REAL(wp), INTENT(IN) :: tension + TYPE(DeckSection), INTENT(IN) :: sections(:) + TYPE(DeckLineType), INTENT(IN) :: types(:) + TYPE(DeckOptions), INTENT(IN) :: opts + CHARACTER(*), INTENT(OUT) :: note + INTEGER :: j, k + REAL(wp) :: strain, limit + CHARACTER(32) :: b1, b2, b3 + CHARACTER(40) :: source + + note = '' + IF (.NOT. (tension > CD_ZERO .AND. tension < HUGE(CD_ONE))) RETURN + DO j = 1, SIZE(sections) + IF (sections(j)%line_id /= line_id) CYCLE + k = find_type(types, sections(j)%ltype_name) + IF (k < 1) RETURN + IF (types(k)%is_syrope .OR. types(k)%elastic_mod == 3 .OR. .NOT. (types(k)%ea > CD_ZERO)) RETURN + strain = tension/types(k)%ea + limit = STATIC_STRAIN_NOTE_DEFAULT + source = 'the static default' + IF (opts%has_max_strain .AND. opts%max_strain > CD_ZERO) THEN + limit = opts%max_strain + source = 'OPTION maxStrain' + END IF + IF (.NOT. (strain > limit)) RETURN + WRITE (b1, '(F10.1)') 100.0_wp*strain + WRITE (b2, '(F10.1)') 100.0_wp*limit + WRITE (b3, '(ES10.3)') tension + note = 'LINE '//TRIM(int_to_str(line_id))//' is stretched to a static strain of '//TRIM(ADJUSTL(b1))// & + ' % at the fairlead (tension '//TRIM(ADJUSTL(b3))//' N over the EA of section type '// & + TRIM(types(k)%name)//'), above '//TRIM(ADJUSTL(b2))//' % ('//TRIM(source)// & + '): check the line length against the span and the EA. The dynamic maxStrain guard does '// & + 'not apply to the static solve' + RETURN + END DO + END SUBROUTINE static_strain_note + SUBROUTINE warn_line_below_anchor(lines, points, sections, q_all, q_off) !! Standard-output WARNING for a deck with no seabed (no WtrDpth or bathymetryFile) on !! which a line hangs below its lowest Fixed end by more than max(1 m, 1 % of its @@ -9609,7 +9757,7 @@ SUBROUTINE solve_one_line(ln, sections, types, points, opts, q, tension, converg REAL(wp), ALLOCATABLE :: kn(:) REAL(wp) :: anchor(3), fairlead(3), force_a(3), force_b(3) INTEGER :: ne, n_dof, i, j, ns, es - CHARACTER(200) :: em + CHARACTER(1024) :: em TYPE(CableSolverConfig) :: cfg TYPE(CD_StaticLineReport) :: report TYPE(CableCurrentLoad) :: cur @@ -9871,7 +10019,7 @@ SUBROUTINE parse_deck(path, types, bodies, rod_types, rods, points, lines, secti CHARACTER(3*DECK_RECLEN) :: row ! The whole header record: a title banner may carry "INPUT FILE" far to the right. CHARACTER(DECK_RECLEN) :: secname - CHARACTER(256) :: why + CHARACTER(1024) :: why ! Deck line of each OUTPUTS channel, for finalizer messages. INTEGER, ALLOCATABLE :: channel_lines(:) INTEGER :: nch_before, i_ch @@ -10548,7 +10696,7 @@ SUBROUTINE read_waterkin_records(path, deck_directory, opts, ErrStat, ErrMsg, li INTEGER, INTENT(OUT) :: lineno INTEGER :: unit, ios, k, nrow, wavekinmod, currentmod, row_status - CHARACTER(256) :: why + CHARACTER(1024) :: why ! Value lines are split into whitespace tokens and each value is parsed whole: a ! list-directed READ would stop an unquoted WaveKinFile path at its first '/' and ! read "0.5/2" as 0.5. @@ -10804,7 +10952,7 @@ SUBROUTINE read_wave_elevation_components(path, opts, dt_wave, wave_dir, fft_tma INTEGER :: unit, ios, n, n_window, j, k, nc, nraw, bracket, row_status, lineno CHARACTER(DECK_RECLEN) :: line - CHARACTER(256) :: why + CHARACTER(1024) :: why REAL(wp) :: te_row(2), tr, dt, tol, angle, ca, sa, scale, frac REAL(wp) :: cos_step, sin_step, cos_j, sin_j, cos_next, trig_norm REAL(wp), ALLOCATABLE :: times(:), eta_rows(:), sample_eta(:) @@ -11192,7 +11340,7 @@ SUBROUTINE read_table(name, nmin, nmax, headers, t) INTEGER :: unit, ios, st, lineno, nrow, nc_row LOGICAL :: started CHARACTER(DECK_RECLEN) :: line - CHARACTER(256) :: why + CHARACTER(1024) :: why CHARACTER(CD_DECK_PATHLEN) :: fpath ALLOCATE (t(nmax, 16)) fpath = path_join(dir, TRIM(name)) @@ -12820,7 +12968,7 @@ SUBROUTINE apply_equivalent_buoyancy(types, equivs, opts, ErrStat, ErrMsg) REAL(wp) :: mass_per_length(1) INTEGER :: i, j, idx, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = 0 ErrMsg = '' @@ -13202,6 +13350,7 @@ SUBROUTINE apply_option(line, opts, ErrStat, ErrMsg) CALL rd(val, opts%ramp_time, ErrStat, ErrMsg) CASE ('maxstrain', 'max_strain') CALL rd(val, opts%max_strain, ErrStat, ErrMsg) + opts%has_max_strain = ErrStat == 0 CASE ('streamorder', 'stream_order') CALL rd(val, x1, ErrStat, ErrMsg) IF (ErrStat == 0) THEN @@ -13969,7 +14118,7 @@ SUBROUTINE check_fixed_point_above_seabed(pt, z_floor, what, ErrStat, ErrMsg, z_ INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(IN), OPTIONAL :: z_grid - CHARACTER(32) :: zs, fs, ts + CHARACTER(32) :: zs, fs, ts, ds REAL(wp) :: tol ErrStat = 0; ErrMsg = '' @@ -13989,10 +14138,13 @@ SUBROUTINE check_fixed_point_above_seabed(pt, z_floor, what, ErrStat, ErrMsg, z_ WRITE (zs, '(G0.8)') pt%pos(3) WRITE (fs, '(G0.8)') z_floor WRITE (ts, '(ES9.2)') tol + WRITE (ds, '(ES9.2)') z_floor - pt%pos(3) CALL fail(ErrStat, ErrMsg, 'POINT '//TRIM(int_to_str(pt%id))//' (Fixed) lies below the seabed: z = '// & TRIM(ADJUSTL(zs))//' m is under '//what//' = '//TRIM(ADJUSTL(fs))// & - ' m by more than the '//TRIM(ADJUSTL(ts))//' m seabed tolerance; place the anchor on (or above) '// & - 'the seabed') + ' m by '//TRIM(ADJUSTL(ds))//' m, more than the '//TRIM(ADJUSTL(ts))//' m seabed tolerance '// & + '(max(1 mm, 1e-5 |seabed z|); an anchor within it rests on the seabed and is placed on it, '// & + 'a deeper one is never moved silently). Set the anchor Z to '//TRIM(ADJUSTL(fs))// & + ' m (the seabed) or higher') END SUBROUTINE check_fixed_point_above_seabed SUBROUTINE check_fixed_points_on_bathymetry(points, bathymetry, ErrStat, ErrMsg) @@ -14005,7 +14157,7 @@ SUBROUTINE check_fixed_points_on_bathymetry(points, bathymetry, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, es REAL(wp) :: z_floor, z_grid - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = 0; ErrMsg = '' DO i = 1, SIZE(points) @@ -14070,6 +14222,7 @@ SUBROUTINE finalize_checks(types, bodies, rod_types, rods, points, lines, sectio INTEGER :: i, j, idx, nsec_for_line, body_id, body_idx, rod_id, rod_idx, na_ref, nb_ref INTEGER :: nstep LOGICAL :: grid_ok + REAL(wp) :: displaced_mass CHARACTER(NAMELEN) :: ta, tb ErrStat = 0; ErrMsg = '' at_line = 0 @@ -14773,8 +14926,12 @@ SUBROUTINE finalize_checks(types, bodies, rod_types, rods, points, lines, sectio IF (.NOT. ((tb == 'coupled' .OR. tb == 'vessel') .AND. & points(find_point(points, lines(i)%nodeA))%turbine_id > 0 .AND. & points(find_point(points, lines(i)%nodeB))%turbine_id > 0)) THEN - CALL fail(ErrStat, ErrMsg, 'LINE End B (NodeB) must be a Fixed (anchor) point '// & - '(exception: a FAST.Farm shared line between two Turbine fairleads)'); RETURN + CALL fail(ErrStat, ErrMsg, 'LINE '//TRIM(int_to_str(lines(i)%id))//' End B (NodeB, POINT '// & + TRIM(int_to_str(lines(i)%nodeB))//', '//TRIM(tb)//') must be a Fixed (anchor) point: a line '// & + 'between two moving points (a shared line) is not supported, except a FAST.Farm shared line '// & + 'between two Turbine fairleads. Workaround: split it into two lines that meet at a '// & + 'Connect point in the middle (each line then ends on one Coupled point; the deck becomes '// & + 'dynamic and needs dtM and TMax)'); RETURN END IF ELSE IF (points(find_point(points, lines(i)%nodeA))%pos(3) < & @@ -14857,10 +15014,18 @@ SUBROUTINE finalize_checks(types, bodies, rod_types, rods, points, lines, sectio ! run gets its clock from dtM; the executable's metadata scan also admits a ! clock-free static aggregate solve. Unsupported endpoint coupling is rejected ! before initialization. - IF (types(idx)%mass <= opts%rhoW*QUARTER_PI*types(idx)%diam**2) THEN + displaced_mass = opts%rhoW*QUARTER_PI*types(idx)%diam**2 + IF (types(idx)%mass <= displaced_mass*(CD_ONE + NEUTRAL_BUOYANCY_REL_TOL)) THEN IF (types(idx)%ei <= CD_ZERO .OR. & (.NOT. opts%has_dtm .AND. .NOT. caller_driven .AND. & .NOT. (allow_static_finite_ei .AND. .NOT. opts%has_tmax))) THEN + IF (types(idx)%ei <= CD_ZERO .AND. types(idx)%mass > displaced_mass*(CD_ONE - NEUTRAL_BUOYANCY_REL_TOL)) THEN + CALL fail(ErrStat, ErrMsg, 'LINE TYPE "'//TRIM(types(idx)%name)//'" is net-buoyant to within 1e-6 '// & + '(neutrally buoyant: its dry mass equals the displaced water mass), so an EI=0 line of it is '// & + 'weightless and slack: its static shape is indeterminate (every slack shape balances). '// & + 'Give the line type weight (a larger MassDenInAir), or a finite EI with a tension that '// & + 'holds it taut'); RETURN + END IF CALL fail(ErrStat, ErrMsg, 'LINE TYPE "'//TRIM(types(idx)%name)// & '" is net-buoyant (dry mass <= displaced water mass): buoyant / lazy-wave '// & 'sections require a dynamic finite-EI deck'); RETURN @@ -15037,7 +15202,7 @@ SUBROUTINE write_out(out_root, channels, lines, points, ne, q_all, q_off, ten_al TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: unit, ios, i, nch, li, line_id, comp, es CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(512) :: em + CHARACTER(1024) :: em REAL(wp) :: val TYPE(CD_RangeSet) :: ranges ErrStat = 0; ErrMsg = '' @@ -15258,7 +15423,7 @@ SUBROUTINE open_dynamic_line_outputs(out_root, lines, models, pos_units, ten_uni INTEGER :: i, ios, ndof, nnode, ne, node, seg, es CHARACTER(LEN(out_root) + 32) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -15320,7 +15485,7 @@ SUBROUTINE open_dynamic_system_line_outputs(out_root, lines, system, pos_units, INTEGER :: i, ios, ndof, nnode, ne, node, seg, es CHARACTER(LEN(out_root) + 32) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -15382,7 +15547,7 @@ SUBROUTINE write_dynamic_line_outputs(time, lines, models, pos_units, ten_units, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, ndof, nnode, ne, es - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -15492,7 +15657,7 @@ SUBROUTINE write_dynamic_system_line_outputs(time, lines, system, pos_units, ten CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, ndof, nnode, ne, es - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -15607,7 +15772,7 @@ SUBROUTINE write_dynamic_finite_line_outputs(time, lines, models, pos_units, ten CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, nnode, ndof, ne, es - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -15769,7 +15934,7 @@ SUBROUTINE write_dynamic_out(out_root, channels, lines, points, opts, models, co INTEGER :: miss_count, consecutive_miss, max_consecutive_miss INTEGER :: recovery_event_count, recovery_max_substeps_used CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time TYPE(MotionTable) :: motion @@ -15944,7 +16109,7 @@ SUBROUTINE write_system_dynamic_out(out_root, channels, lines, points, opts, sys INTEGER, ALLOCATABLE :: pos_units(:), ten_units(:) INTEGER :: miss_count, consecutive_miss, max_consecutive_miss CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time TYPE(HydroUpdateWorkspace) :: hydro_work @@ -16121,7 +16286,7 @@ SUBROUTINE CD_Replay_Deck_Failures(system, lines, points, failures, target_faile INTEGER :: k, j, li, i, es, maxid INTEGER, ALLOCATABLE :: model_lines(:) - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -16183,7 +16348,7 @@ SUBROUTINE check_and_fire_failures(system, lines, points, failures, t, ErrStat, REAL(wp), ALLOCATABLE :: tension(:) REAL(wp) :: ten_end LOGICAL :: fire - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -16318,7 +16483,7 @@ SUBROUTINE write_rigid6_dynamic_out(out_root, channels, bodies, lines, points, o INTEGER, ALLOCATABLE :: pos_units(:), ten_units(:) INTEGER :: miss_count, consecutive_miss, max_consecutive_miss CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time TYPE(HydroUpdateWorkspace) :: hydro_work @@ -16491,7 +16656,7 @@ SUBROUTINE write_rod_dynamic_out(out_root, channels, rod_types, rods, lines, poi INTEGER, ALLOCATABLE :: rod_pos_units(:) INTEGER :: miss_count, consecutive_miss, max_consecutive_miss CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time TYPE(HydroUpdateWorkspace) :: hydro_work @@ -17073,7 +17238,7 @@ SUBROUTINE object_channel_value(ch, val, found, rigid, rods, points, opts, time, INTEGER :: oid, node, qty, ib, ir, body_of, es REAL(wp) :: ang(3), rr(3, 3), axis(3), half, ends(3), f6(6), ten(2), sub, arm(3), phi, beta TYPE(RodState) :: rs - CHARACTER(256) :: em + CHARACTER(1024) :: em REAL(wp), PARAMETER :: R2D = 45.0_wp/QUARTER_PI val = CD_ZERO @@ -17213,7 +17378,7 @@ SUBROUTINE point_line_force(points, pidx, system, mb, f, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: k, c, es REAL(wp) :: f_first(3), f_last(3), fl(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em f = CD_ZERO ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -17343,7 +17508,7 @@ SUBROUTINE rod_net_wrench(rs, body_of, points, opts, time, f6, ten, sub, ErrStat REAL(wp) :: f(3), m(3), f2(3), m2(3), a6(6, 6), d6(6, 6), pa(3), pb(3), fe(3, 2), eta(2), za, zb, s0, s1 REAL(wp) :: wv(3), wa(3) INTEGER :: ip, e, es - CHARACTER(200) :: em + CHARACTER(1024) :: em f6 = CD_ZERO ten = CD_ZERO @@ -17593,7 +17758,7 @@ SUBROUTINE write_objects_dynamic_out(out_root, channels, bodies, rod_types, rods TYPE(DeckRod), ALLOCATABLE :: own(:) INTEGER :: unit, ios, step, nstep, k, es, nsub, isub REAL(wp) :: t, acc(3), alpha(3), dv0(6), dts, ts - CHARACTER(160) :: em + CHARACTER(1024) :: em TYPE(DriverProgress) :: progress converged = .TRUE. @@ -17922,7 +18087,7 @@ SUBROUTINE write_multibody_dynamic_out(deck_path, out_root, channels, types, bod LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time, rb(3, 3) CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em TYPE(HydroUpdateWorkspace) :: hydro_work TYPE(ModelOutputWorkspace) :: output_work TYPE(DriverProgress) :: progress @@ -17967,7 +18132,13 @@ SUBROUTINE write_multibody_dynamic_out(deck_path, out_root, channels, types, bod IF (is_fin(i)) THEN IF (TRIM(points(pb)%ptype) /= 'fixed') THEN CALL fail(ErrStat, ErrMsg, 'finite-EI LINE '//TRIM(int_to_str(lines(i)%id))//' in a mixed-topology '// & - 'deck needs a Fixed End B (the cable is driven at End A)'); RETURN + 'deck needs a Fixed End B (the cable is driven at End A), but End B is POINT '// & + TRIM(int_to_str(points(pb)%id))//' ('//TRIM(points(pb)%ptype)//'). A finite-EI cable that '// & + 'ends on a Connect/Free/Coupled point (a junction with other lines, a buoy or a pliant-wave '// & + 'hang-off) '// & + 'is not supported in a deck with Connect/Free points, bodies or rods (the multibody '// & + 'march). Anchor the cable on a Fixed point, or run the cable and the lines it joins as '// & + 'separate decks'); RETURN END IF IF (TRIM(points(pa)%ptype) == 'free' .OR. TRIM(points(pa)%ptype) == 'connect' .OR. & point_on_point3_body(points(pa), bodies)) THEN @@ -17976,8 +18147,12 @@ SUBROUTINE write_multibody_dynamic_out(deck_path, out_root, channels, types, bod 'a rod end or a Fixed point'); RETURN END IF IF (TRIM(points(pa)%ptype) == 'coupled' .OR. TRIM(points(pa)%ptype) == 'vessel') THEN - CALL fail(ErrStat, ErrMsg, 'finite-EI LINE '//TRIM(int_to_str(lines(i)%id))//': a Coupled End A '// & - 'needs motionFile coupling, which a mixed-topology deck does not support'); RETURN + CALL fail(ErrStat, ErrMsg, 'finite-EI LINE '//TRIM(int_to_str(lines(i)%id))//': a Coupled/Vessel End A '// & + '(POINT '//TRIM(int_to_str(points(pa)%id))//') is driven by a motionFile, which a '// & + 'mixed-topology deck with Connect/Free points or bodies (marched as one multibody system) '// & + 'does not support. '// & + 'Remove the Connect/Free points so the deck runs as a coupled mixed deck (EI=0 lines on the '// & + 'Coupled point directly), or attach the cable to a Rigid6 body, a rod end or a Fixed point'); RETURN END IF IF (lines(i)%endconn_mode(1) /= CD_ENDCONN_PINNED .AND. TRIM(points(pa)%ptype) /= 'fixed') THEN ! a clamped or elastic End A on a body or rod: implicit (monolithic step) only @@ -18110,7 +18285,8 @@ SUBROUTINE write_multibody_dynamic_out(deck_path, out_root, channels, types, bod ALLOCATE (sum_cab(0)) END IF summaries = [sum_sys, sum_cab] - CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, summaries) + CALL print_deck_init_report(deck_path, lines, points, sections, n_finite, summaries, & + types=types, opts=opts) ! ---- objects ---- CALL init_rigid6_states(bodies, points, mb%rigid, ErrStat, ErrMsg, rod_types, rods, allow_no_points=.TRUE.) @@ -18302,7 +18478,7 @@ SUBROUTINE probe_record(col, time) BLOCK REAL(wp) :: ke, se INTEGER :: es_p - CHARACTER(200) :: em_p + CHARACTER(1024) :: em_p CALL CD_HermiteCable_Dyn_Energy(mb%cables(1)%line, ke, se, es_p, em_p) probe_rec(23, col) = ke + se IF (es_p /= CD_HCDYN_OK) probe_rec(23, col) = -HUGE(CD_ONE) @@ -18477,7 +18653,7 @@ SUBROUTINE mb_cable_drive(mb, c, dt, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: xa(3), va(3), aa(3), dcm(3, 3), wa(3), ala(3) INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' mb%cables(c)%dt = dt @@ -18502,7 +18678,7 @@ SUBROUTINE mb_cable_committed_loads(mb, c, f, m, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' CALL CD_HFMF_CalcOutput(mb%cables(c), f, es, em, y_moment=m) @@ -18787,7 +18963,7 @@ SUBROUTINE mb_group_solve(m6b, rhsb, xb, wb, has_body, nc, m6c, rhsc, pinw, rc, INTEGER :: k, n, o, nb REAL(wp) :: p(3), l(3), xk(6) REAL(wp), ALLOCATABLE :: amat(:, :), bvec(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -18943,7 +19119,7 @@ SUBROUTINE mb_scatter(mb, points, ErrStat, ErrMsg) INTEGER :: es, ir, k, base INTEGER :: bases(2) REAL(wp) :: arms(3, 2) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' IF (.NOT. mb%has_sys) RETURN @@ -18974,7 +19150,7 @@ SUBROUTINE mb_line_loads(mb, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, c - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' IF (mb%has_sys) THEN @@ -19145,7 +19321,7 @@ SUBROUTINE mb_step_once(mb, points, opts, time, dt, converged, stalled, n_iter, TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: ib, ir, c, es REAL(wp) :: x(3), v(3), a(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .TRUE. stalled = .FALSE. @@ -19420,7 +19596,7 @@ SUBROUTINE mb_imp_states(mb, x, dt, gam_na, beta_na, gam_p, beta_p, ErrStat, Err INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ib, ir, p, o, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' DO ib = 1, SIZE(mb%rigid) @@ -19478,7 +19654,7 @@ SUBROUTINE mb_imp_scatter(mb, points, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ir, k, base, p, es, bases(2) REAL(wp) :: arms(3, 2) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' IF (.NOT. mb%has_sys) RETURN @@ -19846,7 +20022,7 @@ RECURSIVE SUBROUTINE mb_step_implicit(mb, points, opts, time, dt, converged, sta INTEGER, PARAMETER :: TAN_MAX_AGE = 20 REAL(wp) :: rho, am, af, beta_na, gam_na, t_af, h, fac, dth, worst, tol_it, am_p, gam_p, beta_p REAL(wp), ALLOCATABLE :: x(:), xp(:), r(:), rp(:), jac(:, :), dx(:), kg(:, :), ga(:, :), rscale(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .FALSE. stalled = .FALSE. @@ -20397,7 +20573,7 @@ FUNCTION line_attachment_stiffness(system, dof) RESULT(katt) REAL(wp) :: katt(3, 3) REAL(wp) :: t(3), chord(3), lc_len, k_ax, ten, el(3), ll, eye(3, 3) INTEGER :: i, j, lo, nc, es, node, far, nn, ee - CHARACTER(160) :: em + CHARACTER(1024) :: em katt = CD_ZERO eye = CD_ZERO @@ -20734,7 +20910,7 @@ SUBROUTINE step_rod_once(system, points, opts, rod_state, time, dt, converged, s INTEGER :: ir, es REAL(wp) :: dv0(6), acc(3), alpha(3), arm(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em TYPE(RigidBodyState) :: no_parent(0) converged = .FALSE. @@ -21095,7 +21271,7 @@ SUBROUTINE step_prescribed_rod_system(system, points, opts, motion, rod_state, t TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .FALSE. stalled = .FALSE. @@ -21143,7 +21319,7 @@ SUBROUTINE apply_rod_states_to_system(system, points, rod_state, work, ErrStat, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -21906,7 +22082,7 @@ SUBROUTINE fluid_at(xq, s, uq, duq, etaq, pdq, want_pdyn) LOGICAL, INTENT(IN) :: want_pdyn INTEGER :: es, ih REAL(wp) :: tq - CHARACTER(160) :: em + CHARACTER(1024) :: em uq = CD_ZERO duq = CD_ZERO @@ -22233,7 +22409,7 @@ SUBROUTINE solve_body_equilibrium_core(types, bodies, rod_types, rods, points, l INTEGER :: nobj, n, i, j, k, it, inner, info, worst, jk LOGICAL :: ok, only_points REAL(wp) :: sc, rnorm, rnorm_try, mu, step_cap, len_min, dmax, trust, pred - CHARACTER(160) :: lin_msg + CHARACTER(1024) :: lin_msg CHARACTER(24) :: b1 ErrStat = CD_DECKDRV_OK @@ -22770,7 +22946,7 @@ SUBROUTINE own_loads(xs, fk, mk, cen, sc_out, good) TYPE(RodState), ALLOCATABLE :: rst(:) REAL(wp) :: f(3), m(3), f2(3), m2(3), w6(6, 6), a6(6, 6), d3(3, 3), meff, u(3), xb(3), rb(3, 3) INTEGER :: kk, es_l, ib - CHARACTER(512) :: em_l + CHARACTER(1024) :: em_l TYPE(DeckRod) :: rg good = .FALSE. @@ -23270,7 +23446,7 @@ SUBROUTINE prepare_line(jl, es_out, em_out) TYPE(CD_LineSection), ALLOCATABLE :: secs(:) REAL(wp), ALLOCATABLE :: mpl(:), diam(:), load(:, :) INTEGER :: js, ii, ns, ne, es_l - CHARACTER(200) :: em_l + CHARACTER(1024) :: em_l es_out = CD_DECKDRV_OK em_out = '' @@ -23357,7 +23533,7 @@ SUBROUTINE cached_line_solve(jl, pts, es_out, em_out, want_k, k_ok) REAL(wp) :: anchor(3), fairlead(3), fa(3), fb(3) INTEGER :: nn, ii, es_l, nit LOGICAL :: conv, stalled, at_floor - CHARACTER(512) :: em_l + CHARACTER(1024) :: em_l es_out = CD_DECKDRV_OK em_out = '' @@ -23486,7 +23662,7 @@ SUBROUTINE condensed_end_stiffness(jl, zf, ok) INTEGER, ALLOCATABLE :: free(:), ipiv(:) REAL(wp) :: kee(6, 6), blk(3, 3), chord(3), tt(3), ll, tens, dfx, eye(3, 3), bp(3, 3) INTEGER :: nn, ne, nf, kl, ku, ldab, ee, na, nb, ii, jj, es_l, info, pair, ni, nj, si, sj - CHARACTER(200) :: em_l + CHARACTER(1024) :: em_l EXTERNAL :: dgbsv ok = .FALSE. @@ -23611,7 +23787,7 @@ LOGICAL FUNCTION node_on_floor(pos, zf) RESULT(below) REAL(wp), ALLOCATABLE, INTENT(IN) :: zf REAL(wp) :: zfl INTEGER :: es_b - CHARACTER(160) :: em_b + CHARACTER(1024) :: em_b below = .FALSE. IF (PRESENT(bathymetry)) THEN CALL CD_Bathymetry_Floor(bathymetry, pos(1), pos(2), zfl, es_b, em_b) @@ -23780,8 +23956,8 @@ SUBROUTINE hermite_end_loads(jl, fm, km, rot) TYPE(DeckPoint), ALLOCATABLE :: pc(:) REAL(wp) :: rclamp(3, 3), dclamp(3), dtb INTEGER :: node, es - CHARACTER(512) :: note - CHARACTER(300) :: em + CHARACTER(1024) :: note + CHARACTER(1024) :: em fm = CD_ZERO km = CD_ZERO lnc = lines(jl) @@ -25133,7 +25309,7 @@ SUBROUTINE step_rigid6_once(system, points, opts, rigid, time, dt, converged, st INTEGER :: ib, es, p, base REAL(wp) :: dv0(6), acc(3), alpha(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ! detached: the active free points that are not deck points -- the reserve points a line ! FAILURE moved line ends onto. They are integrated on their line-end loads; every other ! point follows its body or stays held. @@ -25300,7 +25476,7 @@ SUBROUTINE rigid_start_loads(system, q, v, a, loads, dload_da, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -25403,7 +25579,7 @@ SUBROUTINE step_prescribed_rigid6_system(system, points, opts, motion, rigid, ti TYPE(HydroUpdateWorkspace), INTENT(INOUT) :: hydro_work INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .FALSE. stalled = .FALSE. @@ -25454,7 +25630,7 @@ SUBROUTINE apply_rigid6_states_to_system(system, points, rigid, work, ErrStat, E CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -25833,7 +26009,7 @@ SUBROUTINE deck_seabed_floor_at(x, y, opts, has_floor, z_floor, ErrStat, ErrMsg, TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em LOGICAL :: bathy_ready ErrStat = CD_DECKDRV_OK @@ -25873,7 +26049,7 @@ SUBROUTINE rigid6_wet_fraction(body, opts, time, phi, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es REAL(wp) :: x_cb(3), eta, u(3), du(3), r_e, h - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -25996,7 +26172,7 @@ SUBROUTINE rigid6_environment_force(body, opts, time, force, effective_mass, dra INTEGER :: es REAL(wp) :: eta, rel(3), rel_speed, fluid_velocity(3), fluid_acceleration(3), phi, fk - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -26077,7 +26253,7 @@ SUBROUTINE write_hermite_dynamic_out(out_root, channels, lines, points, opts, ca INTEGER :: recovery_events, recovery_max_used INTEGER, ALLOCATABLE :: pos_units(:), ten_units(:) CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em REAL(wp) :: t, up(3), uv(3), ua(3), tensile_force, tensile_threshold, tensile_xi, tensile_time, turn ! Per-step tangent turn [deg] above which the time-step note is printed (see below). REAL(wp), PARAMETER :: TURN_NOTE_FORCE_BLEND = 0.25_wp, TURN_NOTE_CONFIG_BLEND = 0.1_wp @@ -26391,7 +26567,7 @@ SUBROUTINE write_hermite_static_element_profile(out_root, lines, cables, ErrStat REAL(wp) :: qr(12), l0, arc_start, arc_end, curvature_peak, u_curvature_internal, & u_curvature_public, arc_peak, moment_peak, minimum_resultant, minimum_u_internal, & minimum_u_public, maximum_resultant, maximum_u_internal, maximum_u_public - CHARACTER(200) :: em + CHARACTER(1024) :: em CHARACTER(LEN(out_root) + 20) :: path CHARACTER(1) :: tab @@ -26462,7 +26638,7 @@ SUBROUTINE apply_motion_to_hermite_cables(cables, lines, points, motion, time_in CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, pidx, es REAL(wp) :: q(3), v(3), a(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' IF (SIZE(cables) /= SIZE(lines)) THEN @@ -26500,7 +26676,7 @@ SUBROUTINE update_hermite_deck_fluid(cables, opts, time, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, j, nn, es REAL(wp) :: eta, wv(3), wa(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' IF (.NOT. (opts%has_current .OR. opts%has_wave)) RETURN DO i = 1, SIZE(cables) @@ -26557,7 +26733,7 @@ SUBROUTINE write_hermite_model_row(unit, time, channels, lines, points, cables, INTEGER :: i, line_id, li, pidx, comp, pp, mi, k, es REAL(wp) :: val, f(3), fl(3) CHARACTER(NAMELEN) :: lo - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' IF (PRESENT(ranges)) THEN DO li = 1, SIZE(lines) @@ -26769,7 +26945,7 @@ SUBROUTINE write_finite_dynamic_out(out_root, channels, lines, points, opts, mod INTEGER, ALLOCATABLE :: pos_units(:), ten_units(:) INTEGER :: miss_count, consecutive_miss, max_consecutive_miss CHARACTER(LEN(out_root) + 8) :: path - CHARACTER(256) :: em + CHARACTER(1024) :: em LOGICAL :: step_converged, stalled REAL(wp) :: t, first_miss_time, last_miss_time TYPE(MotionTable) :: motion @@ -27087,7 +27263,7 @@ SUBROUTINE write_deck_modes_ei0(out_root, types, points, lines, sections, opts, REAL(wp), ALLOCATABLE :: kmat(:, :), mmat(:, :), floor_z(:) LOGICAL, ALLOCATABLE :: free(:) INTEGER :: li, n, nm, es, kd - CHARACTER(512) :: em + CHARACTER(1024) :: em ALLOCATE (models(0)) ! defined descriptor for the INTENT(OUT) dummy (-Wmaybe-uninitialized at -O0) CALL init_deck_models_from_parsed(types, points, lines, sections, opts, models, ErrStat, ErrMsg) @@ -27149,7 +27325,7 @@ SUBROUTINE write_deck_modes_hermite(out_root, lines, opts, cables, ErrStat, ErrM REAL(wp), ALLOCATABLE :: kmat(:, :), mmat(:, :), floor_z(:) LOGICAL, ALLOCATABLE :: free(:) INTEGER :: li, n, nm, es, kd - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -27408,7 +27584,7 @@ SUBROUTINE update_system_point_hydro(system, points, opts, time, work, ErrStat, INTEGER :: i, es REAL(wp) :: eta, wave_velocity(3), wave_acceleration(3) REAL(wp) :: fluid_density - CHARACTER(160) :: em + CHARACTER(1024) :: em LOGICAL :: points_ready ErrStat = CD_DECKDRV_OK @@ -27495,7 +27671,7 @@ SUBROUTINE update_system_line_hydro(system, opts, time, work, ErrStat, ErrMsg, i INTEGER :: i, j, ndof, nnode, es REAL(wp) :: eta, wave_velocity(3), wave_acceleration(3) LOGICAL :: at_initial_condition, changed - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -27595,7 +27771,7 @@ SUBROUTINE update_wave_models(models, opts, time, work, ErrStat, ErrMsg, initial INTEGER :: i, j, ndof, nnode, es REAL(wp) :: eta, wave_velocity(3), wave_acceleration(3) LOGICAL :: at_initial_condition, changed - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -27815,7 +27991,7 @@ SUBROUTINE check_model_plausibility(model, max_strain, line_id, time, ErrStat, E INTEGER :: e, na, nb, worst_elem REAL(wp) :: strain, worst_strain - CHARACTER(200) :: detail + CHARACTER(1024) :: detail ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -28022,7 +28198,7 @@ SUBROUTINE write_planned_row(unit, time, channels, lines, points, work, label, E INTEGER :: i, k, n, li, off, nd, ne, nnode, stride, es LOGICAL :: has_motion, ok REAL(wp) :: val, q_point(3), v_point(3), a_point(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -28125,7 +28301,7 @@ SUBROUTINE write_planned_row(unit, time, channels, lines, points, work, label, E SUBROUTINE sample_ranges() !! Sample every line with a range file or TDP channel at this row's committed state. INTEGER :: il, es_r - CHARACTER(512) :: em_r + CHARACTER(1024) :: em_r DO il = 1, SIZE(lines) IF (.NOT. CD_Range_Needs_Sample(work%rset, il)) CYCLE IF (PRESENT(models)) THEN @@ -28180,7 +28356,7 @@ SUBROUTINE fetch_state(il, fetched) INTEGER, INTENT(IN) :: il LOGICAL, INTENT(OUT) :: fetched INTEGER :: o, m, es - CHARACTER(160) :: msg + CHARACTER(1024) :: msg fetched = work%state_row(il) == work%row IF (fetched) RETURN o = work%state_off(il) @@ -28208,7 +28384,7 @@ SUBROUTINE end_tension_override(il, inode, nel, v) INTEGER, INTENT(IN) :: il, inode, nel REAL(wp), INTENT(INOUT) :: v INTEGER :: es_o - CHARACTER(160) :: msg_o + CHARACTER(1024) :: msg_o IF (inode /= 1 .AND. inode /= nel + 1) RETURN IF (PRESENT(models)) THEN CALL line_model_end_tension(models(il), inode, nel + 1, v, es_o, msg_o) @@ -28228,7 +28404,7 @@ SUBROUTINE fetch_tension(il, fetched) INTEGER, INTENT(IN) :: il LOGICAL, INTENT(OUT) :: fetched INTEGER :: o, m, es - CHARACTER(160) :: msg + CHARACTER(1024) :: msg fetched = work%ten_row(il) == work%row IF (fetched) RETURN o = work%ten_off(il) @@ -28253,7 +28429,7 @@ SUBROUTINE line_sizes(il, sized, tension_sized) INTEGER, INTENT(IN) :: il LOGICAL, INTENT(OUT) :: sized, tension_sized INTEGER :: es, ndof_l, ne_l - CHARACTER(160) :: msg + CHARACTER(1024) :: msg tension_sized = .FALSE. IF (PRESENT(models)) THEN ndof_l = CD_Model_NDOF(models(il), es, msg) @@ -28520,7 +28696,7 @@ SUBROUTINE CD_Classify_Dynamic_Completion(label, nstep, miss_count, max_consecut INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg - CHARACTER(512) :: msg_buf + CHARACTER(1024) :: msg_buf INTEGER :: ios ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -28551,7 +28727,7 @@ SUBROUTINE system_channel_value(ch, lines, points, system, work, val, ErrStat, E INTEGER :: li, pidx, comp, kind, node, ndof, nnode, es, ne, inode REAL(wp) :: q_point(3), v_point(3), a_point(3) CHARACTER(NAMELEN) :: lo - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -28696,7 +28872,7 @@ SUBROUTINE finite_model_channel_value(ch, lines, points, models, work, val, ErrS INTEGER :: li, pidx, comp, kind, node, nnode, es, inode, ppos, midx CHARACTER(NAMELEN) :: lo - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -28833,7 +29009,7 @@ SUBROUTINE finite_model_tension(deck_model, tension, work, ErrStat, ErrMsg) INTEGER :: e, es, nnode REAL(wp) :: xa(3), xb(3), length - CHARACTER(160) :: em + CHARACTER(1024) :: em tension = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -28873,7 +29049,7 @@ SUBROUTINE model_channel_value(ch, lines, points, models, work, val, ErrStat, Er INTEGER :: li, pidx, comp, kind, node, ndof, nnode, es, ne, inode, midx CHARACTER(NAMELEN) :: lo - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -29015,7 +29191,7 @@ SUBROUTINE model_point_channel_value(point_id, comp, lines, points, models, work CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, es, ndof, nnode, internal_node, ppos - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -29068,7 +29244,7 @@ INTEGER FUNCTION model_nelem_from_line(line, model, ErrStat, ErrMsg) RESULT(ne) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ndof, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ndof = CD_Model_NDOF(model, es, em) IF (es /= CD_MODEL_OK) THEN @@ -29099,7 +29275,7 @@ SUBROUTINE seed_finite_initial_acceleration(models, opts, ErrStat, ErrMsg) INTEGER :: i, es LOGICAL :: use_live_env - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -29172,7 +29348,7 @@ SUBROUTINE step_finite_held_models(models, opts, time, dt, converged, stalled, n INTEGER :: i, es, line_iter, active_model LOGICAL :: line_converged, line_stalled, use_motion, use_live_env, line_has_live_load - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .TRUE. stalled = .FALSE. @@ -29349,7 +29525,7 @@ SUBROUTINE finite_motion_targets(model, line, points, motion, time_index, q_ft, INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ndof, pa, pb, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' ndof = SIZE(q_ft) @@ -29379,7 +29555,7 @@ SUBROUTINE step_held_models(models, dt, recovery_max_substeps, converged, stalle INTEGER :: i, j, ndof, nc, es, line_iter, line_substeps LOGICAL :: line_converged, line_stalled - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .TRUE. stalled = .FALSE. @@ -29450,7 +29626,7 @@ SUBROUTINE step_motion_models(models, lines, points, motion, time_index, dt, rec INTEGER :: i, ndof, es, line_iter, line_substeps LOGICAL :: line_converged, line_stalled - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .TRUE. stalled = .FALSE. @@ -29502,7 +29678,7 @@ SUBROUTINE apply_motion_to_models(models, lines, points, motion, time_index, Err INTEGER :: i, j, ndof, nc, es INTEGER, ALLOCATABLE :: coupled_dofs(:) REAL(wp), ALLOCATABLE :: qc(:), vc(:), ac(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em TYPE(LineStepWorkspace) :: work ErrStat = CD_DECKDRV_OK @@ -29566,7 +29742,7 @@ SUBROUTINE apply_motion_to_finite_models(models, lines, points, motion, time_ind INTEGER :: dofs(6) REAL(wp) :: q_vals(6), v_vals(6), a_vals(6) LOGICAL :: do_recompute - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -29604,7 +29780,7 @@ SUBROUTINE prescribed_full_state(model, line, points, motion, time_index, q, v, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ndof, es, pa, pb - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -29741,7 +29917,7 @@ SUBROUTINE read_motion_file(path, points, opts, motion, ErrStat, ErrMsg, include CHARACTER(DECK_RECLEN) :: roll_tok REAL(wp) :: t, qv(3), vv(3), av(3), tol, row(11), trow(21), rq(3, 3), rp(3) CHARACTER(DECK_RECLEN) :: line - CHARACTER(256) :: why + CHARACTER(1024) :: why LOGICAL, ALLOCATABLE :: seen(:, :), turb_seen(:, :) LOGICAL :: accept_rod_points, accept_body_points, grid_ok INTEGER :: jturb @@ -30071,7 +30247,7 @@ SUBROUTINE read_vessel_record(path, opts, motion, rref, vref, aref, ErrStat, Err CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), PARAMETER :: D2R = QUARTER_PI/45.0_wp CHARACTER(DECK_RECLEN) :: line - CHARACTER(256) :: why + CHARACTER(1024) :: why INTEGER :: unit, ios, lineno, ntok, nform, row_status, it, off REAL(wp) :: row(20), tol, qn LOGICAL, ALLOCATABLE :: seen(:) @@ -30177,7 +30353,7 @@ SUBROUTINE read_rao_table(path, rao, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER, PARAMETER :: MAXH = 361, MAXP = 2000 CHARACTER(DECK_RECLEN) :: line - CHARACTER(256) :: why + CHARACTER(1024) :: why CHARACTER(DECK_RECLEN) :: tok INTEGER :: unit, ios, lineno, nh, np, np_first, row_status, i, j, k, es INTEGER, ALLOCATABLE :: perm_p(:), perm_h(:) @@ -30185,7 +30361,7 @@ SUBROUTINE read_rao_table(path, rao, ErrStat, ErrMsg) REAL(wp), ALLOCATABLE :: heads(:), pers(:, :), amp(:, :, :), ph(:, :, :) REAL(wp), ALLOCATABLE :: amp_s(:, :, :), ph_s(:, :, :), per_s(:), head_s(:) LOGICAL :: found, ok - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' ! read buffers at the table limits (about 75 MB); STAT keeps a failed allocation a clean error @@ -30336,7 +30512,7 @@ SUBROUTINE synthesize_vessel_rao(path, opts, motion, rref, vref, aref, ErrStat, REAL(wp) :: cb, sb, r, rd, rdd, x6(6), v6(6), a6(6) INTEGER :: nc, i, it, es, nclamp LOGICAL :: clamped - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' rref = CD_ZERO; vref = CD_ZERO; aref = CD_ZERO @@ -30839,7 +31015,7 @@ SUBROUTINE point_force_value(ch, lines, models, val, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: pidx, comp, k, es REAL(wp) :: f(3), f_first(3), f_last(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -30875,7 +31051,7 @@ SUBROUTINE system_point_force_value(ch, system, val, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: pidx, comp, k, es REAL(wp) :: f(3), f_first(3), f_last(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31314,7 +31490,7 @@ SUBROUTINE collect_aggregate_init_summaries(lines, agg, ErrStat, ErrMsg) INTEGER :: i, es REAL(wp) :: tension, declination, azimuth, fair_force(3), f_first(3) CHARACTER(NAMELEN) :: cten, cdec, cazi - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31401,7 +31577,7 @@ SUBROUTINE collect_model_init_summaries(lines, points, models, summaries, ErrSta INTEGER :: i, es REAL(wp) :: tension, declination, azimuth, f_first(3), fair_force(3) CHARACTER(NAMELEN) :: cten, cdec, cazi - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' ALLOCATE (summaries(SIZE(lines))) @@ -31435,7 +31611,7 @@ SUBROUTINE collect_system_init_summaries(lines, points, system, summaries, ErrSt INTEGER :: i, es REAL(wp) :: tension, declination, azimuth, f_first(3), fair_force(3) CHARACTER(NAMELEN) :: cten, cdec, cazi - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' ALLOCATE (summaries(SIZE(lines))) @@ -31510,7 +31686,7 @@ SUBROUTINE collect_hermite_init_summaries(lines, cables, summaries, ErrStat, Err END DO END SUBROUTINE collect_hermite_init_summaries - SUBROUTINE print_deck_init_report(deck_path, lines, points, sections, n_finite, summaries) + SUBROUTINE print_deck_init_report(deck_path, lines, points, sections, n_finite, summaries, types, opts) !! The initialization report goes to stderr (see doc/cli.rst). CHARACTER(*), INTENT(IN) :: deck_path TYPE(DeckLine), INTENT(IN) :: lines(:) @@ -31518,8 +31694,11 @@ SUBROUTINE print_deck_init_report(deck_path, lines, points, sections, n_finite, TYPE(DeckSection), INTENT(IN) :: sections(:) INTEGER, INTENT(IN) :: n_finite TYPE(CD_LineInitSummary), INTENT(IN) :: summaries(:) + TYPE(DeckLineType), INTENT(IN), OPTIONAL :: types(:) + TYPE(DeckOptions), INTENT(IN), OPTIONAL :: opts INTEGER :: i REAL(wp) :: f_incl + CHARACTER(1024) :: strain_note WRITE (error_unit, '(A)') ' Parsing CableDyn input file: '//TRIM(deck_path) WRITE (error_unit, '(A,I0,A,I0,A,I0,A,I0,A,I0,A)') & @@ -31545,6 +31724,10 @@ SUBROUTINE print_deck_init_report(deck_path, lines, points, sections, n_finite, WRITE (error_unit, '(A,F9.3,A,F9.3,A,F9.3,A)') ' line tangent: inclination=', & summaries(i)%fair_inclination, ' deg, declination=', summaries(i)%fair_declination, & ' deg, azimuth=', summaries(i)%fair_azimuth, ' deg' + IF (PRESENT(types) .AND. PRESENT(opts)) THEN + CALL static_strain_note(summaries(i)%line_id, summaries(i)%fair_tension, sections, types, opts, strain_note) + IF (LEN_TRIM(strain_note) > 0) WRITE (error_unit, '(A)') ' Note: '//TRIM(strain_note)//'.' + END IF END DO WRITE (error_unit, '(A)') ' CableDyn initialization completed.' END SUBROUTINE print_deck_init_report @@ -31587,7 +31770,7 @@ SUBROUTINE range_setup(rset, lines, channels, opts, nnodes, by_id, ErrStat, ErrM INTEGER, ALLOCATABLE :: ids(:) LOGICAL, ALLOCATABLE :: want_r(:), want_t(:) INTEGER :: i, k, n, line_id, comp, es - CHARACTER(512) :: em + CHARACTER(1024) :: em n = SIZE(nnodes) ALLOCATE (ids(n), want_r(n), want_t(n)) @@ -31638,7 +31821,7 @@ SUBROUTINE range_setup_planned(rset, lines, channels, opts, ErrStat, ErrMsg, mod TYPE(CD_HFMF_ModuleType), INTENT(IN), OPTIONAL :: cables(:) TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: nnodes(SIZE(lines)), il, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31668,7 +31851,7 @@ SUBROUTINE range_write(rset, out_root, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em CALL CD_Range_Write_Files(rset, out_root, es, em) CALL range_status(es, em, ErrStat, ErrMsg) END SUBROUTINE range_write @@ -31710,7 +31893,7 @@ SUBROUTINE range_sample_model(model, rl, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nn, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31762,7 +31945,7 @@ SUBROUTINE range_sample_fmodel(fmodel, rl, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nn, ne, e, j, inode, es REAL(wp) :: xa(3), xb(3), length, kc(3), kr(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31809,7 +31992,7 @@ SUBROUTINE range_sample_cable(cable, rl, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nn, ne, e, j, k, inode, es REAL(wp) :: curv, bend - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31915,7 +32098,7 @@ SUBROUTINE aggregate_line_positions(system, cables, line_is_cable, line_obj_inde INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nn, j, k, inode, obj, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -31967,7 +32150,7 @@ SUBROUTINE range_setup_aggregate(rset, lines, channels, opts, has_sys, system, c TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER, ALLOCATABLE :: nnodes(:) INTEGER :: k, obj, es - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32013,7 +32196,7 @@ SUBROUTINE CD_Deck_Range_Sample_Aggregate(rset, has_sys, system, cables, line_is INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: k, obj, es - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32057,7 +32240,7 @@ SUBROUTINE aggregate_tdp_value(ch, system, cables, line_is_cable, line_obj_index INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: line_id, comp, nn, es - CHARACTER(512) :: em + CHARACTER(1024) :: em val = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -32128,7 +32311,7 @@ SUBROUTINE CD_Eval_Aggregate_Channel(ch, has_sys, system, cables, line_is_cable, LOGICAL :: found INTEGER :: line_id, node, kind, comp, pidx, es, k, c REAL(wp) :: qp(3), vp(3), ap(3), f(3), f_first(3), f_last(3), fl(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32304,7 +32487,7 @@ SUBROUTINE CD_Eval_Aggregate_Segment_Tensions(line_id, has_sys, system, cables, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: obj, ne, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32443,7 +32626,7 @@ SUBROUTINE line_model_end_tension(model, inode, nnode, val, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: f_first(3), f_last(3) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em val = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -32475,7 +32658,7 @@ SUBROUTINE eval_system_line_channel(system, li, ch, val, ErrStat, ErrMsg) CHARACTER(NAMELEN) :: lo INTEGER :: line_id, node, kind, comp, ndof, nnode, ne, inode, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32599,7 +32782,7 @@ SUBROUTINE eval_cable_channel(cable, ch, val, ErrStat, ErrMsg, mesh_node) INTEGER :: line_id, node, kind, comp, nnode, nelem, inode, es LOGICAL :: deck_numbering REAL(wp) :: sec_ten, sec_curv, sec_bend - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32795,7 +32978,7 @@ REAL(wp) FUNCTION cable_axial_tension(cable, e, xi) RESULT(t) REAL(wp), INTENT(IN) :: xi REAL(wp) :: qr(12), vr(12), l0, viscous INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em t = CD_ZERO IF (e < 1 .OR. e > cable%line%ne) RETURN l0 = cable%line%l0(e) @@ -32859,7 +33042,7 @@ SUBROUTINE cable_end_tension(cable, inode, tension, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: force(3) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -33887,7 +34070,7 @@ SUBROUTINE host_substep_start(system, nsub, q0h, v0h, a0h, ErrStat, ErrMsg, host CHARACTER(*), INTENT(OUT) :: ErrMsg LOGICAL, INTENT(IN), OPTIONAL :: host_mask(:) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' IF (.NOT. PRESENT(host_mask) .OR. nsub <= 1) RETURN @@ -34215,8 +34398,8 @@ SUBROUTINE load_bathymetry_file(path, bathymetry, ErrStat, ErrMsg, points) REAL(wp), ALLOCATABLE :: xr(:), yr(:), dr(:), xgrid(:), ygrid(:), depth(:, :) LOGICAL, ALLOCATABLE :: filled(:, :) CHARACTER(DECK_RECLEN) :: line - CHARACTER(200) :: em - CHARACTER(256) :: why + CHARACTER(1024) :: em + CHARACTER(1024) :: why ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -34411,7 +34594,7 @@ SUBROUTINE read_syrope_settings(path, owc_strain, owc_tension, wc_mod, p1, p2, E LOGICAL :: have_owc, have_wc, have_k1, have_k2 REAL(wp) :: row(2) REAL(wp), ALLOCATABLE :: es(:), ts(:) - CHARACTER(256) :: why + CHARACTER(1024) :: why ErrStat = 0; ErrMsg = '' IF (PRESENT(owc_file)) owc_file = '' diff --git a/src/CableDyn_Driver.f90 b/src/CableDyn_Driver.f90 index 0082c547..000c6fa8 100644 --- a/src/CableDyn_Driver.f90 +++ b/src/CableDyn_Driver.f90 @@ -73,7 +73,7 @@ SUBROUTINE CD_Run_Static_Driver(input_path, output_path, converged, ErrStat, Err LOGICAL :: tension_only, has_seabed, stalled, at_floor INTEGER :: n_iter, es, i REAL(wp), ALLOCATABLE :: kn_arr(:) - CHARACTER(256) :: em + CHARACTER(1024) :: em TYPE(CableSolverConfig) :: cfg converged = .FALSE. @@ -206,7 +206,7 @@ SUBROUTINE CD_Run_Line_Static_Driver(input_path, output_path, converged, ErrStat REAL(wp), ALLOCATABLE :: l0(:), ea(:), mass_pl(:), diam(:), w(:), load(:, :) REAL(wp), ALLOCATABLE :: f_ext(:), q0(:), q(:), tension(:), kn(:) INTEGER :: n_elem, n_nodes, n_dof, es, i, n_iter, n_stages - CHARACTER(256) :: em + CHARACTER(1024) :: em converged = .FALSE. ErrStat = CD_DRIVER_OK diff --git a/src/CableDyn_Dynamic.f90 b/src/CableDyn_Dynamic.f90 index 03df8de5..4b753adf 100644 --- a/src/CableDyn_Dynamic.f90 +++ b/src/CableDyn_Dynamic.f90 @@ -434,7 +434,7 @@ SUBROUTINE CD_Cable_Initial_Acceleration(q, v, elem_conn, l0, ea, rho_a, tension TYPE(CD_CableGenAlphaWorkspace), TARGET :: local_workspace TYPE(CD_CableGenAlphaWorkspace), POINTER :: work INTEGER :: es - CHARACTER(120) :: em + CHARACTER(1024) :: em LOGICAL :: use_element_mass_band a0 = CD_ZERO @@ -758,7 +758,7 @@ SUBROUTINE CD_Cable_Gen_Alpha_Step(q, v, a, elem_conn, l0, ea, rho_a, tension_on LOGICAL :: factored_now, guess_used, prev_end_ok, reuse_factor, reused, warm_call, r_at_qk LOGICAL :: scales_stale, trial_is_iterate INTEGER :: es - CHARACTER(120) :: em + CHARACTER(1024) :: em q_new = CD_ZERO v_new = CD_ZERO @@ -1439,7 +1439,7 @@ SUBROUTINE end_junction_data() !! factors the tangent at qk once. INTEGER :: nfx, j, i, k2, es2 REAL(wp) :: h, acc - CHARACTER(120) :: em2 + CHARACTER(1024) :: em2 LOGICAL :: keep LOGICAL :: act(SIZE(fixed)) REAL(wp), ALLOCATABLE :: sfe(:, :) @@ -2586,7 +2586,7 @@ SUBROUTINE validate_topology_once(work, elem_conn, n_nodes, validated) INTEGER, INTENT(IN) :: elem_conn(:, :), n_nodes LOGICAL, INTENT(OUT) :: validated INTEGER :: es, istat - CHARACTER(160) :: em + CHARACTER(1024) :: em validated = work%topo_valid IF (validated) validated = work%topo_n_nodes == n_nodes diff --git a/src/CableDyn_FiniteEIModel.f90 b/src/CableDyn_FiniteEIModel.f90 index 84f60be5..38555917 100644 --- a/src/CableDyn_FiniteEIModel.f90 +++ b/src/CableDyn_FiniteEIModel.f90 @@ -77,7 +77,7 @@ SUBROUTINE CD_Init_FiniteEI_Model(model, nodes_ref, elem_conn, ea, gas, ei, gj, INTEGER :: n_nodes, n_elem, n_dof, i, es TYPE(CD_FiniteEIModelType) :: old_model - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DYN_OK ErrMsg = '' @@ -324,7 +324,7 @@ SUBROUTINE CD_Set_FiniteEI_Model_PrescribedDofs(model, dofs, q_vals, v_vals, a_v INTEGER :: i, d, es LOGICAL :: do_recompute REAL(wp), ALLOCATABLE :: q_tmp(:), v_tmp(:), a_tmp(:), a_presc(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DYN_OK ErrMsg = '' @@ -410,7 +410,7 @@ SUBROUTINE CD_Set_FiniteEI_Model_Load(model, f_ext, ErrStat, ErrMsg, recompute_a LOGICAL :: recompute INTEGER :: es REAL(wp), ALLOCATABLE :: a_tmp(:), a_presc(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_DYN_OK ErrMsg = '' diff --git a/src/CableDyn_FiniteEIStatic.f90 b/src/CableDyn_FiniteEIStatic.f90 index 7b948a19..db382be5 100644 --- a/src/CableDyn_FiniteEIStatic.f90 +++ b/src/CableDyn_FiniteEIStatic.f90 @@ -344,7 +344,7 @@ SUBROUTINE newton_nd(q0, nodes_ref, elem_conn, ea, gas, ei, gj, f_ext, fixed, kn REAL(wp), ALLOCATABLE :: R_free(:), dq(:), dq_global(:), q_trial(:), R_trial(:) REAL(wp) :: f_ext_base, conv_scale, scale_trial, rnorm, merit, merit_trial, alpha INTEGER :: n_free, iteration, bt, nd, zdof, es - CHARACTER(120) :: em + CHARACTER(1024) :: em converged = .FALSE.; stalled = .FALSE. ErrStat = CD_FEI_OK; ErrMsg = '' @@ -422,7 +422,7 @@ SUBROUTINE eval_residual(qe, Rf, sc) REAL(wp), INTENT(IN) :: qe(:) REAL(wp), INTENT(OUT) :: Rf(:), sc INTEGER :: ndl, zdofl, es_e - CHARACTER(120) :: em_e + CHARACTER(1024) :: em_e CALL CD_Assemble_Cosserat_Internal_Force(nodes_ref, elem_conn, ea, gas, ei, gj, qe, & .TRUE., fint, es_e, em_e) IF (es_e /= 0) THEN diff --git a/src/CableDyn_HermiteArch.f90 b/src/CableDyn_HermiteArch.f90 index 1b6f14a4..0bbda671 100644 --- a/src/CableDyn_HermiteArch.f90 +++ b/src/CableDyn_HermiteArch.f90 @@ -230,7 +230,7 @@ SUBROUTINE CD_FiniteEI_Hermite_Arch_Seed_LengthMatched(end_a, end_b, tan_a, tan_ REAL(wp), ALLOCATABLE :: q_trial(:), nodes_trial(:, :), arc_trial(:), curvature_trial(:) REAL(wp) :: total_l, lo, hi, mid, trial_len, tol INTEGER :: n_elem, n_nodes, iter, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HARCH_OK ErrMsg = '' diff --git a/src/CableDyn_HermiteCable.f90 b/src/CableDyn_HermiteCable.f90 index 2dea8258..8dbcf467 100644 --- a/src/CableDyn_HermiteCable.f90 +++ b/src/CableDyn_HermiteCable.f90 @@ -70,7 +70,7 @@ SUBROUTINE CD_HermiteCable_Element(qr, L, EA, EI, Eout, fint, Kt, ErrStat, ErrMs REAL(wp) :: energy_axial, energy_bending, force_axial(12), force_bending(12) REAL(wp) :: tangent_axial(12, 12), tangent_bending(12, 12) INTEGER :: axial_order, bending_order, es - CHARACTER(200) :: em + CHARACTER(1024) :: em LOGICAL :: half_tangent, only_tangent axial_order = NG @@ -515,7 +515,7 @@ SUBROUTINE curv_at(u, curvature) REAL(wp), INTENT(IN) :: u REAL(wp), INTENT(OUT) :: curvature INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL CD_HermiteCable_Curvature(qr, L, u, curvature, es, em) IF (es /= CD_HCABLE_OK) THEN ErrStat = es @@ -633,7 +633,7 @@ SUBROUTINE resultant_at(u, resultant) REAL(wp), INTENT(IN) :: u REAL(wp), INTENT(OUT) :: resultant INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL CD_HermiteCable_Axial_Resultant(qr, L, EA, u, resultant, es, em) IF (es /= CD_HCABLE_OK) THEN ErrStat = es diff --git a/src/CableDyn_HermiteCableDynamic.f90 b/src/CableDyn_HermiteCableDynamic.f90 index 02a635a3..28d446fc 100644 --- a/src/CableDyn_HermiteCableDynamic.f90 +++ b/src/CableDyn_HermiteCableDynamic.f90 @@ -272,7 +272,7 @@ MODULE CableDyn_HermiteCableDynamic REAL(wp), ALLOCATABLE :: ws_elem_f(:, :), ws_elem_K(:, :, :), ws_elem_Kdrag(:, :, :) REAL(wp), ALLOCATABLE :: ws_elem_Kv(:, :, :), ws_elem_Kwave(:, :, :), ws_elem_Kheld(:, :, :) INTEGER, ALLOCATABLE :: ws_elem_es(:) - CHARACTER(200), ALLOCATABLE :: ws_elem_em(:) + CHARACTER(512), ALLOCATABLE :: ws_elem_em(:) REAL(wp) :: alpha_m = CD_ZERO, alpha_f = CD_ZERO, beta = CD_ZERO, gamma = CD_ZERO ! Optional Morison drag (transverse + tangential quadratic drag on the submerged cable, relative ! to a uniform fluid velocity). Off by default; wired in via CD_HermiteCable_Dyn_Set_Drag. @@ -554,7 +554,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Init(model, l0, EA, EI, rho_a, w, seed, fixed_dof INTEGER :: ne, nn, ndof, i, e, es, nf, gi REAL(wp) :: Me(12, 12), rho - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK ErrMsg = '' @@ -717,7 +717,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Contact(model, kn_node, cn_node, mu, ErrStat, REAL(wp), ALLOCATABLE :: new_kn(:), new_cn(:), old_kn(:), old_cn(:), old_a(:) LOGICAL :: old_has_contact, old_has_bathymetry TYPE(CD_BathymetryType) :: new_bathymetry, old_bathymetry - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' model%rc_epoch = model%rc_epoch + 1 @@ -888,7 +888,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Friction_Anchors(model, anchors, ErrStat, Err REAL(wp), ALLOCATABLE :: a_old(:), anchor_old(:, :) LOGICAL :: active_old INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' IF (.NOT. model%initialized) THEN @@ -957,7 +957,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Attachments(model, node, mass, volume, cda, c CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: n, k, d, dof, es REAL(wp), ALLOCATABLE :: a_old(:), mgb_old(:, :) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' n = SIZE(node) @@ -1848,7 +1848,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_EndConnection(model, k_rot, d0, ErrStat, ErrM LOGICAL :: had_conn, snap_was_valid LOGICAL, ALLOCATABLE :: solve_mask_old(:) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' ! A load-configuration change invalidates the cached committed force F_n. @@ -2316,7 +2316,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Axial_Damping(model, BA, ErrStat, ErrMsg) REAL(wp), ALLOCATABLE :: old_BA(:), new_BA(:), old_a(:) LOGICAL :: old_has INTEGER :: es, istat - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK model%rc_epoch = model%rc_epoch + 1 @@ -2483,7 +2483,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Waves(model, height, period, direction_deg, d REAL(wp) :: h_old, om_old, k_old, dep_old, dir_old, omega, k LOGICAL :: had_wave INTEGER :: es - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' model%rc_epoch = model%rc_epoch + 1 @@ -2603,7 +2603,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Irregular_Waves(model, amplitude, period, pha REAL(wp) :: h_old, om_old, k_old, dep_old, dir_old LOGICAL :: had_wave INTEGER :: i, n, nc_old, es - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' model%rc_epoch = model%rc_epoch + 1 @@ -2741,7 +2741,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Held_Fluid(model, fluid_velocity, fluid_accel CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: istat, es LOGICAL :: had_field - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' model%rc_epoch = model%rc_epoch + 1 ! A load-configuration change invalidates the cached committed force F_n. The carried step @@ -3081,7 +3081,7 @@ SUBROUTINE dyn_step_core(model, dt, max_iter, tol, ErrStat, ErrMsg, iters_out, r ! Newton's. REAL(wp), PARAMETER :: XS_TOL_FACTOR = 0.3_wp INTEGER(INT64) :: pc0, pc1, pcr, pt0, pt1 - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK ErrMsg = '' @@ -3902,7 +3902,7 @@ SUBROUTINE dyn_step_core(model, dt, max_iter, tol, ErrStat, ErrMsg, iters_out, r ! cache; a failure here only leaves it invalid (a query then evaluates and reports it) BLOCK INTEGER :: es_tc - CHARACTER(200) :: em_tc + CHARACTER(1024) :: em_tc CALL torsion_cache_fill(model, es_tc, em_tc) END BLOCK END IF @@ -4292,7 +4292,7 @@ SUBROUTINE torsion_theta_at(model, q_cfg, ends, theta, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: raw INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em theta = model%torsion%theta CALL CD_HermiteTorsion_Line(q_cfg, model%l0, ends, raw, model%tors_gq, es, em, & quadrature_order=model%torsion%quadrature_order, work=model%tors_work) @@ -4385,7 +4385,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Step_Recovering(model, dt, max_iter, tol, ErrStat ! The step-rotation diagnostic must not keep the turn of a step that is rewound. REAL(wp) :: rotation_save REAL(wp) :: tors_theta0, tors_phi0, tors_phi1, tors_ends0(3, 4), tors_ends1(3, 4), tors_sub(3, 4) - CHARACTER(300) :: em + CHARACTER(1024) :: em ! Tensile-qualification failure flag reported by each step (classified by flag, not by ! message text, so a short caller buffer cannot change the recovery decision). LOGICAL :: tensile_fail @@ -4919,7 +4919,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Energy(model, kinetic, strain, ErrStat, ErrMsg, c REAL(wp), INTENT(OUT), OPTIONAL :: connection INTEGER :: e, es REAL(wp) :: qe(12), Ee, fe(12), Ke(12, 12), connection_energy, end_energy - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = ''; kinetic = CD_ZERO; strain = CD_ZERO connection_energy = CD_ZERO IF (PRESENT(connection)) connection = CD_ZERO @@ -5011,7 +5011,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Curvature_Exact(model, curv_out, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: a, es REAL(wp) :: qe(12), kL, kR - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' IF (.NOT. model%initialized) THEN ErrStat = CD_HCDYN_BADINPUT; ErrMsg = 'CD_HermiteCable_Dyn_Curvature_Exact: model not initialised'; RETURN @@ -5065,7 +5065,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Reaction(model, node, freac, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, gi - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = ''; freac = CD_ZERO IF (.NOT. model%initialized) THEN ErrStat = CD_HCDYN_BADINPUT; ErrMsg = 'CD_HermiteCable_Dyn_Reaction: model not initialised'; RETURN @@ -5117,7 +5117,7 @@ SUBROUTINE CD_HermiteCable_Dyn_End_Force(model, node, force, ErrStat, ErrMsg) REAL(wp) :: curv_e(3), fcrease_e(3), kcrease_e(3, 3) INTEGER :: e, i0, iz, zslot, es, k LOGICAL :: dry, has_jac - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = ''; force = CD_ZERO; gap = -HUGE(CD_ONE) IF (.NOT. model%initialized) THEN @@ -5789,7 +5789,7 @@ SUBROUTINE CD_HermiteCable_Dyn_EndConnection_Moment(model, node, moment, ErrStat INTEGER :: iend, base, es REAL(wp) :: f_ec(3), k_ec(3, 3), direction(3), bend_moment(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em moment = CD_ZERO ErrStat = CD_HCDYN_OK @@ -5905,7 +5905,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Set_Torsion(model, torsion, ErrStat, ErrMsg) REAL(wp) :: saved_drive_ends(3, 4), saved_drive_phi LOGICAL :: saved_snap_valid, saved_drive_set INTEGER :: es, iend - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK ErrMsg = '' IF (.NOT. model%initialized) THEN @@ -6025,7 +6025,7 @@ SUBROUTINE CD_HermiteCable_Dyn_Torsion_State(model, theta, torque, ErrStat, ErrM REAL(wp), ALLOCATABLE :: g(:) REAL(wp) :: raw, eg(6), c INTEGER :: es, nb - CHARACTER(200) :: em + CHARACTER(1024) :: em theta = CD_ZERO torque = CD_ZERO IF (PRESENT(grad)) grad = CD_ZERO @@ -6107,7 +6107,7 @@ SUBROUTINE torsion_cache_fill(model, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: raw, eg(6), th INTEGER :: es, nb, i - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK ErrMsg = '' model%tors_c_valid = .FALSE. @@ -6418,7 +6418,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta LOGICAL :: dry REAL(wp) :: endconn_d0_eval(3, 2), support(3), dsupport(3), nin(3), mend INTEGER :: inode, jr, jc - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' ne = model%ne @@ -6870,7 +6870,7 @@ SUBROUTINE assemble_torsion(model, q_cfg, want_residual, want_tangent, ErrStat, REAL(wp), POINTER :: g(:) REAL(wp) :: raw, th, mt, phi INTEGER :: es, i - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK ErrMsg = '' IF (want_tangent) THEN @@ -6965,7 +6965,7 @@ SUBROUTINE assemble_contact(model, q_cfg, v_cfg, want_residual, want_tangent, Er REAL(wp) :: ffr(2), dfr_dd(2, 2), dfr_dc(2) REAL(wp) :: curv_g(3), curv_l(3), fcrease(3), kcrease(3, 3) LOGICAL :: creased - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' IF (.NOT. model%has_contact .OR. .NOT. ALLOCATED(model%contact_kn) .OR. & @@ -7103,7 +7103,7 @@ LOGICAL FUNCTION held_end_floor_support(model, q_cfg, iend, support, dsupport, i INTEGER, INTENT(OUT) :: inode INTEGER :: node, e, ix, es REAL(wp) :: gap, sfac, share, nvec(3), sfac_in, gap_in, normal, normal_gap, elem, delem - CHARACTER(200) :: em + CHARACTER(1024) :: em support = CD_ZERO dsupport = CD_ZERO nin = [CD_ZERO, CD_ZERO, CD_ONE] @@ -7176,7 +7176,7 @@ SUBROUTINE commit_friction_anchors(model) INTEGER :: i, ix, iz, es REAL(wp) :: xl, yl, xg, yg, z_floor, gxg, gyg, gap, normal, normal_gap, gate, gate_gap REAL(wp) :: dxy(2), dlen, cap, mu_d, q_d, gq_d(2), gx, gy, sfac, nvec(3), vn - CHARACTER(200) :: em + CHARACTER(1024) :: em DO i = 1, model%nn ix = 6*i - 5; iz = ix + 2 gx = CD_ZERO @@ -7246,7 +7246,7 @@ SUBROUTINE evaluate_tangent_element(model, e, q_cfg, v_cfg, t_eval, Kstruct, Kdr REAL(wp) :: djq(12, 12), djv(12, 12), fjq(12, 12) REAL(wp) :: hf_mid(3) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' qe(1:6) = q_cfg(6*(e - 1) + 1:6*e) @@ -7591,7 +7591,7 @@ SUBROUTINE CD_HermiteCable_Drag_Element(qe, ve, l0, fluid, waterline_z, rho, dia REAL(wp) :: scale, eta_w, uw(3), aw(3) LOGICAL :: has_wv, has_shared, has_trio, has_cmp, any_wv_arg, want_jac INTEGER :: g, s, c, sp, cp, a, b, es - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(djq) @@ -7864,7 +7864,7 @@ SUBROUTINE CD_HermiteCable_FK_Element(qe, l0, waterline_z, rho, diam, can, cat, REAL(wp) :: fpl(3), Jtan(3, 3), proj(3, 3), projk(3), dalpha LOGICAL :: has_trio, has_cmp, has_held, want_jac INTEGER :: g, s, c, sp, cp, a, b, k, es - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(fjq) @@ -8038,7 +8038,7 @@ SUBROUTINE assemble_added_mass(model, q_cfg, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: e, es REAL(wp) :: qe(12), Me(12, 12), wl_e - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' model%ws_Mamb = CD_ZERO IF (.NOT. model%has_am) RETURN @@ -8074,7 +8074,7 @@ SUBROUTINE build_rigid_bases(model, directions, bases, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: iend, es - CHARACTER(200) :: em + CHARACTER(1024) :: em bases = CD_ZERO ErrStat = CD_HCDYN_OK ErrMsg = '' @@ -8097,7 +8097,7 @@ SUBROUTINE project_rigid_tangents(model, directions, q, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: iend, base, es REAL(wp) :: projected(3) - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCDYN_OK ErrMsg = '' DO iend = 1, 2 @@ -8284,7 +8284,7 @@ SUBROUTINE solve_consistent_acceleration(model, ErrStat, ErrMsg, pres_dofs, pres INTEGER :: nf, np, i, ip, jp, gdof, es, iend, base LOGICAL :: has_pres REAL(wp) :: rigid_basis(3, 3, 2), old_acceleration(3), axial_acceleration - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' ! This solve factors the mass into ws_Keffb: the carried step factor is gone. model%tr_valid = .FALSE. diff --git a/src/CableDyn_HermiteCableStatic.f90 b/src/CableDyn_HermiteCableStatic.f90 index 626c2efe..d8df857a 100644 --- a/src/CableDyn_HermiteCableStatic.f90 +++ b/src/CableDyn_HermiteCableStatic.f90 @@ -477,7 +477,7 @@ SUBROUTINE CD_HermiteCable_Static_Solve(l0, EA, EI, w, seed, fixed_dofs, seabed_ REAL(wp), ALLOCATABLE :: R(:), dq(:), ab(:, :), ab_recovery(:, :), scaled_residual(:) REAL(wp), ALLOCATABLE :: elem_f(:, :), elem_K(:, :, :), elem_E(:) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(200), ALLOCATABLE :: elem_em(:) + CHARACTER(512), ALLOCATABLE :: elem_em(:) ! Secant-predictor history: the converged states of the two previous buoyancy ! stages (q_sec1 = stage b-1, q_sec2 = stage b-2). REAL(wp), ALLOCATABLE :: q_sec1(:), q_sec2(:) @@ -1093,7 +1093,7 @@ RECURSIVE SUBROUTINE newton_step(rnorm, es, em, do_update) INTEGER :: jr, jc INTEGER :: e, a, b, gi, gj, j, es2, bt, es_trial, zdof(4) LOGICAL :: dry, accepted - CHARACTER(200) :: em2, em_trial + CHARACTER(1024) :: em2, em_trial es = CD_HCSTAT_OK; em = ''; rnorm = CD_ZERO; merit = CD_ZERO IF (use_rigid) THEN @@ -1556,7 +1556,7 @@ RECURSIVE SUBROUTINE energy_update(es, em) REAL(wp) :: pi0, pi_abs0, merit0, dmax, gd, alpha, trial_norm, sc, share0(2) INTEGER :: shift, bt, j, i, es_trial, info LOGICAL :: accepted - CHARACTER(200) :: em_trial + CHARACTER(1024) :: em_trial EXTERNAL :: dpbtrf, dpbtrs es = CD_HCSTAT_OK; em = '' @@ -1820,7 +1820,7 @@ SUBROUTINE torsion_continuation(ecs, ecm) INTEGER :: ks, cuts, wios LOGICAL :: ok CHARACTER(200) :: km - CHARACTER(512) :: why + CHARACTER(1024) :: why CHARACTER(1024) :: wbuf ecs = CD_HCSTAT_OK ecm = '' @@ -2516,7 +2516,7 @@ SUBROUTINE add_end_support(iend, e, inode, sgn, sp_stat, sp_msg) REAL(wp) :: z_fl, gxg_s, gyg_s, g_s(2), sf, n_in(3), pen_s, normal_s, normal_gap_s, elem, delem, mom REAL(wp) :: elem_pi INTEGER :: base, bin, i, j - CHARACTER(200) :: em_s + CHARACTER(1024) :: em_s sp_stat = CD_HCSTAT_OK sp_msg = '' base = MERGE(3, 6*(nn - 1) + 3, iend == 1) ! end tangent DOFs are base+1 .. base+3 @@ -2593,7 +2593,7 @@ REAL(wp) FUNCTION nodal_curvature(a) RESULT(kap) INTEGER, INTENT(IN) :: a REAL(wp) :: qe(12), kL, kR INTEGER :: es3 - CHARACTER(200) :: em3 + CHARACTER(1024) :: em3 kap = CD_ZERO IF (a <= ne) THEN CALL gather_elem(a, qe) @@ -2804,7 +2804,7 @@ SUBROUTINE CD_HermiteCable_Friction_Anchors(l0, q, fr, contact_kn, seabed_z, anc REAL(wp), ALLOCATABLE :: ref(:, :) REAL(wp) :: z_floor, gxg, gyg, xg, yg, normal, normal_gap, dfd(2, 2), dfc(2), cs(2) INTEGER :: node, ix, nn, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' nn = SIZE(l0) + 1 @@ -2930,7 +2930,7 @@ SUBROUTINE current_element_load(current, qe, l0e, d, cn, ct, want_jac, fd, djq, CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: ve(12), djv(12, 12), ua(3), ub(3), ug(3), ul(3) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' fd = CD_ZERO @@ -3053,10 +3053,10 @@ FUNCTION current_compression_note(l0, EA, qx, seabed_z, flat, frictional, fricti ! TRUE for the two frictionless grounded-run diagnoses (the run folds against its end or ! is pushed along the seabed in compression). LOGICAL, INTENT(OUT), OPTIONAL :: frictionless_run - CHARACTER(512) :: note + CHARACTER(1024) :: note REAL(wp) :: t_min, t_max, s_min, z_min, z_top INTEGER :: k, k_min, wios, ne, es - CHARACTER(200) :: em + CHARACTER(1024) :: em note = '' IF (PRESENT(frictionless_run)) frictionless_run = .FALSE. ne = SIZE(l0) @@ -3162,7 +3162,7 @@ SUBROUTINE CD_HermiteCable_Static_Solve_Continuation(l0, EA, EI, w, seed, fixed_ REAL(wp) :: lambda, lambda_try, dlog, stage_tol, res REAL(wp), ALLOCATABLE :: q(:), q_try(:), curv(:), ei_stage(:) REAL(wp) :: k_stage(2) - CHARACTER(512) :: em + CHARACTER(1024) :: em LOGICAL :: final_stage, restart_stage, snapped ! The current is brought in after the still-water EI continuation (unallocated: the ! stages run without the configuration-dependent drag). @@ -3479,7 +3479,7 @@ LOGICAL FUNCTION frictionless_run_limit(qx) RESULT(run_limit) !! TRUE when the diagnosis of state qx is a grounded run driven along a frictionless !! seabed (see current_compression_note). REAL(wp), INTENT(IN) :: qx(:) - CHARACTER(512) :: note + CHARACTER(1024) :: note LOGICAL :: flat flat = .NOT. PRESENT(bathymetry) run_limit = .FALSE. @@ -3491,7 +3491,7 @@ END FUNCTION frictionless_run_limit FUNCTION compression_note(qx) RESULT(note) !! current_compression_note for this line (flat seabed plane unless bathymetry). REAL(wp), INTENT(IN) :: qx(:) - CHARACTER(512) :: note + CHARACTER(1024) :: note LOGICAL :: flat flat = .NOT. PRESENT(bathymetry) note = '' @@ -3803,7 +3803,7 @@ SUBROUTINE friction_capacity(qx, cap) REAL(wp) :: z_floor, gxg, gyg, xg, yg, normal, normal_gap, trib_k, cs(2), mu_c, q_c, gq_c(2) REAL(wp), ALLOCATABLE :: fr_ref_c(:, :), kn_c(:) INTEGER :: k, es_c - CHARACTER(200) :: em_c + CHARACTER(1024) :: em_c cs = [CD_ONE, CD_ZERO] IF (PRESENT(contact_frame_cs)) cs = contact_frame_cs IF (current%friction%mu_axial > CD_ZERO .AND. ABS(current%friction%mu_axial - current%friction%mu) > CD_ZERO) THEN @@ -4514,7 +4514,7 @@ SUBROUTINE solve_seq_try(l0, EA, EI, w, seed, fixed_dofs, seabed_z, kn, & REAL(wp), ALLOCATABLE :: q_prev(:) INTEGER, ALLOCATABLE :: fx_l(:), nodes_l(:), nodes_prev(:) TYPE(CD_HermiteResolutionType) :: coarse_diag - CHARACTER(300) :: em_l + CHARACTER(1024) :: em_l ! The level solve failed only on its final residual (a finite best iterate to continue from). LOGICAL :: unmet_l CHARACTER(200) :: diagnostic_msg @@ -5066,7 +5066,7 @@ SUBROUTINE reject_unresolved_sequence(l0, q, ErrStat, ErrMsg) CHARACTER(*), INTENT(INOUT) :: ErrMsg INTEGER :: es, ne TYPE(CD_HermiteResolutionType) :: diag - CHARACTER(200) :: em + CHARACTER(1024) :: em IF (ErrStat /= CD_HCSTAT_OK) RETURN ne = SIZE(l0) @@ -5139,7 +5139,7 @@ SUBROUTINE CD_HermiteCable_Resolution_Metrics(l0, q, seabed_z, contact_band, & axial_element_min, axial_element_min_xi, axial_element_max, axial_element_max_xi, & axial_element_strain, tol_e, tol_rel, ratio REAL(wp), ALLOCATABLE :: elem_min(:), elem_min_xi(:), elem_max(:) - CHARACTER(120) :: em3 + CHARACTER(1024) :: em3 LOGICAL, ALLOCATABLE :: contact_node(:) LOGICAL :: in_island, axial_strain_seen @@ -5473,7 +5473,7 @@ SUBROUTINE CD_HermiteCable_Branch_Audit(l0, q, EA, audit, ErrStat, ErrMsg, end_z REAL(wp) :: H(4), dH(4), r(3), rp(3), ke, u_peak, nmin, nmax, umin, umax, ea_max, nmean, ng, allowance REAL(wp) :: reversal, emean(SIZE(l0)), sm, wl LOGICAL :: reject_c, folded - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' @@ -5950,7 +5950,7 @@ SUBROUTINE compressive_refinement_marks(l0, q, EA, marks, ErrStat, ErrMsg, compr REAL(wp) :: qe(12), nmin, xmin, nmax, xmax, tol_rel, tol_e REAL(wp), ALLOCATABLE :: elem_min(:) LOGICAL, ALLOCATABLE :: raw(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK; ErrMsg = '' IF (SIZE(l0) < 1 .OR. SIZE(EA) /= SIZE(l0) .OR. SIZE(q) /= 6*(SIZE(l0) + 1)) THEN @@ -6597,7 +6597,7 @@ REAL(wp) FUNCTION max_penetration(qx) RESULT(pen) REAL(wp), INTENT(IN) :: qx(:) INTEGER :: node, gz, esx REAL(wp) :: z_floor - CHARACTER(200) :: emx + CHARACTER(1024) :: emx pen = CD_ZERO DO node = 1, SIZE(qx)/6 gz = 6*(node - 1) + 3 diff --git a/src/CableDyn_HermiteTorsion.f90 b/src/CableDyn_HermiteTorsion.f90 index abbab9dd..44d5872b 100644 --- a/src/CableDyn_HermiteTorsion.f90 +++ b/src/CableDyn_HermiteTorsion.f90 @@ -237,7 +237,7 @@ SUBROUTINE CD_HermiteTorsion_Bordered_Solve(ab, kl, ku, g, compliance, rhs, x, E REAL(wp) :: sigma, eta, knorm INTEGER :: n, ldab, attempt, refine LOGICAL :: ok, finite_fail - CHARACTER(160) :: why + CHARACTER(1024) :: why x = CD_ZERO IF (PRESENT(backward_error)) backward_error = HUGE(CD_ONE) @@ -329,7 +329,7 @@ SUBROUTINE dense_solve(success) LOGICAL, INTENT(OUT) :: success REAL(wp), ALLOCATABLE :: kd(:, :) INTEGER :: i, j, info - CHARACTER(200) :: lmsg + CHARACTER(1024) :: lmsg ALLOCATE (kd(n, n)) DO j = 1, n DO i = 1, n @@ -708,7 +708,7 @@ PURE SUBROUTINE CD_HermiteTorsion_Element(qe, L, h, grad, ErrStat, ErrMsg, hess, REAL(wp) :: hk(12, 12), margin INTEGER :: order - CHARACTER(200) :: em + CHARACTER(1024) :: em order = NG_DEFAULT IF (PRESENT(quadrature_order)) order = quadrature_order @@ -992,7 +992,7 @@ PURE SUBROUTINE line_core(q, Le, ends, theta_raw, grad, ErrStat, ErrMsg, nw, u, LOGICAL :: want_hess, finite REAL(wp) :: scale, margin, he, ge(12), hk(12, 12), v(3), chi, sum_h, eg(6), eh(3, 3, 2), ec(3, 3, 2) REAL(wp) :: om, g9(9), h9(9, 9), pj(3, 3), pk(3, 3), sd(3, 3), dmy - CHARACTER(200) :: em + CHARACTER(1024) :: em theta_raw = CD_ZERO grad = CD_ZERO diff --git a/src/CableDyn_Modal.f90 b/src/CableDyn_Modal.f90 index ed705916..358870f3 100644 --- a/src/CableDyn_Modal.f90 +++ b/src/CableDyn_Modal.f90 @@ -184,7 +184,7 @@ SUBROUTINE CD_Modal_Bar_Band(q, elem_conn, l0, ea, rho_a, tension_only, kd, K, M REAL(wp), INTENT(IN), OPTIONAL :: seabed_kn(:), floor_z(:) INTEGER :: n, nn, ne, e, a, b, ia, ib, i, j, conn1(2, 1), gd(6) REAL(wp) :: d(3), l, t, ke(3, 3), mm, ke6(6, 6), me6(6, 6), ma(6, 6), q2(6), wl2(2), l02(1), f, df - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_MODAL_OK ErrMsg = '' @@ -298,7 +298,7 @@ SUBROUTINE CD_Modal_Hermite_Band(q, l0, ea, ei, rho_a, kd, K, M, ErrStat, ErrMsg REAL(wp), INTENT(IN), OPTIONAL :: contact_kn(:), floor_z(:) INTEGER :: n, nn, ne, e, i0, i, ao, bo, gd(12) REAL(wp) :: qe(12), energy, fint(12), kt(12, 12), me(12, 12), ma(12, 12), f, df - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_MODAL_OK ErrMsg = '' @@ -441,7 +441,7 @@ SUBROUTINE CD_Modal_Solve_Band(K, M, kd, free, n_modes, omega2, shapes, n_found, REAL(wp), ALLOCATABLE :: vec(:, :), bvec(:, :) REAL(wp) :: qdum(1, 1), zdum(1, 1), anorm, bnorm, shift, scale, nrm, res, rq, noise LOGICAL :: converged - CHARACTER(512) :: em + CHARACTER(1024) :: em EXTERNAL :: dsbgvx ErrStat = CD_MODAL_OK diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index 631fc344..2161f3cb 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -485,7 +485,7 @@ SUBROUTINE CD_Init_Model(model, q0, v0, elem_conn, l0, ea, rho_a, tension_only, INTEGER :: n_dof, n_elem, n_nodes, es, istat, e INTEGER, ALLOCATABLE :: free(:) TYPE(CD_ModelType) :: old_model - CHARACTER(160) :: em + CHARACTER(1024) :: em LOGICAL :: use_seabed, use_seabed_damping, use_seabed_friction LOGICAL :: use_damping, use_drag, use_fk, use_buoyancy, use_added_mass, has_load LOGICAL :: use_viscoelastic, use_syrope @@ -1518,7 +1518,7 @@ SUBROUTINE CD_Init_Line_Model(model, anchor, fairlead, line_types, sections, gra REAL(wp) :: laid_az, laid_t LOGICAL :: reverse_line, converged, use_current LOGICAL :: use_seabed, use_seabed_damping, use_seabed_friction, use_damping - CHARACTER(200) :: em + CHARACTER(1024) :: em TYPE(CableCurrentLoad) :: cur TYPE(CD_StaticLineReport) :: report @@ -2540,7 +2540,7 @@ SUBROUTINE step_model_plain(model, dt, converged, stalled, n_iter, ErrStat, ErrM REAL(wp), INTENT(IN), OPTIONAL :: prescribed_q(:), prescribed_v(:), prescribed_a(:) INTEGER :: es, e - CHARACTER(160) :: em + CHARACTER(1024) :: em LOGICAL :: has_load, blend, force_lengths REAL(wp) :: af REAL(wp), ALLOCATABLE :: l0_new(:), l0_dot_new(:), l0_start(:), l0_mass(:), f_ext_new(:), f_ext_c(:) @@ -2748,7 +2748,7 @@ SUBROUTINE step_model_plain(model, dt, converged, stalled, n_iter, ErrStat, ErrM BLOCK INTEGER :: e2, na, nb, es2 REAL(wp) :: ea_d_eff, ea_1_eff - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 DO e2 = 1, model%n_elem IF (model%ve_mode(e2) == 0) CYCLE na = model%elem_conn(1, e2) @@ -2804,7 +2804,7 @@ SUBROUTINE step_model_plain(model, dt, converged, stalled, n_iter, ErrStat, ErrM BLOCK INTEGER :: e2, na, nb, es2 REAL(wp) :: dl1_next, ea_d_eff, ea_1_eff - CHARACTER(200) :: em2 + CHARACTER(1024) :: em2 DO e2 = 1, model%n_elem IF (model%ve_mode(e2) == 0) CYCLE CALL model_viscoelastic_coeffs(model, e2, ea_d_eff, ea_1_eff, es2, em2) @@ -2998,7 +2998,7 @@ SUBROUTINE CD_Step_Model_Recovering(model, dt, converged, stalled, n_iter, ErrSt REAL(wp) :: subdt, fraction, hmax0 TYPE(CD_SubstepStats) :: stats0 REAL(wp), ALLOCATABLE :: pq(:), pv(:), pa(:) - CHARACTER(300) :: em, first_em + CHARACTER(1024) :: em, first_em converged = .FALSE. stalled = .FALSE. @@ -3711,7 +3711,7 @@ SUBROUTINE CD_Set_Model_Syrope_State(model, slow, tmax, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: e, es REAL(wp) :: ws(CD_SYROPE_NWC), wt(CD_SYROPE_NWC), wsl(CD_SYROPE_NWC) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' IF (.NOT. model%initialized) THEN @@ -3871,7 +3871,7 @@ SUBROUTINE CD_Calc_Model_CoupledLoads(model, coupled_loads, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, istat, k - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -3955,7 +3955,7 @@ SUBROUTINE CD_Calc_Model_CoupledKinematicDerivatives(model, dload_dq, dload_dv, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, nc, n_free, i, j, row, col - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -4105,7 +4105,7 @@ SUBROUTINE CD_Update_Model_CoupledAccelDerivative(model, ErrStat, ErrMsg) INTEGER :: idx(6), conn1(2, 1) REAL(wp) :: coeff, s, q2(6), l02(1), wl2(2), m2(6, 6) LOGICAL :: hit, ok - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -4454,7 +4454,7 @@ SUBROUTINE CD_Update_Model_SegmentLength(model, elem, l0_new, l0_dot, ErrStat, E LOGICAL, INTENT(IN), OPTIONAL :: restored INTEGER :: es REAL(wp) :: rate - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' rate = positive_zero(l0_dot) @@ -4674,7 +4674,7 @@ SUBROUTINE CD_Get_Model_EndNodeAddedMass(model, coupled_slot, ma_block, ErrStat, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: e, node, d0, idx(6), es REAL(wp) :: q2(6), wl2(2), m2(6, 6) - CHARACTER(160) :: em + CHARACTER(1024) :: em ma_block = CD_ZERO ErrStat = CD_MODEL_OK ErrMsg = '' @@ -4979,7 +4979,7 @@ SUBROUTINE CD_Get_Model_EndForces(model, force_first, force_last, ErrStat, ErrMs REAL(wp) :: load(9) REAL(wp) :: fint_first(3), fint_last(3), nodes6(6), Kt6(6, 6), fint6(6), Te INTEGER :: es, n, nn, e, a, b - CHARACTER(160) :: em + CHARACTER(1024) :: em force_first = CD_ZERO force_last = CD_ZERO @@ -5035,7 +5035,7 @@ SUBROUTINE CD_Get_Model_Tension(model, tension, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em tension = CD_ZERO ErrStat = CD_MODEL_OK @@ -5340,7 +5340,7 @@ SUBROUTINE CD_Update_Model_External_Loads(model, f_ext, ErrStat, ErrMsg) REAL(wp) :: f_dist(SIZE(model%f_ext)) REAL(wp), ALLOCATABLE :: base_entry(:) INTEGER :: es2 - CHARACTER(160) :: em2 + CHARACTER(1024) :: em2 IF (ALLOCATED(model%dist_load)) THEN CALL CD_Assemble_Distributed_Load(model%elem_conn, model%l0, model%dist_load, f_dist, es2, em2) IF (es2 /= 0) THEN @@ -5489,7 +5489,7 @@ SUBROUTINE recompute_model_acceleration_now(model, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em LOGICAL :: has_load INTEGER :: nc LOGICAL :: prescribed_workspace_ready @@ -5559,7 +5559,7 @@ SUBROUTINE apply_prescribed_acceleration_coupling(model, prescribed_a, ErrStat, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, n_free, i, j, row, col - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -6093,7 +6093,7 @@ SUBROUTINE CD_Copy_Model(src, dst, ErrStat, ErrMsg) TYPE(CD_ModelType) :: work INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -6497,7 +6497,7 @@ SUBROUTINE copy_syrope_types(src, dst, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: istat, e, es2 - CHARACTER(160) :: em2 + CHARACTER(1024) :: em2 ErrStat = CD_MODEL_OK ErrMsg = '' @@ -6589,7 +6589,7 @@ SUBROUTINE restore_after_init_alloc_fail(model, old_model, label, ErrStat, ErrMs CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL CD_End_Model(model, es, em) model = old_model @@ -6796,7 +6796,7 @@ SUBROUTINE model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrM INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' ea_d_eff = CD_ZERO @@ -6835,7 +6835,7 @@ SUBROUTINE model_syrope_element(model, e, q2, v2, force, jac_q, jac_v, t_mean, d REAL(wp) :: ws(CD_SYROPE_NWC), wt(CD_SYROPE_NWC), wsl(CD_SYROPE_NWC), slow_at LOGICAL :: on_wc INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em force = CD_ZERO jac_q = CD_ZERO jac_v = CD_ZERO @@ -6875,7 +6875,7 @@ SUBROUTINE model_syrope_state_next(model, e, q2, v2, dt, slow_next, t_mean, ErrS REAL(wp) :: chord(3), length, eps, slow_at, f6(6), jq6(6, 6), dslow LOGICAL :: on_wc INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em slow_next = model%syrope_slow(e) t_mean = CD_ZERO @@ -7859,7 +7859,7 @@ SUBROUTINE model_floor_gradient(model, x, y, z_floor, dfdx, dfdy, ErrStat, ErrMs CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(OUT), OPTIONAL :: curvature(3) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL CD_Bathymetry_Floor_Gradient(model%bathymetry, x, y, z_floor, dfdx, dfdy, es, em, & crease_curvature=curvature) IF (es == CD_BATHY_OK) THEN @@ -7884,7 +7884,7 @@ SUBROUTINE node_contact_normal(model, x, y, z, vel, gap_n, vn, nvec, sloped, Err CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es REAL(wp) :: z_floor, dfdx, dfdy, sfac - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_MODEL_OK ErrMsg = '' diff --git a/src/CableDyn_OpenFAST_Aggregate.f90 b/src/CableDyn_OpenFAST_Aggregate.f90 index 1b06e130..5db07dd6 100644 --- a/src/CableDyn_OpenFAST_Aggregate.f90 +++ b/src/CableDyn_OpenFAST_Aggregate.f90 @@ -580,7 +580,7 @@ SUBROUTINE CD_AGG_GetMovingPointMesh(self, position, velocity, acceleration, loa INTEGER :: c, col, es REAL(wp) :: y_fair(3) - CHARACTER(512) :: em + CHARACTER(1024) :: em position = CD_ZERO velocity = CD_ZERO @@ -746,7 +746,7 @@ SUBROUTINE CD_AGG_UpdateStates_Moving(self, position, velocity, acceleration, Er INTEGER :: c, col, es REAL(wp) :: zero_angular(3) LOGICAL :: is_output_probe - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN zero_angular = CD_ZERO @@ -910,7 +910,7 @@ SUBROUTINE CD_AGG_Step_Moving(self, dt, position, velocity, acceleration, conver INTEGER :: c, col, es, nsys, nsub LOGICAL :: csys, ssys, staged REAL(wp) :: t_start - CHARACTER(512) :: em + CHARACTER(1024) :: em converged = .FALSE. stalled = .FALSE. @@ -1235,7 +1235,7 @@ SUBROUTINE CD_AGG_Snapshot(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: c, es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN IF (self%has_sys) THEN CALL CD_FMF_Snapshot(self%sys, es, em) @@ -1274,7 +1274,7 @@ SUBROUTINE CD_AGG_Restore(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: c, es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN IF (self%has_sys) THEN CALL CD_FMF_Restore(self%sys, es, em) @@ -1305,7 +1305,7 @@ SUBROUTINE undo_staged_step(self, ErrMsg) TYPE(CD_AGG_ModuleType), INTENT(INOUT) :: self CHARACTER(*), INTENT(INOUT) :: ErrMsg INTEGER :: c, es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (self%has_sys) THEN CALL CD_FMF_Restore(self%sys, es, em) IF (es /= CD_FMF_OK) ErrMsg = TRIM(ErrMsg)//'; RESTORE FAILED (system): '//TRIM(em) @@ -1328,7 +1328,7 @@ SUBROUTINE size_fluid_surface(candidate, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nl, li, ic, ib, ir, ip, nbody, nrod, nhydropt, ndof, nn, maxdof, nblk, es, istat - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_AGG_OK ErrMsg = '' candidate%nfluid = 0 @@ -1428,7 +1428,7 @@ SUBROUTINE CD_AGG_GetFluidNodePositions(self, xyz, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: li, ndof, nn, i, es - CHARACTER(300) :: em + CHARACTER(1024) :: em xyz = CD_ZERO IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN IF (SIZE(xyz, 1) /= 3 .OR. SIZE(xyz, 2) /= self%nfluid) THEN @@ -1518,7 +1518,7 @@ SUBROUTINE CD_AGG_SetFluidFields(self, fluid_velocity, fluid_acceleration, water CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(IN), OPTIONAL :: dynamic_pressure(:) INTEGER :: li, o1, o2, i, es - CHARACTER(300) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN ! Uniform contract for BOTH line families: host fields are only accepted on a ! build that declared them. Cables always carry a drag/added-mass configuration, @@ -1650,7 +1650,7 @@ SUBROUTINE CD_AGG_CalcOutput(self, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN IF (self%has_sys) THEN @@ -1693,7 +1693,7 @@ SUBROUTINE CD_AGG_Set_Failure_Flags(self, flags, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_AGG_OK ErrMsg = '' IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN @@ -1752,7 +1752,7 @@ SUBROUTINE CD_AGG_Apply_LineControl(self, delta_l, delta_l_dot, ErrStat, ErrMsg, INTEGER :: c, ch, es, nspan, k, nrow REAL(wp) :: lambda, mean_seg - CHARACTER(512) :: em + CHARACTER(1024) :: em CHARACTER(16) :: line_kind ErrStat = CD_AGG_OK @@ -2119,7 +2119,7 @@ SUBROUTINE CD_AGG_EvalChannel(self, i, value, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em value = CD_ZERO IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN @@ -2152,7 +2152,7 @@ SUBROUTINE CD_AGG_Range_Sample(self, time, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN IF (.NOT. self%ranges%active) RETURN @@ -2176,7 +2176,7 @@ SUBROUTINE CD_AGG_Range_Write(self, root, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN CALL CD_Deck_Range_Write(self%ranges, root, es, em) @@ -2199,7 +2199,7 @@ SUBROUTINE CD_AGG_WriteStaticProfile(self, path, ErrStat, ErrMsg) LOGICAL :: refined REAL(wp) :: s, xyz(3), xyz_prev(3), tension, curvature, bend_moment, declination, azimuth CHARACTER(CD_DECK_NAMELEN) :: ch - CHARACTER(512) :: em + CHARACTER(1024) :: em CHARACTER(1) :: tab ErrStat = CD_AGG_OK @@ -2377,7 +2377,7 @@ SUBROUTINE overlay_host_objects(self, output_probe, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_AGG_OK ErrMsg = '' IF (self%nhost_rod + self%nhost_body == 0 .OR. .NOT. self%has_sys) RETURN @@ -2408,7 +2408,7 @@ SUBROUTINE set_host_objects(self, position, velocity, acceleration, ErrStat, Err LOGICAL, INTENT(IN), OPTIONAL :: step_start INTEGER :: c0, c1, es LOGICAL :: at_start - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_AGG_OK ErrMsg = '' at_start = .FALSE. diff --git a/src/CableDyn_OpenFAST_FMF.f90 b/src/CableDyn_OpenFAST_FMF.f90 index b540dd46..2ac5ba61 100644 --- a/src/CableDyn_OpenFAST_FMF.f90 +++ b/src/CableDyn_OpenFAST_FMF.f90 @@ -162,7 +162,7 @@ SUBROUTINE CD_FMF_Init_From_Deck(self, deck_path, dt, ErrStat, ErrMsg, env_gravi TYPE(CD_FMF_ModuleType) :: candidate REAL(wp) :: deck_dt, gravity, rho_water INTEGER :: es, n_coupled - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_FMF_OK ErrMsg = '' @@ -221,7 +221,7 @@ SUBROUTINE CD_FMF_Init_From_System(self, system, dt, gravity, rho_water, ErrStat TYPE(CD_FMF_ModuleType) :: candidate INTEGER :: es, n_coupled - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_FMF_OK ErrMsg = '' @@ -475,7 +475,7 @@ SUBROUTINE build_moving_blocks(self, ErrStat, ErrMsg) INTEGER, ALLOCATABLE :: blocks(:) INTEGER :: i, k, n_all, es, istat - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_FMF_OK ErrMsg = '' @@ -666,7 +666,7 @@ SUBROUTINE CD_FMF_Snapshot(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN CALL CD_System_Snapshot(self%fast%system, es, em) IF (es /= CD_SYSTEM_OK) THEN @@ -694,7 +694,7 @@ SUBROUTINE CD_FMF_Restore(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em IF (.NOT. require_initialized(self, ErrStat, ErrMsg)) RETURN CALL CD_System_Restore(self%fast%system, es, em) IF (es /= CD_SYSTEM_OK) THEN diff --git a/src/CableDyn_OpenFAST_HermiteFMF.f90 b/src/CableDyn_OpenFAST_HermiteFMF.f90 index 01853ea9..c29fa843 100644 --- a/src/CableDyn_OpenFAST_HermiteFMF.f90 +++ b/src/CableDyn_OpenFAST_HermiteFMF.f90 @@ -171,7 +171,7 @@ SUBROUTINE CD_HFMF_Init(self, l0, EA, EI, rho_a, w, q_static, fixed_dofs, seabed INTEGER, INTENT(IN), OPTIONAL :: axial_quadrature_order, bending_quadrature_order TYPE(CD_HFMF_ModuleType) :: candidate INTEGER :: es, s, gd - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. CD_Is_Finite(dt) .OR. dt <= CD_ZERO) THEN @@ -244,7 +244,7 @@ SUBROUTINE CD_HFMF_Set_Drag(self, rho_w, diam, cdn, cdt, waterline_z, current, E CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(IN), OPTIONAL :: gravity INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Drag: module not initialised'; RETURN @@ -265,7 +265,7 @@ SUBROUTINE CD_HFMF_Set_Attachments(self, node, mass, volume, cda, cdax, ca, rho_ INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Attachments: module not initialised'; RETURN @@ -284,7 +284,7 @@ SUBROUTINE CD_HFMF_Set_Axial_Damping(self, BA, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK ErrMsg = '' IF (.NOT. self%initialized) THEN @@ -315,7 +315,7 @@ SUBROUTINE CD_HFMF_Set_EndConnection(self, k_rot, d0_global, ErrStat, ErrMsg, & LOGICAL :: endpoint_connected REAL(wp) :: d0_local(3, 2) REAL(wp) :: parent_d0(3), parent_d0_norm, dcm(3, 3) - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK ErrMsg = '' @@ -417,7 +417,7 @@ SUBROUTINE CD_HFMF_Set_Torsion(self, torsion, ErrStat, ErrMsg, coupled_frame_par REAL(wp), INTENT(IN), OPTIONAL :: coupled_frame_parent(3, 2), parent_orientation(3, 3) INTEGER :: es, ci REAL(wp) :: dl(3), nl(3) - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK ErrMsg = '' IF (.NOT. self%initialized) THEN @@ -499,7 +499,7 @@ SUBROUTINE CD_HFMF_Set_ModifiedNewton(self, enabled, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_ModifiedNewton: module not initialised'; RETURN @@ -516,7 +516,7 @@ SUBROUTINE CD_HFMF_Set_Tensile_Safety(self, enabled, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Tensile_Safety: module not initialised'; RETURN @@ -534,7 +534,7 @@ SUBROUTINE CD_HFMF_Set_Tensile_Monitor(self, mode, ErrStat, ErrMsg, strain_toler CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(IN), OPTIONAL :: strain_tolerance INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Tensile_Monitor: module not initialised'; RETURN @@ -552,7 +552,7 @@ SUBROUTINE CD_HFMF_Get_Tensile_Diagnostics(self, event_count, worst_force, worst REAL(wp), INTENT(OUT) :: worst_force, worst_threshold, worst_xi, worst_time CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em IF (.NOT. self%initialized) THEN event_count = 0; worst_element = 0 worst_force = CD_ZERO; worst_threshold = CD_ZERO; worst_xi = CD_ZERO; worst_time = CD_ZERO @@ -572,7 +572,7 @@ SUBROUTINE CD_HFMF_Get_Recovery_Diagnostics(self, event_count, max_substeps_used INTEGER, INTENT(OUT) :: event_count, max_substeps_used, ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em IF (.NOT. self%initialized) THEN event_count = 0; max_substeps_used = 0 ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Get_Recovery_Diagnostics: module not initialised'; RETURN @@ -611,7 +611,7 @@ SUBROUTINE CD_HFMF_Set_AddedMass(self, rho_w, diam, can, cat, waterline_z, ErrSt INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_AddedMass: module not initialised'; RETURN @@ -629,7 +629,7 @@ SUBROUTINE CD_HFMF_Set_Waves(self, height, period, direction_deg, depth, gravity INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Waves: module not initialised'; RETURN @@ -657,7 +657,7 @@ SUBROUTINE CD_HFMF_UpdateStates(self, u_pos, u_vel, u_acc, ErrStat, ErrMsg, u_or REAL(wp) :: tors_ends(3, 4), tors_phi REAL(wp) :: target_dcm(3, 3), target_d0(3, 2), target_omega(3), target_alpha(3) REAL(wp) :: target_d0_rate(3, 2), target_d0_acceleration(3, 2), omega_local(3), alpha_local(3) - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_UpdateStates: module not initialised'; RETURN @@ -763,7 +763,7 @@ SUBROUTINE CD_HFMF_Snapshot(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Snapshot: module not initialised'; RETURN @@ -785,7 +785,7 @@ SUBROUTINE CD_HFMF_Restore(self, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Restore: module not initialised'; RETURN @@ -813,7 +813,7 @@ SUBROUTINE CD_HFMF_PreflightCoupledKinematics(self, u_pos, u_vel, u_acc, ErrStat REAL(wp), INTENT(IN), OPTIONAL :: u_angular_velocity(3), u_angular_acceleration(3) REAL(wp) :: target_dcm(3, 3), d0_target(3, 2), tangent_q(3), tangent_v(3), tangent_a(3) REAL(wp) :: target_omega(3), target_alpha(3) - CHARACTER(300) :: em + CHARACTER(1024) :: em CALL prepare_coupled_kinematics(self, u_pos, u_vel, u_acc, target_dcm, target_omega, target_alpha, & d0_target, tangent_q, tangent_v, tangent_a, ErrStat, em, & @@ -909,7 +909,7 @@ SUBROUTINE CD_HFMF_SetCoupledKinematics(self, u_pos, u_vel, u_acc, ErrStat, ErrM REAL(wp) :: tangent_q(3), tangent_v(3), tangent_a(3) REAL(wp) :: target_omega(3), target_alpha(3), tors_ends(3, 4) INTEGER :: base, es - CHARACTER(300) :: em + CHARACTER(1024) :: em CALL prepare_coupled_kinematics(self, u_pos, u_vel, u_acc, target_dcm, target_omega, target_alpha, & d0_target, tangent_q, tangent_v, tangent_a, ErrStat, em, & @@ -1141,7 +1141,7 @@ SUBROUTINE CD_HFMF_Set_Held_Fluid(self, fluid_velocity, fluid_acceleration, wate CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es, i LOGICAL :: has_heading - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Set_Held_Fluid: module not initialised'; RETURN @@ -1178,7 +1178,7 @@ SUBROUTINE CD_HFMF_Set_Contact(self, kn_node, cn_node, mu, ErrStat, ErrMsg, bath CHARACTER(*), INTENT(OUT) :: ErrMsg TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: es - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN @@ -1228,7 +1228,7 @@ SUBROUTINE CD_HFMF_Refresh_Acceleration(self, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es REAL(wp) :: coupled_a(3) - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN @@ -1283,7 +1283,7 @@ SUBROUTINE CD_HFMF_CalcOutput(self, y_fair, ErrStat, ErrMsg, y_moment) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(OUT), OPTIONAL :: y_moment(3) INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = ''; y_fair = CD_ZERO IF (PRESENT(y_moment)) y_moment = CD_ZERO IF (.NOT. self%initialized) THEN @@ -1416,7 +1416,7 @@ SUBROUTINE CD_HFMF_Curvature(self, curv_out, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Curvature: module not initialised'; RETURN diff --git a/src/CableDyn_OpenFAST_Mesh.f90 b/src/CableDyn_OpenFAST_Mesh.f90 index 44c625a3..ca79d01b 100644 --- a/src/CableDyn_OpenFAST_Mesh.f90 +++ b/src/CableDyn_OpenFAST_Mesh.f90 @@ -197,7 +197,7 @@ SUBROUTINE CD_FAST_Set_PointMesh_From_Body(mesh, body_q, body_v, body_a, offsets CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_FAST_MESH_OK ErrMsg = '' @@ -266,7 +266,7 @@ SUBROUTINE CD_FAST_CalcBodyWrench_From_PointMesh(mesh, body_q, offsets_body, bod CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(240) :: em + CHARACTER(1024) :: em body_wrench = CD_ZERO ErrStat = CD_FAST_MESH_OK diff --git a/src/CableDyn_RangeOutput.f90 b/src/CableDyn_RangeOutput.f90 index 53059acd..18c9247c 100644 --- a/src/CableDyn_RangeOutput.f90 +++ b/src/CableDyn_RangeOutput.f90 @@ -203,7 +203,7 @@ SUBROUTINE CD_Range_Clearance(set, r, clearance, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: j, es REAL(wp) :: zf - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_RANGE_OK ErrMsg = '' diff --git a/src/CableDyn_Static.f90 b/src/CableDyn_Static.f90 index 50b1140e..72d3130a 100644 --- a/src/CableDyn_Static.f90 +++ b/src/CableDyn_Static.f90 @@ -209,7 +209,7 @@ SUBROUTINE CD_Static_Cable_Solve(q0, elem_conn, l0, ea, tension_only, f_ext, fix ! Smallest Levenberg-Marquardt shift (relative to kappa) of the slack-capable law: keeps ! directions without any stiffness (a grounded node between slack elements) solvable. REAL(wp), PARAMETER :: LM_MU_MIN_SLACK = 1.0e-12_wp - CHARACTER(120) :: em + CHARACTER(1024) :: em ! slack-capable law: base assembly flag, compressed-branch ratio, and the second ! (compression-capable) assembly the blend needs when 0 < r < 1 LOGICAL :: law_to, reg_law, blend @@ -733,7 +733,7 @@ SUBROUTINE eval_residual(qe, Rf, sc) REAL(wp), ALLOCATABLE :: fint_e(:) REAL(wp) :: scale_load, scale_drag INTEGER :: es_e - CHARACTER(120) :: em_e + CHARACTER(1024) :: em_e ALLOCATE (fint_e(n_dof)) CALL CD_Assemble_Cable_Internal_Force(reshape3(qe, n_dof), elem_conn, l0, ea, law_to, & fint_e, es_e, em_e) @@ -807,7 +807,7 @@ SUBROUTINE eval_energy(qe, energy, magnitude) REAL(wp), INTENT(OUT) :: energy, magnitude INTEGER :: e, a, b, i, es_e REAL(wp) :: ell, eps, w_el, zf, gx, gy, g, s, pot, bl - CHARACTER(120) :: em_e + CHARACTER(1024) :: em_e energy = CD_ZERO magnitude = CD_ZERO @@ -1255,7 +1255,7 @@ SUBROUTINE CD_Static_Friction_Anchors(q, current, seabed_kn, anchors, ErrStat, E TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: n_nodes, i, es REAL(wp) :: z_floor, dfdx, dfdy, normal, tangent, fvec(3), jac(3, 3), f(2), dfd(2, 2), dfc(2), curv(3) - CHARACTER(120) :: em + CHARACTER(1024) :: em ErrStat = CD_STATIC_OK ErrMsg = '' n_nodes = SIZE(q)/3 @@ -1658,7 +1658,7 @@ SUBROUTINE CD_Static_Line_Equilibrium(anchor, fairlead, elem_conn, l0, ea, weigh REAL(wp), ALLOCATABLE :: q_seed(:), q_try(:), q_mid(:), q_best(:), ten(:) REAL(wp) :: f_node, t_min, t_max, r_soft, r_firm, floor_a, slope_a, h_cat, g_cat LOGICAL :: has_seabed, anchor_grounded, conv, stalled, at_floor, have_seed, done, have_best - CHARACTER(200) :: em + CHARACTER(1024) :: em CHARACTER(64) :: seed_name CHARACTER(400) :: notes TYPE(CableSolverConfig) :: cfg_adm @@ -1907,7 +1907,7 @@ SUBROUTINE run_solve(qs, factors, slack_law, ratio, cfg_use, qo, ok) REAL(wp), INTENT(OUT) :: qo(:) LOGICAL, INTENT(OUT) :: ok INTEGER :: es_r - CHARACTER(200) :: em_r + CHARACTER(1024) :: em_r ok = .FALSE. IF (slack_law) THEN @@ -1969,7 +1969,7 @@ SUBROUTINE tension_range(qe, tmin, tmax) REAL(wp), INTENT(IN) :: qe(:) REAL(wp), INTENT(OUT) :: tmin, tmax INTEGER :: es_t - CHARACTER(200) :: em_t + CHARACTER(1024) :: em_t CALL CD_Compute_Cable_Tension(RESHAPE(qe, [3, n_nodes]), elem_conn, l0, ea, .FALSE., ten, es_t, em_t) IF (es_t /= 0) THEN tmin = -HUGE(CD_ONE) @@ -2020,7 +2020,7 @@ SUBROUTINE build_seed(which, ok) INTEGER, INTENT(IN) :: which LOGICAL, INTENT(OUT) :: ok INTEGER :: es_s, i_s - CHARACTER(200) :: em_s + CHARACTER(1024) :: em_s LOGICAL :: hang REAL(wp) :: pen @@ -2176,7 +2176,7 @@ SUBROUTINE drape_at(k, mismatch, valid) REAL(wp) :: hd(2), hlen, arc, d, zf, g, p(3), step, arc_prev REAL(wp), ALLOCATABLE :: q_sus(:) REAL(wp) :: h_s, g_s, u(3) - CHARACTER(200) :: em_d + CHARACTER(1024) :: em_d valid = .FALSE. mismatch = -HUGE(CD_ONE) @@ -2232,7 +2232,7 @@ SUBROUTINE fold_seed(ok) REAL(wp) :: hd(2), hlen, zp, c, arc_ap, g, e, a, dmax, total, s_node, pp(3), s_arc, d REAL(wp) :: dtab(0:NTAB), atab(0:NTAB) INTEGER :: i, j, es_f - CHARACTER(200) :: em_f + CHARACTER(1024) :: em_f ok = .FALSE. hd = fairlead(1:2) - anchor(1:2) @@ -2295,7 +2295,7 @@ SUBROUTINE seabed_slope_along(x, y, hd, g) REAL(wp), INTENT(OUT) :: g REAL(wp) :: zf, gx, gy INTEGER :: es_g - CHARACTER(200) :: em_g + CHARACTER(1024) :: em_g g = CD_ZERO IF (.NOT. PRESENT(bathymetry)) RETURN CALL CD_Bathymetry_Floor_Gradient(bathymetry, x, y, zf, gx, gy, es_g, em_g) @@ -2455,7 +2455,7 @@ SUBROUTINE CD_Static_Line_End_Forces(q, elem_conn, l0, ea, f_ext, tension_only, INTEGER :: n_dof, n_nodes, n_elem, k, e, a, b, node, es REAL(wp), ALLOCATABLE :: fint(:) REAL(wp) :: zf, gx, gy, fvec(3), jac(3, 3), curv(3), f2(6), jq2(6, 6), jv2(6, 6), va(3), vb(3), de, cn, ct, wla, wlb - CHARACTER(200) :: em + CHARACTER(1024) :: em INTEGER :: ends(2) LOGICAL :: drag_ends diff --git a/src/CableDyn_StreamWave.f90 b/src/CableDyn_StreamWave.f90 index 843ccbaa..76837338 100644 --- a/src/CableDyn_StreamWave.f90 +++ b/src/CableDyn_StreamWave.f90 @@ -56,7 +56,7 @@ SUBROUTINE CD_Stream_Solve(wave, height, period, depth, gravity, direction_deg, REAL(wp), ALLOCATABLE :: z(:), zprev(:), zprev2(:), res(:), jac(:, :), dz(:), zt(:), rt(:) REAL(wp) :: hs, ts, k0, omega, h_step, rnorm, a, h, ch LOGICAL :: ok - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_STREAM_OK ErrMsg = '' diff --git a/src/CableDyn_Syrope.f90 b/src/CableDyn_Syrope.f90 index bd99459e..511ef818 100644 --- a/src/CableDyn_Syrope.f90 +++ b/src/CableDyn_Syrope.f90 @@ -205,7 +205,7 @@ SUBROUTINE CD_Syrope_Init(td, owc_strain, owc_tension, wc_mod, p1, p2, alpha, be td%scan_hi = owc_tension(n) BLOCK INTEGER :: k, es - CHARACTER(200) :: em, first_em + CHARACTER(1024) :: em, first_em REAL(wp) :: ws(CD_SYROPE_NWC), wt(CD_SYROPE_NWC), wsl(CD_SYROPE_NWC) first_em = '' DO k = 1, CD_SYROPE_NSCAN diff --git a/src/CableDyn_System.f90 b/src/CableDyn_System.f90 index bf5b025f..791fcff6 100644 --- a/src/CableDyn_System.f90 +++ b/src/CableDyn_System.f90 @@ -190,7 +190,7 @@ MODULE CableDyn_System ! parallel region so failure selection and mapped-load accumulation stay reproducible. INTEGER, ALLOCATABLE :: line_off(:), line_stat(:), line_iter(:) LOGICAL, ALLOCATABLE :: line_converged(:), line_stalled(:) - CHARACTER(160), ALLOCATABLE :: line_msg(:) + CHARACTER(512), ALLOCATABLE :: line_msg(:) REAL(wp), ALLOCATABLE :: line_load_work(:) ! Snapshot of the COMMITTED system state (every line's q/v/a/f_ext + every point) for ! the aggregate stage-then-commit contract. The per-line q_rollback buffers CANNOT @@ -241,7 +241,7 @@ SUBROUTINE CD_Init_System_From_Models(system, models, ErrStat, ErrMsg, coupled_d TYPE(CD_SystemType) :: candidate INTEGER :: i, es, copy_stat, istat, n_local, nc - CHARACTER(200) :: em, copy_msg + CHARACTER(1024) :: em, copy_msg ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -352,7 +352,7 @@ SUBROUTINE CD_Init_System_From_Points(system, models, points, bindings, ErrStat, INTEGER, ALLOCATABLE :: map(:), pbase(:) INTEGER :: es, istat, i, pidx REAL(wp) :: md - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL build_point_coupled_map(models, points, bindings, map, pbase, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -425,7 +425,7 @@ SUBROUTINE CD_End_System(system, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, es - CHARACTER(120) :: em + CHARACTER(1024) :: em IF (ALLOCATED(system%lines)) THEN DO i = 1, SIZE(system%lines) @@ -693,7 +693,7 @@ SUBROUTINE CD_Set_System_DynamicPoint_States(system, buf, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, k, es, base - CHARACTER(256) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' IF (.NOT. system%initialized) THEN @@ -823,7 +823,7 @@ SUBROUTINE CD_Get_System_Line_State(system, line_index, q, v, a, ErrStat, ErrMsg CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em q = CD_ZERO v = CD_ZERO @@ -859,7 +859,7 @@ SUBROUTINE CD_Get_System_Line_VE_Dl1(system, line_index, dl1, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em dl1 = CD_ZERO CALL validate_line_index(system, line_index, ErrStat, ErrMsg) @@ -884,7 +884,7 @@ SUBROUTINE CD_Set_System_Line_VE_Dl1(system, line_index, dl1, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -918,7 +918,7 @@ SUBROUTINE CD_Get_System_Line_Syrope_State(system, line_index, slow, tmax, ErrSt CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em slow = CD_ZERO tmax = CD_ZERO @@ -944,7 +944,7 @@ SUBROUTINE CD_Set_System_Line_Syrope_State(system, line_index, slow, tmax, ErrSt CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -976,7 +976,7 @@ SUBROUTINE CD_Get_System_Line_Friction_Anchors(system, line_index, anchors, ErrS INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em anchors = CD_ZERO CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -998,7 +998,7 @@ SUBROUTINE CD_Set_System_Line_Friction_Anchors(system, line_index, anchors, ErrS INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN CALL CD_Set_Model_Friction_Anchors(system%lines(line_index), anchors, es, em) @@ -1020,7 +1020,7 @@ SUBROUTINE CD_Get_System_Line_Tension(system, line_index, tension, ErrStat, ErrM CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em tension = CD_ZERO CALL validate_line_index(system, line_index, ErrStat, ErrMsg) @@ -1044,7 +1044,7 @@ SUBROUTINE CD_Get_System_CoupledMotion(system, q_coupled, v_coupled, a_coupled, INTEGER :: i, lo, hi, nc, es, local_id, sys_id, dof, n_mapped REAL(wp), PARAMETER :: TOL = 1.0e-10_wp - CHARACTER(160) :: em + CHARACTER(1024) :: em q_coupled = CD_ZERO v_coupled = CD_ZERO @@ -1126,7 +1126,7 @@ SUBROUTINE CD_Update_System_CoupledMotion(system, q_coupled, v_coupled, a_couple INTEGER :: i, lo, hi, nc, es LOGICAL :: save_for_rollback - CHARACTER(160) :: em + CHARACTER(1024) :: em save_for_rollback = .TRUE. IF (PRESENT(caller_owns_rollback)) save_for_rollback = .NOT. caller_owns_rollback @@ -1259,7 +1259,7 @@ RECURSIVE SUBROUTINE CD_Step_System(system, dt, q_coupled, v_coupled, a_coupled, INTEGER :: i, j, lo, hi, nc, es, line_dof, sys_dof, depth, iter2, ntot, nve, nsy, lo_ve, lo_sy, ne, nfr, lo_fr INTEGER :: n_team, nel, lo_el LOGICAL :: conv2, stall2 - CHARACTER(160) :: em + CHARACTER(1024) :: em REAL(wp), ALLOCATABLE :: q0(:), v0(:), a0(:), qm(:), vm(:), am(:), qs(:), vs(:), as(:) REAL(wp), ALLOCATABLE :: dl1s(:), slows(:), tmaxs(:), frs(:, :), hmaxs(:), l0cs(:), l0dcs(:) TYPE(CD_SubstepStats), ALLOCATABLE :: subs(:) @@ -1648,7 +1648,7 @@ SUBROUTINE CD_Step_System_DynamicPoints(system, dt, converged, stalled, n_iter, REAL(wp) :: ma_blk(3, 3), k_blk(3, 3), c_blk(3, 3), rhs3(3), kv_nbr(3) LOGICAL :: solve_ok LOGICAL, ALLOCATABLE :: integ(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em converged = .FALSE. stalled = .FALSE. @@ -1851,7 +1851,7 @@ SUBROUTINE point_line_end_blocks(system, point_index, ma_block, k_block, c_block CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: k, es REAL(wp) :: blk(3, 3), kb(3, 3), cb(3, 3), kv(3) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' ma_block = CD_ZERO @@ -1928,7 +1928,7 @@ SUBROUTINE CD_Update_System_Line_SegmentLength(system, line_index, elem, l0_new, INTEGER :: k, i, kb, es REAL(wp) :: md - CHARACTER(240) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -2023,7 +2023,7 @@ SUBROUTINE recompute_point_line_mass_diag(system, point_index, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: k, es REAL(wp) :: md - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' system%points(point_index)%line_mass_diag = CD_ZERO @@ -2057,7 +2057,7 @@ SUBROUTINE CD_Detach_System_LineEnds(system, fail_point_id, line_indices, reserv INTEGER :: i, k, pf, pr, es, local_base, e, nmoved REAL(wp) :: md - CHARACTER(240) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2161,7 +2161,7 @@ SUBROUTINE CD_Calc_System_CoupledLoads(system, coupled_loads, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, lo, hi, es, n_team - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2231,7 +2231,7 @@ SUBROUTINE CD_Calc_System_CoupledKinematicDerivatives(system, dload_dq, dload_dv CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, j, k, lo, hi, nc, es, row, col - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2295,7 +2295,7 @@ SUBROUTINE CD_Calc_System_CoupledAccelDerivative(system, dload_da, ErrStat, ErrM INTEGER :: i, j, k, lo, hi, nc, es, row, col LOGICAL :: frozen - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2365,7 +2365,7 @@ SUBROUTINE CD_Recompute_System_Acceleration(system, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: i, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2396,7 +2396,7 @@ SUBROUTINE CD_Update_System_Line_External_Loads(system, line_index, f_ext, ErrSt CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -2485,7 +2485,7 @@ SUBROUTINE CD_Update_System_Line_Hydro_Fields(system, line_index, ErrStat, ErrMs REAL(wp), INTENT(IN), OPTIONAL :: buoyancy_waterline_z(:) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -2518,7 +2518,7 @@ SUBROUTINE CD_Update_System_Line_Interior_State(system, line_index, q_interior, REAL(wp), INTENT(IN), OPTIONAL :: a_interior(:) INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em CALL validate_line_index(system, line_index, ErrStat, ErrMsg) IF (ErrStat /= CD_SYSTEM_OK) RETURN @@ -2580,7 +2580,7 @@ END FUNCTION query CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em n = 0 CALL validate_line_index(system, line_index, ErrStat, ErrMsg) @@ -2603,7 +2603,7 @@ SUBROUTINE validate_system_motion_shape(system, q_coupled, v_coupled, a_coupled, CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: n, es - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -2720,7 +2720,7 @@ SUBROUTINE build_point_coupled_map(models, points, bindings, map, point_base_out INTEGER :: point_dof_base, local_base INTEGER, ALLOCATABLE :: point_base(:) LOGICAL, ALLOCATABLE :: bound(:, :), point_bound(:) - CHARACTER(160) :: em + CHARACTER(1024) :: em ErrStat = CD_SYSTEM_OK ErrMsg = '' @@ -3287,7 +3287,7 @@ SUBROUTINE CD_System_Restore(system, ErrStat, ErrMsg) IF (ALLOCATED(system%snap_l0)) THEN BLOCK INTEGER :: le, he, ne_i, es2 - CHARACTER(240) :: em2 + CHARACTER(1024) :: em2 le = 1 lo = 1 DO i = 1, system%n_lines diff --git a/src/openfast/CableDyn_OF.f90 b/src/openfast/CableDyn_OF.f90 index 07a32f3d..1947d4fc 100644 --- a/src/openfast/CableDyn_OF.f90 +++ b/src/openfast/CableDyn_OF.f90 @@ -247,7 +247,7 @@ SUBROUTINE open_native_outputs( id, root, t_start, ErrStat, ErrMsg, write_profil character(*), parameter :: RoutineName = 'CableDyn:open_native_outputs' INTEGER(IntKi) :: es, un, ic, nch, owner, ios - CHARACTER(512) :: em, iomsg + CHARACTER(ErrMsgLen) :: em, iomsg CHARACTER(ChanLen) :: hdr, unt REAL(wp) :: value LOGICAL :: write_static @@ -470,7 +470,7 @@ SUBROUTINE CD_Init(InitInp, u, p, x, xd, z, other, y, m, DTcoupling, InitOut, Er character(*), parameter :: RoutineName = 'CD_Init' INTEGER(IntKi) :: ErrStat2, es CHARACTER(ErrMsgLen) :: ErrMsg2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em INTEGER(IntKi) :: id, ncp, nlines, il, i, ndofl, nstates, ic, nch, nsuper, nglue INTEGER(IntKi) :: nreportlines, npoints, nsections, nei0, nfinite, line_id INTEGER(IntKi) :: clock_count, nT, prof_c0, prof_c1, prof_rate @@ -1264,7 +1264,7 @@ SUBROUTINE rebuild_from_checkpoint( t, u1, p, x, other, m, ErrStat, ErrMsg ) CHARACTER(2100) :: rst_deck INTEGER(IntKi) :: id, old_id, stale_id, i, es, ncp, nlines, il, ndofl, nin, k, ic, csz, koff LOGICAL :: use_extf, profile_requested, preserve_profile - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em INTEGER(IntKi) :: ErrStat2 CHARACTER(ErrMsgLen) :: ErrMsg2 @@ -1519,7 +1519,7 @@ SUBROUTINE CD_UpdateStates( t, n, u, t_array, p, x, xd, z, other, m, ErrStat, Er INTEGER(IntKi) :: ErrStat2, es, id, niter, iu_t, i_u INTEGER(IntKi) :: prof_c0, prof_c1, prof_rate, prof_phase0 CHARACTER(ErrMsgLen) :: ErrMsg2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em LOGICAL :: conv, stalled ErrStat = ErrID_None @@ -1728,7 +1728,7 @@ SUBROUTINE sample_wavefield( inst_e, p, m, t_sample, ErrStat, ErrMsg, at_init ) ! interpolates the current at the depth mapped with it. Only the grid check reads it, so ! it exists only until that check has warned. REAL(wp), ALLOCATABLE :: wl_sampled(:) - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em INTEGER(IntKi) :: ErrStat2 CHARACTER(ErrMsgLen) :: ErrMsg2 @@ -2114,7 +2114,7 @@ SUBROUTINE CD_CalcOutput( t, u, p, x, xd, z, other, y, m, ErrStat, ErrMsg ) INTEGER(IntKi) :: ErrStat2, es, id, i INTEGER(IntKi) :: prof_c0, prof_c1, prof_rate, prof_phase0 CHARACTER(ErrMsgLen) :: ErrMsg2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em REAL(wp) :: cval LOGICAL :: fresh, state_overlaid @@ -2351,7 +2351,7 @@ SUBROUTINE restore_calcoutput_probe( inst_e, m, ErrStat, ErrMsg ) INTEGER(IntKi), INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER(IntKi) :: es, ErrStat2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em CHARACTER(ErrMsgLen) :: ErrMsg2 ErrStat = ErrID_None @@ -2721,7 +2721,7 @@ SUBROUTINE probe_loads( pos, PErrStat, PErrMsg ) REAL(wp) :: q_p(3, ncp), v_p(3, ncp), a_p(3, ncp), f_p(3, ncp) REAL(wp) :: cval INTEGER(IntKi) :: es_p, ich - CHARACTER(512) :: em_p + CHARACTER(ErrMsgLen) :: em_p PErrStat = ErrID_None PErrMsg = '' @@ -2891,7 +2891,7 @@ SUBROUTINE CD_InitVars(Vars, u, p, x, y, m, inst_, Linearize, ErrStat, ErrMsg) character(*), parameter :: RoutineName = 'CD_InitVars' INTEGER(IntKi) :: ErrStat2, es CHARACTER(ErrMsgLen) :: ErrMsg2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em INTEGER(IntKi) :: il, i, j, N, ndofl, nin, ic, csz, nf, koff, nve CHARACTER(32) :: LinStr CHARACTER(ChanLen) :: whdr, wunt @@ -3364,7 +3364,7 @@ SUBROUTINE reload_interiors_ary(inst_, m, states, t_clock, ErrStat, ErrMsg) character(*), parameter :: RoutineName = 'CableDyn:reload_interiors' INTEGER(IntKi) :: es, il, ndofl, nin, k, ic, csz, koff, npd, ncd, nfl, nve - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em ErrStat = ErrID_None ErrMsg = '' @@ -3604,7 +3604,7 @@ SUBROUTINE reload_cable_mirrors(inst_, m, states, t_clock, torsion_only, koff, E character(*), parameter :: RoutineName = 'CableDyn:reload_cable_mirrors' INTEGER(IntKi) :: es, ic, csz - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em ErrStat = ErrID_None ErrMsg = '' @@ -3649,7 +3649,7 @@ INTEGER(IntKi) FUNCTION line_friction_mirror_size(inst_) RESULT(n) !! every line on a frictional seabed (0 without such lines). TYPE(CD_OF_Instance), INTENT(IN) :: inst_ INTEGER(IntKi) :: il, es - CHARACTER(256) :: em + CHARACTER(ErrMsgLen) :: em n = 0 IF (.NOT. inst_%agg%has_sys) RETURN DO il = 1, inst_%nlines @@ -3678,7 +3678,7 @@ SUBROUTINE pack_state_mirror_ary(inst_, m, states, ErrStat, ErrMsg) character(*), parameter :: RoutineName = 'CableDyn:pack_state_mirror' INTEGER(IntKi) :: es, il, ndofl, nin, k, ic, csz, koff, npd, ncd, nfl, nve - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em ErrStat = ErrID_None ErrMsg = '' @@ -3890,7 +3890,7 @@ SUBROUTINE build_farm_meshes( inst_e, u, y, InitInp, nT, ncp, pos, ErrStat, ErrM character(*), parameter :: RoutineName = 'CableDyn:build_farm_meshes' INTEGER(IntKi) :: es, s, J, k, nk, ErrStat2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em CHARACTER(ErrMsgLen) :: ErrMsg2 REAL(R8Ki) :: OrMatJ(3,3), OrientIdent(3,3), refp(3), ptfmJ(6), ploc(3) LOGICAL :: hasp @@ -4075,7 +4075,7 @@ SUBROUTINE release_instance( k, ErrStat, ErrMsg ) INTEGER(IntKi), OPTIONAL, INTENT(OUT) :: ErrStat CHARACTER(*), OPTIONAL, INTENT(OUT) :: ErrMsg INTEGER(IntKi) :: es, ErrStat2 - CHARACTER(512) :: em + CHARACTER(ErrMsgLen) :: em CHARACTER(ErrMsgLen) :: ErrMsg2 IF (PRESENT(ErrStat)) ErrStat = ErrID_None IF (PRESENT(ErrMsg)) ErrMsg = '' diff --git a/tests/data/msg_anchor_below_seabed.dat b/tests/data/msg_anchor_below_seabed.dat new file mode 100644 index 00000000..46040133 --- /dev/null +++ b/tests/data/msg_anchor_below_seabed.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_anchor_below_seabed +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -10 0 0 0 0 +2 Fixed 450 0 -100.01 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 520 52 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +100.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_coarse_section.dat b/tests/data/msg_coarse_section.dat new file mode 100644 index 00000000..053e37da --- /dev/null +++ b/tests/data/msg_coarse_section.dat @@ -0,0 +1,37 @@ +--------------------- CableDyn Input File --- +msg_coarse_section +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -10 0 0 0 0 +2 Fixed 450 0 -100 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 100 1 +1 chain 320 1000 +1 chain 100 2 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +100.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_mixed_connect_coupled_cable.dat b/tests/data/msg_mixed_connect_coupled_cable.dat new file mode 100644 index 00000000..26620fca --- /dev/null +++ b/tests/data/msg_mixed_connect_coupled_cable.dat @@ -0,0 +1,64 @@ +--------------------- CableDyn Input File --- +msg_mixed_connect_coupled_cable +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +pc 0.16 36.7 469000000 -1 19900 1.2 0.1 1 0 +buoy 0.5 170.666793 469000000 -1 19900 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -14 0 0 0 0 +2 Fixed 830 0 -200 0 0 0 0 +3 Fixed -415 719 -200 0 0 0 0 +4 Fixed -300 -50 -200 0 0 0 0 +5 Connect 400 0 -150 8000 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 5 - +2 5 2 - +3 1 4 - +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 450 45 +2 chain 420 42 +3 pc 180 180 +3 buoy 80 80 +3 pc 150 150 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +0.05 dtM +0.0 TMax +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"FairTen2" +"AnchTen2" +"FairTen3" +"AnchTen3" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +"Point3Fx" +"Point3Fy" +"Point3Fz" +"Point4Fx" +"Point4Fy" +"Point4Fz" +"Point5Fx" +"Point5Fy" +"Point5Fz" +"Point5px" +"Point5py" +"Point5pz" +--------------------- need this line --- diff --git a/tests/data/msg_mixed_current.dat b/tests/data/msg_mixed_current.dat new file mode 100644 index 00000000..e74f01da --- /dev/null +++ b/tests/data/msg_mixed_current.dat @@ -0,0 +1,58 @@ +--------------------- CableDyn Input File --- +msg_mixed_current +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +pc 0.16 36.7 469000000 -1 19900 1.2 0.1 1 0 +buoy 0.5 170.666793 469000000 -1 19900 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -14 0 0 0 0 +2 Fixed 830 0 -200 0 0 0 0 +3 Fixed -415 719 -200 0 0 0 0 +4 Fixed -300 -50 -200 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 - +2 1 3 - +3 1 4 - +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 850 85 +2 chain 850 85 +3 pc 180 180 +3 buoy 80 80 +3 pc 150 150 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +0.05 dtM +0.0 TMax +uniform 0.5 0 0 current +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"FairTen2" +"AnchTen2" +"FairTen3" +"AnchTen3" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +"Point3Fx" +"Point3Fy" +"Point3Fz" +"Point4Fx" +"Point4Fy" +"Point4Fz" +--------------------- need this line --- diff --git a/tests/data/msg_pliant_connect_end_b.dat b/tests/data/msg_pliant_connect_end_b.dat new file mode 100644 index 00000000..08dfab34 --- /dev/null +++ b/tests/data/msg_pliant_connect_end_b.dat @@ -0,0 +1,56 @@ +--------------------- CableDyn Input File --- +msg_pliant_connect_end_b +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +pc 0.16 36.7 469000000 -1 19900 1.2 0.1 1 0 +buoy 0.5 170.666793 469000000 -1 19900 1.2 0.1 1 0 +chainS 0.1368 114.9424 493270400 -1 0 1.37 0.64 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -20 0 0 0 0 +2 Connect 250 0 -150 0 0 0 0 +3 Fixed 400 0 -200 0 0 0 0 +4 Fixed 260 0 -200 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 - +2 2 3 - +3 2 4 - +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 pc 180 180 +1 buoy 80 80 +2 pc 200 200 +3 chainS 45 20 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +0.05 dtM +0.0 TMax +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"FairTen2" +"AnchTen2" +"FairTen3" +"AnchTen3" +"Point2Fx" +"Point2Fy" +"Point2Fz" +"Point2px" +"Point2py" +"Point2pz" +"Point3Fx" +"Point3Fy" +"Point3Fz" +"Point4Fx" +"Point4Fy" +"Point4Fz" +--------------------- need this line --- diff --git a/tests/data/msg_shared_line.dat b/tests/data/msg_shared_line.dat new file mode 100644 index 00000000..e1315fc7 --- /dev/null +++ b/tests/data/msg_shared_line.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_shared_line +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +wire 0.1 50 900000000 -1 0 1.2 0.008 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -15 0 0 0 0 +2 Coupled 800 0 -15 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 wire 900 90 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_static_strain.dat b/tests/data/msg_static_strain.dat new file mode 100644 index 00000000..c64428c4 --- /dev/null +++ b/tests/data/msg_static_strain.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_static_strain +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -10 0 0 0 0 +2 Fixed 450 0 -100 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 229.4558781 46 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +100.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_tensile_safety_motion.txt b/tests/data/msg_tensile_safety_motion.txt new file mode 100644 index 00000000..07b0e02f --- /dev/null +++ b/tests/data/msg_tensile_safety_motion.txt @@ -0,0 +1,346 @@ +# time id x y z vx vy vz ax ay az +0.000000 1 5.0000000000e+00 0.0000000000e+00 -1.4000000000e+01 0.0000000000e+00 0.0000000000e+00 0.0000000000e+00 0.0000000000e+00 0.0000000000e+00 0.0000000000e+00 +0.025000 1 5.0000000000e+00 0.0000000000e+00 -1.3999999944e+01 0.0000000000e+00 0.0000000000e+00 9.0178347426e-06 0.0000000000e+00 0.0000000000e+00 1.0791875902e-03 +0.050000 1 5.0000000000e+00 0.0000000000e+00 -1.3999999103e+01 0.0000000000e+00 0.0000000000e+00 7.1541205409e-05 0.0000000000e+00 0.0000000000e+00 4.2679788790e-03 +0.075000 1 5.0000000000e+00 0.0000000000e+00 -1.3999995489e+01 0.0000000000e+00 0.0000000000e+00 2.3934890270e-04 0.0000000000e+00 0.0000000000e+00 9.4884210092e-03 +0.100000 1 5.0000000000e+00 0.0000000000e+00 -1.3999985843e+01 0.0000000000e+00 0.0000000000e+00 5.6219367406e-04 0.0000000000e+00 0.0000000000e+00 1.6656440931e-02 +0.125000 1 5.0000000000e+00 0.0000000000e+00 -1.3999965690e+01 0.0000000000e+00 0.0000000000e+00 1.0876535691e-03 0.0000000000e+00 0.0000000000e+00 2.5682194750e-02 +0.150000 1 5.0000000000e+00 0.0000000000e+00 -1.3999929394e+01 0.0000000000e+00 0.0000000000e+00 1.8609921150e-03 0.0000000000e+00 0.0000000000e+00 3.6470424618e-02 +0.175000 1 5.0000000000e+00 0.0000000000e+00 -1.3999870217e+01 0.0000000000e+00 0.0000000000e+00 2.9250274991e-03 0.0000000000e+00 0.0000000000e+00 4.8920822328e-02 +0.200000 1 5.0000000000e+00 0.0000000000e+00 -1.3999780384e+01 0.0000000000e+00 0.0000000000e+00 4.3200109175e-03 0.0000000000e+00 0.0000000000e+00 6.2928398803e-02 +0.225000 1 5.0000000000e+00 0.0000000000e+00 -1.3999651145e+01 0.0000000000e+00 0.0000000000e+00 6.0835142251e-03 0.0000000000e+00 0.0000000000e+00 7.8383858639e-02 +0.250000 1 5.0000000000e+00 0.0000000000e+00 -1.3999472846e+01 0.0000000000e+00 0.0000000000e+00 8.2503270044e-03 0.0000000000e+00 0.0000000000e+00 9.5173978882e-02 +0.275000 1 5.0000000000e+00 0.0000000000e+00 -1.3999235001e+01 0.0000000000e+00 0.0000000000e+00 1.0852363148e-02 0.0000000000e+00 0.0000000000e+00 1.1318199122e-01 +0.300000 1 5.0000000000e+00 0.0000000000e+00 -1.3998926359e+01 0.0000000000e+00 0.0000000000e+00 1.3918577029e-02 0.0000000000e+00 0.0000000000e+00 1.3228796675e-01 +0.325000 1 5.0000000000e+00 0.0000000000e+00 -1.3998534987e+01 0.0000000000e+00 0.0000000000e+00 1.7474889317e-02 0.0000000000e+00 0.0000000000e+00 1.5236920254e-01 +0.350000 1 5.0000000000e+00 0.0000000000e+00 -1.3998048339e+01 0.0000000000e+00 0.0000000000e+00 2.1544122468e-02 0.0000000000e+00 0.0000000000e+00 1.7330060916e-01 +0.375000 1 5.0000000000e+00 0.0000000000e+00 -1.3997453341e+01 0.0000000000e+00 0.0000000000e+00 2.6145945911e-02 0.0000000000e+00 0.0000000000e+00 1.9495509834e-01 +0.400000 1 5.0000000000e+00 0.0000000000e+00 -1.3996736466e+01 0.0000000000e+00 0.0000000000e+00 3.1296830914e-02 0.0000000000e+00 0.0000000000e+00 2.1720397005e-01 +0.425000 1 5.0000000000e+00 0.0000000000e+00 -1.3995883813e+01 0.0000000000e+00 0.0000000000e+00 3.7010015117e-02 0.0000000000e+00 0.0000000000e+00 2.3991729813e-01 +0.450000 1 5.0000000000e+00 0.0000000000e+00 -1.3994881195e+01 0.0000000000e+00 0.0000000000e+00 4.3295476679e-02 0.0000000000e+00 0.0000000000e+00 2.6296431381e-01 +0.475000 1 5.0000000000e+00 0.0000000000e+00 -1.3993714214e+01 0.0000000000e+00 0.0000000000e+00 5.0159917971e-02 0.0000000000e+00 0.0000000000e+00 2.8621378621e-01 +0.500000 1 5.0000000000e+00 0.0000000000e+00 -1.3992368345e+01 0.0000000000e+00 0.0000000000e+00 5.7606758748e-02 0.0000000000e+00 0.0000000000e+00 3.0953439921e-01 +0.525000 1 5.0000000000e+00 0.0000000000e+00 -1.3990829020e+01 0.0000000000e+00 0.0000000000e+00 6.5636138680e-02 0.0000000000e+00 0.0000000000e+00 3.3279512392e-01 +0.550000 1 5.0000000000e+00 0.0000000000e+00 -1.3989081709e+01 0.0000000000e+00 0.0000000000e+00 7.4244929139e-02 0.0000000000e+00 0.0000000000e+00 3.5586558601e-01 +0.575000 1 5.0000000000e+00 0.0000000000e+00 -1.3987111998e+01 0.0000000000e+00 0.0000000000e+00 8.3426754092e-02 0.0000000000e+00 0.0000000000e+00 3.7861642723e-01 +0.600000 1 5.0000000000e+00 0.0000000000e+00 -1.3984905675e+01 0.0000000000e+00 0.0000000000e+00 9.3172019957e-02 0.0000000000e+00 0.0000000000e+00 4.0091966045e-01 +0.625000 1 5.0000000000e+00 0.0000000000e+00 -1.3982448807e+01 0.0000000000e+00 0.0000000000e+00 1.0346795424e-01 0.0000000000e+00 0.0000000000e+00 4.2264901753e-01 +0.650000 1 5.0000000000e+00 0.0000000000e+00 -1.3979727820e+01 0.0000000000e+00 0.0000000000e+00 1.1429865279e-01 0.0000000000e+00 0.0000000000e+00 4.4368028942e-01 +0.675000 1 5.0000000000e+00 0.0000000000e+00 -1.3976729575e+01 0.0000000000e+00 0.0000000000e+00 1.2564513543e-01 0.0000000000e+00 0.0000000000e+00 4.6389165785e-01 +0.700000 1 5.0000000000e+00 0.0000000000e+00 -1.3973441447e+01 0.0000000000e+00 0.0000000000e+00 1.3748540977e-01 0.0000000000e+00 0.0000000000e+00 4.8316401803e-01 +0.725000 1 5.0000000000e+00 0.0000000000e+00 -1.3969851397e+01 0.0000000000e+00 0.0000000000e+00 1.4979454302e-01 0.0000000000e+00 0.0000000000e+00 5.0138129176e-01 +0.750000 1 5.0000000000e+00 0.0000000000e+00 -1.3965948044e+01 0.0000000000e+00 0.0000000000e+00 1.6254474140e-01 0.0000000000e+00 0.0000000000e+00 5.1843073044e-01 +0.775000 1 5.0000000000e+00 0.0000000000e+00 -1.3961720738e+01 0.0000000000e+00 0.0000000000e+00 1.7570543711e-01 0.0000000000e+00 0.0000000000e+00 5.3420320740e-01 +0.800000 1 5.0000000000e+00 0.0000000000e+00 -1.3957159627e+01 0.0000000000e+00 0.0000000000e+00 1.8924338240e-01 0.0000000000e+00 0.0000000000e+00 5.4859349915e-01 +0.825000 1 5.0000000000e+00 0.0000000000e+00 -1.3952255723e+01 0.0000000000e+00 0.0000000000e+00 2.0312275054e-01 0.0000000000e+00 0.0000000000e+00 5.6150055495e-01 +0.850000 1 5.0000000000e+00 0.0000000000e+00 -1.3947000963e+01 0.0000000000e+00 0.0000000000e+00 2.1730524338e-01 0.0000000000e+00 0.0000000000e+00 5.7282775436e-01 +0.875000 1 5.0000000000e+00 0.0000000000e+00 -1.3941388273e+01 0.0000000000e+00 0.0000000000e+00 2.3175020521e-01 0.0000000000e+00 0.0000000000e+00 5.8248315227e-01 +0.900000 1 5.0000000000e+00 0.0000000000e+00 -1.3935411623e+01 0.0000000000e+00 0.0000000000e+00 2.4641474257e-01 0.0000000000e+00 0.0000000000e+00 5.9037971104e-01 +0.925000 1 5.0000000000e+00 0.0000000000e+00 -1.3929066081e+01 0.0000000000e+00 0.0000000000e+00 2.6125384969e-01 0.0000000000e+00 0.0000000000e+00 5.9643551949e-01 +0.950000 1 5.0000000000e+00 0.0000000000e+00 -1.3922347866e+01 0.0000000000e+00 0.0000000000e+00 2.7622053926e-01 0.0000000000e+00 0.0000000000e+00 6.0057399818e-01 +0.975000 1 5.0000000000e+00 0.0000000000e+00 -1.3915254397e+01 0.0000000000e+00 0.0000000000e+00 2.9126597814e-01 0.0000000000e+00 0.0000000000e+00 6.0272409086e-01 +1.000000 1 5.0000000000e+00 0.0000000000e+00 -1.3907784332e+01 0.0000000000e+00 0.0000000000e+00 3.0633962766e-01 0.0000000000e+00 0.0000000000e+00 6.0282044178e-01 +1.025000 1 5.0000000000e+00 0.0000000000e+00 -1.3899937614e+01 0.0000000000e+00 0.0000000000e+00 3.2138938827e-01 0.0000000000e+00 0.0000000000e+00 6.0080355849e-01 +1.050000 1 5.0000000000e+00 0.0000000000e+00 -1.3891715507e+01 0.0000000000e+00 0.0000000000e+00 3.3636174792e-01 0.0000000000e+00 0.0000000000e+00 5.9661996009e-01 +1.075000 1 5.0000000000e+00 0.0000000000e+00 -1.3883120628e+01 0.0000000000e+00 0.0000000000e+00 3.5120193411e-01 0.0000000000e+00 0.0000000000e+00 5.9022231057e-01 +1.100000 1 5.0000000000e+00 0.0000000000e+00 -1.3874156977e+01 0.0000000000e+00 0.0000000000e+00 3.6585406898e-01 0.0000000000e+00 0.0000000000e+00 5.8156953719e-01 +1.125000 1 5.0000000000e+00 0.0000000000e+00 -1.3864829965e+01 0.0000000000e+00 0.0000000000e+00 3.8026132726e-01 0.0000000000e+00 0.0000000000e+00 5.7062693371e-01 +1.150000 1 5.0000000000e+00 0.0000000000e+00 -1.3855146432e+01 0.0000000000e+00 0.0000000000e+00 3.9436609650e-01 0.0000000000e+00 0.0000000000e+00 5.5736624837e-01 +1.175000 1 5.0000000000e+00 0.0000000000e+00 -1.3845114666e+01 0.0000000000e+00 0.0000000000e+00 4.0811013946e-01 0.0000000000e+00 0.0000000000e+00 5.4176575659e-01 +1.200000 1 5.0000000000e+00 0.0000000000e+00 -1.3834744420e+01 0.0000000000e+00 0.0000000000e+00 4.2143475794e-01 0.0000000000e+00 0.0000000000e+00 5.2381031830e-01 +1.225000 1 5.0000000000e+00 0.0000000000e+00 -1.3824046915e+01 0.0000000000e+00 0.0000000000e+00 4.3428095802e-01 0.0000000000e+00 0.0000000000e+00 5.0349141988e-01 +1.250000 1 5.0000000000e+00 0.0000000000e+00 -1.3813034851e+01 0.0000000000e+00 0.0000000000e+00 4.4658961608e-01 0.0000000000e+00 0.0000000000e+00 4.8080720078e-01 +1.275000 1 5.0000000000e+00 0.0000000000e+00 -1.3801722406e+01 0.0000000000e+00 0.0000000000e+00 4.5830164524e-01 0.0000000000e+00 0.0000000000e+00 4.5576246480e-01 +1.300000 1 5.0000000000e+00 0.0000000000e+00 -1.3790125232e+01 0.0000000000e+00 0.0000000000e+00 4.6935816203e-01 0.0000000000e+00 0.0000000000e+00 4.2836867612e-01 +1.325000 1 5.0000000000e+00 0.0000000000e+00 -1.3778260448e+01 0.0000000000e+00 0.0000000000e+00 4.7970065265e-01 0.0000000000e+00 0.0000000000e+00 3.9864394024e-01 +1.350000 1 5.0000000000e+00 0.0000000000e+00 -1.3766146633e+01 0.0000000000e+00 0.0000000000e+00 4.8927113860e-01 0.0000000000e+00 0.0000000000e+00 3.6661296981e-01 +1.375000 1 5.0000000000e+00 0.0000000000e+00 -1.3753803802e+01 0.0000000000e+00 0.0000000000e+00 4.9801234130e-01 0.0000000000e+00 0.0000000000e+00 3.3230703576e-01 +1.400000 1 5.0000000000e+00 0.0000000000e+00 -1.3741253397e+01 0.0000000000e+00 0.0000000000e+00 5.0586784529e-01 0.0000000000e+00 0.0000000000e+00 2.9576390356e-01 +1.425000 1 5.0000000000e+00 0.0000000000e+00 -1.3728518253e+01 0.0000000000e+00 0.0000000000e+00 5.1278225959e-01 0.0000000000e+00 0.0000000000e+00 2.5702775521e-01 +1.450000 1 5.0000000000e+00 0.0000000000e+00 -1.3715622578e+01 0.0000000000e+00 0.0000000000e+00 5.1870137707e-01 0.0000000000e+00 0.0000000000e+00 2.1614909683e-01 +1.475000 1 5.0000000000e+00 0.0000000000e+00 -1.3702591919e+01 0.0000000000e+00 0.0000000000e+00 5.2357233119e-01 0.0000000000e+00 0.0000000000e+00 1.7318465245e-01 +1.500000 1 5.0000000000e+00 0.0000000000e+00 -1.3689453125e+01 0.0000000000e+00 0.0000000000e+00 5.2734375000e-01 0.0000000000e+00 0.0000000000e+00 1.2819724397e-01 +1.525000 1 5.0000000000e+00 0.0000000000e+00 -1.3676234309e+01 0.0000000000e+00 0.0000000000e+00 5.2996590696e-01 0.0000000000e+00 0.0000000000e+00 8.1255657894e-02 +1.550000 1 5.0000000000e+00 0.0000000000e+00 -1.3662964807e+01 0.0000000000e+00 0.0000000000e+00 5.3139086821e-01 0.0000000000e+00 0.0000000000e+00 3.2434498891e-02 +1.575000 1 5.0000000000e+00 0.0000000000e+00 -1.3649675126e+01 0.0000000000e+00 0.0000000000e+00 5.3157263613e-01 0.0000000000e+00 0.0000000000e+00 -1.8185969194e-02 +1.600000 1 5.0000000000e+00 0.0000000000e+00 -1.3636396902e+01 0.0000000000e+00 0.0000000000e+00 5.3046728864e-01 0.0000000000e+00 0.0000000000e+00 -7.0519994699e-02 +1.625000 1 5.0000000000e+00 0.0000000000e+00 -1.3623162836e+01 0.0000000000e+00 0.0000000000e+00 5.2803311414e-01 0.0000000000e+00 0.0000000000e+00 -1.2447652136e-01 +1.650000 1 5.0000000000e+00 0.0000000000e+00 -1.3610006648e+01 0.0000000000e+00 0.0000000000e+00 5.2423074175e-01 0.0000000000e+00 0.0000000000e+00 -1.7995938303e-01 +1.675000 1 5.0000000000e+00 0.0000000000e+00 -1.3596963009e+01 0.0000000000e+00 0.0000000000e+00 5.1902326648e-01 0.0000000000e+00 0.0000000000e+00 -2.3686750939e-01 +1.700000 1 5.0000000000e+00 0.0000000000e+00 -1.3584067481e+01 0.0000000000e+00 0.0000000000e+00 5.1237636915e-01 0.0000000000e+00 0.0000000000e+00 -2.9509514222e-01 +1.725000 1 5.0000000000e+00 0.0000000000e+00 -1.3571356450e+01 0.0000000000e+00 0.0000000000e+00 5.0425843080e-01 0.0000000000e+00 0.0000000000e+00 -3.5453206185e-01 +1.750000 1 5.0000000000e+00 0.0000000000e+00 -1.3558867059e+01 0.0000000000e+00 0.0000000000e+00 4.9464064127e-01 0.0000000000e+00 0.0000000000e+00 -4.1506382309e-01 +1.775000 1 5.0000000000e+00 0.0000000000e+00 -1.3546637133e+01 0.0000000000e+00 0.0000000000e+00 4.8349710181e-01 0.0000000000e+00 0.0000000000e+00 -4.7657200030e-01 +1.800000 1 5.0000000000e+00 0.0000000000e+00 -1.3534705110e+01 0.0000000000e+00 0.0000000000e+00 4.7080492143e-01 0.0000000000e+00 0.0000000000e+00 -5.3893444102e-01 +1.825000 1 5.0000000000e+00 0.0000000000e+00 -1.3523109959e+01 0.0000000000e+00 0.0000000000e+00 4.5654430682e-01 0.0000000000e+00 0.0000000000e+00 -6.0202552763e-01 +1.850000 1 5.0000000000e+00 0.0000000000e+00 -1.3511891104e+01 0.0000000000e+00 0.0000000000e+00 4.4069864564e-01 0.0000000000e+00 0.0000000000e+00 -6.6571644640e-01 +1.875000 1 5.0000000000e+00 0.0000000000e+00 -1.3501088347e+01 0.0000000000e+00 0.0000000000e+00 4.2325458295e-01 0.0000000000e+00 0.0000000000e+00 -7.2987546353e-01 +1.900000 1 5.0000000000e+00 0.0000000000e+00 -1.3490741780e+01 0.0000000000e+00 0.0000000000e+00 4.0420209075e-01 0.0000000000e+00 0.0000000000e+00 -7.9436820744e-01 +1.925000 1 5.0000000000e+00 0.0000000000e+00 -1.3480891702e+01 0.0000000000e+00 0.0000000000e+00 3.8353453029e-01 0.0000000000e+00 0.0000000000e+00 -8.5905795686e-01 +1.950000 1 5.0000000000e+00 0.0000000000e+00 -1.3471578540e+01 0.0000000000e+00 0.0000000000e+00 3.6124870719e-01 0.0000000000e+00 0.0000000000e+00 -9.2380593399e-01 +1.975000 1 5.0000000000e+00 0.0000000000e+00 -1.3462842751e+01 0.0000000000e+00 0.0000000000e+00 3.3734491910e-01 0.0000000000e+00 0.0000000000e+00 -9.8847160223e-01 +2.000000 1 5.0000000000e+00 0.0000000000e+00 -1.3454724746e+01 0.0000000000e+00 0.0000000000e+00 3.1182699595e-01 0.0000000000e+00 0.0000000000e+00 -1.0529129679e+00 +2.025000 1 5.0000000000e+00 0.0000000000e+00 -1.3447264792e+01 0.0000000000e+00 0.0000000000e+00 2.8470233254e-01 0.0000000000e+00 0.0000000000e+00 -1.1169868851e+00 +2.050000 1 5.0000000000e+00 0.0000000000e+00 -1.3440502928e+01 0.0000000000e+00 0.0000000000e+00 2.5598191353e-01 0.0000000000e+00 0.0000000000e+00 -1.1805493635e+00 +2.075000 1 5.0000000000e+00 0.0000000000e+00 -1.3434478874e+01 0.0000000000e+00 0.0000000000e+00 2.2568033067e-01 0.0000000000e+00 0.0000000000e+00 -1.2434558779e+00 +2.100000 1 5.0000000000e+00 0.0000000000e+00 -1.3429231937e+01 0.0000000000e+00 0.0000000000e+00 1.9381579226e-01 0.0000000000e+00 0.0000000000e+00 -1.3055616798e+00 +2.125000 1 5.0000000000e+00 0.0000000000e+00 -1.3424800928e+01 0.0000000000e+00 0.0000000000e+00 1.6041012490e-01 0.0000000000e+00 0.0000000000e+00 -1.3667221089e+00 +2.150000 1 5.0000000000e+00 0.0000000000e+00 -1.3421224063e+01 0.0000000000e+00 0.0000000000e+00 1.2548876729e-01 0.0000000000e+00 0.0000000000e+00 -1.4267929055e+00 +2.175000 1 5.0000000000e+00 0.0000000000e+00 -1.3418538879e+01 0.0000000000e+00 0.0000000000e+00 8.9080756404e-02 0.0000000000e+00 0.0000000000e+00 -1.4856305225e+00 +2.200000 1 5.0000000000e+00 0.0000000000e+00 -1.3416782143e+01 0.0000000000e+00 0.0000000000e+00 5.1218705734e-02 0.0000000000e+00 0.0000000000e+00 -1.5430924358e+00 +2.225000 1 5.0000000000e+00 0.0000000000e+00 -1.3415989760e+01 0.0000000000e+00 0.0000000000e+00 1.1938775864e-02 0.0000000000e+00 0.0000000000e+00 -1.5990374537e+00 +2.250000 1 5.0000000000e+00 0.0000000000e+00 -1.3416196690e+01 0.0000000000e+00 0.0000000000e+00 -2.8719362675e-02 0.0000000000e+00 0.0000000000e+00 -1.6533260232e+00 +2.275000 1 5.0000000000e+00 0.0000000000e+00 -1.3417436855e+01 0.0000000000e+00 0.0000000000e+00 -7.0712574186e-02 0.0000000000e+00 0.0000000000e+00 -1.7058205343e+00 +2.300000 1 5.0000000000e+00 0.0000000000e+00 -1.3419743057e+01 0.0000000000e+00 0.0000000000e+00 -1.1399431014e-01 0.0000000000e+00 0.0000000000e+00 -1.7563856204e+00 +2.325000 1 5.0000000000e+00 0.0000000000e+00 -1.3423146893e+01 0.0000000000e+00 0.0000000000e+00 -1.5851466898e-01 0.0000000000e+00 0.0000000000e+00 -1.8048884541e+00 +2.350000 1 5.0000000000e+00 0.0000000000e+00 -1.3427678670e+01 0.0000000000e+00 0.0000000000e+00 -2.0422046324e-01 0.0000000000e+00 0.0000000000e+00 -1.8511990394e+00 +2.375000 1 5.0000000000e+00 0.0000000000e+00 -1.3433367326e+01 0.0000000000e+00 0.0000000000e+00 -2.5105529395e-01 0.0000000000e+00 0.0000000000e+00 -1.8951904980e+00 +2.400000 1 5.0000000000e+00 0.0000000000e+00 -1.3440240349e+01 0.0000000000e+00 0.0000000000e+00 -2.9895963206e-01 0.0000000000e+00 0.0000000000e+00 -1.9367393495e+00 +2.425000 1 5.0000000000e+00 0.0000000000e+00 -1.3448323700e+01 0.0000000000e+00 0.0000000000e+00 -3.4787090687e-01 0.0000000000e+00 0.0000000000e+00 -1.9757257860e+00 +2.450000 1 5.0000000000e+00 0.0000000000e+00 -1.3457641740e+01 0.0000000000e+00 0.0000000000e+00 -3.9772360117e-01 0.0000000000e+00 0.0000000000e+00 -2.0120339393e+00 +2.475000 1 5.0000000000e+00 0.0000000000e+00 -1.3468217156e+01 0.0000000000e+00 0.0000000000e+00 -4.4844935300e-01 0.0000000000e+00 0.0000000000e+00 -2.0455521409e+00 +2.500000 1 5.0000000000e+00 0.0000000000e+00 -1.3480070891e+01 0.0000000000e+00 0.0000000000e+00 -4.9997706383e-01 0.0000000000e+00 0.0000000000e+00 -2.0761731734e+00 +2.525000 1 5.0000000000e+00 0.0000000000e+00 -1.3493222078e+01 0.0000000000e+00 0.0000000000e+00 -5.5223301288e-01 0.0000000000e+00 0.0000000000e+00 -2.1037945148e+00 +2.550000 1 5.0000000000e+00 0.0000000000e+00 -1.3507687976e+01 0.0000000000e+00 0.0000000000e+00 -6.0514097744e-01 0.0000000000e+00 0.0000000000e+00 -2.1283185725e+00 +2.575000 1 5.0000000000e+00 0.0000000000e+00 -1.3523483906e+01 0.0000000000e+00 0.0000000000e+00 -6.5862235900e-01 0.0000000000e+00 0.0000000000e+00 -2.1496529088e+00 +2.600000 1 5.0000000000e+00 0.0000000000e+00 -1.3540623199e+01 0.0000000000e+00 0.0000000000e+00 -7.1259631476e-01 0.0000000000e+00 0.0000000000e+00 -2.1677104560e+00 +2.625000 1 5.0000000000e+00 0.0000000000e+00 -1.3559117136e+01 0.0000000000e+00 0.0000000000e+00 -7.6697989452e-01 0.0000000000e+00 0.0000000000e+00 -2.1824097220e+00 +2.650000 1 5.0000000000e+00 0.0000000000e+00 -1.3578974900e+01 0.0000000000e+00 0.0000000000e+00 -8.2168818250e-01 0.0000000000e+00 0.0000000000e+00 -2.1936749840e+00 +2.675000 1 5.0000000000e+00 0.0000000000e+00 -1.3600203529e+01 0.0000000000e+00 0.0000000000e+00 -8.7663444391e-01 0.0000000000e+00 0.0000000000e+00 -2.2014364728e+00 +2.700000 1 5.0000000000e+00 0.0000000000e+00 -1.3622807869e+01 0.0000000000e+00 0.0000000000e+00 -9.3173027592e-01 0.0000000000e+00 0.0000000000e+00 -2.2056305442e+00 +2.725000 1 5.0000000000e+00 0.0000000000e+00 -1.3646790540e+01 0.0000000000e+00 0.0000000000e+00 -9.8688576286e-01 0.0000000000e+00 0.0000000000e+00 -2.2061998395e+00 +2.750000 1 5.0000000000e+00 0.0000000000e+00 -1.3672151894e+01 0.0000000000e+00 0.0000000000e+00 -1.0420096352e+00 0.0000000000e+00 0.0000000000e+00 -2.2030934335e+00 +2.775000 1 5.0000000000e+00 0.0000000000e+00 -1.3698889988e+01 0.0000000000e+00 0.0000000000e+00 -1.0970094322e+00 0.0000000000e+00 0.0000000000e+00 -2.1962669706e+00 +2.800000 1 5.0000000000e+00 0.0000000000e+00 -1.3727000553e+01 0.0000000000e+00 0.0000000000e+00 -1.1517916675e+00 0.0000000000e+00 0.0000000000e+00 -2.1856827877e+00 +2.825000 1 5.0000000000e+00 0.0000000000e+00 -1.3756476973e+01 0.0000000000e+00 0.0000000000e+00 -1.2062619982e+00 0.0000000000e+00 0.0000000000e+00 -2.1713100245e+00 +2.850000 1 5.0000000000e+00 0.0000000000e+00 -1.3787310262e+01 0.0000000000e+00 0.0000000000e+00 -1.2603253956e+00 0.0000000000e+00 0.0000000000e+00 -2.1531247206e+00 +2.875000 1 5.0000000000e+00 0.0000000000e+00 -1.3819489055e+01 0.0000000000e+00 0.0000000000e+00 -1.3138863196e+00 0.0000000000e+00 0.0000000000e+00 -2.1311098994e+00 +2.900000 1 5.0000000000e+00 0.0000000000e+00 -1.3852999592e+01 0.0000000000e+00 0.0000000000e+00 -1.3668488933e+00 0.0000000000e+00 0.0000000000e+00 -2.1052556382e+00 +2.925000 1 5.0000000000e+00 0.0000000000e+00 -1.3887825713e+01 0.0000000000e+00 0.0000000000e+00 -1.4191170807e+00 0.0000000000e+00 0.0000000000e+00 -2.0755591248e+00 +2.950000 1 5.0000000000e+00 0.0000000000e+00 -1.3923948859e+01 0.0000000000e+00 0.0000000000e+00 -1.4705948650e+00 0.0000000000e+00 0.0000000000e+00 -2.0420247003e+00 +2.975000 1 5.0000000000e+00 0.0000000000e+00 -1.3961348071e+01 0.0000000000e+00 0.0000000000e+00 -1.5211864272e+00 0.0000000000e+00 0.0000000000e+00 -2.0046638880e+00 +3.000000 1 5.0000000000e+00 0.0000000000e+00 -1.4000000000e+01 0.0000000000e+00 0.0000000000e+00 -1.5707963268e+00 0.0000000000e+00 0.0000000000e+00 -1.9634954085e+00 +3.025000 1 5.0000000000e+00 0.0000000000e+00 -1.4039878916e+01 0.0000000000e+00 0.0000000000e+00 -1.6193296811e+00 0.0000000000e+00 0.0000000000e+00 -1.9185451800e+00 +3.050000 1 5.0000000000e+00 0.0000000000e+00 -1.4080956728e+01 0.0000000000e+00 0.0000000000e+00 -1.6666923451e+00 0.0000000000e+00 0.0000000000e+00 -1.8698463056e+00 +3.075000 1 5.0000000000e+00 0.0000000000e+00 -1.4123203001e+01 0.0000000000e+00 0.0000000000e+00 -1.7127910911e+00 0.0000000000e+00 0.0000000000e+00 -1.8174390459e+00 +3.100000 1 5.0000000000e+00 0.0000000000e+00 -1.4166584982e+01 0.0000000000e+00 0.0000000000e+00 -1.7575337870e+00 0.0000000000e+00 0.0000000000e+00 -1.7613707778e+00 +3.125000 1 5.0000000000e+00 0.0000000000e+00 -1.4211067632e+01 0.0000000000e+00 0.0000000000e+00 -1.8008295733e+00 0.0000000000e+00 0.0000000000e+00 -1.7016959390e+00 +3.150000 1 5.0000000000e+00 0.0000000000e+00 -1.4256613657e+01 0.0000000000e+00 0.0000000000e+00 -1.8425890392e+00 0.0000000000e+00 0.0000000000e+00 -1.6384759591e+00 +3.175000 1 5.0000000000e+00 0.0000000000e+00 -1.4303183549e+01 0.0000000000e+00 0.0000000000e+00 -1.8827243960e+00 0.0000000000e+00 0.0000000000e+00 -1.5717791763e+00 +3.200000 1 5.0000000000e+00 0.0000000000e+00 -1.4350735626e+01 0.0000000000e+00 0.0000000000e+00 -1.9211496491e+00 0.0000000000e+00 0.0000000000e+00 -1.5016807415e+00 +3.225000 1 5.0000000000e+00 0.0000000000e+00 -1.4399226080e+01 0.0000000000e+00 0.0000000000e+00 -1.9577807663e+00 0.0000000000e+00 0.0000000000e+00 -1.4282625071e+00 +3.250000 1 5.0000000000e+00 0.0000000000e+00 -1.4448609030e+01 0.0000000000e+00 0.0000000000e+00 -1.9925358446e+00 0.0000000000e+00 0.0000000000e+00 -1.3516129046e+00 +3.275000 1 5.0000000000e+00 0.0000000000e+00 -1.4498836574e+01 0.0000000000e+00 0.0000000000e+00 -2.0253352723e+00 0.0000000000e+00 0.0000000000e+00 -1.2718268074e+00 +3.300000 1 5.0000000000e+00 0.0000000000e+00 -1.4549858853e+01 0.0000000000e+00 0.0000000000e+00 -2.0561018888e+00 0.0000000000e+00 0.0000000000e+00 -1.1890053816e+00 +3.325000 1 5.0000000000e+00 0.0000000000e+00 -1.4601624107e+01 0.0000000000e+00 0.0000000000e+00 -2.0847611395e+00 0.0000000000e+00 0.0000000000e+00 -1.1032559238e+00 +3.350000 1 5.0000000000e+00 0.0000000000e+00 -1.4654078749e+01 0.0000000000e+00 0.0000000000e+00 -2.1112412269e+00 0.0000000000e+00 0.0000000000e+00 -1.0146916867e+00 +3.375000 1 5.0000000000e+00 0.0000000000e+00 -1.4707167433e+01 0.0000000000e+00 0.0000000000e+00 -2.1354732576e+00 0.0000000000e+00 0.0000000000e+00 -9.2343169253e-01 +3.400000 1 5.0000000000e+00 0.0000000000e+00 -1.4760833129e+01 0.0000000000e+00 0.0000000000e+00 -2.1573913837e+00 0.0000000000e+00 0.0000000000e+00 -8.2960053518e-01 +3.425000 1 5.0000000000e+00 0.0000000000e+00 -1.4815017197e+01 0.0000000000e+00 0.0000000000e+00 -2.1769329396e+00 0.0000000000e+00 0.0000000000e+00 -7.3332817020e-01 +3.450000 1 5.0000000000e+00 0.0000000000e+00 -1.4869659475e+01 0.0000000000e+00 0.0000000000e+00 -2.1940385732e+00 0.0000000000e+00 0.0000000000e+00 -6.3474969441e-01 +3.475000 1 5.0000000000e+00 0.0000000000e+00 -1.4924698359e+01 0.0000000000e+00 0.0000000000e+00 -2.2086523721e+00 0.0000000000e+00 0.0000000000e+00 -5.3400511469e-01 +3.500000 1 5.0000000000e+00 0.0000000000e+00 -1.4980070891e+01 0.0000000000e+00 0.0000000000e+00 -2.2207219825e+00 0.0000000000e+00 0.0000000000e+00 -4.3123910654e-01 +3.525000 1 5.0000000000e+00 0.0000000000e+00 -1.5035712850e+01 0.0000000000e+00 0.0000000000e+00 -2.2301987235e+00 0.0000000000e+00 0.0000000000e+00 -3.2660076289e-01 +3.550000 1 5.0000000000e+00 0.0000000000e+00 -1.5091558845e+01 0.0000000000e+00 0.0000000000e+00 -2.2370376939e+00 0.0000000000e+00 0.0000000000e+00 -2.2024333368e-01 +3.575000 1 5.0000000000e+00 0.0000000000e+00 -1.5147542410e+01 0.0000000000e+00 0.0000000000e+00 -2.2411978729e+00 0.0000000000e+00 0.0000000000e+00 -1.1232395641e-01 +3.600000 1 5.0000000000e+00 0.0000000000e+00 -1.5203596105e+01 0.0000000000e+00 0.0000000000e+00 -2.2426422141e+00 0.0000000000e+00 0.0000000000e+00 -3.0033784888e-03 +3.625000 1 5.0000000000e+00 0.0000000000e+00 -1.5259651613e+01 0.0000000000e+00 0.0000000000e+00 -2.2413377316e+00 0.0000000000e+00 0.0000000000e+00 1.0755432835e-01 +3.650000 1 5.0000000000e+00 0.0000000000e+00 -1.5315639844e+01 0.0000000000e+00 0.0000000000e+00 -2.2372555800e+00 0.0000000000e+00 0.0000000000e+00 2.1918206099e-01 +3.675000 1 5.0000000000e+00 0.0000000000e+00 -1.5371491038e+01 0.0000000000e+00 0.0000000000e+00 -2.2303711263e+00 0.0000000000e+00 0.0000000000e+00 3.3170998463e-01 +3.700000 1 5.0000000000e+00 0.0000000000e+00 -1.5427134877e+01 0.0000000000e+00 0.0000000000e+00 -2.2206640141e+00 0.0000000000e+00 0.0000000000e+00 4.4496583877e-01 +3.725000 1 5.0000000000e+00 0.0000000000e+00 -1.5482500582e+01 0.0000000000e+00 0.0000000000e+00 -2.2081182209e+00 0.0000000000e+00 0.0000000000e+00 5.5877524891e-01 +3.750000 1 5.0000000000e+00 0.0000000000e+00 -1.5537517034e+01 0.0000000000e+00 0.0000000000e+00 -2.1927221064e+00 0.0000000000e+00 0.0000000000e+00 6.7296204335e-01 +3.775000 1 5.0000000000e+00 0.0000000000e+00 -1.5592112873e+01 0.0000000000e+00 0.0000000000e+00 -2.1744684539e+00 0.0000000000e+00 0.0000000000e+00 7.8734857451e-01 +3.800000 1 5.0000000000e+00 0.0000000000e+00 -1.5646216619e+01 0.0000000000e+00 0.0000000000e+00 -2.1533545030e+00 0.0000000000e+00 0.0000000000e+00 9.0175604424e-01 +3.825000 1 5.0000000000e+00 0.0000000000e+00 -1.5699756776e+01 0.0000000000e+00 0.0000000000e+00 -2.1293819739e+00 0.0000000000e+00 0.0000000000e+00 1.0160048324e+00 +3.850000 1 5.0000000000e+00 0.0000000000e+00 -1.5752661947e+01 0.0000000000e+00 0.0000000000e+00 -2.1025570846e+00 0.0000000000e+00 0.0000000000e+00 1.1299148284e+00 +3.875000 1 5.0000000000e+00 0.0000000000e+00 -1.5804860949e+01 0.0000000000e+00 0.0000000000e+00 -2.0728905581e+00 0.0000000000e+00 0.0000000000e+00 1.2433057641e+00 +3.900000 1 5.0000000000e+00 0.0000000000e+00 -1.5856282920e+01 0.0000000000e+00 0.0000000000e+00 -2.0403976228e+00 0.0000000000e+00 0.0000000000e+00 1.3559975496e+00 +3.925000 1 5.0000000000e+00 0.0000000000e+00 -1.5906857439e+01 0.0000000000e+00 0.0000000000e+00 -2.0050980035e+00 0.0000000000e+00 0.0000000000e+00 1.4678106081e+00 +3.950000 1 5.0000000000e+00 0.0000000000e+00 -1.5956514632e+01 0.0000000000e+00 0.0000000000e+00 -1.9670159048e+00 0.0000000000e+00 0.0000000000e+00 1.5785662127e+00 +3.975000 1 5.0000000000e+00 0.0000000000e+00 -1.6005185285e+01 0.0000000000e+00 0.0000000000e+00 -1.9261799850e+00 0.0000000000e+00 0.0000000000e+00 1.6880868211e+00 +4.000000 1 5.0000000000e+00 0.0000000000e+00 -1.6052800957e+01 0.0000000000e+00 0.0000000000e+00 -1.8826233227e+00 0.0000000000e+00 0.0000000000e+00 1.7961964110e+00 +4.025000 1 5.0000000000e+00 0.0000000000e+00 -1.6099294089e+01 0.0000000000e+00 0.0000000000e+00 -1.8363833749e+00 0.0000000000e+00 0.0000000000e+00 1.9027208121e+00 +4.050000 1 5.0000000000e+00 0.0000000000e+00 -1.6144598112e+01 0.0000000000e+00 0.0000000000e+00 -1.7875019260e+00 0.0000000000e+00 0.0000000000e+00 2.0074880369e+00 +4.075000 1 5.0000000000e+00 0.0000000000e+00 -1.6188647556e+01 0.0000000000e+00 0.0000000000e+00 -1.7360250293e+00 0.0000000000e+00 0.0000000000e+00 2.1103286081e+00 +4.100000 1 5.0000000000e+00 0.0000000000e+00 -1.6231378153e+01 0.0000000000e+00 0.0000000000e+00 -1.6820029406e+00 0.0000000000e+00 0.0000000000e+00 2.2110758823e+00 +4.125000 1 5.0000000000e+00 0.0000000000e+00 -1.6272726945e+01 0.0000000000e+00 0.0000000000e+00 -1.6254900427e+00 0.0000000000e+00 0.0000000000e+00 2.3095663699e+00 +4.150000 1 5.0000000000e+00 0.0000000000e+00 -1.6312632384e+01 0.0000000000e+00 0.0000000000e+00 -1.5665447632e+00 0.0000000000e+00 0.0000000000e+00 2.4056400490e+00 +4.175000 1 5.0000000000e+00 0.0000000000e+00 -1.6351034432e+01 0.0000000000e+00 0.0000000000e+00 -1.5052294835e+00 0.0000000000e+00 0.0000000000e+00 2.4991406754e+00 +4.200000 1 5.0000000000e+00 0.0000000000e+00 -1.6387874659e+01 0.0000000000e+00 0.0000000000e+00 -1.4416104408e+00 0.0000000000e+00 0.0000000000e+00 2.5899160853e+00 +4.225000 1 5.0000000000e+00 0.0000000000e+00 -1.6423096338e+01 0.0000000000e+00 0.0000000000e+00 -1.3757576222e+00 0.0000000000e+00 0.0000000000e+00 2.6778184914e+00 +4.250000 1 5.0000000000e+00 0.0000000000e+00 -1.6456644538e+01 0.0000000000e+00 0.0000000000e+00 -1.3077446520e+00 0.0000000000e+00 0.0000000000e+00 2.7627047723e+00 +4.275000 1 5.0000000000e+00 0.0000000000e+00 -1.6488466211e+01 0.0000000000e+00 0.0000000000e+00 -1.2376486709e+00 0.0000000000e+00 0.0000000000e+00 2.8444367534e+00 +4.300000 1 5.0000000000e+00 0.0000000000e+00 -1.6518510283e+01 0.0000000000e+00 0.0000000000e+00 -1.1655502096e+00 0.0000000000e+00 0.0000000000e+00 2.9228814795e+00 +4.325000 1 5.0000000000e+00 0.0000000000e+00 -1.6546727732e+01 0.0000000000e+00 0.0000000000e+00 -1.0915330546e+00 0.0000000000e+00 0.0000000000e+00 2.9979114783e+00 +4.350000 1 5.0000000000e+00 0.0000000000e+00 -1.6573071670e+01 0.0000000000e+00 0.0000000000e+00 -1.0156841079e+00 0.0000000000e+00 0.0000000000e+00 3.0694050147e+00 +4.375000 1 5.0000000000e+00 0.0000000000e+00 -1.6597497420e+01 0.0000000000e+00 0.0000000000e+00 -9.3809324072e-01 0.0000000000e+00 0.0000000000e+00 3.1372463344e+00 +4.400000 1 5.0000000000e+00 0.0000000000e+00 -1.6619962588e+01 0.0000000000e+00 0.0000000000e+00 -8.5885314093e-01 0.0000000000e+00 0.0000000000e+00 3.2013258971e+00 +4.425000 1 5.0000000000e+00 0.0000000000e+00 -1.6640427128e+01 0.0000000000e+00 0.0000000000e+00 -7.7805915488e-01 0.0000000000e+00 0.0000000000e+00 3.2615405990e+00 +4.450000 1 5.0000000000e+00 0.0000000000e+00 -1.6658853411e+01 0.0000000000e+00 0.0000000000e+00 -6.9580912387e-01 0.0000000000e+00 0.0000000000e+00 3.3177939826e+00 +4.475000 1 5.0000000000e+00 0.0000000000e+00 -1.6675206284e+01 0.0000000000e+00 0.0000000000e+00 -6.1220321545e-01 0.0000000000e+00 0.0000000000e+00 3.3699964359e+00 +4.500000 1 5.0000000000e+00 0.0000000000e+00 -1.6689453125e+01 0.0000000000e+00 0.0000000000e+00 -5.2734375000e-01 0.0000000000e+00 0.0000000000e+00 3.4180653777e+00 +4.525000 1 5.0000000000e+00 0.0000000000e+00 -1.6701563894e+01 0.0000000000e+00 0.0000000000e+00 -4.4133502269e-01 0.0000000000e+00 0.0000000000e+00 3.4619254305e+00 +4.550000 1 5.0000000000e+00 0.0000000000e+00 -1.6711511183e+01 0.0000000000e+00 0.0000000000e+00 -3.5428312142e-01 0.0000000000e+00 0.0000000000e+00 3.5015085806e+00 +4.575000 1 5.0000000000e+00 0.0000000000e+00 -1.6719270254e+01 0.0000000000e+00 0.0000000000e+00 -2.6629574084e-01 0.0000000000e+00 0.0000000000e+00 3.5367543234e+00 +4.600000 1 5.0000000000e+00 0.0000000000e+00 -1.6724819083e+01 0.0000000000e+00 0.0000000000e+00 -1.7748199299e-01 0.0000000000e+00 0.0000000000e+00 3.5676097954e+00 +4.625000 1 5.0000000000e+00 0.0000000000e+00 -1.6728138387e+01 0.0000000000e+00 0.0000000000e+00 -8.7952214725e-02 0.0000000000e+00 0.0000000000e+00 3.5940298915e+00 +4.650000 1 5.0000000000e+00 0.0000000000e+00 -1.6729211655e+01 0.0000000000e+00 0.0000000000e+00 2.1822275394e-03 0.0000000000e+00 0.0000000000e+00 3.6159773676e+00 +4.675000 1 5.0000000000e+00 0.0000000000e+00 -1.6728025171e+01 0.0000000000e+00 0.0000000000e+00 9.2809135461e-02 0.0000000000e+00 0.0000000000e+00 3.6334229279e+00 +4.700000 1 5.0000000000e+00 0.0000000000e+00 -1.6724568034e+01 0.0000000000e+00 0.0000000000e+00 1.8381567844e-01 0.0000000000e+00 0.0000000000e+00 3.6463452978e+00 +4.725000 1 5.0000000000e+00 0.0000000000e+00 -1.6718832167e+01 0.0000000000e+00 0.0000000000e+00 2.7508859487e-01 0.0000000000e+00 0.0000000000e+00 3.6547312801e+00 +4.750000 1 5.0000000000e+00 0.0000000000e+00 -1.6710812330e+01 0.0000000000e+00 0.0000000000e+00 3.6651439463e-01 0.0000000000e+00 0.0000000000e+00 3.6585757962e+00 +4.775000 1 5.0000000000e+00 0.0000000000e+00 -1.6700506120e+01 0.0000000000e+00 0.0000000000e+00 4.5797956240e-01 0.0000000000e+00 0.0000000000e+00 3.6578819116e+00 +4.800000 1 5.0000000000e+00 0.0000000000e+00 -1.6687913969e+01 0.0000000000e+00 0.0000000000e+00 5.4937076142e-01 0.0000000000e+00 0.0000000000e+00 3.6526608446e+00 +4.825000 1 5.0000000000e+00 0.0000000000e+00 -1.6673039139e+01 0.0000000000e+00 0.0000000000e+00 6.4057503723e-01 0.0000000000e+00 0.0000000000e+00 3.6429319596e+00 +4.850000 1 5.0000000000e+00 0.0000000000e+00 -1.6655887711e+01 0.0000000000e+00 0.0000000000e+00 7.3148002107e-01 0.0000000000e+00 0.0000000000e+00 3.6287227437e+00 +4.875000 1 5.0000000000e+00 0.0000000000e+00 -1.6636468563e+01 0.0000000000e+00 0.0000000000e+00 8.2197413251e-01 0.0000000000e+00 0.0000000000e+00 3.6100687671e+00 +4.900000 1 5.0000000000e+00 0.0000000000e+00 -1.6614793350e+01 0.0000000000e+00 0.0000000000e+00 9.1194678085e-01 0.0000000000e+00 0.0000000000e+00 3.5870136270e+00 +4.925000 1 5.0000000000e+00 0.0000000000e+00 -1.6590876481e+01 0.0000000000e+00 0.0000000000e+00 1.0012885649e+00 0.0000000000e+00 0.0000000000e+00 3.5596088755e+00 +4.950000 1 5.0000000000e+00 0.0000000000e+00 -1.6564735080e+01 0.0000000000e+00 0.0000000000e+00 1.0898914709e+00 0.0000000000e+00 0.0000000000e+00 3.5279139309e+00 +4.975000 1 5.0000000000e+00 0.0000000000e+00 -1.6536388952e+01 0.0000000000e+00 0.0000000000e+00 1.1776490676e+00 0.0000000000e+00 0.0000000000e+00 3.4919959728e+00 +5.000000 1 5.0000000000e+00 0.0000000000e+00 -1.6505860543e+01 0.0000000000e+00 0.0000000000e+00 1.2644566991e+00 0.0000000000e+00 0.0000000000e+00 3.4519298207e+00 +5.025000 1 5.0000000000e+00 0.0000000000e+00 -1.6473174890e+01 0.0000000000e+00 0.0000000000e+00 1.3502116743e+00 0.0000000000e+00 0.0000000000e+00 3.4077977971e+00 +5.050000 1 5.0000000000e+00 0.0000000000e+00 -1.6438359570e+01 0.0000000000e+00 0.0000000000e+00 1.4348134520e+00 0.0000000000e+00 0.0000000000e+00 3.3596895743e+00 +5.075000 1 5.0000000000e+00 0.0000000000e+00 -1.6401444647e+01 0.0000000000e+00 0.0000000000e+00 1.5181638232e+00 0.0000000000e+00 0.0000000000e+00 3.3077020056e+00 +5.100000 1 5.0000000000e+00 0.0000000000e+00 -1.6362462606e+01 0.0000000000e+00 0.0000000000e+00 1.6001670879e+00 0.0000000000e+00 0.0000000000e+00 3.2519389405e+00 +5.125000 1 5.0000000000e+00 0.0000000000e+00 -1.6321448294e+01 0.0000000000e+00 0.0000000000e+00 1.6807302280e+00 0.0000000000e+00 0.0000000000e+00 3.1925110253e+00 +5.150000 1 5.0000000000e+00 0.0000000000e+00 -1.6278438848e+01 0.0000000000e+00 0.0000000000e+00 1.7597630739e+00 0.0000000000e+00 0.0000000000e+00 3.1295354882e+00 +5.175000 1 5.0000000000e+00 0.0000000000e+00 -1.6233473620e+01 0.0000000000e+00 0.0000000000e+00 1.8371784670e+00 0.0000000000e+00 0.0000000000e+00 3.0631359099e+00 +5.200000 1 5.0000000000e+00 0.0000000000e+00 -1.6186594104e+01 0.0000000000e+00 0.0000000000e+00 1.9128924148e+00 0.0000000000e+00 0.0000000000e+00 2.9934419792e+00 +5.225000 1 5.0000000000e+00 0.0000000000e+00 -1.6137843851e+01 0.0000000000e+00 0.0000000000e+00 1.9868242410e+00 0.0000000000e+00 0.0000000000e+00 2.9205892356e+00 +5.250000 1 5.0000000000e+00 0.0000000000e+00 -1.6087268387e+01 0.0000000000e+00 0.0000000000e+00 2.0588967277e+00 0.0000000000e+00 0.0000000000e+00 2.8447187970e+00 +5.275000 1 5.0000000000e+00 0.0000000000e+00 -1.6034915124e+01 0.0000000000e+00 0.0000000000e+00 2.1290362521e+00 0.0000000000e+00 0.0000000000e+00 2.7659770750e+00 +5.300000 1 5.0000000000e+00 0.0000000000e+00 -1.5980833266e+01 0.0000000000e+00 0.0000000000e+00 2.1971729145e+00 0.0000000000e+00 0.0000000000e+00 2.6845154772e+00 +5.325000 1 5.0000000000e+00 0.0000000000e+00 -1.5925073720e+01 0.0000000000e+00 0.0000000000e+00 2.2632406598e+00 0.0000000000e+00 0.0000000000e+00 2.6004900965e+00 +5.350000 1 5.0000000000e+00 0.0000000000e+00 -1.5867688993e+01 0.0000000000e+00 0.0000000000e+00 2.3271773905e+00 0.0000000000e+00 0.0000000000e+00 2.5140613898e+00 +5.375000 1 5.0000000000e+00 0.0000000000e+00 -1.5808733094e+01 0.0000000000e+00 0.0000000000e+00 2.3889250713e+00 0.0000000000e+00 0.0000000000e+00 2.4253938438e+00 +5.400000 1 5.0000000000e+00 0.0000000000e+00 -1.5748261432e+01 0.0000000000e+00 0.0000000000e+00 2.4484298262e+00 0.0000000000e+00 0.0000000000e+00 2.3346556314e+00 +5.425000 1 5.0000000000e+00 0.0000000000e+00 -1.5686330708e+01 0.0000000000e+00 0.0000000000e+00 2.5056420257e+00 0.0000000000e+00 0.0000000000e+00 2.2420182568e+00 +5.450000 1 5.0000000000e+00 0.0000000000e+00 -1.5622998814e+01 0.0000000000e+00 0.0000000000e+00 2.5605163659e+00 0.0000000000e+00 0.0000000000e+00 2.1476561917e+00 +5.475000 1 5.0000000000e+00 0.0000000000e+00 -1.5558324714e+01 0.0000000000e+00 0.0000000000e+00 2.6130119378e+00 0.0000000000e+00 0.0000000000e+00 2.0517465019e+00 +5.500000 1 5.0000000000e+00 0.0000000000e+00 -1.5492368345e+01 0.0000000000e+00 0.0000000000e+00 2.6630922876e+00 0.0000000000e+00 0.0000000000e+00 1.9544684661e+00 +5.525000 1 5.0000000000e+00 0.0000000000e+00 -1.5425190494e+01 0.0000000000e+00 0.0000000000e+00 2.7107254670e+00 0.0000000000e+00 0.0000000000e+00 1.8560031863e+00 +5.550000 1 5.0000000000e+00 0.0000000000e+00 -1.5356852694e+01 0.0000000000e+00 0.0000000000e+00 2.7558840740e+00 0.0000000000e+00 0.0000000000e+00 1.7565331919e+00 +5.575000 1 5.0000000000e+00 0.0000000000e+00 -1.5287417104e+01 0.0000000000e+00 0.0000000000e+00 2.7985452834e+00 0.0000000000e+00 0.0000000000e+00 1.6562420367e+00 +5.600000 1 5.0000000000e+00 0.0000000000e+00 -1.5216946395e+01 0.0000000000e+00 0.0000000000e+00 2.8386908675e+00 0.0000000000e+00 0.0000000000e+00 1.5553138909e+00 +5.625000 1 5.0000000000e+00 0.0000000000e+00 -1.5145503639e+01 0.0000000000e+00 0.0000000000e+00 2.8763072062e+00 0.0000000000e+00 0.0000000000e+00 1.4539331278e+00 +5.650000 1 5.0000000000e+00 0.0000000000e+00 -1.5073152188e+01 0.0000000000e+00 0.0000000000e+00 2.9113852870e+00 0.0000000000e+00 0.0000000000e+00 1.3522839065e+00 +5.675000 1 5.0000000000e+00 0.0000000000e+00 -1.4999955564e+01 0.0000000000e+00 0.0000000000e+00 2.9439206941e+00 0.0000000000e+00 0.0000000000e+00 1.2505497515e+00 +5.700000 1 5.0000000000e+00 0.0000000000e+00 -1.4925977342e+01 0.0000000000e+00 0.0000000000e+00 2.9739135877e+00 0.0000000000e+00 0.0000000000e+00 1.1489131293e+00 +5.725000 1 5.0000000000e+00 0.0000000000e+00 -1.4851281035e+01 0.0000000000e+00 0.0000000000e+00 3.0013686720e+00 0.0000000000e+00 0.0000000000e+00 1.0475550232e+00 +5.750000 1 5.0000000000e+00 0.0000000000e+00 -1.4775929982e+01 0.0000000000e+00 0.0000000000e+00 3.0262951528e+00 0.0000000000e+00 0.0000000000e+00 9.4665450776e-01 +5.775000 1 5.0000000000e+00 0.0000000000e+00 -1.4699987236e+01 0.0000000000e+00 0.0000000000e+00 3.0487066843e+00 0.0000000000e+00 0.0000000000e+00 8.4638832215e-01 +5.800000 1 5.0000000000e+00 0.0000000000e+00 -1.4623515456e+01 0.0000000000e+00 0.0000000000e+00 3.0686213057e+00 0.0000000000e+00 0.0000000000e+00 7.4693044505e-01 +5.825000 1 5.0000000000e+00 0.0000000000e+00 -1.4546576793e+01 0.0000000000e+00 0.0000000000e+00 3.0860613667e+00 0.0000000000e+00 0.0000000000e+00 6.4845167047e-01 +5.850000 1 5.0000000000e+00 0.0000000000e+00 -1.4469232789e+01 0.0000000000e+00 0.0000000000e+00 3.1010534427e+00 0.0000000000e+00 0.0000000000e+00 5.5111918617e-01 +5.875000 1 5.0000000000e+00 0.0000000000e+00 -1.4391544266e+01 0.0000000000e+00 0.0000000000e+00 3.1136282394e+00 0.0000000000e+00 0.0000000000e+00 4.5509615515e-01 +5.900000 1 5.0000000000e+00 0.0000000000e+00 -1.4313571232e+01 0.0000000000e+00 0.0000000000e+00 3.1238204866e+00 0.0000000000e+00 0.0000000000e+00 3.6054130130e-01 +5.925000 1 5.0000000000e+00 0.0000000000e+00 -1.4235372776e+01 0.0000000000e+00 0.0000000000e+00 3.1316688230e+00 0.0000000000e+00 0.0000000000e+00 2.6760849984e-01 +5.950000 1 5.0000000000e+00 0.0000000000e+00 -1.4157006971e+01 0.0000000000e+00 0.0000000000e+00 3.1372156688e+00 0.0000000000e+00 0.0000000000e+00 1.7644637357e-01 +5.975000 1 5.0000000000e+00 0.0000000000e+00 -1.4078530788e+01 0.0000000000e+00 0.0000000000e+00 3.1405070904e+00 0.0000000000e+00 0.0000000000e+00 8.7197895666e-02 +6.000000 1 5.0000000000e+00 0.0000000000e+00 -1.4000000000e+01 0.0000000000e+00 0.0000000000e+00 3.1415926536e+00 0.0000000000e+00 0.0000000000e+00 8.0578529591e-16 +6.025000 1 5.0000000000e+00 0.0000000000e+00 -1.3921469155e+01 0.0000000000e+00 0.0000000000e+00 3.1405161083e+00 0.0000000000e+00 0.0000000000e+00 -8.6118708075e-02 +6.050000 1 5.0000000000e+00 0.0000000000e+00 -1.3842992131e+01 0.0000000000e+00 0.0000000000e+00 3.1372872100e+00 0.0000000000e+00 0.0000000000e+00 -1.7217839469e-01 +6.075000 1 5.0000000000e+00 0.0000000000e+00 -1.3764622713e+01 0.0000000000e+00 0.0000000000e+00 3.1319081719e+00 0.0000000000e+00 0.0000000000e+00 -2.5812007883e-01 +6.100000 1 5.0000000000e+00 0.0000000000e+00 -1.3686414610e+01 0.0000000000e+00 0.0000000000e+00 3.1243826803e+00 0.0000000000e+00 0.0000000000e+00 -3.4388486037e-01 +6.125000 1 5.0000000000e+00 0.0000000000e+00 -1.3608421423e+01 0.0000000000e+00 0.0000000000e+00 3.1147158929e+00 0.0000000000e+00 0.0000000000e+00 -4.2941396040e-01 +6.150000 1 5.0000000000e+00 0.0000000000e+00 -1.3530696605e+01 0.0000000000e+00 0.0000000000e+00 3.1029144348e+00 0.0000000000e+00 0.0000000000e+00 -5.1464876155e-01 +6.175000 1 5.0000000000e+00 0.0000000000e+00 -1.3453293424e+01 0.0000000000e+00 0.0000000000e+00 3.0889863942e+00 0.0000000000e+00 0.0000000000e+00 -5.9953084814e-01 +6.200000 1 5.0000000000e+00 0.0000000000e+00 -1.3376264928e+01 0.0000000000e+00 0.0000000000e+00 3.0729413166e+00 0.0000000000e+00 0.0000000000e+00 -6.8400204624e-01 +6.225000 1 5.0000000000e+00 0.0000000000e+00 -1.3299663908e+01 0.0000000000e+00 0.0000000000e+00 3.0547901985e+00 0.0000000000e+00 0.0000000000e+00 -7.6800446351e-01 +6.250000 1 5.0000000000e+00 0.0000000000e+00 -1.3223542865e+01 0.0000000000e+00 0.0000000000e+00 3.0345454798e+00 0.0000000000e+00 0.0000000000e+00 -8.5148052888e-01 +6.275000 1 5.0000000000e+00 0.0000000000e+00 -1.3147953966e+01 0.0000000000e+00 0.0000000000e+00 3.0122210352e+00 0.0000000000e+00 0.0000000000e+00 -9.3437303202e-01 +6.300000 1 5.0000000000e+00 0.0000000000e+00 -1.3072949017e+01 0.0000000000e+00 0.0000000000e+00 2.9878321647e+00 0.0000000000e+00 0.0000000000e+00 -1.0166251626e+00 +6.325000 1 5.0000000000e+00 0.0000000000e+00 -1.2998579422e+01 0.0000000000e+00 0.0000000000e+00 2.9613955834e+00 0.0000000000e+00 0.0000000000e+00 -1.0981805490e+00 +6.350000 1 5.0000000000e+00 0.0000000000e+00 -1.2924896151e+01 0.0000000000e+00 0.0000000000e+00 2.9329294094e+00 0.0000000000e+00 0.0000000000e+00 -1.1789832973e+00 +6.375000 1 5.0000000000e+00 0.0000000000e+00 -1.2851949703e+01 0.0000000000e+00 0.0000000000e+00 2.9024531521e+00 0.0000000000e+00 0.0000000000e+00 -1.2589780294e+00 +6.400000 1 5.0000000000e+00 0.0000000000e+00 -1.2779790071e+01 0.0000000000e+00 0.0000000000e+00 2.8699876985e+00 0.0000000000e+00 0.0000000000e+00 -1.3381099209e+00 +6.425000 1 5.0000000000e+00 0.0000000000e+00 -1.2708466710e+01 0.0000000000e+00 0.0000000000e+00 2.8355552986e+00 0.0000000000e+00 0.0000000000e+00 -1.4163247386e+00 +6.450000 1 5.0000000000e+00 0.0000000000e+00 -1.2638028501e+01 0.0000000000e+00 0.0000000000e+00 2.7991795507e+00 0.0000000000e+00 0.0000000000e+00 -1.4935688781e+00 +6.475000 1 5.0000000000e+00 0.0000000000e+00 -1.2568523719e+01 0.0000000000e+00 0.0000000000e+00 2.7608853850e+00 0.0000000000e+00 0.0000000000e+00 -1.5697894001e+00 +6.500000 1 5.0000000000e+00 0.0000000000e+00 -1.2500000000e+01 0.0000000000e+00 0.0000000000e+00 2.7206990464e+00 0.0000000000e+00 0.0000000000e+00 -1.6449340668e+00 +6.525000 1 5.0000000000e+00 0.0000000000e+00 -1.2432504306e+01 0.0000000000e+00 0.0000000000e+00 2.6786480765e+00 0.0000000000e+00 0.0000000000e+00 -1.7189513780e+00 +6.550000 1 5.0000000000e+00 0.0000000000e+00 -1.2366082895e+01 0.0000000000e+00 0.0000000000e+00 2.6347612950e+00 0.0000000000e+00 0.0000000000e+00 -1.7917906057e+00 +6.575000 1 5.0000000000e+00 0.0000000000e+00 -1.2300781289e+01 0.0000000000e+00 0.0000000000e+00 2.5890687798e+00 0.0000000000e+00 0.0000000000e+00 -1.8634018296e+00 +6.600000 1 5.0000000000e+00 0.0000000000e+00 -1.2236644243e+01 0.0000000000e+00 0.0000000000e+00 2.5416018462e+00 0.0000000000e+00 0.0000000000e+00 -1.9337359710e+00 +6.625000 1 5.0000000000e+00 0.0000000000e+00 -1.2173715713e+01 0.0000000000e+00 0.0000000000e+00 2.4923930256e+00 0.0000000000e+00 0.0000000000e+00 -2.0027448263e+00 +6.650000 1 5.0000000000e+00 0.0000000000e+00 -1.2112038827e+01 0.0000000000e+00 0.0000000000e+00 2.4414760433e+00 0.0000000000e+00 0.0000000000e+00 -2.0703811004e+00 +6.675000 1 5.0000000000e+00 0.0000000000e+00 -1.2051655855e+01 0.0000000000e+00 0.0000000000e+00 2.3888857953e+00 0.0000000000e+00 0.0000000000e+00 -2.1365984387e+00 +6.700000 1 5.0000000000e+00 0.0000000000e+00 -1.1992608181e+01 0.0000000000e+00 0.0000000000e+00 2.3346583243e+00 0.0000000000e+00 0.0000000000e+00 -2.2013514591e+00 +6.725000 1 5.0000000000e+00 0.0000000000e+00 -1.1934936273e+01 0.0000000000e+00 0.0000000000e+00 2.2788307951e+00 0.0000000000e+00 0.0000000000e+00 -2.2645957833e+00 +6.750000 1 5.0000000000e+00 0.0000000000e+00 -1.1878679656e+01 0.0000000000e+00 0.0000000000e+00 2.2214414691e+00 0.0000000000e+00 0.0000000000e+00 -2.3262880665e+00 +6.775000 1 5.0000000000e+00 0.0000000000e+00 -1.1823876887e+01 0.0000000000e+00 0.0000000000e+00 2.1625296781e+00 0.0000000000e+00 0.0000000000e+00 -2.3863860282e+00 +6.800000 1 5.0000000000e+00 0.0000000000e+00 -1.1770565524e+01 0.0000000000e+00 0.0000000000e+00 2.1021357972e+00 0.0000000000e+00 0.0000000000e+00 -2.4448484801e+00 +6.825000 1 5.0000000000e+00 0.0000000000e+00 -1.1718782103e+01 0.0000000000e+00 0.0000000000e+00 2.0403012175e+00 0.0000000000e+00 0.0000000000e+00 -2.5016353549e+00 +6.850000 1 5.0000000000e+00 0.0000000000e+00 -1.1668562116e+01 0.0000000000e+00 0.0000000000e+00 1.9770683173e+00 0.0000000000e+00 0.0000000000e+00 -2.5567077338e+00 +6.875000 1 5.0000000000e+00 0.0000000000e+00 -1.1619939979e+01 0.0000000000e+00 0.0000000000e+00 1.9124804332e+00 0.0000000000e+00 0.0000000000e+00 -2.6100278730e+00 +6.900000 1 5.0000000000e+00 0.0000000000e+00 -1.1572949017e+01 0.0000000000e+00 0.0000000000e+00 1.8465818305e+00 0.0000000000e+00 0.0000000000e+00 -2.6615592294e+00 +6.925000 1 5.0000000000e+00 0.0000000000e+00 -1.1527621434e+01 0.0000000000e+00 0.0000000000e+00 1.7794176729e+00 0.0000000000e+00 0.0000000000e+00 -2.7112664861e+00 +6.950000 1 5.0000000000e+00 0.0000000000e+00 -1.1483988296e+01 0.0000000000e+00 0.0000000000e+00 1.7110339913e+00 0.0000000000e+00 0.0000000000e+00 -2.7591155762e+00 +6.975000 1 5.0000000000e+00 0.0000000000e+00 -1.1442079507e+01 0.0000000000e+00 0.0000000000e+00 1.6414776524e+00 0.0000000000e+00 0.0000000000e+00 -2.8050737062e+00 +7.000000 1 5.0000000000e+00 0.0000000000e+00 -1.1401923789e+01 0.0000000000e+00 0.0000000000e+00 1.5707963268e+00 0.0000000000e+00 0.0000000000e+00 -2.8491093789e+00 +7.025000 1 5.0000000000e+00 0.0000000000e+00 -1.1363548662e+01 0.0000000000e+00 0.0000000000e+00 1.4990384558e+00 0.0000000000e+00 0.0000000000e+00 -2.8911924143e+00 +7.050000 1 5.0000000000e+00 0.0000000000e+00 -1.1326980427e+01 0.0000000000e+00 0.0000000000e+00 1.4262532188e+00 0.0000000000e+00 0.0000000000e+00 -2.9312939708e+00 +7.075000 1 5.0000000000e+00 0.0000000000e+00 -1.1292244147e+01 0.0000000000e+00 0.0000000000e+00 1.3524904990e+00 0.0000000000e+00 0.0000000000e+00 -2.9693865649e+00 +7.100000 1 5.0000000000e+00 0.0000000000e+00 -1.1259363627e+01 0.0000000000e+00 0.0000000000e+00 1.2778008498e+00 0.0000000000e+00 0.0000000000e+00 -3.0054440898e+00 +7.125000 1 5.0000000000e+00 0.0000000000e+00 -1.1228361402e+01 0.0000000000e+00 0.0000000000e+00 1.2022354598e+00 0.0000000000e+00 0.0000000000e+00 -3.0394418334e+00 +7.150000 1 5.0000000000e+00 0.0000000000e+00 -1.1199258721e+01 0.0000000000e+00 0.0000000000e+00 1.1258461176e+00 0.0000000000e+00 0.0000000000e+00 -3.0713564954e+00 +7.175000 1 5.0000000000e+00 0.0000000000e+00 -1.1172075527e+01 0.0000000000e+00 0.0000000000e+00 1.0486851767e+00 0.0000000000e+00 0.0000000000e+00 -3.1011662030e+00 +7.200000 1 5.0000000000e+00 0.0000000000e+00 -1.1146830451e+01 0.0000000000e+00 0.0000000000e+00 9.7080551936e-01 0.0000000000e+00 0.0000000000e+00 -3.1288505263e+00 +7.225000 1 5.0000000000e+00 0.0000000000e+00 -1.1123540795e+01 0.0000000000e+00 0.0000000000e+00 8.9226052043e-01 0.0000000000e+00 0.0000000000e+00 -3.1543904917e+00 +7.250000 1 5.0000000000e+00 0.0000000000e+00 -1.1102222521e+01 0.0000000000e+00 0.0000000000e+00 8.1310401070e-01 0.0000000000e+00 0.0000000000e+00 -3.1777685954e+00 +7.275000 1 5.0000000000e+00 0.0000000000e+00 -1.1082890239e+01 0.0000000000e+00 0.0000000000e+00 7.3339024010e-01 0.0000000000e+00 0.0000000000e+00 -3.1989688153e+00 +7.300000 1 5.0000000000e+00 0.0000000000e+00 -1.1065557198e+01 0.0000000000e+00 0.0000000000e+00 6.5317384047e-01 0.0000000000e+00 0.0000000000e+00 -3.2179766217e+00 +7.325000 1 5.0000000000e+00 0.0000000000e+00 -1.1050235277e+01 0.0000000000e+00 0.0000000000e+00 5.7250978811e-01 0.0000000000e+00 0.0000000000e+00 -3.2347789877e+00 +7.350000 1 5.0000000000e+00 0.0000000000e+00 -1.1036934978e+01 0.0000000000e+00 0.0000000000e+00 4.9145336614e-01 0.0000000000e+00 0.0000000000e+00 -3.2493643977e+00 +7.375000 1 5.0000000000e+00 0.0000000000e+00 -1.1025665416e+01 0.0000000000e+00 0.0000000000e+00 4.1006012658e-01 0.0000000000e+00 0.0000000000e+00 -3.2617228558e+00 +7.400000 1 5.0000000000e+00 0.0000000000e+00 -1.1016434314e+01 0.0000000000e+00 0.0000000000e+00 3.2838585229e-01 0.0000000000e+00 0.0000000000e+00 -3.2718458918e+00 +7.425000 1 5.0000000000e+00 0.0000000000e+00 -1.1009247999e+01 0.0000000000e+00 0.0000000000e+00 2.4648651875e-01 0.0000000000e+00 0.0000000000e+00 -3.2797265682e+00 +7.450000 1 5.0000000000e+00 0.0000000000e+00 -1.1004111396e+01 0.0000000000e+00 0.0000000000e+00 1.6441825565e-01 0.0000000000e+00 0.0000000000e+00 -3.2853594838e+00 +7.475000 1 5.0000000000e+00 0.0000000000e+00 -1.1001028025e+01 0.0000000000e+00 0.0000000000e+00 8.2237308497e-02 0.0000000000e+00 0.0000000000e+00 -3.2887407781e+00 +7.500000 1 5.0000000000e+00 0.0000000000e+00 -1.1000000000e+01 0.0000000000e+00 0.0000000000e+00 3.7521301453e-15 0.0000000000e+00 0.0000000000e+00 -3.2898681337e+00 +7.525000 1 5.0000000000e+00 0.0000000000e+00 -1.1001028025e+01 0.0000000000e+00 0.0000000000e+00 -8.2237308497e-02 0.0000000000e+00 0.0000000000e+00 -3.2887407781e+00 +7.550000 1 5.0000000000e+00 0.0000000000e+00 -1.1004111396e+01 0.0000000000e+00 0.0000000000e+00 -1.6441825565e-01 0.0000000000e+00 0.0000000000e+00 -3.2853594838e+00 +7.575000 1 5.0000000000e+00 0.0000000000e+00 -1.1009247999e+01 0.0000000000e+00 0.0000000000e+00 -2.4648651875e-01 0.0000000000e+00 0.0000000000e+00 -3.2797265682e+00 +7.600000 1 5.0000000000e+00 0.0000000000e+00 -1.1016434314e+01 0.0000000000e+00 0.0000000000e+00 -3.2838585229e-01 0.0000000000e+00 0.0000000000e+00 -3.2718458918e+00 +7.625000 1 5.0000000000e+00 0.0000000000e+00 -1.1025665416e+01 0.0000000000e+00 0.0000000000e+00 -4.1006012658e-01 0.0000000000e+00 0.0000000000e+00 -3.2617228558e+00 +7.650000 1 5.0000000000e+00 0.0000000000e+00 -1.1036934978e+01 0.0000000000e+00 0.0000000000e+00 -4.9145336614e-01 0.0000000000e+00 0.0000000000e+00 -3.2493643977e+00 +7.675000 1 5.0000000000e+00 0.0000000000e+00 -1.1050235277e+01 0.0000000000e+00 0.0000000000e+00 -5.7250978811e-01 0.0000000000e+00 0.0000000000e+00 -3.2347789877e+00 +7.700000 1 5.0000000000e+00 0.0000000000e+00 -1.1065557198e+01 0.0000000000e+00 0.0000000000e+00 -6.5317384047e-01 0.0000000000e+00 0.0000000000e+00 -3.2179766217e+00 +7.725000 1 5.0000000000e+00 0.0000000000e+00 -1.1082890239e+01 0.0000000000e+00 0.0000000000e+00 -7.3339024010e-01 0.0000000000e+00 0.0000000000e+00 -3.1989688153e+00 +7.750000 1 5.0000000000e+00 0.0000000000e+00 -1.1102222521e+01 0.0000000000e+00 0.0000000000e+00 -8.1310401070e-01 0.0000000000e+00 0.0000000000e+00 -3.1777685954e+00 +7.775000 1 5.0000000000e+00 0.0000000000e+00 -1.1123540795e+01 0.0000000000e+00 0.0000000000e+00 -8.9226052043e-01 0.0000000000e+00 0.0000000000e+00 -3.1543904917e+00 +7.800000 1 5.0000000000e+00 0.0000000000e+00 -1.1146830451e+01 0.0000000000e+00 0.0000000000e+00 -9.7080551936e-01 0.0000000000e+00 0.0000000000e+00 -3.1288505263e+00 +7.825000 1 5.0000000000e+00 0.0000000000e+00 -1.1172075527e+01 0.0000000000e+00 0.0000000000e+00 -1.0486851767e+00 0.0000000000e+00 0.0000000000e+00 -3.1011662030e+00 +7.850000 1 5.0000000000e+00 0.0000000000e+00 -1.1199258721e+01 0.0000000000e+00 0.0000000000e+00 -1.1258461176e+00 0.0000000000e+00 0.0000000000e+00 -3.0713564954e+00 +7.875000 1 5.0000000000e+00 0.0000000000e+00 -1.1228361402e+01 0.0000000000e+00 0.0000000000e+00 -1.2022354598e+00 0.0000000000e+00 0.0000000000e+00 -3.0394418334e+00 +7.900000 1 5.0000000000e+00 0.0000000000e+00 -1.1259363627e+01 0.0000000000e+00 0.0000000000e+00 -1.2778008498e+00 0.0000000000e+00 0.0000000000e+00 -3.0054440898e+00 +7.925000 1 5.0000000000e+00 0.0000000000e+00 -1.1292244147e+01 0.0000000000e+00 0.0000000000e+00 -1.3524904990e+00 0.0000000000e+00 0.0000000000e+00 -2.9693865649e+00 +7.950000 1 5.0000000000e+00 0.0000000000e+00 -1.1326980427e+01 0.0000000000e+00 0.0000000000e+00 -1.4262532188e+00 0.0000000000e+00 0.0000000000e+00 -2.9312939708e+00 +7.975000 1 5.0000000000e+00 0.0000000000e+00 -1.1363548662e+01 0.0000000000e+00 0.0000000000e+00 -1.4990384558e+00 0.0000000000e+00 0.0000000000e+00 -2.8911924143e+00 +8.000000 1 5.0000000000e+00 0.0000000000e+00 -1.1401923789e+01 0.0000000000e+00 0.0000000000e+00 -1.5707963268e+00 0.0000000000e+00 0.0000000000e+00 -2.8491093789e+00 +8.025000 1 5.0000000000e+00 0.0000000000e+00 -1.1442079507e+01 0.0000000000e+00 0.0000000000e+00 -1.6414776524e+00 0.0000000000e+00 0.0000000000e+00 -2.8050737062e+00 +8.050000 1 5.0000000000e+00 0.0000000000e+00 -1.1483988296e+01 0.0000000000e+00 0.0000000000e+00 -1.7110339913e+00 0.0000000000e+00 0.0000000000e+00 -2.7591155762e+00 +8.075000 1 5.0000000000e+00 0.0000000000e+00 -1.1527621434e+01 0.0000000000e+00 0.0000000000e+00 -1.7794176729e+00 0.0000000000e+00 0.0000000000e+00 -2.7112664861e+00 +8.100000 1 5.0000000000e+00 0.0000000000e+00 -1.1572949017e+01 0.0000000000e+00 0.0000000000e+00 -1.8465818305e+00 0.0000000000e+00 0.0000000000e+00 -2.6615592294e+00 +8.125000 1 5.0000000000e+00 0.0000000000e+00 -1.1619939979e+01 0.0000000000e+00 0.0000000000e+00 -1.9124804332e+00 0.0000000000e+00 0.0000000000e+00 -2.6100278730e+00 +8.150000 1 5.0000000000e+00 0.0000000000e+00 -1.1668562116e+01 0.0000000000e+00 0.0000000000e+00 -1.9770683173e+00 0.0000000000e+00 0.0000000000e+00 -2.5567077338e+00 +8.175000 1 5.0000000000e+00 0.0000000000e+00 -1.1718782103e+01 0.0000000000e+00 0.0000000000e+00 -2.0403012175e+00 0.0000000000e+00 0.0000000000e+00 -2.5016353549e+00 +8.200000 1 5.0000000000e+00 0.0000000000e+00 -1.1770565524e+01 0.0000000000e+00 0.0000000000e+00 -2.1021357972e+00 0.0000000000e+00 0.0000000000e+00 -2.4448484801e+00 +8.225000 1 5.0000000000e+00 0.0000000000e+00 -1.1823876887e+01 0.0000000000e+00 0.0000000000e+00 -2.1625296781e+00 0.0000000000e+00 0.0000000000e+00 -2.3863860282e+00 +8.250000 1 5.0000000000e+00 0.0000000000e+00 -1.1878679656e+01 0.0000000000e+00 0.0000000000e+00 -2.2214414691e+00 0.0000000000e+00 0.0000000000e+00 -2.3262880665e+00 +8.275000 1 5.0000000000e+00 0.0000000000e+00 -1.1934936273e+01 0.0000000000e+00 0.0000000000e+00 -2.2788307951e+00 0.0000000000e+00 0.0000000000e+00 -2.2645957833e+00 +8.300000 1 5.0000000000e+00 0.0000000000e+00 -1.1992608181e+01 0.0000000000e+00 0.0000000000e+00 -2.3346583243e+00 0.0000000000e+00 0.0000000000e+00 -2.2013514591e+00 +8.325000 1 5.0000000000e+00 0.0000000000e+00 -1.2051655855e+01 0.0000000000e+00 0.0000000000e+00 -2.3888857953e+00 0.0000000000e+00 0.0000000000e+00 -2.1365984387e+00 +8.350000 1 5.0000000000e+00 0.0000000000e+00 -1.2112038827e+01 0.0000000000e+00 0.0000000000e+00 -2.4414760433e+00 0.0000000000e+00 0.0000000000e+00 -2.0703811004e+00 +8.375000 1 5.0000000000e+00 0.0000000000e+00 -1.2173715713e+01 0.0000000000e+00 0.0000000000e+00 -2.4923930256e+00 0.0000000000e+00 0.0000000000e+00 -2.0027448263e+00 +8.400000 1 5.0000000000e+00 0.0000000000e+00 -1.2236644243e+01 0.0000000000e+00 0.0000000000e+00 -2.5416018462e+00 0.0000000000e+00 0.0000000000e+00 -1.9337359710e+00 +8.425000 1 5.0000000000e+00 0.0000000000e+00 -1.2300781289e+01 0.0000000000e+00 0.0000000000e+00 -2.5890687798e+00 0.0000000000e+00 0.0000000000e+00 -1.8634018296e+00 +8.450000 1 5.0000000000e+00 0.0000000000e+00 -1.2366082895e+01 0.0000000000e+00 0.0000000000e+00 -2.6347612950e+00 0.0000000000e+00 0.0000000000e+00 -1.7917906057e+00 +8.475000 1 5.0000000000e+00 0.0000000000e+00 -1.2432504306e+01 0.0000000000e+00 0.0000000000e+00 -2.6786480765e+00 0.0000000000e+00 0.0000000000e+00 -1.7189513780e+00 +8.500000 1 5.0000000000e+00 0.0000000000e+00 -1.2500000000e+01 0.0000000000e+00 0.0000000000e+00 -2.7206990464e+00 0.0000000000e+00 0.0000000000e+00 -1.6449340668e+00 +8.525000 1 5.0000000000e+00 0.0000000000e+00 -1.2568523719e+01 0.0000000000e+00 0.0000000000e+00 -2.7608853850e+00 0.0000000000e+00 0.0000000000e+00 -1.5697894001e+00 +8.550000 1 5.0000000000e+00 0.0000000000e+00 -1.2638028501e+01 0.0000000000e+00 0.0000000000e+00 -2.7991795507e+00 0.0000000000e+00 0.0000000000e+00 -1.4935688781e+00 +8.575000 1 5.0000000000e+00 0.0000000000e+00 -1.2708466710e+01 0.0000000000e+00 0.0000000000e+00 -2.8355552986e+00 0.0000000000e+00 0.0000000000e+00 -1.4163247386e+00 +8.600000 1 5.0000000000e+00 0.0000000000e+00 -1.2779790071e+01 0.0000000000e+00 0.0000000000e+00 -2.8699876985e+00 0.0000000000e+00 0.0000000000e+00 -1.3381099209e+00 diff --git a/tests/data/msg_tensile_safety_truncated.dat b/tests/data/msg_tensile_safety_truncated.dat new file mode 100644 index 00000000..1831358c --- /dev/null +++ b/tests/data/msg_tensile_safety_truncated.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File ------------------------------------ +msg_tensile_safety_truncated +--------------------- LINE TYPES --------------------------------------- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (N-s/-) (N-m^2) (-) (-) (-) (-) +bare 0.16 36.7 469000000.0 0.0 19900.0 1.2 0.1 1.0 0.0 +buoy 0.29 59.53 469000000.0 0.0 19900.0 1.2 0.1 1.0 0.0 +--------------------- POINTS --------------------------------------- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m^3) (m^2) (-) +1 Coupled 5.0 0.0 -14.0 0 0 0 0 +2 Fixed 125.0 0.0 -80.0 0 0 0 0 +--------------------- LINES --------------------------------------- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 - +--------------------- SECTIONS --------------------------------------- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 bare 68.114 28 +1 buoy 50.0 20 +1 bare 52.101 16 +--------------------- OPTIONS --------------------------------------- +0.025 dtM +8.6 TMax +80.0 WtrDpth +msg_tensile_safety_motion.txt motionFile +dynamic_solver 1.0e-4 1.0e-14 100 12 +True tensile_safety +--------------------- OUTPUTS --------------------------------------- +"FairTen1" +"AnchTen1" +"TDP1s" +"Curv1N25" +--------------------- need this line ----------------------------------- diff --git a/tests/data/msg_weightless_ei0.dat b/tests/data/msg_weightless_ei0.dat new file mode 100644 index 00000000..84ff40b9 --- /dev/null +++ b/tests/data/msg_weightless_ei0.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_weightless_ei0 +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +neutral 0.17 23.2654571 200000000 -1 0 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -10 0 0 0 0 +2 Fixed 450 0 -100 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 neutral 520 52 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +100.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_weightless_finite_ei.dat b/tests/data/msg_weightless_finite_ei.dat new file mode 100644 index 00000000..facd0da4 --- /dev/null +++ b/tests/data/msg_weightless_finite_ei.dat @@ -0,0 +1,37 @@ +--------------------- CableDyn Input File --- +msg_weightless_finite_ei +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +neut 0.2 32.2013247 100000000 -1 10000 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -20 0 0 0 0 +2 Fixed 80 0 -100 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 neut 120 120 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +0.05 dtM +0.0 TMax +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- From a69f879cff7b05961804c0e9342bfb5d3288e363 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Fri, 16 Oct 2026 19:08:52 +0900 Subject: [PATCH 02/11] fix: keep message buffers whole and diagnostics truthful Widen the message buffers that still cut solver messages: the mixed standalone runner and its initialisation report (4096), the as-laid friction, seabed and kernel buffers of the static solvers, the OpenFAST mesh and Hermite module buffers, and the per-line messages of the mooring system and the aggregate (1024). The seed notes of a failed EI=0 static solve and the initialisation notes of a line end with an omission marker instead of stopping mid-note; a line summary holds a whole cable note and the strain note. Keep the net-buoyant rule unchanged (dry mass not above the displaced mass). Only an EI=0 type within a relative 1e-6 below the displaced mass is named neutrally buoyant; the Python deck reader mirrors it. The shared-line rejection offers the Connect-point split only for an EI=0 line and says what applies to a finite-EI one. The Coupled End A rejection says the end would need motionFile coupling and qualifies the coupled mixed deck advice. The coarse-section warning compares each segment with 1/8 of the whole line, so it no longer depends on how a line is split into sections; no example deck triggers it. The static strain note uses 10 % when maxStrain is absent or 0, and prints a small maxStrain with its digits. In the Hermite dynamic assembly the element kernels write into small message buffers, the tangent worker sets its message only on failure, and the Cosserat assembly no longer blank-fills its per-element messages. Results are byte-identical. New driver tests cover the band edge, a finite-EI shared line, and the coarse-section warning and strain note on the standalone mixed route. Signed-off-by: Jae Hoon Seo --- CHANGELOG.md | 37 ++--- CMakeLists.txt | 25 +++- app/cabledyn.f90 | 10 +- doc/capi.rst | 4 +- doc/options.rst | 10 +- doc/troubleshooting.rst | 51 ++++--- python/cabledyn/deck_file.py | 15 +- python/tests/test_deck_file.py | 39 +++++- src/CableDyn_CosseratAssemble.f90 | 12 +- src/CableDyn_DeckDriver.f90 | 167 ++++++++++++++++------- src/CableDyn_HermiteCableDynamic.f90 | 66 +++++---- src/CableDyn_HermiteCableStatic.f90 | 26 ++-- src/CableDyn_OpenFAST_Aggregate.f90 | 2 +- src/CableDyn_OpenFAST_HermiteFMF.f90 | 4 +- src/CableDyn_OpenFAST_Mesh.f90 | 2 +- src/CableDyn_Static.f90 | 38 ++++-- src/CableDyn_System.f90 | 2 +- tests/data/msg_mixed_coarse_strain.dat | 59 ++++++++ tests/data/msg_net_buoyant_ei0.dat | 35 +++++ tests/data/msg_shared_line_finite_ei.dat | 35 +++++ tests/data/msg_weightless_ei0.dat | 2 +- 21 files changed, 465 insertions(+), 176 deletions(-) create mode 100644 tests/data/msg_mixed_coarse_strain.dat create mode 100644 tests/data/msg_net_buoyant_ei0.dat create mode 100644 tests/data/msg_shared_line_finite_ei.dat diff --git a/CHANGELOG.md b/CHANGELOG.md index 449c32b7..c5d6ee36 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -599,31 +599,36 @@ All notable changes to CableDyn are recorded in this file. The format follows driver held 200, 300 and 256 characters. Every message buffer of the solver chain, the C API handle (now 4096 characters; `CableDyn_GetLastError` still truncates to the caller's buffer, and the Python binding reads 4097 bytes), the standalone driver and the OpenFAST - glue is now long enough for the longest diagnostic. Results do not change. + glue is now long enough for the longest diagnostic. A list that can outgrow its buffer (the + seed notes of a failed `EI = 0` static solve, the initialisation notes of a line) ends with + "further ... notes omitted" instead of stopping mid-note. Results do not change. - A neutrally buoyant line is named as such. A finite-EI line whose net weight is zero and that is longer than its span was reported as "the net-heavy line is too long for its span to hang as a catenary", which is not the cause; the message now says the line is weightless, has no catenary, and could only bow under axial compression, and advises shortening it to its span - or giving it weight or tension. An `EI = 0` line type whose mass equals the displaced water - mass to seven digits passed the net-buoyant gate on rounding and then failed with a generic - non-convergence message; the gate now treats a relative 1e-6 band around the displaced mass as - neutral and rejects it at the line type with "weightless and slack: its static shape is - indeterminate". The Python deck reader applies the same band. A line type heavier than the band - is unaffected. + or giving it weight or tension. An `EI = 0` line type rejected as net-buoyant (dry mass not + above the displaced water mass, the unchanged rule) whose mass lies within a relative 1e-6 below + the displaced mass is now named neutrally buoyant, "weightless and slack: its static shape is + indeterminate", with the advice to give it weight or a finite EI and a tension. The Python deck + reader words it the same way. No line type is accepted or rejected differently. - A line stretched far beyond its elastic range now says so. A line 50 % shorter than its span converged at 100 % strain and 1.2 GN with no message, because `maxStrain` guards only the dynamics. The initialisation report notes the static fairlead strain (tension over the EA of - the End A section) above `maxStrain` when the option is given, and above 10 % when it is not. - Only a note: the equilibrium and the outputs are unchanged. + the End A section) of every line, `EI = 0` or finite-EI, above `maxStrain` when the option + is given and positive, and above 10 % otherwise (`0 maxStrain` disables only the dynamic + guard). Only a note: the equilibrium and the outputs are unchanged. - A section too coarse for its line is warned about. The coarse-mesh warning fired only for a line with fewer than three segments in all, so a 100 m one-segment top section on a 520 m line - (fairlead tension off by 50 %) passed silently. Every section of at most four segments whose - segments are longer than 10 % of the line now gets a warning, for `EI = 0` and finite-EI lines, - in the single-topology driver and in the standalone mixed route. -- Rejection messages name the unsupported capability and the workaround. A line between two - Coupled points suggests splitting it at a `Connect` point; a finite-EI cable ending on a - `Connect`/`Free`/`Coupled` point, or driven from a Coupled End A in a deck with `Connect`/`Free` - points, names the point and what the route supports; the "this coupled mode runs the mooring in + (fairlead tension off by 50 %) passed silently. Every section whose segments are longer than + 1/8 of the line (coarser than a uniform eight-segment line, however the line is split into + sections) now gets a warning, for `EI = 0` and finite-EI lines, in the single-topology driver + and in the standalone mixed route. No example deck is affected. +- Rejection messages name the unsupported capability and the workaround. An `EI = 0` line + between two Coupled points suggests splitting it at a `Connect` point, and a finite-EI one, + which that split does not admit, says to anchor it or model the span with `EI = 0` lines; a + finite-EI cable ending on a `Connect`/`Free`/`Coupled` point, or on a Coupled End A that a deck + with `Connect`/`Free` points cannot drive (it would need `motionFile` coupling), names the point + and what the route supports; the "this coupled mode runs the mooring in STILL WATER" message of a mixed deck with waves or current no longer implies a coupled run and says which routes evaluate the deck fluid; an anchor below the seabed by more than the tolerance gives the depth, the tolerance rule, and the Z to use. These messages change no diff --git a/CMakeLists.txt b/CMakeLists.txt index 60dd22e2..7b616bcc 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2210,12 +2210,17 @@ endfunction() cabledyn_msg_test(weightless_finite_ei msg_weightless_finite_ei.dat 2 "weightless .neutrally buoyant. line is longer than its span;shorten the line to its span, or give it net weight" "net-heavy") -# An EI=0 line whose mass equals the displaced water mass to seven digits is weightless and slack. +# An EI=0 line type rejected as net-buoyant whose mass is a relative 4e-9 below the displaced water +# mass is named weightless and slack; one a relative 2e-6 below it keeps the plain message. cabledyn_msg_test(weightless_ei0 msg_weightless_ei0.dat 1 - "is net-buoyant to within 1e-6;weightless and slack: its static shape is indeterminate" "") + "is neutrally buoyant .its dry mass equals the displaced water mass to within a relative 1e-6.;weightless and slack: its static shape is indeterminate" + "") +cabledyn_msg_test(net_buoyant_ei0 msg_net_buoyant_ei0.dat 1 + "is net-buoyant .dry mass <= displaced water mass.: buoyant / lazy-wave sections require a dynamic finite-EI deck" + "weightless") # A line half the length of its span converges at 100 % strain; the static solve says so. cabledyn_msg_test(static_strain msg_static_strain.dat 0 - "Note: LINE 1 is stretched to a static strain of 100.0 % at the fairlead;the static default" "") + "Note: LINE 1 is stretched to a static strain of 100.0 % at the fairlead;above 10.0 % .the note level used without maxStrain." "") # A 100 m one-segment top section of a 520 m line. cabledyn_msg_test(coarse_section msg_coarse_section.dat 0 "WARNING: LINE 1 section of type \"chain\" .100.00 m in 1 segment.s.. has segments of 100.00 m, 19.2 %" "") @@ -2223,7 +2228,12 @@ cabledyn_msg_test(coarse_section msg_coarse_section.dat 0 cabledyn_msg_test(quiet_catenary ../../examples/chain_catenary_r3_100m.dat 0 "" "static strain;too coarse to follow") cabledyn_msg_test(shared_line msg_shared_line.dat 1 - "LINE 1 End B .NodeB, POINT 2, coupled. must be a Fixed .anchor. point;split it into two lines that meet at a Connect point" "") + "LINE 1 End B .NodeB, POINT 2, coupled. must be a Fixed .anchor. point;Workaround for this EI=0 line: split it into two lines that meet at a Connect point" + "cannot be split") +# A finite-EI shared line cannot be split at a Connect point: that advice is not given. +cabledyn_msg_test(shared_line_finite_ei msg_shared_line_finite_ei.dat 1 + "finite-EI LINE 1 End B .NodeB, POINT 2, coupled. must be a Fixed .anchor. point;A finite-EI line cannot be split at a Connect point either;anchor it on a Fixed point" + "Workaround") cabledyn_msg_test(pliant_connect_end_b msg_pliant_connect_end_b.dat 1 "finite-EI LINE 1 in a mixed-topology deck needs a Fixed End B;End B is POINT 2 .connect.;Anchor the cable on a Fixed point" "") @@ -2231,7 +2241,12 @@ cabledyn_msg_test(mixed_current msg_mixed_current.dat 1 "the deck current OPTION is not supported on this route;a standalone mixed deck;runs the mooring in STILL WATER" "this coupled mode") cabledyn_msg_test(mixed_connect_coupled_cable msg_mixed_connect_coupled_cable.dat 1 - "finite-EI LINE 3: a Coupled/Vessel End A .POINT 1. is driven by a motionFile;Remove the Connect/Free points" "") + "finite-EI LINE 3: a Coupled/Vessel End A .POINT 1. would need motionFile coupling to drive it;remove the Connect/Free points;held still .that route takes no motionFile either." + "is driven by a motionFile") +# The standalone mixed route warns about a coarse section and notes a static strain above maxStrain. +cabledyn_msg_test(mixed_coarse_strain msg_mixed_coarse_strain.dat 0 + "WARNING: LINE 1 section of type \"chain\" .150.00 m in 1 segment.s.. has segments of 150.00 m, 17.6 %;Note: LINE 1 is stretched to a static strain of;above 1.00E-02 % .OPTION maxStrain." + "LINE 2 section of type") # The tensile qualification failure of a dynamic step names the remedy to the end (the message was # cut at 256 characters: "... at element 64, xi= 0.5000; increase"). cabledyn_msg_test(tensile_safety_whole msg_tensile_safety_truncated.dat 2 diff --git a/app/cabledyn.f90 b/app/cabledyn.f90 index eb15bb75..1f4bf251 100644 --- a/app/cabledyn.f90 +++ b/app/cabledyn.f90 @@ -64,8 +64,8 @@ PROGRAM cabledyn LOGICAL :: converged, has_dtm, has_tmax, has_motion_file, has_line_outputs, has_objects ! the run-time profile includes the finite-EI cable step counters (not on the mixed route) LOGICAL :: profile_cable_detail = .FALSE. - ! Sized for the aggregate and deck-driver messages it relays (512-character buffers - ! plus deck-line context), so no diagnostic is cut short. + ! Sized for the aggregate and deck-driver messages it relays (built in buffers of up to + ! 2048 characters, plus deck-line context), so no diagnostic is cut short. CHARACTER(4096) :: ErrMsg nargs = COMMAND_ARGUMENT_COUNT() @@ -450,7 +450,7 @@ SUBROUTINE run_mixed_held_deck(deck, root, dt, has_dt, run_time, has_run_time, h INTEGER :: es, n_moving, nstep, step, n_iter, miss_count, consecutive_miss, max_consecutive_miss INTEGER :: unit, ios LOGICAL :: step_converged, stalled, file_open - CHARACTER(512) :: em + CHARACTER(4096) :: em CHARACTER(4096) :: static_path, dynamic_path TYPE(StandaloneProgress) :: progress @@ -697,8 +697,8 @@ SUBROUTINE print_mixed_initialization(aggregate, stat, msg) CHARACTER(*), INTENT(OUT) :: msg INTEGER :: n_lines, n_points, n_sections, n_ei0, n_finite, i, line_id, es REAL(wp) :: tension, force(3), inclination, declination, azimuth - CHARACTER(512) :: em - CHARACTER(1024) :: note + CHARACTER(4096) :: em + CHARACTER(2048) :: note CALL CD_AGG_GetInitMetadata(aggregate, n_lines, n_points, n_sections, n_ei0, n_finite, es, em) IF (es /= CD_AGG_OK) THEN diff --git a/doc/capi.rst b/doc/capi.rst index 76d247a5..4281f708 100644 --- a/doc/capi.rst +++ b/doc/capi.rst @@ -1979,7 +1979,7 @@ surges ±0.05 m with a 10 s period. The program needs no input file. static int report(void *h, const char *where, int err) { - char msg[1024]; + char msg[4097]; /* a message is at most 4096 characters, plus the NUL */ CableDyn_GetLastError(h, msg, (int)sizeof msg); fprintf(stderr, "%s failed (status %d): %s\n", where, err, msg); return 1; @@ -2066,7 +2066,7 @@ host writes its own motion into the blocks of the points it drives before each s int major, minor, patch, abi, err = CD_C_OK, status = 1; void *h = NULL; double *q = NULL, *v = NULL, *a = NULL, *loads = NULL; - char msg[1024]; + char msg[4097]; /* a message is at most 4096 characters, plus the NUL */ CableDyn_GetVersion(&major, &minor, &patch, &abi); if (abi != CABLEDYN_CAPI_ABI_VERSION) { diff --git a/doc/options.rst b/doc/options.rst index 18d61528..a257318a 100644 --- a/doc/options.rst +++ b/doc/options.rst @@ -317,11 +317,11 @@ rejected as unknown. The dynamic Newton controls are set with ``dynamic_solver`` strain of steel, polyester, and nylon lines), stops the run with exit code 2 and a message naming the line, element, strain, estimated elastic tension, and time. It catches a numerically unstable march whose Newton residual still converges; a physical run never - reaches the default. Finite-EI cables are guarded by ``tensile_safety`` instead. The static solve is not - stopped by it: when the static fairlead strain (tension over the EA of the End A section) - exceeds this value, or 10 % when the OPTION is not given, the run prints a ``Note`` and - continues - - both (``EI = 0`` lines) + reaches the default. Finite-EI cables are guarded by ``tensile_safety`` instead. The static + solve is not stopped by it: when the static fairlead strain of any line, ``EI = 0`` or + finite-EI (tension over the EA of the End A section), exceeds this value, or 10 % when the + OPTION is not given or is ``0``, the run prints a ``Note`` and continues + - both for the dynamic guard (``EI = 0`` lines); standalone for the static note (every line) - ``0.5 maxStrain`` * - ``dynamic_solver rel abs max_iter backtracks [rhoInf]`` - keyword-first record: two reals, two integers, optional real diff --git a/doc/troubleshooting.rst b/doc/troubleshooting.rst index b469ff46..493b06b4 100644 --- a/doc/troubleshooting.rst +++ b/doc/troubleshooting.rst @@ -261,9 +261,12 @@ Model data , ) must be a Fixed (anchor) point`` - in a deck without dynamic points every line runs from a fairlead to an anchor. A line between two Coupled points (a shared line) is supported only between two ``Turbine`` - fairleads of a FAST.Farm deck. Split it into two lines that meet at a ``Connect`` point - in the middle; each line then ends on one Coupled point, and the deck becomes dynamic and - needs ``dtM`` and ``TMax``. + fairleads of a FAST.Farm deck. An ``EI = 0`` line can be split into two lines that meet at + a ``Connect`` point in the middle; each line then ends on one Coupled point, and the deck + becomes dynamic and needs ``dtM`` and ``TMax``. A finite-EI line cannot be split that way + (beside ``Connect`` points a finite-EI cable needs a Fixed End B and cannot end on a + ``Connect`` point; the message then starts ``finite-EI LINE ``): anchor it on a Fixed + point, or model the shared span with ``EI = 0`` line types split at a ``Connect`` point. * - ``finite-EI LINE in a mixed-topology deck needs a Fixed End B ... End B is POINT ()`` - a deck with ``Connect``/``Free`` points, bodies or rods that also has finite-EI cables drives @@ -272,12 +275,15 @@ Model data deck with ``Connect``/``Free`` points, bodies or rods, which is marched as one multibody system. Anchor the cable on a Fixed point, or run the cable and the lines it joins as separate decks. - * - ``finite-EI LINE : a Coupled/Vessel End A (POINT ) is driven by a motionFile`` + * - ``finite-EI LINE : a Coupled/Vessel End A (POINT ) would need motionFile coupling + to drive it`` - a mixed-topology deck that has ``Connect``/``Free`` points or bodies is marched as one - multibody system, which does not take a finite-EI cable on a Coupled End A (that end - would need ``motionFile`` coupling). Remove the ``Connect``/``Free`` points so the deck - runs as a coupled mixed deck (the ``EI = 0`` lines on the Coupled point directly), or - attach the cable to a Rigid6 body, a rod end or a Fixed point. + multibody system, which does not take ``motionFile`` coupling, so nothing would drive a + finite-EI cable on a Coupled End A. Attach the cable to a Rigid6 body, a rod end or a + Fixed point. Or remove the ``Connect``/``Free`` points so the deck becomes a coupled mixed + deck (the ``EI = 0`` lines on the Coupled point directly): a host (OpenFAST + ``CompMooring = 5`` or the C API) drives its Coupled points, and the standalone driver + runs it with them held still (that route takes no ``motionFile`` either). * - ``the deck current OPTION is not supported on this route`` / ``the deck waves OPTION ...`` - a mixed ``EI = 0``/finite-EI deck (run standalone, through the C API, OpenFAST or FAST.Farm) runs the mooring in still water: no ambient fluid field covers its span, and @@ -297,12 +303,14 @@ Model data route — a lazy-wave arch needs the finite-EI path. Give the buoyant section an ``EI > 0`` line type, or specify it by target submerged weight (the ``EQUIVALENT BUOYANCY`` block in :doc:`driver_format`). - * - ``is net-buoyant to within 1e-6 (neutrally buoyant ...)`` - - an ``EI = 0`` line type whose dry mass equals the displaced water mass (to a relative - 1e-6, the precision of a typed mass) has no net weight. A slack line of it is weightless - and its static shape is indeterminate (every slack shape balances). Give the line type - weight (a larger ``MassDenInAir``), or use a finite ``EI`` with a tension that holds the - line taut. + * - ``is neutrally buoyant (its dry mass equals the displaced water mass to within a + relative 1e-6)`` + - the net-buoyant rejection above (dry mass ≤ displaced mass, unchanged) of an ``EI = 0`` + line type whose dry mass lies less than a relative 1e-6 (the precision of a typed mass) + below the displaced water mass: it has no net weight, so a slack line of it is + weightless and its static shape is indeterminate (every slack shape balances). Give the + line type weight (a larger ``MassDenInAir``), or use a finite ``EI`` with a tension that + holds the line taut. * - ``the viscoelastic dynamic stiffness Ed (EA = Es|Ed) must be finite and exceed the static Es`` - ``Ed`` must be strictly greater than ``Es``; equal values make the series spring infinite. @@ -605,17 +613,22 @@ Warnings and notes that do not stop a run :ref:`openfast:SeaState grid` for sizes and memory. * - ``Note: LINE is stretched to a static strain of ... % at the fairlead`` - the fairlead tension over the EA of the End A section exceeds ``maxStrain`` (when the - OPTION is given) or 10 % (when it is not). A line far shorter than its span converges at + OPTION is given and positive) or 10 % (when it is not given or is ``0``, which disables + only the dynamic guard). Any line, ``EI = 0`` or finite-EI, is assessed on every + standalone route. A line far shorter than its span converges at such a strain without failing, because the dynamic ``maxStrain`` guard does not apply to the static solve. Check the line length against the span and the EA. Only a note: the equilibrium and the outputs are unchanged. Types with a Syrope working curve or a load-dependent stiffness are not assessed. * - ``WARNING: LINE section of type "" (... m in segment(s)) has segments of ... m, ... % of the line length`` - - a section of at most four segments whose segments are longer than 10 % of the line is too - coarse to follow the line shape there; a 100 m one-segment top section of a 520 m line shifts the fairlead tension - by tens of percent. Refine its ``NumSegs``. (A line with fewer than three segments in all - is reported whole.) + - a section whose segments are longer than 1/8 (12.5 %) of the line, i.e. coarser than a + uniform eight-segment line, is too coarse to follow the line shape there; a 100 m + one-segment top section of a 520 m line shifts the fairlead tension by tens of percent. + The rule compares the segment length with the whole line, so it does not depend on how + the line is split into sections. Refine its ``NumSegs``; a converged tension usually needs + segments well below this bound. (A line with fewer than three segments in all is reported + whole.) * - ``WARNING: line type ... sinks ... m into the seabed ...; kBot is soft for this line`` - a grounded run of this type would sink deeper than its own diameter into the penalty seabed. Raise ``kBot``; the default ``1.0e5`` embeds a heavy chain by about half its diff --git a/python/cabledyn/deck_file.py b/python/cabledyn/deck_file.py index 9c01bef0..3ff8dd6f 100644 --- a/python/cabledyn/deck_file.py +++ b/python/cabledyn/deck_file.py @@ -3606,17 +3606,20 @@ def is_body_kind(kind: str, pinned: bool) -> bool: # Native net-buoyancy gate: an EI=0 route cannot build a buoyant # (lazy-wave) arch, so a used section whose dry mass does not exceed # its displaced water mass needs a dynamic finite-EI line type. + # Within the rejection, an EI=0 type in the neutral band just below the displaced + # mass is named weightless (the native message). displaced_mass = water_density * (math.pi / 4.0) * diameter**2 - if mass <= displaced_mass * (1.0 + _NATIVE_NEUTRAL_BUOYANCY_REL_TOL) and ( + if mass <= displaced_mass and ( ei <= 0.0 or not (has_dtm or self.caller_driven or mixed_static) ): if ei <= 0.0 and mass > displaced_mass * (1.0 - _NATIVE_NEUTRAL_BUOYANCY_REL_TOL): raise DeckFormatError( - f"{self._label}: used LINE TYPE {line_type!r} is net-buoyant to within " - "1e-6 (neutrally buoyant: its dry mass equals the displaced water mass), " - "so an EI=0 line of it is weightless and slack: its static shape is " - "indeterminate (every slack shape balances). Give the line type weight " - "(a larger MassDenInAir), or a finite EI with a tension that holds it taut" + f"{self._label}: used LINE TYPE {line_type!r} is neutrally buoyant " + "(its dry mass equals the displaced water mass to within a relative " + "1e-6), so an EI=0 line of it is weightless and slack: its static " + "shape is indeterminate (every slack shape balances). Give the line " + "type weight (a larger MassDenInAir), or a finite EI with a tension that " + "holds it taut" ) raise DeckFormatError( f"{self._label}: used LINE TYPE {line_type!r} is net-buoyant (dry mass <= " diff --git a/python/tests/test_deck_file.py b/python/tests/test_deck_file.py index 708990c5..12bc59d3 100644 --- a/python/tests/test_deck_file.py +++ b/python/tests/test_deck_file.py @@ -2973,14 +2973,41 @@ def test_net_buoyant_ei0_line_type_fails_like_native(tmp_path, mass): DeckFile.read(path) -@pytest.mark.parametrize("scale", [1.0, 1.0 + 1.0e-7, 1.0 - 1.0e-7]) -def test_neutrally_buoyant_ei0_line_type_is_weightless_and_slack(tmp_path, scale): - # A mass typed to seven digits does not cancel the displaced mass exactly; the gate treats - # the 1e-6 band around it as neutral and says the slack line is indeterminate. +@pytest.mark.parametrize( + ("scale", "ei", "message"), + [ + # inside the neutral band below the displaced mass: named weightless (EI = 0 only) + (1.0 - 1.0e-7, "0.0", "neutrally buoyant .* weightless and slack"), + (1.0 - 9.0e-7, "0.0", "neutrally buoyant .* weightless and slack"), + # below the band: the net-buoyant rejection + (1.0 - 2.0e-6, "0.0", r"net-buoyant \(dry mass <="), + # above the displaced mass the gate admits the type, as it always did + (1.0 + 1.0e-7, "0.0", None), + # a dynamic finite-EI type is admitted on either side of the displaced mass + (1.0 - 1.0e-7, "1.0e4", None), + (1.0 + 1.0e-7, "1.0e4", None), + ], +) +def test_neutral_buoyancy_band_keeps_the_rejection_rule(tmp_path, scale, ei, message): + # The gate rejects mass <= displaced mass, unchanged; only the wording of an EI=0 type + # within a relative 1e-6 below the displaced mass says it is weightless. mass = 1025.0 * math.pi / 4.0 * 0.2466**2 * scale - path = _chain_variant(tmp_path, ("0.2466 373.5 ", f"0.2466 {mass:.9f} ")) - with pytest.raises(DeckFormatError, match="weightless and slack"): + replacements = [ + ( + "0.2466 373.5 1.607e9 -1.0 0.0 ", + f"0.2466 {mass:.9f} 1.607e9 -1.0 {ei} ", + ) + ] + if ei != "0.0": + replacements.append((_OPTIONS_HEADER, _OPTIONS_HEADER + "0.1 dtM\n1.0 TMax\n")) + path = _chain_variant(tmp_path, *replacements) + if message is None: + DeckFile.read(path) + return + with pytest.raises(DeckFormatError, match=message) as caught: DeckFile.read(path) + if "dry mass <=" in message: + assert "weightless" not in str(caught.value) @pytest.mark.parametrize(("weight", "buoyant"), [("100.0", False), ("-100.0", True)]) diff --git a/src/CableDyn_CosseratAssemble.f90 b/src/CableDyn_CosseratAssemble.f90 index 666cc4d0..65d9618b 100644 --- a/src/CableDyn_CosseratAssemble.f90 +++ b/src/CableDyn_CosseratAssemble.f90 @@ -95,7 +95,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force(nodes_ref, elem_conn, ea, gas, ei, REAL(wp), ALLOCATABLE :: fe(:, :), Ke(:, :, :) INTEGER, ALLOCATABLE :: elem_es(:) CHARACTER(512), ALLOCATABLE :: elem_em(:) - CHARACTER(1024) :: em + CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -112,7 +112,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force(nodes_ref, elem_conn, ea, gas, ei, fe = 0.0_wp Ke = 0.0_wp elem_es = 0 - elem_em = '' + ! elem_em(e) is written with elem_es(e) and read only where elem_es(e) /= 0: no blank fill !$OMP PARALLEL DEFAULT(NONE) & !$OMP SHARED(n_elem, elem_conn, nodes_ref, q, ea, gas, ei, gj, reduced_shear, fe, Ke, elem_es, elem_em) & !$OMP PRIVATE(e, a, b, Lam0, L0, qe, finte, Kte, es, em) @@ -271,7 +271,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force_Banded_Free_Workspace(nodes_ref, e LOGICAL :: apply_chain INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), Kte(12, 12), finte(12) - CHARACTER(1024) :: em + CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -315,7 +315,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force_Banded_Free_Workspace(nodes_ref, e work%fe(:, 1:n_elem) = 0.0_wp work%Ke(:, :, 1:n_elem) = 0.0_wp work%elem_es(1:n_elem) = 0 - work%elem_em(1:n_elem) = '' + ! elem_em(e) is written with elem_es(e) and read only where elem_es(e) /= 0: no blank fill !$OMP PARALLEL DEFAULT(NONE) & !$OMP SHARED(n_elem, elem_conn, nodes_ref, q, ea, gas, ei, gj, reduced_shear, work) & !$OMP PRIVATE(e, a, b, Lam0, L0, qe, finte, Kte, es, em) @@ -415,7 +415,7 @@ SUBROUTINE CD_Assemble_Cosserat_Internal_Force_Workspace(nodes_ref, elem_conn, e INTEGER :: n_nodes, n_elem, e, a, b, ndof, gmap(12), i, es INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), finte(12) - CHARACTER(1024) :: em + CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) CD_COSASM_N_FORCE = CD_COSASM_N_FORCE + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -431,7 +431,7 @@ SUBROUTINE CD_Assemble_Cosserat_Internal_Force_Workspace(nodes_ref, elem_conn, e IF (ErrStat /= 0) RETURN work%fe(:, 1:n_elem) = 0.0_wp work%elem_es(1:n_elem) = 0 - work%elem_em(1:n_elem) = '' + ! elem_em(e) is written with elem_es(e) and read only where elem_es(e) /= 0: no blank fill !$OMP PARALLEL DEFAULT(NONE) & !$OMP SHARED(n_elem, elem_conn, nodes_ref, q, ea, gas, ei, gj, reduced_shear, work) & !$OMP PRIVATE(e, a, b, Lam0, L0, qe, finte, es, em) diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index 7cf11493..c5648bbf 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -163,15 +163,17 @@ MODULE CableDyn_DeckDriver INTEGER, PARAMETER :: INSTALLED_SEQUENCE_COARSE_FLOOR = 24 ! Deepest mesh hierarchy CD_HermiteCable_Sequence_* accepts (levels including the user mesh). INTEGER, PARAMETER :: SEQUENCE_MAX_LEVELS = 20 - ! A line type whose dry mass is within this relative band of the displaced water mass is - ! neutrally buoyant: its net weight is zero to within the precision of a typed mass - ! (a mass written to seven digits against a diameter does not cancel exactly). + ! Relative band within which a net weight counts as zero (neutrally buoyant) to the precision + ! of a typed mass (a mass written to seven digits against a diameter does not cancel exactly). + ! It only selects the wording of a diagnosis -- an EI=0 line type rejected as net-buoyant + ! whose mass lies within it below the displaced water mass, a finite-EI line whose every + ! element weighs within it of nothing -- and changes no acceptance rule. REAL(wp), PARAMETER :: NEUTRAL_BUOYANCY_REL_TOL = 1.0e-6_wp - ! A section of at most COARSE_SECTION_MAX_SEGS segments, each longer than COARSE_SECTION_FRACTION of its - ! line, is warned about as too coarse (warn_coarse_sections). A static strain above - ! STATIC_STRAIN_NOTE_DEFAULT is noted (static_strain_note) when OPTION maxStrain is not given. - REAL(wp), PARAMETER :: COARSE_SECTION_FRACTION = 0.1_wp - INTEGER, PARAMETER :: COARSE_SECTION_MAX_SEGS = 4 + ! A section whose segments are longer than COARSE_SECTION_FRACTION of its line (coarser than a + ! uniform eight-segment line) is warned about as too coarse (warn_coarse_sections). A static + ! strain above STATIC_STRAIN_NOTE_DEFAULT is noted (static_strain_note) when OPTION maxStrain + ! is not positive. + REAL(wp), PARAMETER :: COARSE_SECTION_FRACTION = 0.125_wp REAL(wp), PARAMETER :: STATIC_STRAIN_NOTE_DEFAULT = 0.1_wp PUBLIC :: CD_Run_Deck_Driver @@ -973,9 +975,10 @@ MODULE CableDyn_DeckDriver REAL(wp) :: fair_declination = CD_ZERO REAL(wp) :: fair_azimuth = CD_ZERO LOGICAL :: force_is_total = .TRUE. - ! Static-initialisation notes of a finite-EI line (compression, mesh refinement, - ! accepted residual floor), one per text line; empty when there is nothing to report. - CHARACTER(1024) :: note = '' + ! Static-initialisation notes of the line (finite-EI compression, mesh refinement, accepted + ! residual floor; the static strain note of any line), one per text line (append_note_line); + ! empty when there is nothing to report. It holds a whole cable note (1024) and a strain note. + CHARACTER(2048) :: note = '' END TYPE CD_LineInitSummary TYPE :: CD_DeckAggregateType @@ -4045,7 +4048,7 @@ LOGICAL FUNCTION as_laid_cross_slope() RESULT(cross) REAL(wp) :: az, laid_t, o_xy(2), dir(2), e_cross(2), span, ds, zf, gx, gy INTEGER :: k, n_s, es_c LOGICAL :: from_top - CHARACTER(200) :: em_c + CHARACTER(1024) :: em_c cross = .FALSE. IF (.NOT. (contact_enabled .AND. opts%has_friction .AND. & opts%static_friction == CD_STATIC_FRICTION_AS_LAID)) RETURN @@ -4221,13 +4224,7 @@ SUBROUTINE report_note(text) !! One initialisation note: printed on a standalone run, appended to init_note. CHARACTER(*), INTENT(IN) :: text IF (standalone_mode) WRITE (error_unit, '(A)') ' Note: '//TRIM(text)//'.' - IF (PRESENT(init_note)) THEN - IF (LEN_TRIM(init_note) > 0) THEN - init_note = TRIM(init_note)//NEW_LINE('a')//TRIM(text) - ELSE - init_note = TRIM(text) - END IF - END IF + IF (PRESENT(init_note)) CALL append_note_line(init_note, text) END SUBROUTINE report_note END SUBROUTINE build_one_hermite_cable @@ -4979,7 +4976,7 @@ SUBROUTINE laid_seed_positions(ok) REAL(wp) :: c, s, a_g(3), f_g(3), xl_, yl_ INTEGER :: e_, k_, es_ld LOGICAL :: conv_ld - CHARACTER(512) :: em_ld + CHARACTER(1024) :: em_ld ok = .FALSE. c = frame_cs(1) s = frame_cs(2) @@ -6723,11 +6720,7 @@ SUBROUTINE CD_Init_Deck_Aggregate(deck_path, dt, agg, ErrStat, ErrMsg, env_gravi CALL static_strain_note(agg%init_lines(il)%line_id, agg%init_lines(il)%fair_tension, sections, types, opts, & strain_note) IF (LEN_TRIM(strain_note) == 0) CYCLE - IF (LEN_TRIM(agg%init_lines(il)%note) > 0) THEN - agg%init_lines(il)%note = TRIM(agg%init_lines(il)%note)//NEW_LINE('a')//TRIM(strain_note) - ELSE - agg%init_lines(il)%note = strain_note - END IF + CALL append_note_line(agg%init_lines(il)%note, strain_note) END DO IF (PRESENT(range_files)) THEN IF (range_files) CALL warn_coarse_sections(lines, sections) @@ -9597,12 +9590,14 @@ SUBROUTINE print_static_input_warnings(types, points, lines, sections, opts) END SUBROUTINE print_static_input_warnings SUBROUTINE warn_coarse_sections(lines, sections) - !! Standard-output WARNINGS for a section too coarse for the line it belongs to: a section of at - !! most COARSE_SECTION_MAX_SEGS segments whose segments (section length / NumSegs) are longer - !! than COARSE_SECTION_FRACTION of the line's total length (a short line of eight segments is - !! a deliberate coarse model and is not reported). Each segment of an EI=0 line is - !! a straight chord and each element of a finite-EI line a cubic-Hermite span, so a one-element - !! 100 m top section on a 520 m line cannot follow the line shape there and shifts the fairlead tension by tens of percent. The + !! Standard-output WARNINGS for a section too coarse for the line it belongs to: a section whose + !! segments (section length / NumSegs) are longer than COARSE_SECTION_FRACTION (1/8) of the + !! line's total length, i.e. coarser than a uniform eight-segment line. The rule looks only at + !! the segment length relative to the whole line, so it does not depend on how the line is + !! split into sections (an eight-segment uniform line written as two four-segment sections is + !! not reported). Each segment of an EI=0 line is a straight chord and each element of a + !! finite-EI line a cubic-Hermite span, so a one-element 100 m top section on a 520 m line + !! cannot follow the line shape there and shifts the fairlead tension by tens of percent. The !! whole-line check of print_static_input_warnings (fewer than three segments) does not see a !! coarse section inside a finely meshed line, and a line with fewer than three segments is !! reported whole by that check, not here. @@ -9624,7 +9619,8 @@ SUBROUTINE warn_coarse_sections(lines, sections) DO j = 1, SIZE(sections) IF (sections(j)%line_id /= lines(i)%id .OR. sections(j)%nsegs < 1) CYCLE seg_len = sections(j)%length/REAL(sections(j)%nsegs, wp) - IF (seg_len <= COARSE_SECTION_FRACTION*total .OR. sections(j)%nsegs > COARSE_SECTION_MAX_SEGS) CYCLE + ! (the relative 1e-9 keeps a uniform eight-segment line, split in any way, below the bound) + IF (seg_len <= COARSE_SECTION_FRACTION*total*(CD_ONE + 1.0e-9_wp)) CYCLE WRITE (b1, '(F12.2)') sections(j)%length WRITE (b2, '(F12.2)') seg_len WRITE (b3, '(F6.1)') 100.0_wp*seg_len/total @@ -9632,14 +9628,42 @@ SUBROUTINE warn_coarse_sections(lines, sections) TRIM(sections(j)%ltype_name)//'" ('//TRIM(ADJUSTL(b1))//' m in '//TRIM(int_to_str(sections(j)%nsegs))// & ' segment(s)) has segments of '//TRIM(ADJUSTL(b2))//' m, '//TRIM(ADJUSTL(b3))// & ' % of the line length: too coarse to follow the line shape there, which can shift the tensions '// & - 'by tens of percent; refine its NumSegs (aim for segments under 10 % of the line length)' + 'by tens of percent; refine its NumSegs (this warning applies above 1/8 = 12.5 % of the line length, '// & + 'and a converged tension usually needs finer segments)' END DO END DO END SUBROUTINE warn_coarse_sections + SUBROUTINE append_note_line(buffer, text) + !! Append one initialisation note as a new text line of buffer. A note that does not fit + !! with room left for the omission marker is replaced by the marker, which ends the buffer, + !! so no note is ever cut short. + CHARACTER(*), INTENT(INOUT) :: buffer + CHARACTER(*), INTENT(IN) :: text + CHARACTER(*), PARAMETER :: OMITTED = 'further initialisation notes omitted' + INTEGER :: n + IF (LEN_TRIM(text) == 0) RETURN + n = LEN_TRIM(buffer) + IF (n > 0) THEN + IF (n >= LEN(OMITTED)) THEN + IF (buffer(n - LEN(OMITTED) + 1:n) == OMITTED) RETURN + END IF + IF (n + 1 + LEN_TRIM(text) + 1 + LEN(OMITTED) <= LEN(buffer)) THEN + buffer = buffer(1:n)//NEW_LINE('a')//TRIM(text) + ELSE IF (n + 1 + LEN(OMITTED) <= LEN(buffer)) THEN + buffer = buffer(1:n)//NEW_LINE('a')//OMITTED + END IF + ELSE IF (LEN_TRIM(text) + 1 + LEN(OMITTED) <= LEN(buffer)) THEN + buffer = TRIM(text) + ELSE IF (LEN(OMITTED) <= LEN(buffer)) THEN + buffer = OMITTED + END IF + END SUBROUTINE append_note_line + SUBROUTINE static_strain_note(line_id, tension, sections, types, opts, note) - !! The static initial state of a line stretched beyond STATIC_STRAIN_NOTE_DEFAULT (or OPTION - !! maxStrain when it is given): the fairlead tension over the EA of the section at End A. A + !! The static initial state of a line stretched beyond OPTION maxStrain when it is given and + !! positive, or else STATIC_STRAIN_NOTE_DEFAULT (10 %; maxStrain 0 disables the dynamic guard, + !! not this note): the fairlead tension over the EA of the section at End A. A !! line far shorter than its span converges at such a strain without any message, because !! the dynamic strain guard (maxStrain) does not apply to the static solve. Only a note -- !! the equilibrium and every output are unchanged. Types whose tension is not EA times @@ -9653,7 +9677,7 @@ SUBROUTINE static_strain_note(line_id, tension, sections, types, opts, note) INTEGER :: j, k REAL(wp) :: strain, limit CHARACTER(32) :: b1, b2, b3 - CHARACTER(40) :: source + CHARACTER(64) :: source note = '' IF (.NOT. (tension > CD_ZERO .AND. tension < HUGE(CD_ONE))) RETURN @@ -9664,14 +9688,17 @@ SUBROUTINE static_strain_note(line_id, tension, sections, types, opts, note) IF (types(k)%is_syrope .OR. types(k)%elastic_mod == 3 .OR. .NOT. (types(k)%ea > CD_ZERO)) RETURN strain = tension/types(k)%ea limit = STATIC_STRAIN_NOTE_DEFAULT - source = 'the static default' IF (opts%has_max_strain .AND. opts%max_strain > CD_ZERO) THEN limit = opts%max_strain source = 'OPTION maxStrain' + ELSE IF (opts%has_max_strain) THEN + source = 'the note level used when maxStrain is 0' + ELSE + source = 'the note level used without maxStrain' END IF IF (.NOT. (strain > limit)) RETURN - WRITE (b1, '(F10.1)') 100.0_wp*strain - WRITE (b2, '(F10.1)') 100.0_wp*limit + CALL percent_text(100.0_wp*strain, b1) + CALL percent_text(100.0_wp*limit, b2) WRITE (b3, '(ES10.3)') tension note = 'LINE '//TRIM(int_to_str(line_id))//' is stretched to a static strain of '//TRIM(ADJUSTL(b1))// & ' % at the fairlead (tension '//TRIM(ADJUSTL(b3))//' N over the EA of section type '// & @@ -9680,6 +9707,19 @@ SUBROUTINE static_strain_note(line_id, tension, sections, types, opts, note) 'not apply to the static solve' RETURN END DO + + CONTAINS + + SUBROUTINE percent_text(percent, text) + !! One decimal from 0.1 % up; a smaller value (a small maxStrain) keeps its leading digits. + REAL(wp), INTENT(IN) :: percent + CHARACTER(*), INTENT(OUT) :: text + IF (percent >= 0.1_wp) THEN + WRITE (text, '(F10.1)') percent + ELSE + WRITE (text, '(ES9.2)') percent + END IF + END SUBROUTINE percent_text END SUBROUTINE static_strain_note SUBROUTINE warn_line_below_anchor(lines, points, sections, q_all, q_off) @@ -14926,12 +14966,34 @@ SUBROUTINE finalize_checks(types, bodies, rod_types, rods, points, lines, sectio IF (.NOT. ((tb == 'coupled' .OR. tb == 'vessel') .AND. & points(find_point(points, lines(i)%nodeA))%turbine_id > 0 .AND. & points(find_point(points, lines(i)%nodeB))%turbine_id > 0)) THEN + ! The Connect-point split is a workaround only for an EI=0 line: in a deck with + ! Connect points a finite-EI cable needs a Fixed End B and cannot end on a Connect point. + BLOCK + INTEGER :: js, ks + LOGICAL :: shared_finite + shared_finite = .FALSE. + DO js = 1, SIZE(sections) + IF (sections(js)%line_id /= lines(i)%id) CYCLE + ks = find_type(types, sections(js)%ltype_name) + IF (ks < 1) CYCLE + IF (types(ks)%ei > CD_ZERO) shared_finite = .TRUE. + END DO + IF (shared_finite) THEN + CALL fail(ErrStat, ErrMsg, 'finite-EI LINE '//TRIM(int_to_str(lines(i)%id))//' End B (NodeB, '// & + 'POINT '//TRIM(int_to_str(lines(i)%nodeB))//', '//TRIM(tb)//') must be a Fixed '// & + '(anchor) point: a line between two moving points (a shared line) is not supported, '// & + 'except a FAST.Farm shared line between two Turbine fairleads. A finite-EI line '// & + 'cannot be split at a Connect point either (beside Connect points a finite-EI cable '// & + 'needs a Fixed End B and cannot end on a Connect point): anchor it on a Fixed point, '// & + 'or model the shared span with EI=0 line types split at a Connect point'); RETURN + END IF + END BLOCK CALL fail(ErrStat, ErrMsg, 'LINE '//TRIM(int_to_str(lines(i)%id))//' End B (NodeB, POINT '// & TRIM(int_to_str(lines(i)%nodeB))//', '//TRIM(tb)//') must be a Fixed (anchor) point: a line '// & 'between two moving points (a shared line) is not supported, except a FAST.Farm shared line '// & - 'between two Turbine fairleads. Workaround: split it into two lines that meet at a '// & - 'Connect point in the middle (each line then ends on one Coupled point; the deck becomes '// & - 'dynamic and needs dtM and TMax)'); RETURN + 'between two Turbine fairleads. Workaround for this EI=0 line: split it into two lines '// & + 'that meet at a Connect point in the middle (each line then ends on one Coupled point; the '// & + 'deck becomes dynamic and needs dtM and TMax)'); RETURN END IF ELSE IF (points(find_point(points, lines(i)%nodeA))%pos(3) < & @@ -15013,15 +15075,16 @@ SUBROUTINE finalize_checks(types, bodies, rod_types, rods, points, lines, sectio ! route has the cubic-Hermite arch seed and may proceed. A dynamic standalone ! run gets its clock from dtM; the executable's metadata scan also admits a ! clock-free static aggregate solve. Unsupported endpoint coupling is rejected - ! before initialization. + ! before initialization. The rejection condition is mass <= displaced mass; within it, an + ! EI=0 type whose mass lies in the neutral band just below the displaced mass is named weightless. displaced_mass = opts%rhoW*QUARTER_PI*types(idx)%diam**2 - IF (types(idx)%mass <= displaced_mass*(CD_ONE + NEUTRAL_BUOYANCY_REL_TOL)) THEN + IF (types(idx)%mass <= displaced_mass) THEN IF (types(idx)%ei <= CD_ZERO .OR. & (.NOT. opts%has_dtm .AND. .NOT. caller_driven .AND. & .NOT. (allow_static_finite_ei .AND. .NOT. opts%has_tmax))) THEN IF (types(idx)%ei <= CD_ZERO .AND. types(idx)%mass > displaced_mass*(CD_ONE - NEUTRAL_BUOYANCY_REL_TOL)) THEN - CALL fail(ErrStat, ErrMsg, 'LINE TYPE "'//TRIM(types(idx)%name)//'" is net-buoyant to within 1e-6 '// & - '(neutrally buoyant: its dry mass equals the displaced water mass), so an EI=0 line of it is '// & + CALL fail(ErrStat, ErrMsg, 'LINE TYPE "'//TRIM(types(idx)%name)//'" is neutrally buoyant (its dry '// & + 'mass equals the displaced water mass to within a relative 1e-6), so an EI=0 line of it is '// & 'weightless and slack: its static shape is indeterminate (every slack shape balances). '// & 'Give the line type weight (a larger MassDenInAir), or a finite EI with a tension that '// & 'holds it taut'); RETURN @@ -18148,11 +18211,13 @@ SUBROUTINE write_multibody_dynamic_out(deck_path, out_root, channels, types, bod END IF IF (TRIM(points(pa)%ptype) == 'coupled' .OR. TRIM(points(pa)%ptype) == 'vessel') THEN CALL fail(ErrStat, ErrMsg, 'finite-EI LINE '//TRIM(int_to_str(lines(i)%id))//': a Coupled/Vessel End A '// & - '(POINT '//TRIM(int_to_str(points(pa)%id))//') is driven by a motionFile, which a '// & - 'mixed-topology deck with Connect/Free points or bodies (marched as one multibody system) '// & - 'does not support. '// & - 'Remove the Connect/Free points so the deck runs as a coupled mixed deck (EI=0 lines on the '// & - 'Coupled point directly), or attach the cable to a Rigid6 body, a rod end or a Fixed point'); RETURN + '(POINT '//TRIM(int_to_str(points(pa)%id))//') would need motionFile coupling to drive it, '// & + 'which a mixed-topology deck with Connect/Free points or bodies (marched as one multibody '// & + 'system) does not support. Attach the cable to a Rigid6 body, a rod end or a Fixed point; or '// & + 'remove the Connect/Free points so the deck becomes a coupled mixed deck (EI=0 lines on the '// & + 'Coupled point directly), which a host (OpenFAST CompMooring=5 or the C API) drives and the '// & + 'standalone driver runs with its Coupled points held still (that route takes no motionFile '// & + 'either)'); RETURN END IF IF (lines(i)%endconn_mode(1) /= CD_ENDCONN_PINNED .AND. TRIM(points(pa)%ptype) /= 'fixed') THEN ! a clamped or elastic End A on a body or rod: implicit (monolithic step) only diff --git a/src/CableDyn_HermiteCableDynamic.f90 b/src/CableDyn_HermiteCableDynamic.f90 index 28d446fc..5cb2594a 100644 --- a/src/CableDyn_HermiteCableDynamic.f90 +++ b/src/CableDyn_HermiteCableDynamic.f90 @@ -6419,6 +6419,10 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta REAL(wp) :: endconn_d0_eval(3, 2), support(3), dsupport(3), nin(3), mend INTEGER :: inode, jr, jc CHARACTER(1024) :: em2 + ! The per-element kernels (element, axial damping, drag, wave load) report fixed messages of + ! under 200 characters, nested ones included; em_e takes them. Each kernel resets its message + ! buffer at every call, so this one is kept small (a 1024-character one costs 2-3 % of a step). + CHARACTER(256) :: em_e ErrStat = CD_HCDYN_OK; ErrMsg = '' ne = model%ne @@ -6465,17 +6469,17 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta qe(7:9) = q_cfg(6*e + 1:6*e + 3) qe(10:12) = q_cfg(6*e + 4:6*e + 6) IF (want_tangent) THEN - CALL CD_HermiteCable_Element(qe, model%l0(e), model%EA(e), model%EI(e), Ee, fe, Ke, es, em2, & + CALL CD_HermiteCable_Element(qe, model%l0(e), model%EA(e), model%EI(e), Ee, fe, Ke, es, em_e, & symmetric_half=.TRUE., & axial_quadrature_order=model%axial_quadrature_order, & bending_quadrature_order=model%bending_quadrature_order) ELSE - CALL CD_HermiteCable_Element(qe, model%l0(e), model%EA(e), model%EI(e), Ee, fe, ErrStat=es, ErrMsg=em2, & + CALL CD_HermiteCable_Element(qe, model%l0(e), model%EA(e), model%EI(e), Ee, fe, ErrStat=es, ErrMsg=em_e, & axial_quadrature_order=model%axial_quadrature_order, & bending_quadrature_order=model%bending_quadrature_order) END IF IF (es /= CD_HCABLE_OK) THEN - ErrStat = CD_HCDYN_NOCONVERGE; ErrMsg = 'element: '//TRIM(em2); RETURN + ErrStat = CD_HCDYN_NOCONVERGE; ErrMsg = 'element: '//TRIM(em_e); RETURN END IF IF (want_residual) THEN DO a = 1, 12 @@ -6618,7 +6622,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%axial_quadrature_order, model%l0_dot(e)) ELSE IF (want_tangent) THEN CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & - fdamp, kdq, kdv, es, em2, & + fdamp, kdq, kdv, es, em_e, & model%axial_quadrature_order) ELSE IF (model%has_ctrl) THEN CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & @@ -6627,11 +6631,11 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta l0_dot=model%l0_dot(e)) ELSE CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & - fdamp, ErrStat=es, ErrMsg=em2, & + fdamp, ErrStat=es, ErrMsg=em_e, & quadrature_order=model%axial_quadrature_order) END IF IF (es /= CD_HCDYN_OK) THEN - ErrStat = CD_HCDYN_NOCONVERGE; ErrMsg = TRIM(em2); RETURN + ErrStat = CD_HCDYN_NOCONVERGE; ErrMsg = TRIM(em_e); RETURN END IF IF (want_residual) THEN DO a = 1, 12 @@ -6661,7 +6665,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta IF (model%has_wave .AND. model%wv_ncomp > 0) THEN CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, djq, djv, es, em2, & + fdrag, djq, djv, es, em_e, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & wvc_amp=model%wv_ampc, wvc_om=model%wv_omc, & wvc_k=model%wv_kc, wvc_ph=model%wv_phc, & @@ -6669,7 +6673,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta ELSE IF (model%has_wave) THEN CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, djq, djv, es, em2, & + fdrag, djq, djv, es, em_e, & wv_h=model%wv_h, wv_om=model%wv_om, wv_k=model%wv_k, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval) ELSE IF (model%has_held_field) THEN @@ -6680,17 +6684,17 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%current + 0.5_wp*(model%hf_u(:, e) + model%hf_u(:, e + 1)), & 0.5_wp*(model%hf_wl(e) + model%hf_wl(e + 1)), & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, djq, djv, es, em2) + fdrag, djq, djv, es, em_e) ELSE CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, djq, djv, es, em2) + fdrag, djq, djv, es, em_e) END IF ELSE IF (model%has_wave .AND. model%wv_ncomp > 0) THEN CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, ErrStat=es, ErrMsg=em2, & + fdrag, ErrStat=es, ErrMsg=em_e, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & wvc_amp=model%wv_ampc, wvc_om=model%wv_omc, & wvc_k=model%wv_kc, wvc_ph=model%wv_phc, & @@ -6698,7 +6702,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta ELSE IF (model%has_wave) THEN CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, ErrStat=es, ErrMsg=em2, & + fdrag, ErrStat=es, ErrMsg=em_e, & wv_h=model%wv_h, wv_om=model%wv_om, wv_k=model%wv_k, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval) ELSE IF (model%has_held_field) THEN @@ -6706,15 +6710,15 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%current + 0.5_wp*(model%hf_u(:, e) + model%hf_u(:, e + 1)), & 0.5_wp*(model%hf_wl(e) + model%hf_wl(e + 1)), & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, ErrStat=es, ErrMsg=em2) + fdrag, ErrStat=es, ErrMsg=em_e) ELSE CALL CD_HermiteCable_Drag_Element(qe, ve, model%l0(e), model%current, model%waterline_z, & model%rho_w, model%diam(e), model%cdn(e), model%cdt(e), & - fdrag, ErrStat=es, ErrMsg=em2) + fdrag, ErrStat=es, ErrMsg=em_e) END IF END IF IF (es /= CD_HCDYN_OK) THEN - ErrStat = es; ErrMsg = TRIM(em2); RETURN + ErrStat = es; ErrMsg = TRIM(em_e); RETURN END IF IF (want_residual) THEN DO a = 1, 12 @@ -6763,7 +6767,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta CALL CD_HermiteCable_FK_Element(qe, model%l0(e), model%am_wl, model%am_rho, model%am_diam(e), & model%am_can(e), model%am_cat(e), & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & - ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em2, & + ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em_e, & wvc_amp=model%wv_ampc, wvc_om=model%wv_omc, & wvc_k=model%wv_kc, wvc_ph=model%wv_phc, & wvc_e2kd=model%wv_e2kd) @@ -6771,7 +6775,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta CALL CD_HermiteCable_FK_Element(qe, model%l0(e), model%am_wl, model%am_rho, model%am_diam(e), & model%am_can(e), model%am_cat(e), & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & - ffk=ffk, ErrStat=es, ErrMsg=em2, & + ffk=ffk, ErrStat=es, ErrMsg=em_e, & wvc_amp=model%wv_ampc, wvc_om=model%wv_omc, & wvc_k=model%wv_kc, wvc_ph=model%wv_phc, & wvc_e2kd=model%wv_e2kd) @@ -6782,17 +6786,17 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%am_can(e), model%am_cat(e), & wv_h=model%wv_h, wv_om=model%wv_om, wv_k=model%wv_k, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & - ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em2) + ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em_e) ELSE CALL CD_HermiteCable_FK_Element(qe, model%l0(e), model%am_wl, model%am_rho, model%am_diam(e), & model%am_can(e), model%am_cat(e), & wv_h=model%wv_h, wv_om=model%wv_om, wv_k=model%wv_k, & wv_depth=model%wv_depth, wv_dir=model%wv_dir, wv_t=t_eval, & - ffk=ffk, ErrStat=es, ErrMsg=em2) + ffk=ffk, ErrStat=es, ErrMsg=em_e) END IF END IF IF (es /= CD_HCDYN_OK) THEN - ErrStat = es; ErrMsg = TRIM(em2); RETURN + ErrStat = es; ErrMsg = TRIM(em_e); RETURN END IF IF (want_residual) THEN DO a = 1, 12 @@ -6820,7 +6824,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%am_rho, model%am_diam(e), & model%am_can(e), model%am_cat(e), & wv_depth=CD_ZERO, wv_dir=CD_ZERO, wv_t=CD_ZERO, & - ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em2, & + ffk=ffk, fjq=fjq, ErrStat=es, ErrMsg=em_e, & hf_a=hf_mid) ELSE hf_mid(1) = 0.5_wp*(model%hf_ud(1, e) + model%hf_ud(1, e + 1)) @@ -6831,11 +6835,11 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%am_rho, model%am_diam(e), & model%am_can(e), model%am_cat(e), & wv_depth=CD_ZERO, wv_dir=CD_ZERO, wv_t=CD_ZERO, & - ffk=ffk, ErrStat=es, ErrMsg=em2, & + ffk=ffk, ErrStat=es, ErrMsg=em_e, & hf_a=hf_mid) END IF IF (es /= CD_HCDYN_OK) THEN - ErrStat = es; ErrMsg = TRIM(em2); RETURN + ErrStat = es; ErrMsg = TRIM(em_e); RETURN END IF IF (want_residual) THEN DO a = 1, 12 @@ -7246,9 +7250,13 @@ SUBROUTINE evaluate_tangent_element(model, e, q_cfg, v_cfg, t_eval, Kstruct, Kdr REAL(wp) :: djq(12, 12), djv(12, 12), fjq(12, 12) REAL(wp) :: hf_mid(3) INTEGER :: es - CHARACTER(1024) :: em + ! The element kernels report fixed messages of under 200 characters (nested ones included), + ! which fit em and the 512-character per-element buffer (ws_elem_em) this fills. Each kernel + ! resets em at every call, so em is kept small; ErrMsg is written only on a failure (the + ! caller reads it only when ErrStat says so). + CHARACTER(256) :: em - ErrStat = CD_HCDYN_OK; ErrMsg = '' + ErrStat = CD_HCDYN_OK qe(1:6) = q_cfg(6*(e - 1) + 1:6*e) qe(7:12) = q_cfg(6*e + 1:6*(e + 1)) ve(1:6) = v_cfg(6*(e - 1) + 1:6*e) @@ -7591,7 +7599,9 @@ SUBROUTINE CD_HermiteCable_Drag_Element(qe, ve, l0, fluid, waterline_z, rho, dia REAL(wp) :: scale, eta_w, uw(3), aw(3) LOGICAL :: has_wv, has_shared, has_trio, has_cmp, any_wv_arg, want_jac INTEGER :: g, s, c, sp, cp, a, b, es - CHARACTER(1024) :: em2 + ! the message of a per-Gauss-point CableDyn_Hydro kinematics or Morison call (each is under 200 + ! characters): a small buffer, as these calls reset it at every Gauss point + CHARACTER(256) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(djq) @@ -7864,7 +7874,9 @@ SUBROUTINE CD_HermiteCable_FK_Element(qe, l0, waterline_z, rho, diam, can, cat, REAL(wp) :: fpl(3), Jtan(3, 3), proj(3, 3), projk(3), dalpha LOGICAL :: has_trio, has_cmp, has_held, want_jac INTEGER :: g, s, c, sp, cp, a, b, k, es - CHARACTER(1024) :: em2 + ! the message of a per-Gauss-point CableDyn_Hydro kinematics call (each is under 200 characters): + ! a small buffer, as these calls reset it at every Gauss point + CHARACTER(256) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(fjq) diff --git a/src/CableDyn_HermiteCableStatic.f90 b/src/CableDyn_HermiteCableStatic.f90 index d8df857a..cb42814e 100644 --- a/src/CableDyn_HermiteCableStatic.f90 +++ b/src/CableDyn_HermiteCableStatic.f90 @@ -515,7 +515,7 @@ SUBROUTINE CD_HermiteCable_Static_Solve(l0, EA, EI, w, seed, fixed_dofs, seabed_ REAL(wp) :: end_share_last(2), end_share_pi(2) LOGICAL :: end_share_held, end_share_caller INTEGER :: end_es - CHARACTER(200) :: end_em + CHARACTER(1024) :: end_em ErrStat = CD_HCSTAT_OK ErrMsg = '' @@ -1714,7 +1714,7 @@ SUBROUTINE add_torsion(ecs, ecm) CHARACTER(*), INTENT(OUT) :: ecm REAL(wp) :: raw, th, e_t INTEGER :: ks - CHARACTER(200) :: km + CHARACTER(1024) :: km ecs = CD_HCSTAT_OK ecm = '' IF (skip_tangent) THEN @@ -1781,7 +1781,7 @@ SUBROUTINE torsion_take_step(scale, ecs, ecm) CHARACTER(*), INTENT(OUT) :: ecm REAL(wp) :: sfac, raw, th INTEGER :: k, ks - CHARACTER(200) :: km + CHARACTER(1024) :: km tors_q = q sfac = scale km = '' @@ -1819,7 +1819,7 @@ SUBROUTINE torsion_continuation(ecs, ecm) REAL(wp) :: raw, phi0, total, lam, lam_try, dlam, dlam_max, th_keep, res_untwisted INTEGER :: ks, cuts, wios LOGICAL :: ok - CHARACTER(200) :: km + CHARACTER(1024) :: km CHARACTER(1024) :: why CHARACTER(1024) :: wbuf ecs = CD_HCSTAT_OK @@ -1913,7 +1913,7 @@ SUBROUTINE torsion_stage(ok, why) INTEGER :: it2, ks, wios REAL(wp) :: rn LOGICAL :: st - CHARACTER(512) :: km + CHARACTER(1024) :: km CHARACTER(1024) :: wbuf ok = .FALSE. why = '' @@ -1970,7 +1970,7 @@ SUBROUTINE torsion_stability(st, ecs, ecm) CHARACTER(*), INTENT(OUT) :: ecm REAL(wp) :: rn, ztol INTEGER :: ks, kin, nb, nk - CHARACTER(512) :: km + CHARACTER(1024) :: km st = .FALSE. ecs = CD_HCSTAT_OK ecm = '' @@ -2039,7 +2039,7 @@ SUBROUTINE torsion_descent(ok, why) REAL(wp) :: e0, amp, a, rn, vscale, th0 INTEGER :: attempt, k, j, ks, it2 LOGICAL :: saved_energy, st, moved - CHARACTER(512) :: km + CHARACTER(1024) :: km ok = .FALSE. why = '' km = '' @@ -2642,7 +2642,7 @@ SUBROUTINE CD_HermiteCable_As_Laid_Offsets(fr, l0, EA, node_load, node_kn, offse REAL(wp), ALLOCATABLE :: ref_g(:, :), ref_0(:, :), wn(:), sn(:), kn_o(:), l0_r(:), ea_r(:) REAL(wp) :: dg(2), dg0(2), cs(2) INTEGER :: k, ne, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' ne = SIZE(l0) @@ -3171,12 +3171,12 @@ SUBROUTINE CD_HermiteCable_Static_Solve_Continuation(l0, EA, EI, w, seed, fixed_ REAL(wp) :: cur_frac LOGICAL :: picard_ok, drag_homotopy, planar_run_limit INTEGER :: iters_first - CHARACTER(512) :: arc_msg + CHARACTER(1024) :: arc_msg ! Arclength workspace: residual, banded tangent (and a copy to factor), drag load, free DOFs. REAL(wp), ALLOCATABLE :: fres(:), kband(:, :), kwork(:, :), dvec(:) LOGICAL, ALLOCATABLE :: free(:) REAL(wp) :: wq - CHARACTER(512) :: first_msg + CHARACTER(1024) :: first_msg CHARACTER(16) :: frac_txt ! Seabed friction of the current (active in every stage after the still-water one). LOGICAL :: use_fric @@ -4517,7 +4517,7 @@ SUBROUTINE solve_seq_try(l0, EA, EI, w, seed, fixed_dofs, seabed_z, kn, & CHARACTER(1024) :: em_l ! The level solve failed only on its final residual (a finite best iterate to continue from). LOGICAL :: unmet_l - CHARACTER(200) :: diagnostic_msg + CHARACTER(1024) :: diagnostic_msg CHARACTER(240) :: level_context LOGICAL :: contact_active, use_level_nodal_contact, rebuild_coarse_tangents, coarse_seed_ready LOGICAL :: use_gentle_hierarchy, use_fine_hierarchy @@ -4970,7 +4970,7 @@ SUBROUTINE project_contact(q_seed, old_nodes, new_nodes, stat, msg) CHARACTER(*), INTENT(OUT) :: msg INTEGER :: node, gi, bathy_stat REAL(wp) :: z_floor, xg, yg - CHARACTER(200) :: bathy_msg + CHARACTER(1024) :: bathy_msg stat = CD_HCSTAT_OK msg = '' @@ -6614,7 +6614,7 @@ SUBROUTINE floor_at(xy, z_floor, esx, emx) CHARACTER(*), INTENT(OUT) :: emx INTEGER :: bstat REAL(wp) :: xg, yg - CHARACTER(200) :: bmsg + CHARACTER(1024) :: bmsg esx = CD_HCSTAT_OK emx = '' z_floor = seabed_z diff --git a/src/CableDyn_OpenFAST_Aggregate.f90 b/src/CableDyn_OpenFAST_Aggregate.f90 index 5db07dd6..eb668d28 100644 --- a/src/CableDyn_OpenFAST_Aggregate.f90 +++ b/src/CableDyn_OpenFAST_Aggregate.f90 @@ -155,7 +155,7 @@ MODULE CableDyn_OpenFAST_Aggregate ! Per-cable status staging lets independent finite-EI cables advance concurrently while ! preserving deterministic, cable-order error reporting after the parallel region. INTEGER, ALLOCATABLE :: cable_stat(:) - CHARACTER(512), ALLOCATABLE :: cable_msg(:) + CHARACTER(1024), ALLOCATABLE :: cable_msg(:) ! Host-driven ambient-fluid surface over the EI=0 system's LINE NODES (the sampling ! points a coupled host feeds with wave kinematics): nfluid = total line-node count, ! fl_off(li) = the node offset of system line li in the flat (3, nfluid) arrays, and diff --git a/src/CableDyn_OpenFAST_HermiteFMF.f90 b/src/CableDyn_OpenFAST_HermiteFMF.f90 index c29fa843..3f8bb610 100644 --- a/src/CableDyn_OpenFAST_HermiteFMF.f90 +++ b/src/CableDyn_OpenFAST_HermiteFMF.f90 @@ -830,7 +830,7 @@ SUBROUTINE CD_HFMF_PreflightCoupledKinematics(self, u_pos, u_vel, u_acc, ErrStat REAL(wp), ALLOCATABLE :: qc(:), g(:) REAL(wp) :: ends(3, 4), raw, th INTEGER :: ks, k - CHARACTER(200) :: km + CHARACTER(1024) :: km ends = coupled_torsion_ends(self, target_dcm) DO k = 1, 3, 2 IF (ABS(NORM2(ends(:, k)) - CD_ONE) > 1.0e-8_wp .OR. ABS(NORM2(ends(:, k + 1)) - CD_ONE) > 1.0e-8_wp & @@ -998,7 +998,7 @@ SUBROUTINE prepare_coupled_kinematics(self, u_pos, u_vel, u_acc, target_dcm, tar REAL(wp) :: target_direction_rate(3), target_direction_acceleration(3) REAL(wp) :: omega_local(3), alpha_local(3), rotation_check(3, 3) INTEGER :: base, ecstat - CHARACTER(200) :: ecmsg + CHARACTER(1024) :: ecmsg ErrStat = CD_HFMF_OK ErrMsg = '' diff --git a/src/CableDyn_OpenFAST_Mesh.f90 b/src/CableDyn_OpenFAST_Mesh.f90 index ca79d01b..d464f2eb 100644 --- a/src/CableDyn_OpenFAST_Mesh.f90 +++ b/src/CableDyn_OpenFAST_Mesh.f90 @@ -296,7 +296,7 @@ LOGICAL FUNCTION mesh_matches_module(self, mesh, ErrStat, ErrMsg) RESULT(matches CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: fast_stat, n_coupled - CHARACTER(240) :: fast_msg + CHARACTER(1024) :: fast_msg matches = .FALSE. ErrStat = CD_FAST_MESH_OK diff --git a/src/CableDyn_Static.f90 b/src/CableDyn_Static.f90 index 72d3130a..d6a677f7 100644 --- a/src/CableDyn_Static.f90 +++ b/src/CableDyn_Static.f90 @@ -114,7 +114,7 @@ MODULE CableDyn_Static !! equilibrium (or the last failure), for diagnostics and fail-closed error messages. CHARACTER(64) :: seed = '' !! seed of the accepted (or last attempted) solve CHARACTER(64) :: stage = '' !! solver stage of the accepted (or last failed) solve - CHARACTER(400) :: message = '' !! human-readable outcome / failure reason + CHARACTER(560) :: message = '' !! outcome / failure reason (holds the bounded seed notes whole) INTEGER :: n_iter = 0 !! Newton iterations over every attempt REAL(wp) :: min_tension = CD_ZERO !! smallest element tension of the reported state [N] LOGICAL :: slack_branch = .FALSE. !! .TRUE. when the tension-only (slack-capable) solve was needed @@ -1349,7 +1349,7 @@ SUBROUTINE CD_Static_As_Laid_Reference(origin, azimuth, l0, ea, laid_tension, re INTEGER :: n_elem, e, j, nsub, es REAL(wp) :: dir(2), d, ds, step, x, y, zf, gx, gy, g, dshort, sink_j, p(3, 3), t_in(3), t_out(3), nrm(3) REAL(wp), ALLOCATABLE :: ref0(:, :) - CHARACTER(120) :: em + CHARACTER(1024) :: em ErrStat = CD_STATIC_OK ErrMsg = '' @@ -1519,7 +1519,7 @@ SUBROUTINE laid_at(k, mismatch, valid) INTEGER :: i, es_d REAL(wp) :: zf, gx, gy, g, p(3), h_s, g_s, u(3), uh REAL(wp), ALLOCATABLE :: q_sus(:) - CHARACTER(200) :: em_d + CHARACTER(1024) :: em_d valid = .FALSE. mismatch = -HUGE(CD_ONE) @@ -1555,7 +1555,7 @@ SUBROUTINE floor_at(x, y, zf, gx, gy, es_f) REAL(wp), INTENT(IN) :: x, y REAL(wp), INTENT(OUT) :: zf, gx, gy INTEGER, INTENT(OUT) :: es_f - CHARACTER(120) :: em_f + CHARACTER(1024) :: em_f es_f = 0 gx = CD_ZERO gy = CD_ZERO @@ -1660,7 +1660,11 @@ SUBROUTINE CD_Static_Line_Equilibrium(anchor, fairlead, elem_conn, l0, ea, weigh LOGICAL :: has_seabed, anchor_grounded, conv, stalled, at_floor, have_seed, done, have_best CHARACTER(1024) :: em CHARACTER(64) :: seed_name - CHARACTER(400) :: notes + ! The seed notes of a failed solve (report%message holds them after a fixed prefix). Up to + ! seven seeds note up to three stages each, more than this holds: add_note ends the list with + ! an omission marker instead of cutting a note. + CHARACTER(480) :: notes + LOGICAL :: notes_full TYPE(CableSolverConfig) :: cfg_adm converged = .FALSE. @@ -1766,6 +1770,7 @@ SUBROUTINE CD_Static_Line_Equilibrium(anchor, fairlead, elem_conn, l0, ea, weigh END IF notes = '' + notes_full = .FALSE. q_best = CD_ZERO have_best = .FALSE. DO iorder = 1, SIZE(order) @@ -1890,12 +1895,27 @@ SUBROUTINE accept(qa, slack) END SUBROUTINE accept SUBROUTINE add_note(txt) + !! Append one seed note while the notes keep room for it and the omission marker; + !! otherwise end them with the marker, so a note is never cut. CHARACTER(*), INTENT(IN) :: txt - IF (LEN_TRIM(notes) == 0) THEN - notes = txt + CHARACTER(*), PARAMETER :: OMITTED = '; further seed notes omitted' + INTEGER :: n + IF (notes_full) RETURN + n = LEN_TRIM(notes) + IF (n == 0) THEN + IF (LEN_TRIM(txt) + LEN(OMITTED) <= LEN(notes)) THEN + notes = TRIM(txt) + RETURN + END IF + notes = OMITTED(3:) ELSE - notes = TRIM(notes)//'; '//txt + IF (n + 2 + LEN_TRIM(txt) + LEN(OMITTED) <= LEN(notes)) THEN + notes = notes(1:n)//'; '//TRIM(txt) + RETURN + END IF + notes = notes(1:n)//OMITTED END IF + notes_full = .TRUE. END SUBROUTINE add_note SUBROUTINE run_solve(qs, factors, slack_law, ratio, cfg_use, qo, ok) @@ -2112,7 +2132,7 @@ SUBROUTINE laid_seed_from_last(ok) INTEGER :: es_r, i_r REAL(wp) :: floor_n REAL(wp), ALLOCATABLE :: q_rev(:) - CHARACTER(200) :: em_r + CHARACTER(1024) :: em_r ok = .FALSE. floor_n = seabed_floor_at(fairlead(1), fairlead(2), es_r, em_r) IF (es_r /= 0) RETURN diff --git a/src/CableDyn_System.f90 b/src/CableDyn_System.f90 index 791fcff6..0c33d7f4 100644 --- a/src/CableDyn_System.f90 +++ b/src/CableDyn_System.f90 @@ -190,7 +190,7 @@ MODULE CableDyn_System ! parallel region so failure selection and mapped-load accumulation stay reproducible. INTEGER, ALLOCATABLE :: line_off(:), line_stat(:), line_iter(:) LOGICAL, ALLOCATABLE :: line_converged(:), line_stalled(:) - CHARACTER(512), ALLOCATABLE :: line_msg(:) + CHARACTER(1024), ALLOCATABLE :: line_msg(:) REAL(wp), ALLOCATABLE :: line_load_work(:) ! Snapshot of the COMMITTED system state (every line's q/v/a/f_ext + every point) for ! the aggregate stage-then-commit contract. The per-line q_rollback buffers CANNOT diff --git a/tests/data/msg_mixed_coarse_strain.dat b/tests/data/msg_mixed_coarse_strain.dat new file mode 100644 index 00000000..05b0e99a --- /dev/null +++ b/tests/data/msg_mixed_coarse_strain.dat @@ -0,0 +1,59 @@ +--------------------- CableDyn Input File --- +msg_mixed_coarse_strain +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +chain 0.216 286.56 1229760000 -1 0 1.37 0.64 1 0 +pc 0.16 36.7 469000000 -1 19900 1.2 0.1 1 0 +buoy 0.5 170.666793 469000000 -1 19900 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -14 0 0 0 0 +2 Fixed 830 0 -200 0 0 0 0 +3 Fixed -415 719 -200 0 0 0 0 +4 Fixed -300 -50 -200 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 - +2 1 3 - +3 1 4 - +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 chain 150 1 +1 chain 700 70 +2 chain 850 85 +3 pc 180 180 +3 buoy 80 80 +3 pc 150 150 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +0.05 dtM +0.0 TMax +0.0001 maxStrain +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"FairTen2" +"AnchTen2" +"FairTen3" +"AnchTen3" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +"Point3Fx" +"Point3Fy" +"Point3Fz" +"Point4Fx" +"Point4Fy" +"Point4Fz" +--------------------- need this line --- diff --git a/tests/data/msg_net_buoyant_ei0.dat b/tests/data/msg_net_buoyant_ei0.dat new file mode 100644 index 00000000..1069272a --- /dev/null +++ b/tests/data/msg_net_buoyant_ei0.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_net_buoyant_ei0 +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +neutral 0.17 23.2654100 200000000 -1 0 1.2 0.1 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -10 0 0 0 0 +2 Fixed 450 0 -100 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 neutral 520 52 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +100.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_shared_line_finite_ei.dat b/tests/data/msg_shared_line_finite_ei.dat new file mode 100644 index 00000000..54324710 --- /dev/null +++ b/tests/data/msg_shared_line_finite_ei.dat @@ -0,0 +1,35 @@ +--------------------- CableDyn Input File --- +msg_shared_line_finite_ei +--------------------- LINE TYPES --- +TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t +(-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) +wire 0.1 50 900000000 -1 10000 1.2 0.008 1 0 +--------------------- POINTS --- +ID Type X Y Z Mass Vol CdA Ca +(-) (-) (m) (m) (m) (kg) (m3) (m2) (-) +1 Coupled 0 0 -15 0 0 0 0 +2 Coupled 800 0 -15 0 0 0 0 +--------------------- LINES --- +ID NodeA NodeB Outputs +(-) (-) (-) (-) +1 1 2 pt +--------------------- SECTIONS --- +LineID LineType Length NumSegs +(-) (-) (m) (-) +1 wire 900 90 +--------------------- OPTIONS --- +9.80665 g +1025.0 rhoW +200.0 WtrDpth +100000.0 kBot +1.0e4 cBot +--------------------- OUTPUTS --- +"FairTen1" +"AnchTen1" +"Point1Fx" +"Point1Fy" +"Point1Fz" +"Point2Fx" +"Point2Fy" +"Point2Fz" +--------------------- need this line --- diff --git a/tests/data/msg_weightless_ei0.dat b/tests/data/msg_weightless_ei0.dat index 84ff40b9..6d2b18ee 100644 --- a/tests/data/msg_weightless_ei0.dat +++ b/tests/data/msg_weightless_ei0.dat @@ -3,7 +3,7 @@ msg_weightless_ei0 --------------------- LINE TYPES --- TypeName Diam MassDenInAir EA BA EI Cd_n Cd_t Ca_n Ca_t (-) (m) (kg/m) (N) (-) (Nm2) (-) (-) (-) (-) -neutral 0.17 23.2654571 200000000 -1 0 1.2 0.1 1 0 +neutral 0.17 23.2654570 200000000 -1 0 1.2 0.1 1 0 --------------------- POINTS --- ID Type X Y Z Mass Vol CdA Ca (-) (-) (m) (m) (m) (kg) (m3) (m2) (-) From d96b2a99bdd8c3af87a716efd4464cac4344c928 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Fri, 16 Oct 2026 20:30:30 +0900 Subject: [PATCH 03/11] fix: keep hot-path message buffers short Widening every message buffer to 1024 characters slowed the dynamic step by up to 5 %, because element, node and Gauss-point kernels reset their whole message buffer on every call. A hot-path buffer now only holds the longest text that can actually reach it, and long messages are still assembled in full on the cold failure paths. Back to their previous lengths, each bounded by the kernels it calls: the Hermite element, drag and wave-load locals and the per-element message array (200), the Hermite element and sampling locals, the torsion element and line, the EI=0 element assembly, the Cosserat assembly and energy, and the per-node seabed, kinematics, range and static-friction buffers. The EI=0 load and added-mass assemblies, the assembly input checks and the rod seabed queries pass their kernels a 200- or 120-character share of the caller's message, so a kernel no longer resets a 1024-character buffer. The per-node seabed query of the Hermite static Newton step and the per-node kinematics of the deck fluid update use their own short buffers. Every message still fits whole, the blank-on-success contract of public kernels is unchanged, and results are byte-identical. Signed-off-by: Jae Hoon Seo --- src/CableDyn_Assemble.f90 | 36 +++++--- src/CableDyn_CosseratAssemble.f90 | 10 +-- src/CableDyn_CosseratDynamic.f90 | 2 +- src/CableDyn_DeckDriver.f90 | 39 ++++---- src/CableDyn_HermiteCable.f90 | 6 +- src/CableDyn_HermiteCableDynamic.f90 | 37 ++++---- src/CableDyn_HermiteCableStatic.f90 | 13 +-- src/CableDyn_HermiteTorsion.f90 | 4 +- src/CableDyn_Model.f90 | 129 +++++++++++++++------------ src/CableDyn_RangeOutput.f90 | 2 +- src/CableDyn_Static.f90 | 2 +- 11 files changed, 155 insertions(+), 125 deletions(-) diff --git a/src/CableDyn_Assemble.f90 b/src/CableDyn_Assemble.f90 index 9f2561e1..e6d54fdd 100644 --- a/src/CableDyn_Assemble.f90 +++ b/src/CableDyn_Assemble.f90 @@ -99,14 +99,17 @@ SUBROUTINE CD_Assemble_Cable_Tangent_Force(nodes, elem_conn, l0, ea, & INTEGER :: n_nodes, n_elem, e, a, b, ia, ib, i, j, es REAL(wp) :: nodes6(6), Kt6(6, 6), fint6(6), Te - CHARACTER(1024) :: em + CHARACTER(120) :: em Kt = CD_ZERO fint = CD_ZERO tension = CD_ZERO - CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) + ! the input checks write messages of at most 80 characters into a 120-character share + ErrMsg = '' + CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120)), & + topology_validated) IF (ErrStat /= 0) RETURN - CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg) + CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120))) IF (ErrStat /= 0) RETURN IF (.NOT. shape_ok_2d(Kt, 3*n_nodes) .OR. SIZE(fint) /= 3*n_nodes & .OR. SIZE(tension) /= n_elem) THEN @@ -233,9 +236,12 @@ SUBROUTINE CD_Assemble_Cable_Tangent_Force_Banded_Free(nodes, elem_conn, l0, ea, Kb = CD_ZERO fint = CD_ZERO tension = CD_ZERO - CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) + ! the input checks write messages of at most 80 characters into a 120-character share + ErrMsg = '' + CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120)), & + topology_validated) IF (ErrStat /= 0) RETURN - CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg) + CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120))) IF (ErrStat /= 0) RETURN ndof = 3*n_nodes ldab = 2*kl + ku + 1 @@ -277,7 +283,7 @@ SUBROUTINE assemble_elements(g2f) INTEGER, INTENT(IN) :: g2f(:) INTEGER :: e, a, b, i, j, fi, fj, row, gmap(6), elem_es REAL(wp) :: nodes6(6), Kt6(6, 6), fint6(6), Te - CHARACTER(1024) :: em + CHARACTER(120) :: em DO e = 1, n_elem a = elem_conn(1, e) @@ -342,12 +348,15 @@ SUBROUTINE CD_Assemble_Cable_Internal_Force(nodes, elem_conn, l0, ea, tension_on REAL(wp), ALLOCATABLE :: fe(:, :) INTEGER, ALLOCATABLE :: elem_es(:) INTEGER :: n_team - CHARACTER(1024) :: em + CHARACTER(120) :: em fint = CD_ZERO - CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) + ! the input checks write messages of at most 80 characters into a 120-character share + ErrMsg = '' + CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120)), & + topology_validated) IF (ErrStat /= 0) RETURN - CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg) + CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120))) IF (ErrStat /= 0) RETURN IF (SIZE(fint) /= 3*n_nodes) THEN CALL fail(ErrStat, ErrMsg, 'fint must have shape (3 n_nodes)') @@ -428,12 +437,15 @@ SUBROUTINE CD_Compute_Cable_Tension(nodes, elem_conn, l0, ea, tension_only, & REAL(wp), ALLOCATABLE :: te_buf(:) INTEGER, ALLOCATABLE :: elem_es(:) INTEGER :: n_team - CHARACTER(1024) :: em + CHARACTER(120) :: em tension = CD_ZERO - CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg, topology_validated) + ! the input checks write messages of at most 80 characters into a 120-character share + ErrMsg = '' + CALL check_topology(nodes, elem_conn, n_nodes, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120)), & + topology_validated) IF (ErrStat /= 0) RETURN - CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg) + CALL check_props(l0, ea, n_elem, ErrStat, ErrMsg(1:MIN(LEN(ErrMsg), 120))) IF (ErrStat /= 0) RETURN IF (SIZE(tension) /= n_elem) THEN CALL fail(ErrStat, ErrMsg, 'tension must have shape (n_elem)') diff --git a/src/CableDyn_CosseratAssemble.f90 b/src/CableDyn_CosseratAssemble.f90 index 65d9618b..3c25f44b 100644 --- a/src/CableDyn_CosseratAssemble.f90 +++ b/src/CableDyn_CosseratAssemble.f90 @@ -56,7 +56,7 @@ MODULE CableDyn_CosseratAssemble REAL(wp), ALLOCATABLE :: fe(:, :) REAL(wp), ALLOCATABLE :: Ke(:, :, :) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(512), ALLOCATABLE :: elem_em(:) + CHARACTER(120), ALLOCATABLE :: elem_em(:) END TYPE CD_CosseratAssemblyWorkspace CONTAINS @@ -94,8 +94,8 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force(nodes_ref, elem_conn, ea, gas, ei, REAL(wp) :: Lam0(3, 3), L0, qe(12), Kte(12, 12), finte(12) REAL(wp), ALLOCATABLE :: fe(:, :), Ke(:, :, :) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(512), ALLOCATABLE :: elem_em(:) - CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) + CHARACTER(120), ALLOCATABLE :: elem_em(:) + CHARACTER(120) :: em CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -271,7 +271,7 @@ SUBROUTINE CD_Assemble_Cosserat_Tangent_Force_Banded_Free_Workspace(nodes_ref, e LOGICAL :: apply_chain INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), Kte(12, 12), finte(12) - CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) + CHARACTER(120) :: em CD_COSASM_N_TANGENT = CD_COSASM_N_TANGENT + 1 CALL SYSTEM_CLOCK(c0, rate) @@ -415,7 +415,7 @@ SUBROUTINE CD_Assemble_Cosserat_Internal_Force_Workspace(nodes_ref, elem_conn, e INTEGER :: n_nodes, n_elem, e, a, b, ndof, gmap(12), i, es INTEGER(INT64) :: c0, rate REAL(wp) :: Lam0(3, 3), L0, qe(12), finte(12) - CHARACTER(512) :: em ! an element message (short and fixed), stored in elem_em(512) + CHARACTER(120) :: em CD_COSASM_N_FORCE = CD_COSASM_N_FORCE + 1 CALL SYSTEM_CLOCK(c0, rate) diff --git a/src/CableDyn_CosseratDynamic.f90 b/src/CableDyn_CosseratDynamic.f90 index 9e19f406..2c315ad0 100644 --- a/src/CableDyn_CosseratDynamic.f90 +++ b/src/CableDyn_CosseratDynamic.f90 @@ -205,7 +205,7 @@ SUBROUTINE CD_Cosserat_Mechanical_Energy(nodes_ref, elem_conn, ea, gas, ei, gj, REAL(wp) :: Lam0(3, 3), L0, qe(12), Is(3, 3), om(3), w REAL(wp), ALLOCATABLE :: mv(:), v_trans(:) LOGICAL :: mult_e - CHARACTER(1024) :: em + CHARACTER(120) :: em strain_e = CD_ZERO; kinetic_e = CD_ZERO; ErrStat = CD_DYN_OK; ErrMsg = '' IF (SIZE(nodes_ref, 1) /= 3 .OR. SIZE(elem_conn, 1) /= 2) THEN ErrStat = CD_DYN_BADINPUT; ErrMsg = 'CD_Cosserat_Mechanical_Energy: nodes_ref (3,*) / elem_conn (2,*)' diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index c5648bbf..86917936 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -8975,7 +8975,7 @@ SUBROUTINE finite_bathymetry_contact_force(q, v, bathymetry, kn, cn, mu, f_ext, INTEGER :: nnode, i, ix, iy, iz, es REAL(wp), PARAMETER :: vreg = 1.0e-3_wp REAL(wp) :: z_floor, gap, normal, normal_tangent, gate, gate_tangent, denom - CHARACTER(1024) :: em + CHARACTER(160) :: em f_ext = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -9067,7 +9067,7 @@ SUBROUTINE finite_bathymetry_contact_load_banded(q, v, bathymetry, kn, cn, mu, f INTEGER :: nnode, i, ix, iy, iz, es REAL(wp) :: z_floor, dfdx, dfdy - CHARACTER(1024) :: em + CHARACTER(160) :: em CALL init_finite_contact_band(q, v, kn, cn, mu, free, kl, ku, free_map, f_ext, jac_q_band, jac_v_band, & nnode, ErrStat, ErrMsg) @@ -9267,7 +9267,7 @@ SUBROUTINE finite_environment_force(model, opts, time, q, v, f_ext, ErrStat, Err INTEGER :: idx(6) REAL(wp) :: xa(3), xb(3), va(3), vb(3), eta_a, eta_b REAL(wp) :: fluid_a(3), fluid_b(3), accel_a(3), accel_b(3), f2(6) - CHARACTER(1024) :: em + CHARACTER(200) :: em ! per-element kinematics and Morison messages (at most 160 characters) f_ext = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -9335,7 +9335,7 @@ SUBROUTINE finite_environment_load_banded(model, opts, time, q, v, free, kl, ku, INTEGER :: idx(6) REAL(wp) :: xa(3), xb(3), va(3), vb(3), eta_a, eta_b REAL(wp) :: fluid_a(3), fluid_b(3), accel_a(3), accel_b(3), f2(6), jq2(6, 6), jv2(6, 6) - CHARACTER(1024) :: em + CHARACTER(200) :: em ! per-element kinematics and Morison messages (at most 160 characters) ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -9429,7 +9429,7 @@ SUBROUTINE finite_environment_node(opts, time, x, eta, fluid_velocity, fluid_acc CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: current_velocity(3) INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(200) :: em ! per-node kinematics messages (at most 160 characters) eta = CD_ZERO fluid_velocity = CD_ZERO @@ -19661,7 +19661,7 @@ SUBROUTINE mb_imp_states(mb, x, dt, gam_na, beta_na, gam_p, beta_p, ErrStat, Err INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ib, ir, p, o, es - CHARACTER(1024) :: em + CHARACTER(160) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' DO ib = 1, SIZE(mb%rigid) @@ -21513,7 +21513,9 @@ SUBROUTINE rod_seabed_contact(rod, opts, force, moment, load_dv, ErrStat, ErrMsg arm = MATMUL(rod%rot_mat, [s, CD_ZERO, CD_ZERO]) r_eval = rod%r + arm v_eval = rod%v + cross3(rod%omega, arm) - CALL deck_seabed_floor_at(r_eval(1), r_eval(2), opts, has_floor, z_floor, ErrStat, ErrMsg, bathymetry) + ! (a floor query message is at most 126 characters: it resets only that share of ErrMsg) + CALL deck_seabed_floor_at(r_eval(1), r_eval(2), opts, has_floor, z_floor, ErrStat, & + ErrMsg(1:MIN(LEN(ErrMsg), 200)), bathymetry) IF (ErrStat /= CD_DECKDRV_OK) RETURN IF (.NOT. has_floor) CYCLE penetration = z_floor - r_eval(3) @@ -22147,7 +22149,7 @@ SUBROUTINE fluid_at(xq, s, uq, duq, etaq, pdq, want_pdyn) LOGICAL, INTENT(IN) :: want_pdyn INTEGER :: es, ih REAL(wp) :: tq - CHARACTER(1024) :: em + CHARACTER(200) :: em ! per-node kinematics messages (at most 160 characters) uq = CD_ZERO duq = CD_ZERO @@ -23852,7 +23854,7 @@ LOGICAL FUNCTION node_on_floor(pos, zf) RESULT(below) REAL(wp), ALLOCATABLE, INTENT(IN) :: zf REAL(wp) :: zfl INTEGER :: es_b - CHARACTER(1024) :: em_b + CHARACTER(160) :: em_b below = .FALSE. IF (PRESENT(bathymetry)) THEN CALL CD_Bathymetry_Floor(bathymetry, pos(1), pos(2), zfl, es_b, em_b) @@ -26074,7 +26076,7 @@ SUBROUTINE deck_seabed_floor_at(x, y, opts, has_floor, z_floor, ErrStat, ErrMsg, TYPE(CD_BathymetryType), INTENT(IN), OPTIONAL :: bathymetry INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(160) :: em LOGICAL :: bathy_ready ErrStat = CD_DECKDRV_OK @@ -26114,7 +26116,7 @@ SUBROUTINE rigid6_wet_fraction(body, opts, time, phi, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es REAL(wp) :: x_cb(3), eta, u(3), du(3), r_e, h - CHARACTER(1024) :: em + CHARACTER(200) :: em ! kinematics messages (at most 160 characters) ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -26237,7 +26239,7 @@ SUBROUTINE rigid6_environment_force(body, opts, time, force, effective_mass, dra INTEGER :: es REAL(wp) :: eta, rel(3), rel_speed, fluid_velocity(3), fluid_acceleration(3), phi, fk - CHARACTER(1024) :: em + CHARACTER(200) :: em ! kinematics messages (at most 160 characters) ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -26742,6 +26744,7 @@ SUBROUTINE update_hermite_deck_fluid(cables, opts, time, ErrStat, ErrMsg) INTEGER :: i, j, nn, es REAL(wp) :: eta, wv(3), wa(3) CHARACTER(1024) :: em + CHARACTER(200) :: em_k ! a per-node current or wave kinematics message (at most 160 characters) ErrStat = CD_DECKDRV_OK; ErrMsg = '' IF (.NOT. (opts%has_current .OR. opts%has_wave)) RETURN DO i = 1, SIZE(cables) @@ -26755,15 +26758,15 @@ SUBROUTINE update_hermite_deck_fluid(cables, opts, time, ErrStat, ErrMsg) fv = CD_ZERO; fa = CD_ZERO; wl = CD_ZERO DO j = 1, nn IF (opts%has_current) THEN - fv(:, j) = deck_current_velocity(opts, xyz(3, j), es, em) + fv(:, j) = deck_current_velocity(opts, xyz(3, j), es, em_k) IF (es /= CD_HYDRO_OK) THEN - CALL hermite_fluid_fail('current profile', em); RETURN + CALL hermite_fluid_fail('current profile', em_k); RETURN END IF END IF IF (opts%has_wave) THEN - CALL deck_wave_kinematics(opts, xyz(1, j), xyz(2, j), xyz(3, j), time, eta, wv, wa, es, em) + CALL deck_wave_kinematics(opts, xyz(1, j), xyz(2, j), xyz(3, j), time, eta, wv, wa, es, em_k) IF (es /= CD_HYDRO_OK) THEN - CALL hermite_fluid_fail('wave kinematics', em); RETURN + CALL hermite_fluid_fail('wave kinematics', em_k); RETURN END IF fv(:, j) = fv(:, j) + wv; fa(:, j) = wa; wl(j) = eta END IF @@ -32057,7 +32060,7 @@ SUBROUTINE range_sample_cable(cable, rl, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: nn, ne, e, j, k, inode, es REAL(wp) :: curv, bend - CHARACTER(1024) :: em + CHARACTER(200) :: em ! per-element curvature messages (at most 55 characters) ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -33043,7 +33046,7 @@ REAL(wp) FUNCTION cable_axial_tension(cable, e, xi) RESULT(t) REAL(wp), INTENT(IN) :: xi REAL(wp) :: qr(12), vr(12), l0, viscous INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(160) :: em t = CD_ZERO IF (e < 1 .OR. e > cable%line%ne) RETURN l0 = cable%line%l0(e) diff --git a/src/CableDyn_HermiteCable.f90 b/src/CableDyn_HermiteCable.f90 index 8dbcf467..2dea8258 100644 --- a/src/CableDyn_HermiteCable.f90 +++ b/src/CableDyn_HermiteCable.f90 @@ -70,7 +70,7 @@ SUBROUTINE CD_HermiteCable_Element(qr, L, EA, EI, Eout, fint, Kt, ErrStat, ErrMs REAL(wp) :: energy_axial, energy_bending, force_axial(12), force_bending(12) REAL(wp) :: tangent_axial(12, 12), tangent_bending(12, 12) INTEGER :: axial_order, bending_order, es - CHARACTER(1024) :: em + CHARACTER(200) :: em LOGICAL :: half_tangent, only_tangent axial_order = NG @@ -515,7 +515,7 @@ SUBROUTINE curv_at(u, curvature) REAL(wp), INTENT(IN) :: u REAL(wp), INTENT(OUT) :: curvature INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(160) :: em CALL CD_HermiteCable_Curvature(qr, L, u, curvature, es, em) IF (es /= CD_HCABLE_OK) THEN ErrStat = es @@ -633,7 +633,7 @@ SUBROUTINE resultant_at(u, resultant) REAL(wp), INTENT(IN) :: u REAL(wp), INTENT(OUT) :: resultant INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(160) :: em CALL CD_HermiteCable_Axial_Resultant(qr, L, EA, u, resultant, es, em) IF (es /= CD_HCABLE_OK) THEN ErrStat = es diff --git a/src/CableDyn_HermiteCableDynamic.f90 b/src/CableDyn_HermiteCableDynamic.f90 index 5cb2594a..76d4d608 100644 --- a/src/CableDyn_HermiteCableDynamic.f90 +++ b/src/CableDyn_HermiteCableDynamic.f90 @@ -272,7 +272,7 @@ MODULE CableDyn_HermiteCableDynamic REAL(wp), ALLOCATABLE :: ws_elem_f(:, :), ws_elem_K(:, :, :), ws_elem_Kdrag(:, :, :) REAL(wp), ALLOCATABLE :: ws_elem_Kv(:, :, :), ws_elem_Kwave(:, :, :), ws_elem_Kheld(:, :, :) INTEGER, ALLOCATABLE :: ws_elem_es(:) - CHARACTER(512), ALLOCATABLE :: ws_elem_em(:) + CHARACTER(200), ALLOCATABLE :: ws_elem_em(:) REAL(wp) :: alpha_m = CD_ZERO, alpha_f = CD_ZERO, beta = CD_ZERO, gamma = CD_ZERO ! Optional Morison drag (transverse + tangential quadratic drag on the submerged cable, relative ! to a uniform fluid velocity). Off by default; wired in via CD_HermiteCable_Dyn_Set_Drag. @@ -6419,10 +6419,10 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta REAL(wp) :: endconn_d0_eval(3, 2), support(3), dsupport(3), nin(3), mend INTEGER :: inode, jr, jc CHARACTER(1024) :: em2 - ! The per-element kernels (element, axial damping, drag, wave load) report fixed messages of - ! under 200 characters, nested ones included; em_e takes them. Each kernel resets its message - ! buffer at every call, so this one is kept small (a 1024-character one costs 2-3 % of a step). - CHARACTER(256) :: em_e + ! em_e takes the messages of the per-element kernels (element, axial damping, drag, wave load), + ! fixed texts of at most 184 characters with the nested CableDyn_Hydro ones. Each kernel resets + ! its message at every call, so this buffer stays as short as those texts allow. + CHARACTER(200) :: em_e ErrStat = CD_HCDYN_OK; ErrMsg = '' ne = model%ne @@ -6969,7 +6969,7 @@ SUBROUTINE assemble_contact(model, q_cfg, v_cfg, want_residual, want_tangent, Er REAL(wp) :: ffr(2), dfr_dd(2, 2), dfr_dc(2) REAL(wp) :: curv_g(3), curv_l(3), fcrease(3), kcrease(3, 3) LOGICAL :: creased - CHARACTER(1024) :: em + CHARACTER(200) :: em ErrStat = CD_HCDYN_OK; ErrMsg = '' IF (.NOT. model%has_contact .OR. .NOT. ALLOCATED(model%contact_kn) .OR. & @@ -7107,7 +7107,7 @@ LOGICAL FUNCTION held_end_floor_support(model, q_cfg, iend, support, dsupport, i INTEGER, INTENT(OUT) :: inode INTEGER :: node, e, ix, es REAL(wp) :: gap, sfac, share, nvec(3), sfac_in, gap_in, normal, normal_gap, elem, delem - CHARACTER(1024) :: em + CHARACTER(200) :: em support = CD_ZERO dsupport = CD_ZERO nin = [CD_ZERO, CD_ZERO, CD_ONE] @@ -7180,7 +7180,7 @@ SUBROUTINE commit_friction_anchors(model) INTEGER :: i, ix, iz, es REAL(wp) :: xl, yl, xg, yg, z_floor, gxg, gyg, gap, normal, normal_gap, gate, gate_gap REAL(wp) :: dxy(2), dlen, cap, mu_d, q_d, gq_d(2), gx, gy, sfac, nvec(3), vn - CHARACTER(1024) :: em + CHARACTER(200) :: em DO i = 1, model%nn ix = 6*i - 5; iz = ix + 2 gx = CD_ZERO @@ -7250,11 +7250,10 @@ SUBROUTINE evaluate_tangent_element(model, e, q_cfg, v_cfg, t_eval, Kstruct, Kdr REAL(wp) :: djq(12, 12), djv(12, 12), fjq(12, 12) REAL(wp) :: hf_mid(3) INTEGER :: es - ! The element kernels report fixed messages of under 200 characters (nested ones included), - ! which fit em and the 512-character per-element buffer (ws_elem_em) this fills. Each kernel - ! resets em at every call, so em is kept small; ErrMsg is written only on a failure (the - ! caller reads it only when ErrStat says so). - CHARACTER(256) :: em + ! The element kernels write fixed messages of at most 184 characters (nested ones included), + ! which fit em and the per-element buffer ws_elem_em this fills. Each kernel resets em at every + ! call, so em stays short; ErrMsg is written only on a failure (the caller reads it only then). + CHARACTER(200) :: em ErrStat = CD_HCDYN_OK qe(1:6) = q_cfg(6*(e - 1) + 1:6*e) @@ -7599,9 +7598,9 @@ SUBROUTINE CD_HermiteCable_Drag_Element(qe, ve, l0, fluid, waterline_z, rho, dia REAL(wp) :: scale, eta_w, uw(3), aw(3) LOGICAL :: has_wv, has_shared, has_trio, has_cmp, any_wv_arg, want_jac INTEGER :: g, s, c, sp, cp, a, b, es - ! the message of a per-Gauss-point CableDyn_Hydro kinematics or Morison call (each is under 200 - ! characters): a small buffer, as these calls reset it at every Gauss point - CHARACTER(256) :: em2 + ! the message of a per-Gauss-point CableDyn_Hydro kinematics or Morison call (at most 154 + ! characters): a short buffer, as these calls reset it at every Gauss point + CHARACTER(200) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(djq) @@ -7874,9 +7873,9 @@ SUBROUTINE CD_HermiteCable_FK_Element(qe, l0, waterline_z, rho, diam, can, cat, REAL(wp) :: fpl(3), Jtan(3, 3), proj(3, 3), projk(3), dalpha LOGICAL :: has_trio, has_cmp, has_held, want_jac INTEGER :: g, s, c, sp, cp, a, b, k, es - ! the message of a per-Gauss-point CableDyn_Hydro kinematics call (each is under 200 characters): - ! a small buffer, as these calls reset it at every Gauss point - CHARACTER(256) :: em2 + ! the message of a per-Gauss-point CableDyn_Hydro kinematics call (at most 154 characters): a + ! short buffer, as these calls reset it at every Gauss point + CHARACTER(200) :: em2 ErrStat = CD_HCDYN_OK; ErrMsg = '' want_jac = PRESENT(fjq) diff --git a/src/CableDyn_HermiteCableStatic.f90 b/src/CableDyn_HermiteCableStatic.f90 index cb42814e..88829029 100644 --- a/src/CableDyn_HermiteCableStatic.f90 +++ b/src/CableDyn_HermiteCableStatic.f90 @@ -477,7 +477,7 @@ SUBROUTINE CD_HermiteCable_Static_Solve(l0, EA, EI, w, seed, fixed_dofs, seabed_ REAL(wp), ALLOCATABLE :: R(:), dq(:), ab(:, :), ab_recovery(:, :), scaled_residual(:) REAL(wp), ALLOCATABLE :: elem_f(:, :), elem_K(:, :, :), elem_E(:) INTEGER, ALLOCATABLE :: elem_es(:) - CHARACTER(512), ALLOCATABLE :: elem_em(:) + CHARACTER(200), ALLOCATABLE :: elem_em(:) ! Secant-predictor history: the converged states of the two previous buoyancy ! stages (q_sec1 = stage b-1, q_sec2 = stage b-2). REAL(wp), ALLOCATABLE :: q_sec1(:), q_sec2(:) @@ -1094,6 +1094,7 @@ RECURSIVE SUBROUTINE newton_step(rnorm, es, em, do_update) INTEGER :: e, a, b, gi, gj, j, es2, bt, es_trial, zdof(4) LOGICAL :: dry, accepted CHARACTER(1024) :: em2, em_trial + CHARACTER(160) :: em_b ! a per-node bathymetry query message (at most 69 characters) es = CD_HCSTAT_OK; em = ''; rnorm = CD_ZERO; merit = CD_ZERO IF (use_rigid) THEN @@ -1246,9 +1247,9 @@ RECURSIVE SUBROUTINE newton_step(rnorm, es, em, do_update) IF (use_bathymetry) THEN xg = contact_cs(1)*q(gi - 2) - contact_cs(2)*q(gi - 1) yg = contact_cs(2)*q(gi - 2) + contact_cs(1)*q(gi - 1) - CALL CD_Bathymetry_Floor_Gradient(bathymetry, xg, yg, z_floor, gxg, gyg, es2, em2, crease_curvature=curv_g) + CALL CD_Bathymetry_Floor_Gradient(bathymetry, xg, yg, z_floor, gxg, gyg, es2, em_b, crease_curvature=curv_g) IF (es2 /= CD_BATHY_OK) THEN - es = CD_HCSTAT_NOCONVERGE; em = 'bathymetry query failed: '//TRIM(em2); RETURN + es = CD_HCSTAT_NOCONVERGE; em = 'bathymetry query failed: '//TRIM(em_b); RETURN END IF gx = contact_cs(1)*gxg + contact_cs(2)*gyg gy = -contact_cs(2)*gxg + contact_cs(1)*gyg @@ -2593,7 +2594,7 @@ REAL(wp) FUNCTION nodal_curvature(a) RESULT(kap) INTEGER, INTENT(IN) :: a REAL(wp) :: qe(12), kL, kR INTEGER :: es3 - CHARACTER(1024) :: em3 + CHARACTER(200) :: em3 kap = CD_ZERO IF (a <= ne) THEN CALL gather_elem(a, qe) @@ -2804,7 +2805,7 @@ SUBROUTINE CD_HermiteCable_Friction_Anchors(l0, q, fr, contact_kn, seabed_z, anc REAL(wp), ALLOCATABLE :: ref(:, :) REAL(wp) :: z_floor, gxg, gyg, xg, yg, normal, normal_gap, dfd(2, 2), dfc(2), cs(2) INTEGER :: node, ix, nn, es - CHARACTER(1024) :: em + CHARACTER(200) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' nn = SIZE(l0) + 1 @@ -2930,7 +2931,7 @@ SUBROUTINE current_element_load(current, qe, l0e, d, cn, ct, want_jac, fd, djq, CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: ve(12), djv(12, 12), ua(3), ub(3), ug(3), ul(3) INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(200) :: em ErrStat = CD_HCSTAT_OK ErrMsg = '' fd = CD_ZERO diff --git a/src/CableDyn_HermiteTorsion.f90 b/src/CableDyn_HermiteTorsion.f90 index 44d5872b..998ef475 100644 --- a/src/CableDyn_HermiteTorsion.f90 +++ b/src/CableDyn_HermiteTorsion.f90 @@ -708,7 +708,7 @@ PURE SUBROUTINE CD_HermiteTorsion_Element(qe, L, h, grad, ErrStat, ErrMsg, hess, REAL(wp) :: hk(12, 12), margin INTEGER :: order - CHARACTER(1024) :: em + CHARACTER(200) :: em order = NG_DEFAULT IF (PRESENT(quadrature_order)) order = quadrature_order @@ -992,7 +992,7 @@ PURE SUBROUTINE line_core(q, Le, ends, theta_raw, grad, ErrStat, ErrMsg, nw, u, LOGICAL :: want_hess, finite REAL(wp) :: scale, margin, he, ge(12), hk(12, 12), v(3), chi, sum_h, eg(6), eh(3, 3, 2), ec(3, 3, 2) REAL(wp) :: om, g9(9), h9(9, 9), pj(3, 3), pk(3, 3), sd(3, 3), dmy - CHARACTER(1024) :: em + CHARACTER(200) :: em theta_raw = CD_ZERO grad = CD_ZERO diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index 2161f3cb..2f37fe91 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -170,6 +170,12 @@ MODULE CableDyn_Model LOGICAL :: active = .FALSE. REAL(wp), ALLOCATABLE :: l0(:), l0_dot(:), f_ext(:), kn(:), cn(:) END TYPE model_lengths_aside + ! The per-element and per-node kernels of the load and added-mass assemblies write messages of + ! at most 187 characters (Hydro, Damping, Viscoelastic, Syrope, bathymetry and band-scatter texts, + ! with their prefixes) and blank their message on entry, also when inputs_validated skips their + ! input scan. They receive the first KERNEL_MSG_LEN characters of the caller's message buffer, + ! so each call resets that much and not the whole (up to 1024-character) buffer. + INTEGER, PARAMETER :: KERNEL_MSG_LEN = 200 TYPE :: CD_ModelType !! Persistent positions-only EI=0 model state and immutable mesh/properties. @@ -2748,7 +2754,7 @@ SUBROUTINE step_model_plain(model, dt, converged, stalled, n_iter, ErrStat, ErrM BLOCK INTEGER :: e2, na, nb, es2 REAL(wp) :: ea_d_eff, ea_1_eff - CHARACTER(1024) :: em2 + CHARACTER(200) :: em2 DO e2 = 1, model%n_elem IF (model%ve_mode(e2) == 0) CYCLE na = model%elem_conn(1, e2) @@ -2804,7 +2810,7 @@ SUBROUTINE step_model_plain(model, dt, converged, stalled, n_iter, ErrStat, ErrM BLOCK INTEGER :: e2, na, nb, es2 REAL(wp) :: dl1_next, ea_d_eff, ea_1_eff - CHARACTER(1024) :: em2 + CHARACTER(200) :: em2 DO e2 = 1, model%n_elem IF (model%ve_mode(e2) == 0) CYCLE CALL model_viscoelastic_coeffs(model, e2, ea_d_eff, ea_1_eff, es2, em2) @@ -6796,7 +6802,7 @@ SUBROUTINE model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrM INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(200) :: em ErrStat = CD_MODEL_OK ErrMsg = '' ea_d_eff = CD_ZERO @@ -6835,7 +6841,7 @@ SUBROUTINE model_syrope_element(model, e, q2, v2, force, jac_q, jac_v, t_mean, d REAL(wp) :: ws(CD_SYROPE_NWC), wt(CD_SYROPE_NWC), wsl(CD_SYROPE_NWC), slow_at LOGICAL :: on_wc INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(200) :: em force = CD_ZERO jac_q = CD_ZERO jac_v = CD_ZERO @@ -6875,7 +6881,7 @@ SUBROUTINE model_syrope_state_next(model, e, q2, v2, dt, slow_next, t_mean, ErrS REAL(wp) :: chord(3), length, eps, slow_at, f6(6), jq6(6, 6), dslow LOGICAL :: on_wc INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(200) :: em slow_next = model%syrope_slow(e) t_mean = CD_ZERO @@ -7084,7 +7090,9 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q REAL(wp) :: q2(6), v2(6), f2(6), jq2(6, 6), jv2(6, 6), ea_d_eff, ea_1_eff, syr_tm, syr_ds LOGICAL :: free_map_ready REAL(wp) :: fluid2(3, 2), accel2(3, 2), wl2(2), dfdv(2, 2) + INTEGER :: lk ! the kernels' share of ErrMsg (KERNEL_MSG_LEN) + lk = MIN(LEN(ErrMsg), KERNEL_MSG_LEN) force = CD_ZERO jac_q_band = CD_ZERO jac_v_band = CD_ZERO @@ -7131,7 +7139,7 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q iy = 3*i - 1 iz = 3*i IF (model%has_bathymetry) THEN - CALL model_floor_gradient(model, q(ix), q(iy), z_floor, dfdx, dfdy, ErrStat, ErrMsg, curvature=curv_n) + CALL model_floor_gradient(model, q(ix), q(iy), z_floor, dfdx, dfdy, ErrStat, ErrMsg(1:lk), curvature=curv_n) IF (ErrStat /= CD_MODEL_OK) RETURN ELSE z_floor = model%seabed_z_floor @@ -7151,7 +7159,7 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q DO cb = 1, 3 DO ra = 1, 3 CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix + ra - 1, ix + cb - 1, & - jac3(ra, cb), ErrStat, ErrMsg) + jac3(ra, cb), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END DO END DO @@ -7161,7 +7169,7 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q CALL CD_Seabed_Normal_Law(gap, model%seabed_kn(i), normal, tangent) force(iz) = force(iz) + normal CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iz, iz, tangent, & - ErrStat, ErrMsg) + ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END DO END IF @@ -7172,16 +7180,16 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q iy = 3*i - 1 iz = 3*i ! damping along the floor normal, at the normal penetration and normal velocity - CALL node_contact_normal(model, q(ix), q(iy), q(iz), v(ix:iz), gap, vn, nvec, sloped, ErrStat, ErrMsg) + CALL node_contact_normal(model, q(ix), q(iy), q(iz), v(ix:iz), gap, vn, nvec, sloped, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL seabed_normal_damping_terms(gap, vn, model%seabed_cn(i), damp_force, damp_dgap, damp_dvz) IF (.NOT. sloped) THEN force(iz) = force(iz) + damp_force CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iz, iz, damp_dgap, & - ErrStat, ErrMsg) + ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL scatter_scalar_band(jac_v_band, model%free_map_work, kl, ku, iz, iz, -damp_dvz, & - ErrStat, ErrMsg) + ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CYCLE END IF @@ -7192,10 +7200,10 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q DO cb = 1, 3 DO ra = 1, 3 CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix + ra - 1, ix + cb - 1, & - damp_dgap*nvec(ra)*nvec(cb), ErrStat, ErrMsg) + damp_dgap*nvec(ra)*nvec(cb), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL scatter_scalar_band(jac_v_band, model%free_map_work, kl, ku, ix + ra - 1, ix + cb - 1, & - -damp_dvz*nvec(ra)*nvec(cb), ErrStat, ErrMsg) + -damp_dvz*nvec(ra)*nvec(cb), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END DO END DO @@ -7208,7 +7216,7 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q ix = 3*i - 2 iy = 3*i - 1 iz = 3*i - normal = seabed_normal_reaction(model, q(ix), q(iy), q(iz), v(ix:iz), i, ErrStat, ErrMsg) + normal = seabed_normal_reaction(model, q(ix), q(iy), q(iz), v(ix:iz), i, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN IF (normal <= CD_ZERO) CYCLE ! stick-slip spring to the committed anchor; the load on the node is -f @@ -7226,23 +7234,23 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q END IF force(ix) = force(ix) - g(1) force(iy) = force(iy) - g(2) - CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix, ix, dfdv(1, 1), ErrStat, ErrMsg) + CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix, ix, dfdv(1, 1), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix, iy, dfdv(1, 2), ErrStat, ErrMsg) + CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, ix, iy, dfdv(1, 2), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iy, ix, dfdv(2, 1), ErrStat, ErrMsg) + CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iy, ix, dfdv(2, 1), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iy, iy, dfdv(2, 2), ErrStat, ErrMsg) + CALL scatter_scalar_band(jac_q_band, model%free_map_work, kl, ku, iy, iy, dfdv(2, 2), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN IF (ABS(dfc(1)) + ABS(dfc(2)) <= CD_ZERO) CYCLE ! sliding: the capacity follows the normal reaction CALL scatter_seabed_friction_position_band(model, q(ix), q(iy), q(iz), v(ix:iz), i, ix, dfc(1), jac_q_band, & - model%free_map_work, kl, ku, ErrStat, ErrMsg, mu_c) + model%free_map_work, kl, ku, ErrStat, ErrMsg(1:lk), mu_c) IF (ErrStat /= CD_MODEL_OK) RETURN CALL scatter_seabed_friction_position_band(model, q(ix), q(iy), q(iz), v(ix:iz), i, iy, dfc(2), jac_q_band, & - model%free_map_work, kl, ku, ErrStat, ErrMsg, mu_c) + model%free_map_work, kl, ku, ErrStat, ErrMsg(1:lk), mu_c) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL seabed_normal_velocity_gradient(model, q(ix), q(iy), q(iz), v(ix:iz), i, dn_dv, ErrStat, ErrMsg) + CALL seabed_normal_velocity_gradient(model, q(ix), q(iy), q(iz), v(ix:iz), i, dn_dv, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN BLOCK INTEGER :: rr, cc @@ -7251,7 +7259,7 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q ! a level floor has dn_dv = (0, 0, d): skip its structural zeros IF (cc < 3 .AND. .NOT. (ABS(dn_dv(cc)) > CD_ZERO)) CYCLE CALL scatter_scalar_band(jac_v_band, model%free_map_work, kl, ku, ix + rr - 1, ix + cc - 1, & - mu_c*dn_dv(cc)*dfc(rr), ErrStat, ErrMsg) + mu_c*dn_dv(cc)*dfc(rr), ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END DO END DO @@ -7269,39 +7277,39 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q CALL extract_element_state(model, e, q, v, idx, q2, v2) IF (model%has_damping) THEN CALL CD_Axial_Damping_Element_Load(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & - model%ba_dyn(e), f2, jq2, jv2, ErrStat, ErrMsg, & + model%ba_dyn(e), f2, jq2, jv2, ErrStat, ErrMsg(1:lk), & l0_dot=model%l0_dot(e), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END IF IF (model%has_viscoelastic) THEN IF (model%ve_mode(e) /= 0) THEN - CALL model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrMsg) + CALL model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL CD_Viscoelastic_Element_Load(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & ea_d_eff, ea_1_eff, model%ve_ba(e), & model%ve_ba_d(e), model%ve_dl_1(e), model%ve_dt, & - f2, jq2, jv2, ErrStat, ErrMsg) + f2, jq2, jv2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END IF END IF IF (model%has_syrope) THEN IF (model%syrope_is(e)) THEN - CALL model_syrope_element(model, e, q2, v2, f2, jq2, jv2, syr_tm, syr_ds, ErrStat, ErrMsg) + CALL model_syrope_element(model, e, q2, v2, f2, jq2, jv2, syr_tm, syr_ds, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END IF END IF @@ -7311,13 +7319,13 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q CALL CD_Morison_Drag_Element_Load(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & fluid2(:, 1), fluid2(:, 2), wl2(1), wl2(2), model%drag_rho, & model%drag_diameter_elem(e), model%drag_cdn_elem(e), & - model%drag_cdt_elem(e), f2, jq2, jv2, ErrStat, ErrMsg, & + model%drag_cdt_elem(e), f2, jq2, jv2, ErrStat, ErrMsg(1:lk), & inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN - CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_v_band, model%free_map_work, kl, ku, idx, jv2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END IF IF (model%has_froude_krylov) THEN @@ -7326,11 +7334,11 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q CALL CD_Froude_Krylov_Element_Load(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & accel2(:, 1), accel2(:, 2), wl2(1), wl2(2), model%fk_rho, & model%fk_diameter_elem(e), model%fk_can_elem(e), & - model%fk_cat_elem(e), f2, jq2, jv2, ErrStat, ErrMsg, & + model%fk_cat_elem(e), f2, jq2, jv2, ErrStat, ErrMsg(1:lk), & inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN ! jv2 is identically zero (a velocity-independent load), and adding zeros changes no ! entry of a band that starts at +0 and only accumulates: its scatter is skipped. The @@ -7341,11 +7349,11 @@ SUBROUTINE model_contributor_load_banded(model, q, v, free, kl, ku, force, jac_q CALL extract_nodal_scalar(model%buoyancy_waterline_z, model, e, wl2) CALL CD_Buoyancy_Recovery_Element_Load(q2(1:3), q2(4:6), model%l0(e), wl2(1), wl2(2), & model%buoyancy_rho, model%buoyancy_diameter_elem(e), & - model%buoyancy_gravity, f2, jq2, jv2, ErrStat, ErrMsg, & + model%buoyancy_gravity, f2, jq2, jv2, ErrStat, ErrMsg(1:lk), & inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) - CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(jac_q_band, model%free_map_work, kl, ku, idx, jq2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN ! jv2 is identically zero: no scatter (as for Froude-Krylov above) END IF @@ -7386,7 +7394,9 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node REAL(wp) :: d_fr(2) REAL(wp) :: q2(6), v2(6), f2(6), ea_d_eff, ea_1_eff, syr_tm, syr_ds, syr_jac(6, 6), syr_jac_v(6, 6) REAL(wp) :: fluid2(3, 2), accel2(3, 2), wl2(2) + INTEGER :: lk ! the kernels' share of ErrMsg (KERNEL_MSG_LEN) + lk = MIN(LEN(ErrMsg), KERNEL_MSG_LEN) force = CD_ZERO n = SIZE(q) ends = .FALSE. @@ -7430,7 +7440,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node ! sloped seabed: frictionless contact along the surface normal BLOCK REAL(wp) :: fvec(3), jac3(3, 3), gx, gy, curv(3) - CALL model_floor_gradient(model, q(ix), q(iy), z_floor, gx, gy, ErrStat, ErrMsg, curvature=curv) + CALL model_floor_gradient(model, q(ix), q(iy), z_floor, gx, gy, ErrStat, ErrMsg(1:lk), curvature=curv) IF (ErrStat /= CD_MODEL_OK) RETURN IF (ABS(gx) > CD_ZERO .OR. ABS(gy) > CD_ZERO .OR. ANY(ABS(curv) > CD_ZERO)) THEN CALL CD_Seabed_Normal_Contact(z_floor - q(iz), gx, gy, model%seabed_kn(i), fvec, jac3, curvature=curv) @@ -7456,7 +7466,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node BLOCK REAL(wp) :: vn, nvec(3) LOGICAL :: sloped - CALL node_contact_normal(model, q(ix), q(iy), q(iz), v(ix:iz), gap, vn, nvec, sloped, ErrStat, ErrMsg) + CALL node_contact_normal(model, q(ix), q(iy), q(iz), v(ix:iz), gap, vn, nvec, sloped, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL seabed_normal_damping_terms(gap, vn, model%seabed_cn(i), damp_force, damp_dgap, damp_dvz) IF (sloped) THEN @@ -7474,7 +7484,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node ix = 3*i - 2 iy = 3*i - 1 iz = 3*i - normal = seabed_normal_reaction(model, q(ix), q(iy), q(iz), v(ix:iz), i, ErrStat, ErrMsg) + normal = seabed_normal_reaction(model, q(ix), q(iy), q(iz), v(ix:iz), i, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN IF (normal <= CD_ZERO) CYCLE d_fr(1) = q(ix) - model%fr_anchor(1, i) @@ -7501,19 +7511,19 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node IF (ends) idx = [(slot(idx(i)), i=1, 6)] IF (model%has_damping) THEN CALL CD_Axial_Damping_Element_Force(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & - model%ba_dyn(e), f2, ErrStat, ErrMsg, & + model%ba_dyn(e), f2, ErrStat, ErrMsg(1:lk), & l0_dot=model%l0_dot(e), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) END IF IF (model%has_viscoelastic) THEN IF (model%ve_mode(e) /= 0) THEN - CALL model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrMsg) + CALL model_viscoelastic_coeffs(model, e, ea_d_eff, ea_1_eff, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL CD_Viscoelastic_Element_Force(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & ea_d_eff, ea_1_eff, model%ve_ba(e), & model%ve_ba_d(e), model%ve_dl_1(e), model%ve_dt, & - f2, ErrStat, ErrMsg) + f2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) IF (PRESENT(law_tension)) law_tension(e) = element_law_tension() @@ -7522,7 +7532,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node END IF IF (model%has_syrope) THEN IF (model%syrope_is(e)) THEN - CALL model_syrope_element(model, e, q2, v2, f2, syr_jac, syr_jac_v, syr_tm, syr_ds, ErrStat, ErrMsg) + CALL model_syrope_element(model, e, q2, v2, f2, syr_jac, syr_jac_v, syr_tm, syr_ds, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN CALL scatter_element_vector(force, idx, f2) IF (PRESENT(law_tension)) law_tension(e) = element_law_tension() @@ -7536,7 +7546,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node CALL CD_Morison_Drag_Element_Force(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & fluid2(:, 1), fluid2(:, 2), wl2(1), wl2(2), model%drag_rho, & model%drag_diameter_elem(e), model%drag_cdn_elem(e), & - model%drag_cdt_elem(e), f2, ErrStat, ErrMsg, inputs_validated=.TRUE.) + model%drag_cdt_elem(e), f2, ErrStat, ErrMsg(1:lk), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) END IF @@ -7546,7 +7556,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node CALL CD_Froude_Krylov_Element_Force(q2(1:3), q2(4:6), v2(1:3), v2(4:6), model%l0(e), & accel2(:, 1), accel2(:, 2), wl2(1), wl2(2), model%fk_rho, & model%fk_diameter_elem(e), model%fk_can_elem(e), & - model%fk_cat_elem(e), f2, ErrStat, ErrMsg, inputs_validated=.TRUE.) + model%fk_cat_elem(e), f2, ErrStat, ErrMsg(1:lk), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) END IF @@ -7554,7 +7564,7 @@ SUBROUTINE model_contributor_force(model, q, v, force, ErrStat, ErrMsg, end_node CALL extract_nodal_scalar(model%buoyancy_waterline_z, model, e, wl2) CALL CD_Buoyancy_Recovery_Element_Force(q2(1:3), q2(4:6), model%l0(e), wl2(1), wl2(2), & model%buoyancy_rho, model%buoyancy_diameter_elem(e), & - model%buoyancy_gravity, f2, ErrStat, ErrMsg, & + model%buoyancy_gravity, f2, ErrStat, ErrMsg(1:lk), & inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(force, idx, f2) @@ -7859,7 +7869,7 @@ SUBROUTINE model_floor_gradient(model, x, y, z_floor, dfdx, dfdy, ErrStat, ErrMs CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp), INTENT(OUT), OPTIONAL :: curvature(3) INTEGER :: es - CHARACTER(1024) :: em + CHARACTER(160) :: em CALL CD_Bathymetry_Floor_Gradient(model%bathymetry, x, y, z_floor, dfdx, dfdy, es, em, & crease_curvature=curvature) IF (es == CD_BATHY_OK) THEN @@ -7884,7 +7894,7 @@ SUBROUTINE node_contact_normal(model, x, y, z, vel, gap_n, vn, nvec, sloped, Err CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es REAL(wp) :: z_floor, dfdx, dfdy, sfac - CHARACTER(1024) :: em + CHARACTER(160) :: em ErrStat = CD_MODEL_OK ErrMsg = '' @@ -8134,7 +8144,9 @@ SUBROUTINE model_added_mass_banded(model, q, accel, free, kl, ku, M_add_a, M_add INTEGER :: e, i, n, ldab, idx(6) REAL(wp) :: q2(6), a2(6), wl2(2), m2(6, 6), dm2(6, 6), ma2(6), le LOGICAL :: want_tangent, zero_accel, free_map_ready + INTEGER :: lk ! the kernels' share of ErrMsg (KERNEL_MSG_LEN) + lk = MIN(LEN(ErrMsg), KERNEL_MSG_LEN) ErrStat = CD_MODEL_OK ErrMsg = '' want_tangent = .TRUE. @@ -8204,14 +8216,14 @@ SUBROUTINE model_added_mass_banded(model, q, accel, free, kl, ku, M_add_a, M_add CALL CD_Added_Mass_Element_Matrix(q2(1:3), q2(4:6), le, wl2(1), wl2(2), & model%added_mass_rho, model%added_mass_diameter_elem(e), & model%added_mass_can_elem(e), model%added_mass_cat_elem(e), & - m2, ErrStat, ErrMsg, inputs_validated=.TRUE.) + m2, ErrStat, ErrMsg(1:lk), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN ma2 = CD_ZERO ELSE CALL CD_Added_Mass_Element(q2(1:3), q2(4:6), a2(1:3), a2(4:6), le, wl2(1), wl2(2), & model%added_mass_rho, model%added_mass_diameter_elem(e), & model%added_mass_can_elem(e), model%added_mass_cat_elem(e), & - m2, dm2, ErrStat, ErrMsg, inputs_validated=.TRUE.) + m2, dm2, ErrStat, ErrMsg(1:lk), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN ma2 = MATMUL(m2, a2) END IF @@ -8219,15 +8231,15 @@ SUBROUTINE model_added_mass_banded(model, q, accel, free, kl, ku, M_add_a, M_add CALL CD_Added_Mass_Element_Force(q2(1:3), q2(4:6), a2(1:3), a2(4:6), le, wl2(1), wl2(2), & model%added_mass_rho, model%added_mass_diameter_elem(e), & model%added_mass_can_elem(e), model%added_mass_cat_elem(e), & - ma2, ErrStat, ErrMsg, inputs_validated=.TRUE.) + ma2, ErrStat, ErrMsg(1:lk), inputs_validated=.TRUE.) IF (ErrStat /= 0) RETURN END IF CALL scatter_element_vector(M_add_a, idx, ma2) IF (want_tangent) THEN - CALL scatter_element_matrix_band(M_add_band, model%free_map_work, kl, ku, idx, m2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(M_add_band, model%free_map_work, kl, ku, idx, m2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN IF (.NOT. zero_accel) THEN - CALL scatter_element_matrix_band(dMa_a_dq_band, model%free_map_work, kl, ku, idx, dm2, ErrStat, ErrMsg) + CALL scatter_element_matrix_band(dMa_a_dq_band, model%free_map_work, kl, ku, idx, dm2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN END IF END IF @@ -8270,7 +8282,10 @@ SUBROUTINE model_added_mass_force(model, q, accel, M_add_a, ErrStat, ErrMsg) INTEGER :: e, idx(6) REAL(wp) :: q2(6), a2(6), wl2(2), ma2(6) + INTEGER :: lk ! the kernels' share of ErrMsg (KERNEL_MSG_LEN) + lk = MIN(LEN(ErrMsg), KERNEL_MSG_LEN) + ErrMsg = '' ! the part past lk stays blank when a kernel fails M_add_a = CD_ZERO DO e = 1, model%n_elem CALL extract_element_positions(model, e, q, idx, q2) @@ -8279,7 +8294,7 @@ SUBROUTINE model_added_mass_force(model, q, accel, M_add_a, ErrStat, ErrMsg) CALL CD_Added_Mass_Element_Force(q2(1:3), q2(4:6), a2(1:3), a2(4:6), model%l0(e), wl2(1), wl2(2), & model%added_mass_rho, model%added_mass_diameter_elem(e), & model%added_mass_can_elem(e), model%added_mass_cat_elem(e), & - ma2, ErrStat, ErrMsg) + ma2, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= 0) RETURN CALL scatter_element_vector(M_add_a, idx, ma2) END DO diff --git a/src/CableDyn_RangeOutput.f90 b/src/CableDyn_RangeOutput.f90 index 18c9247c..53059acd 100644 --- a/src/CableDyn_RangeOutput.f90 +++ b/src/CableDyn_RangeOutput.f90 @@ -203,7 +203,7 @@ SUBROUTINE CD_Range_Clearance(set, r, clearance, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: j, es REAL(wp) :: zf - CHARACTER(1024) :: em + CHARACTER(160) :: em ErrStat = CD_RANGE_OK ErrMsg = '' diff --git a/src/CableDyn_Static.f90 b/src/CableDyn_Static.f90 index d6a677f7..e3e1af9d 100644 --- a/src/CableDyn_Static.f90 +++ b/src/CableDyn_Static.f90 @@ -807,7 +807,7 @@ SUBROUTINE eval_energy(qe, energy, magnitude) REAL(wp), INTENT(OUT) :: energy, magnitude INTEGER :: e, a, b, i, es_e REAL(wp) :: ell, eps, w_el, zf, gx, gy, g, s, pot, bl - CHARACTER(1024) :: em_e + CHARACTER(120) :: em_e energy = CD_ZERO magnitude = CD_ZERO From 5cd8886e6f5699730a5c36139cdd6d9c215781aa Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Fri, 16 Oct 2026 21:00:06 +0900 Subject: [PATCH 04/11] fix: name the rejecting route and keep the strain note The rejection of deck waves or current on the still-water routes listed the C API and single-turbine OpenFAST, which never reach it, and told a FAST.Farm user to let the host supply the fluid. It now names the route that rejects the deck: a standalone mixed EI=0/finite-EI deck is told to remove the OPTION, use a single-family deck, or couple the deck to OpenFAST with SeaState; a FAST.Farm deck is told the farm runs in still water and to remove the OPTION. The troubleshooting rows, the changelog and the driver test follow. The friction-anchor mapping, run twice per step, now gives its per-node seabed query only a short share of the caller's message buffer, as the load assembly does. A cable whose notes ended with the omission marker in its 1024-character buffer lost the static strain note when the notes were copied into the 2048-character line summary. A note that fits now goes before the marker, which stays last. Signed-off-by: Jae Hoon Seo --- CHANGELOG.md | 6 +++-- CMakeLists.txt | 4 +-- doc/troubleshooting.rst | 16 +++++++----- src/CableDyn_DeckDriver.f90 | 51 ++++++++++++++++++++++++++----------- src/CableDyn_Model.f90 | 5 ++-- 5 files changed, 55 insertions(+), 27 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index c5d6ee36..5da378e2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -629,8 +629,10 @@ All notable changes to CableDyn are recorded in this file. The format follows finite-EI cable ending on a `Connect`/`Free`/`Coupled` point, or on a Coupled End A that a deck with `Connect`/`Free` points cannot drive (it would need `motionFile` coupling), names the point and what the route supports; the "this coupled mode runs the mooring in - STILL WATER" message of a mixed deck with waves or current no longer implies a coupled run and - says which routes evaluate the deck fluid; an anchor below the seabed by more than the + STILL WATER" rejection of deck waves or current now names the route that rejects it (a + standalone mixed deck, which is not coupled, or FAST.Farm) and gives that route's remedy (an + all-`EI = 0` or all-finite-EI deck, or OpenFAST with SeaState; in FAST.Farm, removing the + OPTION); an anchor below the seabed by more than the tolerance gives the depth, the tolerance rule, and the Z to use. These messages change no acceptance rule. - The development environment (`environment.yml`) excludes OpenBLAS 0.3.34, which caused the diff --git a/CMakeLists.txt b/CMakeLists.txt index 7b616bcc..a4c6c0e6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2238,8 +2238,8 @@ cabledyn_msg_test(pliant_connect_end_b msg_pliant_connect_end_b.dat 1 "finite-EI LINE 1 in a mixed-topology deck needs a Fixed End B;End B is POINT 2 .connect.;Anchor the cable on a Fixed point" "") cabledyn_msg_test(mixed_current msg_mixed_current.dat 1 - "the deck current OPTION is not supported on this route;a standalone mixed deck;runs the mooring in STILL WATER" - "this coupled mode") + "the deck current OPTION is not supported for a standalone mixed EI=0/finite-EI deck;runs the mooring in STILL WATER;couple the deck to OpenFAST .CompMooring = 5. with SeaState" + "this coupled mode;the C API;FAST.Farm") cabledyn_msg_test(mixed_connect_coupled_cable msg_mixed_connect_coupled_cable.dat 1 "finite-EI LINE 3: a Coupled/Vessel End A .POINT 1. would need motionFile coupling to drive it;remove the Connect/Free points;held still .that route takes no motionFile either." "is driven by a motionFile") diff --git a/doc/troubleshooting.rst b/doc/troubleshooting.rst index 493b06b4..cc83934a 100644 --- a/doc/troubleshooting.rst +++ b/doc/troubleshooting.rst @@ -284,12 +284,16 @@ Model data deck (the ``EI = 0`` lines on the Coupled point directly): a host (OpenFAST ``CompMooring = 5`` or the C API) drives its Coupled points, and the standalone driver runs it with them held still (that route takes no ``motionFile`` either). - * - ``the deck current OPTION is not supported on this route`` / ``the deck waves OPTION ...`` - - a mixed ``EI = 0``/finite-EI deck (run standalone, through the C API, OpenFAST or - FAST.Farm) runs the mooring in still water: no ambient fluid field covers its span, and - a coupled host supplies its own waves and current. Remove the ``waves``/``current`` - OPTION, run a deck whose lines are all ``EI = 0`` or all finite-EI (those standalone - routes evaluate the deck waves and current), or let the OpenFAST host supply them. + * - ``the deck current OPTION is not supported for a standalone mixed EI=0/finite-EI deck`` / + ``the deck waves OPTION ...`` + - the standalone driver runs a mixed ``EI = 0``/finite-EI deck in still water: no ambient + fluid field covers its span. Remove the ``waves``/``current`` OPTION, run a deck whose + lines are all ``EI = 0`` or all finite-EI (those standalone routes evaluate the deck waves + and current), or couple the deck to OpenFAST (``CompMooring = 5``) with SeaState, which + supplies them. + * - ``the deck current OPTION is not supported in FAST.Farm`` / ``the deck waves OPTION ...`` + - the shared mooring of a FAST.Farm farm runs in still water (no fluid field spans the + farm). Remove the ``waves``/``current`` OPTION. * - ``POINT (Fixed) lies below the seabed ... by m, more than the m seabed tolerance`` - a Fixed anchor within ``max(1 mm, 1e-5 |z_seabed|)`` of the seabed (``-WtrDpth``, or the diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index 86917936..57c03b42 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -6263,21 +6263,31 @@ SUBROUTINE CD_Init_Deck_Aggregate(deck_path, dt, agg, ErrStat, ErrMsg, env_gravi END IF IF (PRESENT(forbid_deck_ambient)) THEN IF (forbid_deck_ambient) THEN + ! The two callers that forbid deck ambient fluid: the FAST.Farm shell (n_turbines >= 1) and + ! the standalone runner of a mixed EI=0/finite-EI deck. Each gets the advice of its route. IF (opts%has_wave) THEN - CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck waves OPTION is not supported on this '// & - 'route: a host-driven or mixed EI=0/finite-EI deck (a standalone mixed deck, the C API, '// & - 'OpenFAST or FAST.Farm) runs the mooring in STILL WATER, because no ambient fluid field covers '// & - 'its span. '// & - 'Remove the waves OPTION, or run a deck whose lines are all EI=0 or all finite-EI (those '// & - 'standalone routes evaluate the deck waves), or let the OpenFAST host supply them'); RETURN + IF (nturb > 0) THEN + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck waves OPTION is not supported in '// & + 'FAST.Farm: the shared mooring of a farm runs in STILL WATER (no fluid field spans the '// & + 'farm). Remove the waves OPTION'); RETURN + END IF + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck waves OPTION is not supported for a '// & + 'standalone mixed EI=0/finite-EI deck: this route runs the mooring in STILL WATER, because '// & + 'no ambient fluid field covers its span. Remove the waves OPTION, run a deck whose lines are '// & + 'all EI=0 or all finite-EI (those standalone routes evaluate the deck waves), or couple the '// & + 'deck to OpenFAST (CompMooring = 5) with SeaState, which supplies the waves'); RETURN END IF IF (opts%has_current .OR. opts%has_current_profile) THEN - CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck current OPTION is not supported on this '// & - 'route: a host-driven or mixed EI=0/finite-EI deck (a standalone mixed deck, the C API, '// & - 'OpenFAST or FAST.Farm) runs the mooring in STILL WATER, because no ambient fluid field covers '// & - 'its span. '// & - 'Remove the current OPTION, or run a deck whose lines are all EI=0 or all finite-EI (those '// & - 'standalone routes evaluate the deck current), or let the OpenFAST host supply it'); RETURN + IF (nturb > 0) THEN + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck current OPTION is not supported in '// & + 'FAST.Farm: the shared mooring of a farm runs in STILL WATER (no fluid field spans the '// & + 'farm). Remove the current OPTION'); RETURN + END IF + CALL fail(ErrStat, ErrMsg, 'CD_Init_Deck_Aggregate: the deck current OPTION is not supported for a '// & + 'standalone mixed EI=0/finite-EI deck: this route runs the mooring in STILL WATER, because '// & + 'no ambient fluid field covers its span. Remove the current OPTION, run a deck whose lines are '// & + 'all EI=0 or all finite-EI (those standalone routes evaluate the deck current), or couple the '// & + 'deck to OpenFAST (CompMooring = 5) with SeaState, which supplies the current'); RETURN END IF END IF END IF @@ -9637,16 +9647,27 @@ END SUBROUTINE warn_coarse_sections SUBROUTINE append_note_line(buffer, text) !! Append one initialisation note as a new text line of buffer. A note that does not fit !! with room left for the omission marker is replaced by the marker, which ends the buffer, - !! so no note is ever cut short. + !! so no note is ever cut short. Notes that ended with the marker in a shorter buffer (a + !! cable's notes copied into a line summary) still take a note that fits: it goes before + !! the marker, which stays last. CHARACTER(*), INTENT(INOUT) :: buffer CHARACTER(*), INTENT(IN) :: text CHARACTER(*), PARAMETER :: OMITTED = 'further initialisation notes omitted' - INTEGER :: n + INTEGER :: n, nb IF (LEN_TRIM(text) == 0) RETURN n = LEN_TRIM(buffer) IF (n > 0) THEN IF (n >= LEN(OMITTED)) THEN - IF (buffer(n - LEN(OMITTED) + 1:n) == OMITTED) RETURN + IF (buffer(n - LEN(OMITTED) + 1:n) == OMITTED) THEN + nb = MAX(0, n - LEN(OMITTED) - 1) ! the notes before the marker and its line break + IF (nb > 0) THEN + IF (nb + 1 + LEN_TRIM(text) + 1 + LEN(OMITTED) <= LEN(buffer)) & + buffer = buffer(1:nb)//NEW_LINE('a')//TRIM(text)//NEW_LINE('a')//OMITTED + ELSE IF (LEN_TRIM(text) + 1 + LEN(OMITTED) <= LEN(buffer)) THEN + buffer = TRIM(text)//NEW_LINE('a')//OMITTED + END IF + RETURN + END IF END IF IF (n + 1 + LEN_TRIM(text) + 1 + LEN(OMITTED) <= LEN(buffer)) THEN buffer = buffer(1:n)//NEW_LINE('a')//TRIM(text) diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index 2f37fe91..a12886de 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -3293,13 +3293,14 @@ SUBROUTINE mapped_friction_anchors(model, q, v, commit, ErrStat, ErrMsg) LOGICAL, INTENT(IN) :: commit INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg - INTEGER :: i, ix + INTEGER :: i, ix, lk REAL(wp) :: normal, cap, d(2), dlen, k, mu_d, q_d, gq_d(2) ErrStat = CD_MODEL_OK ErrMsg = '' + lk = MIN(LEN(ErrMsg), KERNEL_MSG_LEN) ! the per-node query's share of ErrMsg DO i = 1, SIZE(model%fr_anchor, 2) ix = 3*i - 2 - normal = seabed_normal_reaction(model, q(ix), q(ix + 1), q(ix + 2), v(ix:ix + 2), i, ErrStat, ErrMsg) + normal = seabed_normal_reaction(model, q(ix), q(ix + 1), q(ix + 2), v(ix:ix + 2), i, ErrStat, ErrMsg(1:lk)) IF (ErrStat /= CD_MODEL_OK) RETURN IF (.NOT. commit) CYCLE IF (model%seabed_friction_aniso) THEN From 0bb00fb17704bd88c6cdfc0eb0a290cf2b5f5fc8 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Sat, 17 Oct 2026 21:11:20 +0900 Subject: [PATCH 05/11] fix: whole messages on the new recovery and pinned-rod paths Message buffers added since the branch point that can receive a longer message than they hold now hold it whole: - the node-value and segment-tension recovery of a finite-EI cable (node channels and .t.out rows), whose element failure carries the recovery prefix and a 200-character element message, and the node recovery of a range-graph sample, which gets its own buffer while the per-element curvature samples keep their short one; - the anchor force of an EI=0 line (anchor uplift channels), which carries the end-force recovery's load-assembly message; - the host wrench of a pinned rod, which carries the mooring system's coupled-motion and acceleration-derivative messages; - the exact-curvature query of the OpenFAST Hermite module and the step audit of an EI=0 line (1024, as their neighbours). The per-element law tensions of the step audit hold the kernels' bound (KERNEL_MSG_LEN). Buffers on per-station or per-node paths that already hold every message they receive (rod contact reach and waterplane estimate, Hermite node recovery kernels) are unchanged. Signed-off-by: Jae Hoon Seo --- src/CableDyn_DeckDriver.f90 | 13 +++++++------ src/CableDyn_Model.f90 | 4 ++-- src/CableDyn_OpenFAST_HermiteFMF.f90 | 2 +- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index 57c03b42..b6b50f35 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -24717,7 +24717,7 @@ SUBROUTINE CD_Rod_HostWrench(system, rt, loads, k, force, moment, ErrStat, ErrMs INTEGER :: ir, base, j, n, es REAL(wp) :: arm(3), f_end(3, 2), f_env(3), m_env(3), f_sb(3), m_sb(3), added6(6, 6), drag6(6, 6) REAL(wp) :: dv(6, 6), acc6(6), ig(3, 3), mc(3), acc(3), alpha(3), pin_host(9) - CHARACTER(160) :: em + CHARACTER(1024) :: em force = CD_ZERO moment = CD_ZERO @@ -31040,7 +31040,7 @@ SUBROUTINE line_model_anchor_force(model, lo, val, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg REAL(wp) :: f_first(3), f_last(3) INTEGER :: es - CHARACTER(160) :: em + CHARACTER(1024) :: em val = CD_ZERO ErrStat = CD_DECKDRV_OK @@ -32082,6 +32082,7 @@ SUBROUTINE range_sample_cable(cable, rl, ErrStat, ErrMsg) INTEGER :: nn, ne, e, j, k, inode, es REAL(wp) :: curv, bend CHARACTER(200) :: em ! per-element curvature messages (at most 55 characters) + CHARACTER(1024) :: em_rec ! the one node-value recovery message of the sample ErrStat = CD_DECKDRV_OK ErrMsg = '' @@ -32110,11 +32111,11 @@ SUBROUTINE range_sample_cable(cable, rl, ErrStat, ErrMsg) ! equilibrium node values, one pass over the elements straight into the public-order rows ! (internal node i is public node nn + 1 - i); the segment tensions (internal order) stay ! in rl%ten_e for the .t.out row - CALL CD_HermiteCable_Dyn_Node_Recovery(cable%line, es, em, tension=rl%val(CD_RQ_TENSION, nn:1:-1), & + CALL CD_HermiteCable_Dyn_Node_Recovery(cable%line, es, em_rec, tension=rl%val(CD_RQ_TENSION, nn:1:-1), & curvature=rl%val(CD_RQ_CURVATURE, nn:1:-1), & bend_moment=rl%val(CD_RQ_BEND, nn:1:-1), segment_tension=rl%ten_e) IF (es /= CD_HCDYN_OK) THEN - CALL fail_solve(ErrStat, ErrMsg, 'range-graph node-value recovery failed: '//TRIM(em)); RETURN + CALL fail_solve(ErrStat, ErrMsg, 'range-graph node-value recovery failed: '//TRIM(em_rec)); RETURN END IF ELSE CALL range_sample_cable_element(ErrStat, ErrMsg) @@ -33154,7 +33155,7 @@ SUBROUTINE cable_node_values(cable, inode, tension, curvature, bend_moment, ErrS INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' CALL CD_HermiteCable_Dyn_Node_Values(cable%line, inode, tension, curvature, bend_moment, es, em) IF (es /= CD_HCDYN_OK) CALL fail_solve(ErrStat, ErrMsg, 'finite-EI node-value recovery failed: '//TRIM(em)) @@ -33170,7 +33171,7 @@ SUBROUTINE cable_segment_tensions(cable, tension, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: ne, e, es - CHARACTER(200) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK; ErrMsg = '' ne = cable%line%ne IF (cable%line%output_element_recovery) THEN diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index a12886de..2b97b4a4 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -5103,7 +5103,7 @@ SUBROUTINE model_law_tensions(model, tension, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(160) :: em + CHARACTER(KERNEL_MSG_LEN) :: em ! a per-element law message (the kernels' bound) ErrStat = CD_MODEL_OK ErrMsg = '' @@ -5802,7 +5802,7 @@ SUBROUTINE CD_Audit_Model_Step(model, time, dt, new_spike) REAL(wp) :: d(3), ell, strain, u(3), c, line_max, tn, h REAL(wp), ALLOCATABLE :: law(:) LOGICAL :: fresh, laws - CHARACTER(160) :: em + CHARACTER(1024) :: em new_spike = .FALSE. IF (.NOT. model%initialized .OR. model%n_elem < 1) RETURN diff --git a/src/CableDyn_OpenFAST_HermiteFMF.f90 b/src/CableDyn_OpenFAST_HermiteFMF.f90 index 3f8bb610..ca878682 100644 --- a/src/CableDyn_OpenFAST_HermiteFMF.f90 +++ b/src/CableDyn_OpenFAST_HermiteFMF.f90 @@ -1435,7 +1435,7 @@ SUBROUTINE CD_HFMF_Curvature_Exact(self, curv_out, ErrStat, ErrMsg) INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN ErrStat = CD_HFMF_BADINPUT; ErrMsg = 'CD_HFMF_Curvature_Exact: module not initialised'; RETURN From 762a86efba3207dd3d2db46990e5e7a53916e804 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 07:39:59 +0900 Subject: [PATCH 06/11] fix: size the sub-stepping message buffers The rotation- and snap-resolved sub-stepping merged from dev kept a plain sub-step's message in 300 characters, the law tensions of sub_tensions in 160, and the viscoelastic coefficients of segment_wave_stiffness in 200. A plain step's message (the tensile qualification failure) runs to several hundred characters and a law tension message with its prefix to about 250, so they now take 1024 characters, as the recovery rungs do; the per-element coefficient message takes KERNEL_MSG_LEN, the kernels' bound. The messages are discarded on these paths, so no output changes. Signed-off-by: Jae Hoon Seo --- src/CableDyn_Model.f90 | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index 2b97b4a4..12414a5f 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -2121,7 +2121,7 @@ SUBROUTINE run_substeps(n, ok_run) INTEGER :: k, it_k, es_k LOGICAL :: conv_k, stall_k REAL(wp) :: h - CHARACTER(300) :: em_k + CHARACTER(1024) :: em_k ! a plain step's message (discarded: the step falls back) CALL sub_load(model, 1) h = dt/REAL(n, wp) ok_run = .TRUE. @@ -2391,7 +2391,7 @@ SUBROUTINE sub_tensions(model, tension) REAL(wp), INTENT(OUT) :: tension(:) INTEGER :: e, na, nb, es REAL(wp) :: strain - CHARACTER(160) :: em + CHARACTER(1024) :: em ! model_law_tensions: a law message with its prefix DO e = 1, model%n_elem na = model%elem_conn(1, e) nb = model%elem_conn(2, e) @@ -2445,7 +2445,7 @@ REAL(wp) FUNCTION segment_wave_stiffness(model, e, tension) RESULT(stiff) REAL(wp), INTENT(IN) :: tension REAL(wp) :: ea_d_eff, ea_1_eff INTEGER :: es - CHARACTER(200) :: em + CHARACTER(KERNEL_MSG_LEN) :: em ! a per-element law message (the kernels' bound) stiff = model%ea_dyn(e) IF (stiff > CD_ZERO) RETURN stiff = model%ea(e) From 3cdec48a6460a9378b98abbeeeb95a04cb414c23 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 07:54:34 +0900 Subject: [PATCH 07/11] docs(dynamic): state where the condensed junction tangent is asymmetric Signed-off-by: Jae Hoon Seo --- src/CableDyn_Dynamic.f90 | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/CableDyn_Dynamic.f90 b/src/CableDyn_Dynamic.f90 index 4b753adf..c5cb4fb6 100644 --- a/src/CableDyn_Dynamic.f90 +++ b/src/CableDyn_Dynamic.f90 @@ -1431,9 +1431,10 @@ SUBROUTINE end_junction_data() !! end tangent K_E = dR_E/dq_E|_{R_F = 0} (the implicit-function derivative the outer !! junction Newton needs), by forward differences of the step residual: column j of !! S_FE/S_EE from a perturbation of end DOF j, X_j = S_FF^-1 S_FE e_j with the step's - !! factored effective band, and K = S_EE - S_EF X with S_EF taken as S_FE^T (the effective - !! tangent's mass, stiffness and drag-velocity blocks are symmetric; the small asymmetric - !! load terms only slow the outer Newton, never its converged result). A step that + !! factored effective band, and K = S_EE - S_EF X with S_EF taken as S_FE^T (the mass, + !! material-stiffness and drag-velocity blocks are symmetric; the asymmetric parts, from + !! the load terms and, on EI = 0 lines, the force blend's release cap and dashpot share, + !! only slow the outer Newton, never its converged result). A step that !! converged from its warm start without factoring keeps the previous map and tangent !! (the end moved by a Newton correction of the same step); a cold step without a factor !! factors the tangent at qk once. From 3526199d1c3ac017668d274c81aaef5539138508 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 09:13:05 +0900 Subject: [PATCH 08/11] fix: whole messages on the active-tension paths The active tension of finite-EI cables merged from dev added message buffers that could cut a message short: the committed force and acceleration of a cable received a length-rebuild message of up to about 234 characters in 200, the step-start load and committed-length messages of an EI = 0 line went into 160, and the control take-back, the finite-section mesh of a CONTROL row and the segment-length update of the Hermite OpenFAST module held 512 and 300. These cold-path buffers now take 1024 characters; the buffers that receive a kernel message directly (distributed-load assembly and seabed stiffness at the committed or sub-step lengths) take KERNEL_MSG_LEN, the kernels' bound. No output changes. Signed-off-by: Jae Hoon Seo --- src/CableDyn_DeckDriver.f90 | 2 +- src/CableDyn_HermiteCableDynamic.f90 | 4 ++-- src/CableDyn_Model.f90 | 9 +++++---- src/CableDyn_OpenFAST_Aggregate.f90 | 2 +- src/CableDyn_OpenFAST_HermiteFMF.f90 | 2 +- 5 files changed, 10 insertions(+), 9 deletions(-) diff --git a/src/CableDyn_DeckDriver.f90 b/src/CableDyn_DeckDriver.f90 index b6b50f35..a72d2fac 100644 --- a/src/CableDyn_DeckDriver.f90 +++ b/src/CableDyn_DeckDriver.f90 @@ -6825,7 +6825,7 @@ SUBROUTINE build_aggregate_control_table(ctrls, lines, points, rods, sections, t REAL(wp), ALLOCATABLE :: l0_deck(:), ea(:), mpl(:), diam(:), ei(:), gas(:), gj(:), i_rt(:), i_rn(:) REAL(wp) :: span CHARACTER(24) :: lid - CHARACTER(512) :: em + CHARACTER(1024) :: em ErrStat = CD_DECKDRV_OK ErrMsg = '' diff --git a/src/CableDyn_HermiteCableDynamic.f90 b/src/CableDyn_HermiteCableDynamic.f90 index 76d4d608..2fe386f7 100644 --- a/src/CableDyn_HermiteCableDynamic.f90 +++ b/src/CableDyn_HermiteCableDynamic.f90 @@ -1557,7 +1557,7 @@ SUBROUTINE assemble_committed_force(model, ErrStat, ErrMsg) CHARACTER(*), INTENT(OUT) :: ErrMsg TYPE(committed_lengths_aside) :: aside INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em CALL enter_committed_lengths(model, aside, es, em) IF (es /= CD_HCDYN_OK) THEN @@ -1579,7 +1579,7 @@ SUBROUTINE solve_committed_acceleration(model, ErrStat, ErrMsg, pres_dofs, pres_ REAL(wp), INTENT(IN), OPTIONAL :: pres_a(:) TYPE(committed_lengths_aside) :: aside INTEGER :: es - CHARACTER(200) :: em + CHARACTER(1024) :: em CALL enter_committed_lengths(model, aside, es, em) IF (es /= CD_HCDYN_OK) THEN diff --git a/src/CableDyn_Model.f90 b/src/CableDyn_Model.f90 index 12414a5f..8bb49c75 100644 --- a/src/CableDyn_Model.f90 +++ b/src/CableDyn_Model.f90 @@ -170,6 +170,7 @@ MODULE CableDyn_Model LOGICAL :: active = .FALSE. REAL(wp), ALLOCATABLE :: l0(:), l0_dot(:), f_ext(:), kn(:), cn(:) END TYPE model_lengths_aside + ! The per-element and per-node kernels of the load and added-mass assemblies write messages of ! at most 187 characters (Hydro, Damping, Viscoelastic, Syrope, bathymetry and band-scatter texts, ! with their prefixes) and blank their message on entry, also when inputs_validated skips their @@ -2035,7 +2036,7 @@ SUBROUTINE CD_Step_Model(model, dt, converged, stalled, n_iter, ErrStat, ErrMsg, BLOCK TYPE(model_lengths_aside) :: aside INTEGER :: es_c - CHARACTER(160) :: em_c + CHARACTER(1024) :: em_c ! without the loads nothing is rebuilt, so this cannot fail CALL enter_committed_lengths(model, aside, .FALSE., es_c, em_c) CALL sub_tensions_scratch(model, 0) @@ -2337,7 +2338,7 @@ SUBROUTINE sub_lengths_at(model, frac, ErrStat) REAL(wp) :: a, b INTEGER :: e, es LOGICAL :: moved - CHARACTER(160) :: em + CHARACTER(KERNEL_MSG_LEN) :: em ErrStat = CD_MODEL_OK moved = .FALSE. DO e = 1, model%n_elem @@ -2879,7 +2880,7 @@ SUBROUTINE step_start_load(es_s, em_s) !! committed lengths entered after a length change). INTEGER, INTENT(OUT) :: es_s CHARACTER(*), INTENT(OUT) :: em_s - CHARACTER(160) :: em_c + CHARACTER(1024) :: em_c es_s = CD_MODEL_OK em_s = '' IF (.NOT. (has_load .AND. model%cfg%force_blend)) THEN @@ -3202,7 +3203,7 @@ SUBROUTINE enter_committed_lengths(model, aside, loads, ErrStat, ErrMsg) REAL(wp), ALLOCATABLE :: f_c(:), kn_c(:) LOGICAL :: rebuild INTEGER :: es - CHARACTER(160) :: em + CHARACTER(KERNEL_MSG_LEN) :: em ErrStat = CD_MODEL_OK ErrMsg = '' diff --git a/src/CableDyn_OpenFAST_Aggregate.f90 b/src/CableDyn_OpenFAST_Aggregate.f90 index eb668d28..a7ffb3ba 100644 --- a/src/CableDyn_OpenFAST_Aggregate.f90 +++ b/src/CableDyn_OpenFAST_Aggregate.f90 @@ -1857,7 +1857,7 @@ SUBROUTINE take_back(last, msg) INTEGER, INTENT(IN) :: last CHARACTER(*), INTENT(IN) :: msg INTEGER :: r, es2 - CHARACTER(512) :: em2, em_undo + CHARACTER(1024) :: em2, em_undo em_undo = '' DO r = last, 1, -1 IF (self%ctrl_is_cable(r)) THEN diff --git a/src/CableDyn_OpenFAST_HermiteFMF.f90 b/src/CableDyn_OpenFAST_HermiteFMF.f90 index ca878682..3fde5015 100644 --- a/src/CableDyn_OpenFAST_HermiteFMF.f90 +++ b/src/CableDyn_OpenFAST_HermiteFMF.f90 @@ -1207,7 +1207,7 @@ SUBROUTINE CD_HFMF_Set_SegmentLength(self, elems, l0_new, l0_dot, ErrStat, ErrMs INTEGER, INTENT(OUT) :: ErrStat CHARACTER(*), INTENT(OUT) :: ErrMsg INTEGER :: es - CHARACTER(300) :: em + CHARACTER(1024) :: em ErrStat = CD_HFMF_OK; ErrMsg = '' IF (.NOT. self%initialized) THEN From 99fc28361b699c88aa4668c998aafb3d52ce66f5 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 09:37:59 +0900 Subject: [PATCH 09/11] fix: report the axial-damping failure of a controlled cable The axial damping of a finite-EI cable under active length control wrote its kernel message into em2 while the failure handler reports em_e, the per-element kernel buffer, so a non-finite damping force or Jacobian on a controlled line returned a blank or stale message. Both controlled branches now write em_e, as the uncontrolled ones do. A scan of every source file for an error report that names a different message variable than the calls before it finds no other case. Signed-off-by: Jae Hoon Seo --- src/CableDyn_HermiteCableDynamic.f90 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/CableDyn_HermiteCableDynamic.f90 b/src/CableDyn_HermiteCableDynamic.f90 index 2fe386f7..246dca11 100644 --- a/src/CableDyn_HermiteCableDynamic.f90 +++ b/src/CableDyn_HermiteCableDynamic.f90 @@ -6618,7 +6618,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta ve(7:9) = v_cfg(6*e + 1:6*e + 3); ve(10:12) = v_cfg(6*e + 4:6*e + 6) IF (want_tangent .AND. model%has_ctrl) THEN CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & - fdamp, kdq, kdv, es, em2, & + fdamp, kdq, kdv, es, em_e, & model%axial_quadrature_order, model%l0_dot(e)) ELSE IF (want_tangent) THEN CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & @@ -6626,7 +6626,7 @@ SUBROUTINE assemble_residual(model, q_cfg, v_cfg, t_eval, want_residual, want_ta model%axial_quadrature_order) ELSE IF (model%has_ctrl) THEN CALL CD_HermiteCable_Axial_Damping_Element(qe, ve, model%l0(e), model%BA(e), & - fdamp, ErrStat=es, ErrMsg=em2, & + fdamp, ErrStat=es, ErrMsg=em_e, & quadrature_order=model%axial_quadrature_order, & l0_dot=model%l0_dot(e)) ELSE From 3ee60f345554fcfd8183022284d7f8142097c732 Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 10:18:09 +0900 Subject: [PATCH 10/11] test: march the restored control model with tangent reuse off The snapshot test of a controlled cable marched the restored model against a copy taken before the snapshot. Restore clears the carried Newton factor, which the copy still holds, and the iterate a step stops at depends on the factor's age, so the two matched bit for bit only by chance: the merged dev failed the check on the Linux Debug runner while the same tree passed on the pull request. Both models now march with tangent reuse off, the documented condition for an exact restart, as the torsion restart test already does. The coupled cables of the OpenFAST module run with reuse off, so their restart tests are not affected. Signed-off-by: Jae Hoon Seo --- tests/test_hermite_cable_control.f90 | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tests/test_hermite_cable_control.f90 b/tests/test_hermite_cable_control.f90 index 8de7669a..4b1b9785 100644 --- a/tests/test_hermite_cable_control.f90 +++ b/tests/test_hermite_cable_control.f90 @@ -235,6 +235,10 @@ SUBROUTINE check_model_contract() CALL require(unchanged(a, ref) .AND. same_bits(a%l0_dot, ref%l0_dot) .AND. same_bits(a%q, ref%q) .AND. & same_bits(a%v, ref%v) .AND. same_bits(a%a, ref%a) .AND. same_bits2(a%fr_anchor, ref%fr_anchor), & 'A: restore brings back the lengths, rates, caches and state bit for bit') + ! Restore clears the carried Newton factor, which ref still holds, and where a step stops + ! depends on the factor's age: a restart is exact only with tangent reuse off (both models) + a%tangent_reuse = .FALSE. + ref%tangent_reuse = .FALSE. DO k = 1, 3 CALL CD_HermiteCable_Dyn_Step(a, DT, 50, 1.0e-10_wp, es, em) CALL CD_HermiteCable_Dyn_Step(ref, DT, 50, 1.0e-10_wp, es, em) From 415f173e9141c8d6542a1bc94245c5fcc6f60dbc Mon Sep 17 00:00:00 2001 From: Jae Hoon Seo Date: Tue, 20 Oct 2026 12:42:23 +0900 Subject: [PATCH 11/11] test: march the restored control model from an uncached committed force With tangent reuse off the snapshot test still failed on the Linux Debug runner. Restore also clears the cached committed force, so the restored model evaluates F_n afresh on its next step while the copy taken before the snapshot takes it from the cache of its previous step's last iteration. The copy's cache is now cleared as well, so both models take the same path, and the test prints the largest position and velocity difference after the three steps. Signed-off-by: Jae Hoon Seo --- tests/test_hermite_cable_control.f90 | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/tests/test_hermite_cable_control.f90 b/tests/test_hermite_cable_control.f90 index 4b1b9785..1f05ac03 100644 --- a/tests/test_hermite_cable_control.f90 +++ b/tests/test_hermite_cable_control.f90 @@ -235,14 +235,20 @@ SUBROUTINE check_model_contract() CALL require(unchanged(a, ref) .AND. same_bits(a%l0_dot, ref%l0_dot) .AND. same_bits(a%q, ref%q) .AND. & same_bits(a%v, ref%v) .AND. same_bits(a%a, ref%a) .AND. same_bits2(a%fr_anchor, ref%fr_anchor), & 'A: restore brings back the lengths, rates, caches and state bit for bit') - ! Restore clears the carried Newton factor, which ref still holds, and where a step stops - ! depends on the factor's age: a restart is exact only with tangent reuse off (both models) + ! Restore clears the carried Newton factor and the cached committed force, which ref still + ! holds. Where a step stops depends on the factor's age, so a restart is exact only with + ! tangent reuse off; and ref's next step would take its committed force from the cache + ! while a evaluates it afresh. Both models march with reuse off from an uncached + ! committed force, so they take the same path. a%tangent_reuse = .FALSE. ref%tangent_reuse = .FALSE. + ref%fc_valid = .FALSE. DO k = 1, 3 CALL CD_HermiteCable_Dyn_Step(a, DT, 50, 1.0e-10_wp, es, em) CALL CD_HermiteCable_Dyn_Step(ref, DT, 50, 1.0e-10_wp, es, em) END DO + WRITE (*, '(A,ES10.3,A,ES10.3)') ' A: restored vs untouched after 3 steps, max |dq| ', & + MAXVAL(ABS(a%q - ref%q)), ', max |dv| ', MAXVAL(ABS(a%v - ref%v)) CALL require(es == CD_HCDYN_OK .AND. same_bits(a%q, ref%q) .AND. same_bits(a%v, ref%v), & 'A: the restored model marches bit-identically to an untouched copy') CALL CD_HermiteCable_Dyn_End(ref)