diff --git a/doc/XMLreference.rst b/doc/XMLreference.rst index bc3168d9..57bb92ee 100644 --- a/doc/XMLreference.rst +++ b/doc/XMLreference.rst @@ -297,7 +297,7 @@ disable length range computations altogether, include this element and set mode= :at:`inttotal`: :at-val:`real, "10"` The total time interval (in seconds) for running the internal simulation, for each actuator and actuator direction. Each simulation is initialized at qpos0. It is expected to settle after inttotal time has passed. -:at:`inteval`: :at-val:`real, "2"` +:at:`interval`: :at-val:`real, "2"` The time interval at the end of the simulation over which length data is collected and analyzed. The maximum (or respectively minimum) length achieved during this interval is recorded. The difference between the maximum and minimum is also recorded and is used as a measure of divergence. If the simulation settles, this difference will be @@ -308,7 +308,7 @@ disable length range computations altogether, include this element and set mode= prevent actuators from having infinite length. :at:`tolrange`: :at-val:`real, "0.05"` This determines the threshold for detecting divergence and generating a compiler error. The range of actuator lengths - observed during inteval is divided by the overall range computed via simulation. If that value is larger than + observed during interval is divided by the overall range computed via simulation. If that value is larger than tolrange, a compiler error is generated. So one way to suppress compiler errors is to simply make this attribute larger, but in that case the results could be inaccurate. diff --git a/doc/XMLschema.rst b/doc/XMLschema.rst index ec61223a..cdad1fb0 100644 --- a/doc/XMLschema.rst +++ b/doc/XMLschema.rst @@ -33,7 +33,7 @@ | | | +-------------------------+-------------------------+-------------------------+ | | | | | :at:`accel` | :at:`maxforce` | :at:`timeconst` | | | | | +-------------------------+-------------------------+-------------------------+ | -| | | | :at:`timestep` | :at:`inttotal` | :at:`inteval` | | +| | | | :at:`timestep` | :at:`inttotal` | :at:`interval` | | | | | +-------------------------+-------------------------+-------------------------+ | | | | | :at:`tolrange` | | | | | | | +-------------------------+-------------------------+-------------------------+ | diff --git a/doc/changelog.rst b/doc/changelog.rst index 8e23ddee..c58e9928 100644 --- a/doc/changelog.rst +++ b/doc/changelog.rst @@ -9,6 +9,7 @@ General ^^^^^^^ - The ``mjd_transitionFD`` function no longer triggers sensor calculation unless explicitly requested. +- Corrected the spelling of the ``inteval`` attribute to ``interval`` in the ``mjLROpt`` struct. Python bindings ^^^^^^^^^^^^^^^ diff --git a/doc/includes/references.h b/doc/includes/references.h index 0fd7e965..3a68273d 100644 --- a/doc/includes/references.h +++ b/doc/includes/references.h @@ -586,13 +586,13 @@ struct mjLROpt_ { // options for mj_setLengthRange() mjtNum timeconst; // time constant for velocity reduction; min 0.01 mjtNum timestep; // simulation timestep; 0: use mjOption.timestep mjtNum inttotal; // total simulation time interval - mjtNum inteval; // evaluation time interval (at the end) + mjtNum interval; // evaluation time interval (at the end) mjtNum tolrange; // convergence tolerance (relative to range) }; typedef struct mjLROpt_ mjLROpt; struct mjVFS_ { // virtual file system for loading from memory int nfile; // number of files present - char filename[mjMAXVFS][mjMAXVFSNAME]; // file name without path + char filename[mjMAXVFS][mjMAXVFSNAME]; // file name without path int filesize[mjMAXVFS]; // file size in bytes void* filedata[mjMAXVFS]; // buffer with file data }; diff --git a/include/mujoco/mjmodel.h b/include/mujoco/mjmodel.h index 926498f6..ba093457 100644 --- a/include/mujoco/mjmodel.h +++ b/include/mujoco/mjmodel.h @@ -362,7 +362,7 @@ struct mjLROpt_ { // options for mj_setLengthRange() mjtNum timeconst; // time constant for velocity reduction; min 0.01 mjtNum timestep; // simulation timestep; 0: use mjOption.timestep mjtNum inttotal; // total simulation time interval - mjtNum inteval; // evaluation time interval (at the end) + mjtNum interval; // evaluation time interval (at the end) mjtNum tolrange; // convergence tolerance (relative to range) }; typedef struct mjLROpt_ mjLROpt; @@ -372,7 +372,7 @@ typedef struct mjLROpt_ mjLROpt; struct mjVFS_ { // virtual file system for loading from memory int nfile; // number of files present - char filename[mjMAXVFS][mjMAXVFSNAME]; // file name without path + char filename[mjMAXVFS][mjMAXVFSNAME]; // file name without path int filesize[mjMAXVFS]; // file size in bytes void* filedata[mjMAXVFS]; // buffer with file data }; diff --git a/python/mujoco/structs.cc b/python/mujoco/structs.cc index 9b1d28e7..7e16bade 100644 --- a/python/mujoco/structs.cc +++ b/python/mujoco/structs.cc @@ -1940,7 +1940,7 @@ This is useful for example when the MJB is not available as a file on disk.)")); X(timeconst); X(timestep); X(inttotal); - X(inteval); + X(interval); X(tolrange); #undef X diff --git a/src/engine/engine_io.c b/src/engine/engine_io.c index 024c987b..2655cb94 100644 --- a/src/engine/engine_io.c +++ b/src/engine/engine_io.c @@ -50,7 +50,7 @@ void mj_defaultLROpt(mjLROpt* opt) { opt->timeconst = 1; opt->timestep = 0.01; opt->inttotal = 10; - opt->inteval = 2; + opt->interval = 2; opt->tolrange = 0.05; } diff --git a/src/engine/engine_setconst.c b/src/engine/engine_setconst.c index 92514410..780ebb8b 100644 --- a/src/engine/engine_setconst.c +++ b/src/engine/engine_setconst.c @@ -508,7 +508,7 @@ int mj_setLengthRange(mjModel* m, mjData* d, int index, } // update limits - if (d->time > opt->inttotal-opt->inteval) { + if (d->time > opt->inttotal-opt->interval) { if (len"}, {"option", "*", "22", @@ -923,7 +923,7 @@ void mjXReader::Compiler(XMLElement* section, mjCModel* mod) { ReadAttr(elem, "timeconst", 1, &opt->timeconst, text); ReadAttr(elem, "timestep", 1, &opt->timestep, text); ReadAttr(elem, "inttotal", 1, &opt->inttotal, text); - ReadAttr(elem, "inteval", 1, &opt->inteval, text); + ReadAttr(elem, "interval", 1, &opt->interval, text); ReadAttr(elem, "tolrange", 1, &opt->tolrange, text); } } diff --git a/unity/Runtime/Bindings/MjBindings.cs b/unity/Runtime/Bindings/MjBindings.cs index 0539c1ec..62663f65 100644 --- a/unity/Runtime/Bindings/MjBindings.cs +++ b/unity/Runtime/Bindings/MjBindings.cs @@ -1706,7 +1706,7 @@ public unsafe struct mjLROpt_ { public double timeconst; public double timestep; public double inttotal; - public double inteval; + public double interval; public double tolrange; }