diff --git a/doc/world_builder_declarations.schema.json b/doc/world_builder_declarations.schema.json index 66fe85dfc..dc5baa21f 100644 --- a/doc/world_builder_declarations.schema.json +++ b/doc/world_builder_declarations.schema.json @@ -399,10 +399,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the composition of this feature is present.", + "description": "The depth in m from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -422,7 +422,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -444,7 +444,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the composition of this feature is present.", + "description": "The depth in m to which the composition of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -555,7 +555,7 @@ "description": "The depth in m from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -575,7 +575,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -671,10 +671,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the composition of this feature is present.", + "description": "The depth in m from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -694,7 +694,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -716,7 +716,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the composition of this feature is present.", + "description": "The depth in m to which the composition of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -763,12 +763,12 @@ "top temperature": { "default value": 293.15, "type": "number", - "description": "The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used." + "description": "The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used." }, "bottom temperature": { "default value": -1.0, "type": "number", - "description": "The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used." + "description": "The temperature in K at the top of this feature. If the value is below zero, an adiabatic temperature is used." } } }, @@ -800,10 +800,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the composition of this feature is present.", + "description": "The depth in m from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -823,7 +823,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -845,7 +845,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the composition of this feature is present.", + "description": "The depth in m to which the composition of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -892,7 +892,7 @@ "temperature": { "default value": 293.15, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K which the entire feature should have" } } } @@ -936,7 +936,7 @@ "description": "The depth in meters from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -956,7 +956,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -1066,7 +1066,7 @@ "description": "The depth in meters from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -1086,7 +1086,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -1222,7 +1222,7 @@ "description": "The depth in meters from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -1242,7 +1242,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -1375,7 +1375,7 @@ "description": "The depth in meters from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -1395,7 +1395,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -1525,10 +1525,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the composition of this feature is present.", + "description": "The depth in m from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -1548,7 +1548,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -1570,7 +1570,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the composition of this feature is present.", + "description": "The depth in m to which the composition of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -1738,7 +1738,7 @@ "description": "The depth in meters from which the composition of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -1758,7 +1758,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -6390,10 +6390,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the temperature of this feature is present.", + "description": "The depth in m from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -6413,7 +6413,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -6435,7 +6435,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the temperature of this feature is present.", + "description": "The depth in m to which the temperature of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -6482,7 +6482,7 @@ "potential mantle temperature": { "default value": -1.0, "type": "number", - "description": "The potential temperature of the mantle at the surface in Kelvin. If the value is lower then zero, the global value is used." + "description": "The potential temperature in K of the mantle at the surface. If the value is lower then zero, the global value is used." }, "thermal expansion coefficient": { "default value": -1.0, @@ -6529,7 +6529,7 @@ "description": "The depth in meters from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -6549,7 +6549,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -6723,10 +6723,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the temperature of this feature is present.", + "description": "The depth in m from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -6746,7 +6746,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -6768,7 +6768,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the temperature of this feature is present.", + "description": "The depth in m to which the temperature of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -6815,12 +6815,12 @@ "top temperature": { "default value": 293.15, "type": "number", - "description": "The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used." + "description": "The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used." }, "bottom temperature": { "default value": -1.0, "type": "number", - "description": "The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used." + "description": "The temperature in K at the bottom of this feature. If the value is below zero, an adiabatic temperature is used." } } }, @@ -6852,10 +6852,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the temperature of this feature is present.", + "description": "The depth in m from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -6875,7 +6875,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -6897,7 +6897,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the temperature of this feature is present.", + "description": "The depth in m to which the temperature of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -6944,12 +6944,12 @@ "top temperature": { "default value": 293.15, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K from which this feature should have" }, "bottom temperature": { "default value": -1.0, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K to which this feature should have" }, "spreading velocity": { "description": "The spreading velocity of the plate in meter per year. This is the velocity with which one side moves away from the ridge.", @@ -7049,10 +7049,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the temperature of this feature is present.", + "description": "The depth in m from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -7072,7 +7072,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -7094,7 +7094,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the temperature of this feature is present.", + "description": "The depth in m to which the temperature of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -7141,12 +7141,12 @@ "top temperature": { "default value": 293.15, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K at the top surface of this feature." }, "bottom temperature": { "default value": -1.0, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K at the bottom surface of this feature." }, "plate age": { "default value": 80000.0, @@ -7183,10 +7183,10 @@ ] }, "min depth": { - "description": "The depth in meters from which the temperature of this feature is present.", + "description": "The depth in m from which the temperature of this feature is present.", "oneOf": [ { - "default value": 0.0, + "default value": -1.7976931348623157e308, "type": "number", "description": "" }, @@ -7206,7 +7206,7 @@ "anyOf": [ { "type": "number", - "default value": 0.0 + "default value": -1.7976931348623157e308 }, { "type": "array", @@ -7228,7 +7228,7 @@ ] }, "max depth": { - "description": "The depth in meters to which the temperature of this feature is present.", + "description": "The depth in m to which the temperature of this feature is present.", "oneOf": [ { "default value": 1.7976931348623157e308, @@ -7275,7 +7275,7 @@ "temperature": { "default value": 293.15, "type": "number", - "description": "The temperature in degree Kelvin which this feature should have" + "description": "The temperature in K which this feature should have" } } } diff --git a/doc/world_builder_declarations_closed.md b/doc/world_builder_declarations_closed.md index 427e11b21..7c81da17b 100644 --- a/doc/world_builder_declarations_closed.md +++ b/doc/world_builder_declarations_closed.md @@ -495,14 +495,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth/oneOf/1 :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -533,7 +533,7 @@ :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -571,7 +571,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/max depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/max depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_1_max-depth_oneOf @@ -740,7 +740,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/2/min depth/oneOf/1 :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -771,7 +771,7 @@ :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -915,14 +915,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth/oneOf/1 :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -953,7 +953,7 @@ :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -991,7 +991,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/max depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/max depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_3_max-depth_oneOf @@ -1069,7 +1069,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/bottom temperature @@ -1077,7 +1077,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature. If the value is below zero, an adiabatic temperature is used. :::::::::::::::: @@ -1113,14 +1113,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth/oneOf/1 :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1151,7 +1151,7 @@ :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth/oneOf/2/items/items/anyOf/2 @@ -1189,7 +1189,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/max depth :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/max depth/oneOf :name: closed_features_items_oneOf_1_temperature-models_items_oneOf_4_max-depth_oneOf @@ -1267,7 +1267,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K which the entire feature should have :::::::::::::::: @@ -1327,7 +1327,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/velocity models/items/oneOf/1/min depth/oneOf/1 :name: closed_features_items_oneOf_1_velocity-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1358,7 +1358,7 @@ :name: closed_features_items_oneOf_1_velocity-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/velocity models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -1535,7 +1535,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/1/min depth/oneOf/1 :name: closed_features_items_oneOf_1_composition-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1566,7 +1566,7 @@ :name: closed_features_items_oneOf_1_composition-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -1771,7 +1771,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/2/min depth/oneOf/1 :name: closed_features_items_oneOf_1_composition-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1802,7 +1802,7 @@ :name: closed_features_items_oneOf_1_composition-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -2006,7 +2006,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/1/min depth/oneOf/1 :name: closed_features_items_oneOf_1_grains-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2037,7 +2037,7 @@ :name: closed_features_items_oneOf_1_grains-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -2235,14 +2235,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth/oneOf :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth/oneOf/1 :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2273,7 +2273,7 @@ :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -2311,7 +2311,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/max depth :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/max depth/oneOf :name: closed_features_items_oneOf_1_grains-models_items_oneOf_2_max-depth_oneOf @@ -2562,7 +2562,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/3/min depth/oneOf/1 :name: closed_features_items_oneOf_1_grains-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2593,7 +2593,7 @@ :name: closed_features_items_oneOf_1_grains-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -9258,14 +9258,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -9296,7 +9296,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -9334,7 +9334,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/max depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/max depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_1_max-depth_oneOf @@ -9412,7 +9412,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The potential temperature of the mantle at the surface in Kelvin. If the value is lower then zero, the global value is used. +- **description**:The potential temperature in K of the mantle at the surface. If the value is lower then zero, the global value is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/thermal expansion coefficient @@ -9471,7 +9471,7 @@ ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/2/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -9502,7 +9502,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -9773,14 +9773,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -9811,7 +9811,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -9849,7 +9849,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/max depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/max depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_3_max-depth_oneOf @@ -9927,7 +9927,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/bottom temperature @@ -9935,7 +9935,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used. +- **description**:The temperature in K at the bottom of this feature. If the value is below zero, an adiabatic temperature is used. :::::::::::::::: @@ -9971,14 +9971,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -10009,7 +10009,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth/oneOf/2/items/items/anyOf/2 @@ -10047,7 +10047,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/max depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/max depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_4_max-depth_oneOf @@ -10125,7 +10125,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K from which this feature should have :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/bottom temperature @@ -10133,7 +10133,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K to which this feature should have :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/spreading velocity @@ -10280,14 +10280,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -10318,7 +10318,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth/oneOf/2/items/items/anyOf/2 @@ -10356,7 +10356,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/max depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/max depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_5_max-depth_oneOf @@ -10434,7 +10434,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K at the top surface of this feature. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/bottom temperature @@ -10442,7 +10442,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K at the bottom surface of this feature. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/plate age @@ -10486,14 +10486,14 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf ::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth/oneOf/1 :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -10524,7 +10524,7 @@ :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth/oneOf/2/items/items/anyOf/2 @@ -10562,7 +10562,7 @@ ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/max depth :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/max depth/oneOf :name: closed_features_items_oneOf_4_temperature-models_items_oneOf_6_max-depth_oneOf @@ -10640,7 +10640,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K which this feature should have :::::::::::::::: diff --git a/doc/world_builder_declarations_open.md b/doc/world_builder_declarations_open.md index 002b9b627..c9a412084 100644 --- a/doc/world_builder_declarations_open.md +++ b/doc/world_builder_declarations_open.md @@ -561,7 +561,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf @@ -570,7 +570,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -606,7 +606,7 @@ :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -648,7 +648,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/1/max depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_1_max-depth_oneOf @@ -840,7 +840,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -876,7 +876,7 @@ :name: open_features_items_oneOf_1_temperature-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -1038,7 +1038,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf @@ -1047,7 +1047,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1083,7 +1083,7 @@ :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -1125,7 +1125,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/max depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_3_max-depth_oneOf @@ -1214,7 +1214,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/3/bottom temperature @@ -1223,7 +1223,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature. If the value is below zero, an adiabatic temperature is used. :::::::::::::::: @@ -1263,7 +1263,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf @@ -1272,7 +1272,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1308,7 +1308,7 @@ :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/min depth/oneOf/2/items/items/anyOf/2 @@ -1350,7 +1350,7 @@ :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/temperature models/items/oneOf/4/max depth/oneOf :open: :name: open_features_items_oneOf_1_temperature-models_items_oneOf_4_max-depth_oneOf @@ -1439,7 +1439,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K which the entire feature should have :::::::::::::::: @@ -1508,7 +1508,7 @@ :open: :name: open_features_items_oneOf_1_velocity-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1544,7 +1544,7 @@ :name: open_features_items_oneOf_1_velocity-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/velocity models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -1745,7 +1745,7 @@ :open: :name: open_features_items_oneOf_1_composition-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -1781,7 +1781,7 @@ :name: open_features_items_oneOf_1_composition-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -2012,7 +2012,7 @@ :open: :name: open_features_items_oneOf_1_composition-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2048,7 +2048,7 @@ :name: open_features_items_oneOf_1_composition-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/composition models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -2279,7 +2279,7 @@ :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2315,7 +2315,7 @@ :name: open_features_items_oneOf_1_grains-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -2537,7 +2537,7 @@ :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth -- **description**:The depth in meters from which the composition of this feature is present. +- **description**:The depth in m from which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth/oneOf :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf @@ -2546,7 +2546,7 @@ :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2582,7 +2582,7 @@ :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -2624,7 +2624,7 @@ :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_max-depth -- **description**:The depth in meters to which the composition of this feature is present. +- **description**:The depth in m to which the composition of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/2/max depth/oneOf :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_2_max-depth_oneOf @@ -2906,7 +2906,7 @@ :open: :name: open_features_items_oneOf_1_grains-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -2942,7 +2942,7 @@ :name: open_features_items_oneOf_1_grains-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/1/grains models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -10421,7 +10421,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf @@ -10430,7 +10430,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -10466,7 +10466,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/min depth/oneOf/2/items/items/anyOf/2 @@ -10508,7 +10508,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/max depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_1_max-depth_oneOf @@ -10597,7 +10597,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The potential temperature of the mantle at the surface in Kelvin. If the value is lower then zero, the global value is used. +- **description**:The potential temperature in K of the mantle at the surface. If the value is lower then zero, the global value is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/1/thermal expansion coefficient @@ -10664,7 +10664,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_2_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -10700,7 +10700,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_2_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/2/min depth/oneOf/2/items/items/anyOf/2 @@ -11006,7 +11006,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf @@ -11015,7 +11015,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -11051,7 +11051,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/min depth/oneOf/2/items/items/anyOf/2 @@ -11093,7 +11093,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/max depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_3_max-depth_oneOf @@ -11182,7 +11182,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature.If the value is below zero, the an adiabatic temperature is used. +- **description**:The temperature in K at the top of this feature.If the value is below zero, the an adiabatic temperature is used. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/3/bottom temperature @@ -11191,7 +11191,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature at the top in degree Kelvin of this feature. If the value is below zero, an adiabatic temperature is used. +- **description**:The temperature in K at the bottom of this feature. If the value is below zero, an adiabatic temperature is used. :::::::::::::::: @@ -11231,7 +11231,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf @@ -11240,7 +11240,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -11276,7 +11276,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/min depth/oneOf/2/items/items/anyOf/2 @@ -11318,7 +11318,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/max depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_4_max-depth_oneOf @@ -11407,7 +11407,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K from which this feature should have :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/bottom temperature @@ -11416,7 +11416,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K to which this feature should have :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/4/spreading velocity @@ -11582,7 +11582,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf @@ -11591,7 +11591,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -11627,7 +11627,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/min depth/oneOf/2/items/items/anyOf/2 @@ -11669,7 +11669,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/max depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_5_max-depth_oneOf @@ -11758,7 +11758,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K at the top surface of this feature. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/bottom temperature @@ -11767,7 +11767,7 @@ - **default value**:-1.0 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K at the bottom surface of this feature. :::::::::::::::: ::::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/5/plate age @@ -11816,7 +11816,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth -- **description**:The depth in meters from which the temperature of this feature is present. +- **description**:The depth in m from which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf @@ -11825,7 +11825,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf_1 -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 - **type**:number - **description**: :::::::::::::: @@ -11861,7 +11861,7 @@ :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_min-depth_oneOf_2_items_items_anyOf_1 - **type**:number -- **default value**:0.0 +- **default value**:-1.7976931348623157e308 :::::::::: ::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/min depth/oneOf/2/items/items/anyOf/2 @@ -11903,7 +11903,7 @@ :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_max-depth -- **description**:The depth in meters to which the temperature of this feature is present. +- **description**:The depth in m to which the temperature of this feature is present. :::::::::::::::{dropdown} /features/items/oneOf/4/temperature models/items/oneOf/6/max depth/oneOf :open: :name: open_features_items_oneOf_4_temperature-models_items_oneOf_6_max-depth_oneOf @@ -11992,7 +11992,7 @@ - **default value**:293.15 - **type**:number -- **description**:The temperature in degree Kelvin which this feature should have +- **description**:The temperature in K which this feature should have :::::::::::::::: diff --git a/include/world_builder/features/continental_plate_models/composition/random.h b/include/world_builder/features/continental_plate_models/composition/random.h index 5d7a9f401..36590d34f 100644 --- a/include/world_builder/features/continental_plate_models/composition/random.h +++ b/include/world_builder/features/continental_plate_models/composition/random.h @@ -75,22 +75,21 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: // Random composition submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector compositions; std::vector min_value; std::vector max_value; Operations operation; - }; } // namespace Composition } // namespace ContinentalPlateModels diff --git a/include/world_builder/features/continental_plate_models/composition/uniform.h b/include/world_builder/features/continental_plate_models/composition/uniform.h index f6540cf82..d5c8fc9b6 100644 --- a/include/world_builder/features/continental_plate_models/composition/uniform.h +++ b/include/world_builder/features/continental_plate_models/composition/uniform.h @@ -82,10 +82,10 @@ namespace WorldBuilder private: // uniform composition submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector compositions; std::vector fractions; Operations operation; diff --git a/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution.h b/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution.h index dfa20197d..e1ae1f280 100644 --- a/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution.h +++ b/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution.h @@ -92,15 +92,15 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, WorldBuilder::grains grains, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: // uniform grains submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector grains; std::vector compositions; std::string operation; diff --git a/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.h b/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.h index 54c389f25..b281c9812 100644 --- a/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.h +++ b/include/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.h @@ -95,10 +95,10 @@ namespace WorldBuilder const double feature_max_depth) const override final; private: - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector grains; std::vector compositions; std::string operation; diff --git a/include/world_builder/features/continental_plate_models/grains/uniform.h b/include/world_builder/features/continental_plate_models/grains/uniform.h index 6a054a950..cecef3af8 100644 --- a/include/world_builder/features/continental_plate_models/grains/uniform.h +++ b/include/world_builder/features/continental_plate_models/grains/uniform.h @@ -95,10 +95,10 @@ namespace WorldBuilder private: // uniform grains submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector grains; std::vector compositions; std::string operation; diff --git a/include/world_builder/features/continental_plate_models/temperature/adiabatic.h b/include/world_builder/features/continental_plate_models/temperature/adiabatic.h index d8be4739f..59691cb6c 100644 --- a/include/world_builder/features/continental_plate_models/temperature/adiabatic.h +++ b/include/world_builder/features/continental_plate_models/temperature/adiabatic.h @@ -82,26 +82,13 @@ namespace WorldBuilder private: // adiabatic temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; - /** - * Todo - */ + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double potential_mantle_temperature; - - - /** - * Todo - */ double thermal_expansion_coefficient; - - /** - * Todo - */ double specific_heat; - Operations operation; }; diff --git a/include/world_builder/features/continental_plate_models/temperature/chapman.h b/include/world_builder/features/continental_plate_models/temperature/chapman.h index 5e5214568..d702ba62e 100644 --- a/include/world_builder/features/continental_plate_models/temperature/chapman.h +++ b/include/world_builder/features/continental_plate_models/temperature/chapman.h @@ -82,19 +82,19 @@ namespace WorldBuilder const double depth, const double gravity, double temperature, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: - double top_temperature; + double top_temperature_entry; double top_heat_flux; double thermal_conductivity; double heat_production_per_unit_volume; - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; Operations operation; }; diff --git a/include/world_builder/features/continental_plate_models/temperature/linear.h b/include/world_builder/features/continental_plate_models/temperature/linear.h index 07a2a022e..844dc06a2 100644 --- a/include/world_builder/features/continental_plate_models/temperature/linear.h +++ b/include/world_builder/features/continental_plate_models/temperature/linear.h @@ -76,18 +76,18 @@ namespace WorldBuilder const double depth, const double gravity, double temperature, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: // linear temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; - double top_temperature; - double bottom_temperature; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; + double top_temperature_entry; + double bottom_temperature_entry; Operations operation; }; diff --git a/include/world_builder/features/continental_plate_models/temperature/uniform.h b/include/world_builder/features/continental_plate_models/temperature/uniform.h index bb70e04a2..bd6cd0e71 100644 --- a/include/world_builder/features/continental_plate_models/temperature/uniform.h +++ b/include/world_builder/features/continental_plate_models/temperature/uniform.h @@ -76,16 +76,16 @@ namespace WorldBuilder const double depth, const double gravity, double temperature, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: // uniform temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double temperature; Operations operation; diff --git a/include/world_builder/features/continental_plate_models/velocity/uniform_raw.h b/include/world_builder/features/continental_plate_models/velocity/uniform_raw.h index 737ebf54e..d8b81e0cb 100644 --- a/include/world_builder/features/continental_plate_models/velocity/uniform_raw.h +++ b/include/world_builder/features/continental_plate_models/velocity/uniform_raw.h @@ -82,10 +82,10 @@ namespace WorldBuilder private: // uniform raw velocity submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::array velocity; Operations operation; diff --git a/include/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.h b/include/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.h index 0ae3dd84a..0a45515b6 100644 --- a/include/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.h +++ b/include/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.h @@ -84,20 +84,20 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double feature_min_depth, - const double feature_max_depth) const override final; + const double min_depth_feature, + const double max_depth_feature) const override final; private: // TianWaterContent composition submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double density; // Density used to compute the lithostatic pressure - Objects::Surface max_depth_surface; std::vector compositions; - Operations operation; double max_water_content; + Operations operation; enum LithologyName { diff --git a/include/world_builder/features/oceanic_plate_models/composition/uniform.h b/include/world_builder/features/oceanic_plate_models/composition/uniform.h index d4ffad694..565f0fda5 100644 --- a/include/world_builder/features/oceanic_plate_models/composition/uniform.h +++ b/include/world_builder/features/oceanic_plate_models/composition/uniform.h @@ -81,10 +81,10 @@ namespace WorldBuilder private: // uniform composition submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; std::vector compositions; std::vector fractions; Operations operation; diff --git a/include/world_builder/features/oceanic_plate_models/temperature/adiabatic.h b/include/world_builder/features/oceanic_plate_models/temperature/adiabatic.h index 9147f3b99..8d632c716 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/adiabatic.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/adiabatic.h @@ -81,28 +81,14 @@ namespace WorldBuilder private: // adiabatic temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; - /** - * Todo - */ + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double potential_mantle_temperature; - - - /** - * Todo - */ double thermal_expansion_coefficient; - - /** - * Todo - */ double specific_heat; - Operations operation; - }; } // namespace Temperature } // namespace OceanicPlateModels diff --git a/include/world_builder/features/oceanic_plate_models/temperature/half_space_model.h b/include/world_builder/features/oceanic_plate_models/temperature/half_space_model.h index 967134ec5..9606531d6 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/half_space_model.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/half_space_model.h @@ -83,10 +83,10 @@ namespace WorldBuilder private: // plate model temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double top_temperature; double bottom_temperature; std::pair,std::vector> spreading_velocities; diff --git a/include/world_builder/features/oceanic_plate_models/temperature/linear.h b/include/world_builder/features/oceanic_plate_models/temperature/linear.h index 3044603f3..c4320f50b 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/linear.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/linear.h @@ -81,10 +81,10 @@ namespace WorldBuilder private: // linear temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double top_temperature; double bottom_temperature; Operations operation; diff --git a/include/world_builder/features/oceanic_plate_models/temperature/plate_model.h b/include/world_builder/features/oceanic_plate_models/temperature/plate_model.h index ef381bd6f..36e17e847 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/plate_model.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/plate_model.h @@ -87,10 +87,10 @@ namespace WorldBuilder private: // plate model temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double top_temperature; double bottom_temperature; std::pair,std::vector> spreading_velocities; diff --git a/include/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.h b/include/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.h index b73e6ebfc..837a15092 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.h @@ -87,10 +87,10 @@ namespace WorldBuilder private: // plate model constant age temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double top_temperature; double bottom_temperature; double plate_age; diff --git a/include/world_builder/features/oceanic_plate_models/temperature/uniform.h b/include/world_builder/features/oceanic_plate_models/temperature/uniform.h index 031e3c3a0..ad2e653fa 100644 --- a/include/world_builder/features/oceanic_plate_models/temperature/uniform.h +++ b/include/world_builder/features/oceanic_plate_models/temperature/uniform.h @@ -81,10 +81,10 @@ namespace WorldBuilder private: // uniform temperature submodule parameters - double min_depth; - Objects::Surface min_depth_surface; - double max_depth; - Objects::Surface max_depth_surface; + double min_depth_entry; + Objects::Surface min_depth_surface_entry; + double max_depth_entry; + Objects::Surface max_depth_surface_entry; double temperature; Operations operation; diff --git a/source/world_builder/features/continental_plate_models/composition/random.cc b/source/world_builder/features/continental_plate_models/composition/random.cc index cfb0d2086..83fc5974c 100644 --- a/source/world_builder/features/continental_plate_models/composition/random.cc +++ b/source/world_builder/features/continental_plate_models/composition/random.cc @@ -46,8 +46,8 @@ namespace WorldBuilder { Random::Random(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; this->name = "random"; @@ -65,7 +65,7 @@ namespace WorldBuilder "Uniform compositional model. Sets constant compositional field."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -92,10 +92,10 @@ namespace WorldBuilder void Random::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); min_value = prm.get_vector("min value"); @@ -110,14 +110,21 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - if (depth <= max_depth_local && depth >= min_depth_local) + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i : compositions) { diff --git a/source/world_builder/features/continental_plate_models/composition/uniform.cc b/source/world_builder/features/continental_plate_models/composition/uniform.cc index 51130ef82..b8ee8fc9e 100644 --- a/source/world_builder/features/continental_plate_models/composition/uniform.cc +++ b/source/world_builder/features/continental_plate_models/composition/uniform.cc @@ -43,8 +43,8 @@ namespace WorldBuilder { Uniform::Uniform(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; this->name = "uniform"; @@ -62,7 +62,7 @@ namespace WorldBuilder "Uniform compositional model. Sets constant compositional field."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -84,10 +84,10 @@ namespace WorldBuilder void Uniform::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); fractions = prm.get_vector("fractions"); @@ -104,14 +104,21 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - if (depth <= max_depth_local && depth >= min_depth_local) + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i =0; i < compositions.size(); ++i) { diff --git a/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution.cc b/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution.cc index 516b9413a..96bd04379 100644 --- a/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution.cc +++ b/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution.cc @@ -43,8 +43,8 @@ namespace WorldBuilder { RandomUniformDistribution::RandomUniformDistribution(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; @@ -64,7 +64,7 @@ namespace WorldBuilder "to a single value or to a random distribution."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), "The depth in meters to which the composition of this feature is present."); @@ -84,18 +84,15 @@ namespace WorldBuilder prm.declare_entry("normalize grain sizes", Types::Array(Types::Bool(true),0), "A list of whether the sizes of the grains should be normalized or not. If normalized, the total of the grains of a composition will be equal to 1."); - - - } void RandomUniformDistribution::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); operation = prm.get("orientation operation"); @@ -118,14 +115,22 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, WorldBuilder::grains grains_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { WorldBuilder::grains grains_local = grains_; - if (depth <= max_depth && depth >= min_depth) + + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i =0; i < compositions.size(); ++i) diff --git a/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.cc b/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.cc index d1b077f17..740a20f2a 100644 --- a/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.cc +++ b/source/world_builder/features/continental_plate_models/grains/random_uniform_distribution_deflected.cc @@ -42,8 +42,8 @@ namespace WorldBuilder { RandomUniformDistributionDeflected::RandomUniformDistributionDeflected(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; @@ -63,10 +63,10 @@ namespace WorldBuilder "to a single value or to a random distribution."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the composition of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the composition of this feature is present."); + "The depth in m to which the composition of this feature is present."); prm.declare_entry("compositions", Types::Array(Types::UnsignedInt(),0), "A list with the integer labels of the composition which are present there."); @@ -99,10 +99,10 @@ namespace WorldBuilder void RandomUniformDistributionDeflected::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); const bool set_euler_angles = prm.check_entry("basis Euler angles z-x-z"); @@ -155,14 +155,22 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, WorldBuilder::grains grains_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { WorldBuilder::grains grains_local = grains_; - if (depth <= max_depth && depth >= min_depth) + + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i =0; i < compositions.size(); ++i) diff --git a/source/world_builder/features/continental_plate_models/grains/uniform.cc b/source/world_builder/features/continental_plate_models/grains/uniform.cc index 110bd9190..35f731f9b 100644 --- a/source/world_builder/features/continental_plate_models/grains/uniform.cc +++ b/source/world_builder/features/continental_plate_models/grains/uniform.cc @@ -42,8 +42,8 @@ namespace WorldBuilder { Uniform::Uniform(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; @@ -62,7 +62,7 @@ namespace WorldBuilder "Uniform grains model. All grains start exactly the same."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -92,19 +92,19 @@ namespace WorldBuilder void Uniform::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); const bool set_euler_angles = prm.check_entry("Euler angles z-x-z"); const bool set_rotation_matrices = prm.check_entry("rotation matrices"); + WBAssertThrow(!(set_euler_angles == true && set_rotation_matrices == true), "Only Euler angles or Rotation matrices may be set, but both are set for " << prm.get_full_json_path()); - WBAssertThrow(!(set_euler_angles == false && set_rotation_matrices == false), "Euler angles or Rotation matrices have to be set, but neither are set for " << prm.get_full_json_path()); @@ -142,14 +142,21 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, WorldBuilder::grains grains_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { WorldBuilder::grains grains_local = grains_; - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i =0; i < compositions.size(); ++i) diff --git a/source/world_builder/features/continental_plate_models/temperature/adiabatic.cc b/source/world_builder/features/continental_plate_models/temperature/adiabatic.cc index 88d836390..f01ba81c3 100644 --- a/source/world_builder/features/continental_plate_models/temperature/adiabatic.cc +++ b/source/world_builder/features/continental_plate_models/temperature/adiabatic.cc @@ -41,8 +41,8 @@ namespace WorldBuilder { Adiabatic::Adiabatic(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), potential_mantle_temperature(NaN::DSNAN), thermal_expansion_coefficient(NaN::DSNAN), specific_heat(NaN::DSNAN), @@ -63,11 +63,11 @@ namespace WorldBuilder "Adiabatic temperature model. Uses global values by default."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the composition of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the composition of this feature is present."); + "The depth in m to which the composition of this feature is present."); prm.declare_entry("potential mantle temperature", Types::Double(-1), "The potential temperature of the mantle at the surface in Kelvin. " @@ -86,18 +86,15 @@ namespace WorldBuilder void Adiabatic::parse_entries(Parameters &prm, const std::vector> &coordinates) { - - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; - operation = string_operations_to_enum(prm.get("operation")); + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; potential_mantle_temperature = prm.get("potential mantle temperature"); if (potential_mantle_temperature < 0) potential_mantle_temperature = this->world->potential_mantle_temperature; - thermal_expansion_coefficient = prm.get("thermal expansion coefficient"); if (thermal_expansion_coefficient < 0) thermal_expansion_coefficient = this->world->thermal_expansion_coefficient; @@ -106,7 +103,9 @@ namespace WorldBuilder if (specific_heat < 0) specific_heat = this->world->specific_heat; - // Some assertions in debug mode can't hurt and have helped before. + operation = string_operations_to_enum(prm.get("operation")); + + WBAssert(!std::isnan(potential_mantle_temperature), "potential_mantle_temperature is not a number: " << potential_mantle_temperature << '.'); WBAssert(std::isfinite(potential_mantle_temperature), @@ -124,40 +123,46 @@ namespace WorldBuilder } - double Adiabatic::get_temperature(const Point<3> & /*position_in_cartesian_coordinates*/, const Objects::NaturalCoordinate &position_in_natural_coordinates, const double depth, const double gravity_norm, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { - const double adabatic_temperature = potential_mantle_temperature * - std::exp(((thermal_expansion_coefficient * gravity_norm) / - specific_heat) * depth); + const double temperature_calculated = potential_mantle_temperature * + std::exp(((thermal_expansion_coefficient * gravity_norm) / + specific_heat) * depth); - WBAssert(!std::isnan(adabatic_temperature), - "adabatic_temperature is not a number: " << adabatic_temperature << ". " - <<"Parameters: potential_mantle_temperature = " << potential_mantle_temperature - <<", thermal_expansion_coefficient = " << thermal_expansion_coefficient + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated + << ", based on a temperature model with the name " << this->name); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", potential_mantle_temperature = " << potential_mantle_temperature + << ", thermal_expansion_coefficient = " << thermal_expansion_coefficient << ", gravity_norm = " << gravity_norm << ", specific_heat = " << specific_heat << ", depth = " << depth); - WBAssert(std::isfinite(adabatic_temperature), - "adabatic_temperature is not a finite: " << adabatic_temperature << '.'); - - return apply_operation(operation,temperature_,adabatic_temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } return temperature_; diff --git a/source/world_builder/features/continental_plate_models/temperature/chapman.cc b/source/world_builder/features/continental_plate_models/temperature/chapman.cc index 40e42dd84..e0f52763e 100644 --- a/source/world_builder/features/continental_plate_models/temperature/chapman.cc +++ b/source/world_builder/features/continental_plate_models/temperature/chapman.cc @@ -1,5 +1,5 @@ /* - Copyright (C) 2018-2024 by the authors of the World Builder code. + Copyright (C) 2018-2025 by the authors of the World Builder code. This file is part of the World Builder. @@ -42,12 +42,12 @@ namespace WorldBuilder { Chapman::Chapman(WorldBuilder::World *world_) : - top_temperature(NaN::DSNAN), + top_temperature_entry(NaN::DSNAN), top_heat_flux(NaN::DSNAN), thermal_conductivity(NaN::DSNAN), heat_production_per_unit_volume(NaN::DSNAN), - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), operation(Operations::REPLACE) { this->world = world_; @@ -80,7 +80,7 @@ namespace WorldBuilder "The heat generation per unit volume in W m^(-3) of this feature." "The default value is 1e-6."); - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in m from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -91,18 +91,20 @@ namespace WorldBuilder void Chapman::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; - WBAssert(max_depth >= min_depth, "max depth needs to be larger or equal to min depth."); - operation = string_operations_to_enum(prm.get("operation")); + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; + WBAssert(max_depth_entry >= min_depth_entry, "max depth needs to be larger or equal to min depth."); + thermal_conductivity = prm.get("thermal conductivity"); heat_production_per_unit_volume = prm.get("heat generation per unit volume"); top_heat_flux = prm.get("top heat flux"); - top_temperature = prm.get("top temperature"); - WBAssert(!std::isnan(top_temperature), "Top surface temperature is not a number: " << top_temperature + top_temperature_entry = prm.get("top temperature"); + WBAssert(!std::isnan(top_temperature_entry), "Top surface temperature is not a number: " << top_temperature_entry << ", based on a temperature model with the name " << this->name); + + operation = string_operations_to_enum(prm.get("operation")); } @@ -112,43 +114,51 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double feature_min_depth, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { - const double min_depth_local_local = std::max(feature_min_depth, min_depth_local); - - double top_temperature_local = top_temperature; + double top_temperature_local = top_temperature_entry; // use adiabatic temperature if top temperature is below zero if (top_temperature_local < 0) { top_temperature_local = this->world->potential_mantle_temperature * std::exp(((this->world->thermal_expansion_coefficient * gravity_norm) / - this->world->specific_heat) * min_depth_local_local); + this->world->specific_heat) * min_depth_local); } // calculate the temperature at depth z using steady-state 1-D heat conduction equation: // T(z) = t_top + (q_top / k) * (Δz) - (A / (2 * k)) * (Δz)^2 - const double new_temperature = top_temperature + (top_heat_flux / thermal_conductivity) * (depth-min_depth_local_local) - heat_production_per_unit_volume / (2. * thermal_conductivity) * (depth-min_depth_local_local)*(depth-min_depth_local_local); + const double temperature_calculated = top_temperature_local + (top_heat_flux / thermal_conductivity) * (depth-min_depth_local) - heat_production_per_unit_volume / (2. * thermal_conductivity) * (depth-min_depth_local)*(depth-min_depth_local); - WBAssert(!std::isnan(new_temperature), "Temperature is not a number: " << new_temperature + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated << ", based on a temperature model with the name " << this->name); - WBAssert(std::isfinite(new_temperature), "Temperature is not a finite: " << new_temperature + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated << ", based on a temperature model with the name " << this->name << ", top_temperature_local = " << top_temperature_local << ", depth = " << depth << ", min_depth_local = " << min_depth_local + << ", max_depth_local = " << max_depth_local + << ", min_depth_feature = " << min_depth_feature + << ", max_depth_feature = " << max_depth_feature << ", top_heat_flux = " << top_heat_flux - << ", thermal_conductivity=" << thermal_conductivity - << ", min_depth_local_local =" << min_depth_local_local); + << ", thermal_conductivity=" << thermal_conductivity); - return apply_operation(operation,temperature_,new_temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } @@ -160,5 +170,4 @@ namespace WorldBuilder } // namespace Temperature } // namespace ContinentalPlateModels } // namespace Features -} // namespace WorldBuilder - +} // namespace WorldBuilder \ No newline at end of file diff --git a/source/world_builder/features/continental_plate_models/temperature/linear.cc b/source/world_builder/features/continental_plate_models/temperature/linear.cc index 03d173390..c8720838c 100644 --- a/source/world_builder/features/continental_plate_models/temperature/linear.cc +++ b/source/world_builder/features/continental_plate_models/temperature/linear.cc @@ -42,10 +42,10 @@ namespace WorldBuilder { Linear::Linear(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), - top_temperature(NaN::DSNAN), - bottom_temperature(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), + top_temperature_entry(NaN::DSNAN), + bottom_temperature_entry(NaN::DSNAN), operation(Operations::REPLACE) { this->world = world_; @@ -64,33 +64,34 @@ namespace WorldBuilder "Linear temperature model. Can be set to use an adiabatic temperature at the boundaries."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the composition of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the composition of this feature is present."); + "The depth in m to which the composition of this feature is present."); prm.declare_entry("top temperature", Types::Double(293.15), - "The temperature at the top in degree Kelvin of this feature." + "The temperature in K at the top of this feature." "If the value is below zero, the an adiabatic temperature is used."); prm.declare_entry("bottom temperature", Types::Double(-1), - "The temperature at the top in degree Kelvin of this feature. " + "The temperature in K at the top of this feature. " "If the value is below zero, an adiabatic temperature is used."); - } void Linear::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; - WBAssert(max_depth >= min_depth, "max depth needs to be larger or equal to min depth."); + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; + WBAssert(max_depth_entry >= min_depth_entry, "Max depth needs to be larger or equal to min depth."); + + top_temperature_entry = prm.get("top temperature"); + bottom_temperature_entry = prm.get("bottom temperature"); + operation = string_operations_to_enum(prm.get("operation")); - top_temperature = prm.get("top temperature"); - bottom_temperature = prm.get("bottom temperature"); } @@ -100,52 +101,59 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double feature_min_depth, - const double feature_max_depth) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { - const double min_depth_local_local = std::max(feature_min_depth, min_depth_local); - const double max_depth_local_local = std::min(feature_max_depth, max_depth_local); - - double top_temperature_local = top_temperature; + // use adiabatic temperature if the user defined temperature is below zero + double top_temperature_local = top_temperature_entry; if (top_temperature_local < 0) { top_temperature_local = this->world->potential_mantle_temperature * std::exp(((this->world->thermal_expansion_coefficient * gravity_norm) / - this->world->specific_heat) * min_depth_local_local); + this->world->specific_heat) * min_depth_local); } - double bottom_temperature_local = bottom_temperature; + double bottom_temperature_local = bottom_temperature_entry; if (bottom_temperature_local < 0) { bottom_temperature_local = this->world->potential_mantle_temperature * std::exp(((this->world->thermal_expansion_coefficient * gravity_norm) / - this->world->specific_heat) * max_depth_local_local); + this->world->specific_heat) * max_depth_local); } - const double new_temperature = top_temperature_local + (max_depth_local_local - min_depth_local_local < 10.0*std::numeric_limits::epsilon() ? 0.0 : - (depth - min_depth_local) * - ((bottom_temperature_local - top_temperature_local) / (max_depth_local_local - min_depth_local_local))); + const double temperature_calculated = top_temperature_local + (max_depth_local - min_depth_local < 10.0*std::numeric_limits::epsilon() ? 0.0 : + (depth - min_depth_local) * + (bottom_temperature_local - top_temperature_local) / (max_depth_local - min_depth_local)); - WBAssert(!std::isnan(new_temperature), "Temperature is not a number: " << new_temperature + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated << ", based on a temperature model with the name " << this->name); - WBAssert(std::isfinite(new_temperature), "Temperature is not a finite: " << new_temperature - << ", based on a temperature model with the name " << this->name - << ", top_temperature_local = " << top_temperature_local << ", depth = " << depth << ", min_depth_local = " << min_depth_local - << ", bottom_temperature_local= " << bottom_temperature_local << ", top_temperature_local=" << top_temperature_local - << ",max_depth_local_local=" << max_depth_local_local << ", min_depth_local_local =" << min_depth_local_local - << ", feature_max_depth = " << feature_max_depth << ", feature_max_depth = " << feature_max_depth); - return apply_operation(operation,temperature_,new_temperature); + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", depth = " << depth + << ", min_depth_local = " << min_depth_local + << ", max_depth_local = " << max_depth_local + << ", min_depth_feature = " << min_depth_feature + << ", max_depth_feature = " << max_depth_feature + << ", top_temperature_local=" << top_temperature_local + << ", bottom_temperature_local= " << bottom_temperature_local); + + return apply_operation(operation,temperature_,temperature_calculated); } } - - return temperature_; } diff --git a/source/world_builder/features/continental_plate_models/temperature/uniform.cc b/source/world_builder/features/continental_plate_models/temperature/uniform.cc index ff4b8d695..e5615a4ce 100644 --- a/source/world_builder/features/continental_plate_models/temperature/uniform.cc +++ b/source/world_builder/features/continental_plate_models/temperature/uniform.cc @@ -40,8 +40,8 @@ namespace WorldBuilder { Uniform::Uniform(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), temperature(NaN::DSNAN), operation(Operations::REPLACE) { @@ -61,25 +61,23 @@ namespace WorldBuilder "Uniform temperature model. Set the temperature to a constant value."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the composition of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the composition of this feature is present."); + "The depth in m to which the composition of this feature is present."); prm.declare_entry("temperature", Types::Double(293.15), - "The temperature in degree Kelvin which this feature should have"); - + "The temperature in K which the entire feature should have"); } void Uniform::parse_entries(Parameters &prm, const std::vector> &coordinates) { - - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); temperature = prm.get("temperature"); } @@ -91,14 +89,21 @@ namespace WorldBuilder const double depth, const double /*gravity*/, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - if (depth <= max_depth_local && depth >= min_depth_local) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - if (depth <= max_depth && depth >= min_depth) + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + + if (depth <= max_depth_local && depth >= min_depth_local) { return apply_operation(operation,temperature_,temperature); } diff --git a/source/world_builder/features/continental_plate_models/velocity/uniform_raw.cc b/source/world_builder/features/continental_plate_models/velocity/uniform_raw.cc index 9ee4e9403..6bcf1aa74 100644 --- a/source/world_builder/features/continental_plate_models/velocity/uniform_raw.cc +++ b/source/world_builder/features/continental_plate_models/velocity/uniform_raw.cc @@ -41,8 +41,8 @@ namespace WorldBuilder { UniformRaw::UniformRaw(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), velocity({{NaN::DSNAN,NaN::DSNAN,NaN::DSNAN}}), operation(Operations::REPLACE) { @@ -62,7 +62,7 @@ namespace WorldBuilder "Uniform velocity model. Set the velocity to a constant value."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the composition of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -77,10 +77,10 @@ namespace WorldBuilder UniformRaw::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); std::vector velocity_vec = prm.get_vector("velocity"); velocity[0] = velocity_vec[0]; @@ -95,14 +95,21 @@ namespace WorldBuilder const double depth, const double /*gravity*/, std::array velocity_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - if (depth <= max_depth_local && depth >= min_depth_local) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - if (depth <= max_depth && depth >= min_depth) + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + + if (depth <= max_depth_local && depth >= min_depth_local) { //std::cout << "velocity_ = " << velocity_[0] << ":" << velocity_[1] << ":" << velocity_[2] << ", velocity = " << velocity[0] << ":" << velocity[1] << ":" << velocity[2] << ", apply = " << apply_operation(operation,velocity_[0],velocity[0])<< std::endl; return {{ diff --git a/source/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.cc b/source/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.cc index de1ab1192..15a693e9c 100644 --- a/source/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.cc +++ b/source/world_builder/features/oceanic_plate_models/composition/tian2019_water_content.cc @@ -44,8 +44,8 @@ namespace WorldBuilder { TianWaterContent::TianWaterContent(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), density(NaN::DSNAN) { this->world = world_; @@ -99,10 +99,10 @@ namespace WorldBuilder void TianWaterContent::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; density = prm.get("density"); compositions = prm.get_vector("compositions"); max_water_content = prm.get("initial water content"); @@ -163,13 +163,20 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { // The polynomials break down for pressures less than 0.5 GPa, and for pressures above a user defined cutoff pressure diff --git a/source/world_builder/features/oceanic_plate_models/composition/uniform.cc b/source/world_builder/features/oceanic_plate_models/composition/uniform.cc index ea2c7f7c0..314925d4b 100644 --- a/source/world_builder/features/oceanic_plate_models/composition/uniform.cc +++ b/source/world_builder/features/oceanic_plate_models/composition/uniform.cc @@ -41,8 +41,8 @@ namespace WorldBuilder { Uniform::Uniform(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN) + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN) { this->world = world_; this->name = "uniform"; @@ -78,10 +78,10 @@ namespace WorldBuilder void Uniform::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; compositions = prm.get_vector("compositions"); fractions = prm.get_vector("fractions"); operation = string_operations_to_enum(prm.get("operation")); @@ -97,13 +97,20 @@ namespace WorldBuilder const double depth, const unsigned int composition_number, double composition, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { for (unsigned int i =0; i < compositions.size(); ++i) diff --git a/source/world_builder/features/oceanic_plate_models/temperature/adiabatic.cc b/source/world_builder/features/oceanic_plate_models/temperature/adiabatic.cc index d41973ad5..b0a32196b 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/adiabatic.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/adiabatic.cc @@ -41,8 +41,8 @@ namespace WorldBuilder { Adiabatic::Adiabatic(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), potential_mantle_temperature(NaN::DSNAN), thermal_expansion_coefficient(NaN::DSNAN), specific_heat(NaN::DSNAN), @@ -63,14 +63,14 @@ namespace WorldBuilder "Adiabatic temperature model. Uses global values by default."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the temperature of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the temperature of this feature is present."); + "The depth in m to which the temperature of this feature is present."); prm.declare_entry("potential mantle temperature", Types::Double(-1), - "The potential temperature of the mantle at the surface in Kelvin. " + "The potential temperature in K of the mantle at the surface. " "If the value is lower then zero, the global value is used."); prm.declare_entry("thermal expansion coefficient", Types::Double(-1), @@ -87,10 +87,10 @@ namespace WorldBuilder Adiabatic::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); potential_mantle_temperature = prm.get("potential mantle temperature"); @@ -131,33 +131,40 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { - const double adabatic_temperature = potential_mantle_temperature * - std::exp(((thermal_expansion_coefficient * gravity_norm) / - specific_heat) * depth); + const double temperature_calculated = potential_mantle_temperature * + std::exp(((thermal_expansion_coefficient * gravity_norm) / + specific_heat) * depth); - WBAssert(!std::isnan(adabatic_temperature), - "adabatic_temperature is not a number: " << adabatic_temperature << ". " - <<"Parameters: potential_mantle_temperature = " << potential_mantle_temperature - <<", thermal_expansion_coefficient = " << thermal_expansion_coefficient + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated + << ", based on a temperature model with the name " << this->name); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", potential_mantle_temperature = " << potential_mantle_temperature + << ", thermal_expansion_coefficient = " << thermal_expansion_coefficient << ", gravity_norm = " << gravity_norm << ", specific_heat = " << specific_heat << ", depth = " << depth); - WBAssert(std::isfinite(adabatic_temperature), - "adabatic_temperature is not a finite: " << adabatic_temperature << '.'); - - return apply_operation(operation,temperature_,adabatic_temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } diff --git a/source/world_builder/features/oceanic_plate_models/temperature/half_space_model.cc b/source/world_builder/features/oceanic_plate_models/temperature/half_space_model.cc index e6d80f203..024d3904c 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/half_space_model.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/half_space_model.cc @@ -45,8 +45,8 @@ namespace WorldBuilder { HalfSpaceModel::HalfSpaceModel(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), top_temperature(NaN::DSNAN), bottom_temperature(NaN::DSNAN), operation(Operations::REPLACE) @@ -67,7 +67,7 @@ namespace WorldBuilder "Half space cooling mode"); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), "The depth in meters from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), @@ -98,10 +98,10 @@ namespace WorldBuilder HalfSpaceModel::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); top_temperature = prm.get("top temperature"); bottom_temperature = prm.get("bottom temperature"); @@ -141,22 +141,30 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { Objects::NaturalCoordinate position_in_natural_coordinates_at_min_depth = Objects::NaturalCoordinate(position, *(world->parameters.coordinate_system)); - position_in_natural_coordinates_at_min_depth.get_ref_depth_coordinate() += depth-min_depth; + position_in_natural_coordinates_at_min_depth.get_ref_depth_coordinate() += depth-min_depth_local; std::vector> subducting_plate_velocities = {{0}}; std::vector ridge_migration_times = {0.0}; double bottom_temperature_local = bottom_temperature; + double top_temperature_local = top_temperature; if (bottom_temperature_local < 0) { @@ -172,30 +180,27 @@ namespace WorldBuilder subducting_plate_velocities, ridge_migration_times); - - const double thermal_diffusivity = this->world->thermal_diffusivity; const double age = ridge_parameters[1] / ridge_parameters[0]; - double temperature = bottom_temperature_local; + double temperature_calculated = bottom_temperature_local; - temperature = temperature + (age > 0 ? (top_temperature - bottom_temperature_local)*std::erfc(depth/(2*std::sqrt(thermal_diffusivity*age))) : 0.); + temperature_calculated = temperature_calculated + (age > 0 ? (top_temperature_local - bottom_temperature_local)*std::erfc(depth/(2*std::sqrt(thermal_diffusivity*age))) : 0.); - WBAssert(!std::isnan(temperature), "Temperature inside half-space cooling model is not a number: " << temperature - << ". Relevant variables: bottom_temperature_local = " << bottom_temperature_local - << ", top_temperature = " << top_temperature - << ", max_depth = " << max_depth - << ", spreading_velocity = " << ridge_parameters[0] - << ", thermal_diffusivity = " << thermal_diffusivity - << ", age = " << age << '.'); - WBAssert(std::isfinite(temperature), "Temperature inside half-space cooling model is not a finite: " << temperature << ". Relevant variables: bottom_temperature_local = " << bottom_temperature_local - << ", top_temperature = " << top_temperature + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated + << ", based on a temperature model with the name " << this->name); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", bottom_temperature_local = " << bottom_temperature_local + << ", top_temperature_local = " << top_temperature_local + << ", max_depth_local = " << max_depth_local << ", spreading_velocity = " << ridge_parameters[0] << ", thermal_diffusivity = " << thermal_diffusivity << ", age = " << age << '.'); - return apply_operation(operation,temperature_,temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } diff --git a/source/world_builder/features/oceanic_plate_models/temperature/linear.cc b/source/world_builder/features/oceanic_plate_models/temperature/linear.cc index c76478656..f9770bbdf 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/linear.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/linear.cc @@ -40,8 +40,8 @@ namespace WorldBuilder { Linear::Linear(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), top_temperature(NaN::DSNAN), bottom_temperature(NaN::DSNAN), operation(Operations::REPLACE) @@ -62,29 +62,29 @@ namespace WorldBuilder "Linear temperature model. Can be set to use an adiabatic temperature at the boundaries."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the temperature of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the temperature of this feature is present."); + "The depth in m to which the temperature of this feature is present."); prm.declare_entry("top temperature", Types::Double(293.15), - "The temperature at the top in degree Kelvin of this feature." + "The temperature in K at the top of this feature." "If the value is below zero, the an adiabatic temperature is used."); prm.declare_entry("bottom temperature", Types::Double(-1), - "The temperature at the top in degree Kelvin of this feature. " + "The temperature in K at the bottom of this feature. " "If the value is below zero, an adiabatic temperature is used."); } void Linear::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; - WBAssert(max_depth >= min_depth, "max depth needs to be larger or equal to min depth."); + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; + WBAssert(max_depth_entry >= min_depth_entry, "max depth needs to be larger or equal to min depth."); operation = string_operations_to_enum(prm.get("operation")); top_temperature = prm.get("top temperature"); bottom_temperature = prm.get("bottom temperature"); @@ -97,24 +97,28 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double feature_min_depth, - const double feature_max_depth) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { - const double min_depth_local_local = std::max(feature_min_depth, min_depth_local); - const double max_depth_local_local = std::min(feature_max_depth, max_depth_local); - double top_temperature_local = top_temperature; if (top_temperature_local < 0) { top_temperature_local = this->world->potential_mantle_temperature * std::exp(((this->world->thermal_expansion_coefficient * gravity_norm) / - this->world->specific_heat) * min_depth_local_local); + this->world->specific_heat) * min_depth_local); } double bottom_temperature_local = bottom_temperature; @@ -122,14 +126,27 @@ namespace WorldBuilder { bottom_temperature_local = this->world->potential_mantle_temperature * std::exp(((this->world->thermal_expansion_coefficient * gravity_norm) / - this->world->specific_heat) * max_depth_local_local); + this->world->specific_heat) * max_depth_local); } - const double new_temperature = top_temperature_local + (max_depth_local_local - min_depth_local_local < 10.0*std::numeric_limits::epsilon() ? 0.0 : - (depth - min_depth_local_local) * - ((bottom_temperature_local - top_temperature_local) / (max_depth_local_local - min_depth_local_local))); + const double temperature_calculated = top_temperature_local + (max_depth_local - min_depth_local < 10.0*std::numeric_limits::epsilon() ? 0.0 : + (depth - min_depth_local) * + (bottom_temperature_local - top_temperature_local) / (max_depth_local - min_depth_local)); + + WBAssert(!std::isnan(temperature_calculated), "Temperature is not a number: " << temperature_calculated + << ", based on a temperature model with the name " << this->name); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", depth = " << depth + << ", min_depth_local = " << min_depth_local + << ", max_depth_local = " << max_depth_local + << ", min_depth_feature = " << min_depth_feature + << ", max_depth_feature = " << max_depth_feature + << ", top_temperature_local=" << top_temperature_local + << ", bottom_temperature_local= " << bottom_temperature_local); - return apply_operation(operation,temperature_,new_temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } diff --git a/source/world_builder/features/oceanic_plate_models/temperature/plate_model.cc b/source/world_builder/features/oceanic_plate_models/temperature/plate_model.cc index 9184711f9..4035a092e 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/plate_model.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/plate_model.cc @@ -42,8 +42,8 @@ namespace WorldBuilder { PlateModel::PlateModel(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), top_temperature(NaN::DSNAN), bottom_temperature(NaN::DSNAN), operation(Operations::REPLACE) @@ -64,17 +64,17 @@ namespace WorldBuilder "Plate model."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the temperature of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the temperature of this feature is present."); + "The depth in m to which the temperature of this feature is present."); prm.declare_entry("top temperature", Types::Double(293.15), - "The temperature in degree Kelvin which this feature should have"); + "The temperature in K from which this feature should have"); prm.declare_entry("bottom temperature", Types::Double(-1), - "The temperature in degree Kelvin which this feature should have"); + "The temperature in K to which this feature should have"); prm.declare_entry("spreading velocity", Types::OneOf(Types::Double(0.05),Types::Array(Types::ValueAtPoints(0.05, std::numeric_limits::max()))), "The spreading velocity of the plate in meter per year. " @@ -92,10 +92,10 @@ namespace WorldBuilder PlateModel::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); top_temperature = prm.get("top temperature"); bottom_temperature = prm.get("bottom temperature"); @@ -136,21 +136,30 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { Objects::NaturalCoordinate position_in_natural_coordinates_at_min_depth = Objects::NaturalCoordinate(position, *(world->parameters.coordinate_system)); - position_in_natural_coordinates_at_min_depth.get_ref_depth_coordinate() += depth-min_depth; + position_in_natural_coordinates_at_min_depth.get_ref_depth_coordinate() += depth-min_depth_local; std::vector> subducting_plate_velocities = {{0}}; std::vector ridge_migration_times = {0.0}; + double bottom_temperature_local = bottom_temperature; + double top_temperature_local = top_temperature; if (bottom_temperature_local < 0) { @@ -170,36 +179,38 @@ namespace WorldBuilder const double thermal_diffusivity = this->world->thermal_diffusivity; const double age = ridge_parameters[1] / ridge_parameters[0]; - double temperature = top_temperature + (bottom_temperature_local - top_temperature) * (depth / max_depth); + double temperature_calculated = top_temperature_local + (bottom_temperature_local - top_temperature_local) * (depth / max_depth_local); // This formula addresses the horizontal heat transfer by having the spreading velocity and distance to the ridge in it. // (Chapter 7 Heat, Fowler M. The solid earth: an introduction to global geophysics[M]. Cambridge University Press, 1990) for (int i = 1; iname); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", depth = " << depth + << ", min_depth_local = " << min_depth_local + << ", max_depth_local = " << max_depth_local + << ", min_depth_feature = " << min_depth_feature + << ", max_depth_feature = " << max_depth_feature + << ", top_temperature_local=" << top_temperature_local + << ", bottom_temperature_local= " << bottom_temperature_local << ", spreading_velocity = " << ridge_parameters[0] << ", thermal_diffusivity = " << thermal_diffusivity << ", age = " << age << '.'); - WBAssert(std::isfinite(temperature), "Temperature inside plate model is not a finite: " << temperature << ". Relevant variables: bottom_temperature_local = " << bottom_temperature_local - << ", top_temperature = " << top_temperature - << ", spreading_velocity = " << ridge_parameters[0] - << ", thermal_diffusivity = " << thermal_diffusivity - << ", age = " << age << '.'); - - return apply_operation(operation,temperature_,temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } diff --git a/source/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.cc b/source/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.cc index 98e5b7e04..924ee7f9a 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/plate_model_constant_age.cc @@ -41,8 +41,8 @@ namespace WorldBuilder { PlateModelConstantAge::PlateModelConstantAge(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), top_temperature(NaN::DSNAN), bottom_temperature(NaN::DSNAN), operation(Operations::REPLACE) @@ -63,17 +63,17 @@ namespace WorldBuilder "Plate model, but with a fixed age."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the temperature of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the temperature of this feature is present."); + "The depth in m to which the temperature of this feature is present."); prm.declare_entry("top temperature", Types::Double(293.15), - "The temperature in degree Kelvin which this feature should have"); + "The temperature in K at the top surface of this feature."); prm.declare_entry("bottom temperature", Types::Double(-1), - "The temperature in degree Kelvin which this feature should have"); + "The temperature in K at the bottom surface of this feature."); prm.declare_entry("plate age", Types::Double(80e3), "The age of the plate in year. " @@ -84,10 +84,10 @@ namespace WorldBuilder PlateModelConstantAge::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); top_temperature = prm.get("top temperature"); bottom_temperature = prm.get("bottom temperature"); @@ -101,16 +101,24 @@ namespace WorldBuilder const double depth, const double gravity_norm, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { double bottom_temperature_local = bottom_temperature; + double top_temperature_local = top_temperature; if (bottom_temperature_local < 0) { @@ -123,30 +131,34 @@ namespace WorldBuilder // some aliases //const double top_temperature = top_temperature; const double thermal_diffusivity = this->world->thermal_diffusivity; - double temperature = top_temperature + (bottom_temperature_local - top_temperature) * (depth / max_depth); + double temperature_calculated = top_temperature_local + (bottom_temperature_local - top_temperature_local) * (depth / max_depth_local); // This formula ignores the horizontal heat transfer by just having the age of the plate in it. // (Chapter 7 Heat, Fowler M. The solid earth: an introduction to global geophysics[M]. Cambridge University Press, 1990) for (int i = 1; iname); + + WBAssert(std::isfinite(temperature_calculated), "Temperature is not a finite: " << temperature_calculated + << ", based on a temperature model with the name " << this->name + << ", depth = " << depth + << ", min_depth_local = " << min_depth_local + << ", max_depth_local = " << max_depth_local + << ", min_depth_feature = " << min_depth_feature + << ", max_depth_feature = " << max_depth_feature + << ", top_temperature_local=" << top_temperature_local + << ", bottom_temperature_local= " << bottom_temperature_local + << ", thermal_diffusivity = " << thermal_diffusivity + << ", plate_age = " << plate_age << '.'); - return apply_operation(operation,temperature_,temperature); + return apply_operation(operation,temperature_,temperature_calculated); } } diff --git a/source/world_builder/features/oceanic_plate_models/temperature/uniform.cc b/source/world_builder/features/oceanic_plate_models/temperature/uniform.cc index ec3bf293c..defc8c81a 100644 --- a/source/world_builder/features/oceanic_plate_models/temperature/uniform.cc +++ b/source/world_builder/features/oceanic_plate_models/temperature/uniform.cc @@ -40,8 +40,8 @@ namespace WorldBuilder { Uniform::Uniform(WorldBuilder::World *world_) : - min_depth(NaN::DSNAN), - max_depth(NaN::DSNAN), + min_depth_entry(NaN::DSNAN), + max_depth_entry(NaN::DSNAN), temperature(NaN::DSNAN), operation(Operations::REPLACE) { @@ -61,14 +61,14 @@ namespace WorldBuilder "Uniform temperature model. Set the temperature to a constant value."); // Declare entries of this plugin - prm.declare_entry("min depth", Types::OneOf(Types::Double(0),Types::Array(Types::ValueAtPoints(0., 2.))), - "The depth in meters from which the temperature of this feature is present."); + prm.declare_entry("min depth", Types::OneOf(Types::Double(-std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(-std::numeric_limits::max(), 2.))), + "The depth in m from which the temperature of this feature is present."); prm.declare_entry("max depth", Types::OneOf(Types::Double(std::numeric_limits::max()),Types::Array(Types::ValueAtPoints(std::numeric_limits::max(), 2.))), - "The depth in meters to which the temperature of this feature is present."); + "The depth in m to which the temperature of this feature is present."); prm.declare_entry("temperature", Types::Double(293.15), - "The temperature in degree Kelvin which this feature should have"); + "The temperature in K which this feature should have"); } @@ -76,10 +76,10 @@ namespace WorldBuilder Uniform::parse_entries(Parameters &prm, const std::vector> &coordinates) { - min_depth_surface = Objects::Surface(prm.get("min depth",coordinates)); - min_depth = min_depth_surface.minimum; - max_depth_surface = Objects::Surface(prm.get("max depth",coordinates)); - max_depth = max_depth_surface.maximum; + min_depth_surface_entry = Objects::Surface(prm.get("min depth",coordinates)); + min_depth_entry = min_depth_surface_entry.minimum; + max_depth_surface_entry = Objects::Surface(prm.get("max depth",coordinates)); + max_depth_entry = max_depth_surface_entry.maximum; operation = string_operations_to_enum(prm.get("operation")); temperature = prm.get("temperature"); } @@ -91,14 +91,20 @@ namespace WorldBuilder const double depth, const double /*gravity*/, double temperature_, - const double /*feature_min_depth*/, - const double /*feature_max_depth*/) const + const double min_depth_feature, + const double max_depth_feature) const { - - if (depth <= max_depth && depth >= min_depth) + if (depth <= max_depth_entry && depth >= min_depth_entry && depth <= max_depth_feature && depth >= min_depth_feature) { - const double min_depth_local = min_depth_surface.constant_value ? min_depth : min_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; - const double max_depth_local = max_depth_surface.constant_value ? max_depth : max_depth_surface.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + // check if the user defined min_depth and max_depth are constant values + // use those values if that is the case, find the surface point if not + double min_depth_point = min_depth_surface_entry.constant_value ? min_depth_entry : min_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + double max_depth_point = max_depth_surface_entry.constant_value ? max_depth_entry : max_depth_surface_entry.local_value(position_in_natural_coordinates.get_surface_point()).interpolated_value; + + // constrain the depth to the feature min and max depth + double min_depth_local = std::max(min_depth_feature, min_depth_point); + double max_depth_local = std::min(max_depth_feature, max_depth_point); + if (depth <= max_depth_local && depth >= min_depth_local) { return apply_operation(operation,temperature_,temperature);