Class StructureMaterial
Represents a material with physical and thermal properties used in structural analysis.
public class StructureMaterial : IStructureMaterial, IMakeXmlSource, IDuplicate, INameNote, IToXElement
- Inheritance
-
StructureMaterial
- Implements
- Inherited Members
- Extension Methods
Constructors
StructureMaterial()
Default constructor.
public StructureMaterial()
StructureMaterial(StructureMaterial)
Creates a new cutter material as a copy of an existing one.
public StructureMaterial(StructureMaterial src)
Parameters
srcStructureMaterialThe source material to copy from.
StructureMaterial(XElement)
Ctor.
public StructureMaterial(XElement src)
Parameters
srcXElementXML
Properties
AlloySteel42CrMo
Gets a predefined 42CrMo alloy steel material commonly used for milling cutter bodies. The strengths are the quenched-and-tempered minimums of GB/T 3077 (42CrMo: Rm ≥ 1080 MPa, ReL ≥ 930 MPa).
public static StructureMaterial AlloySteel42CrMo { get; }
Property Value
Density_gdcm3
Gets or sets the density in grams per cubic centimeter. NaN when the file the material was read from has no such element (not given); see HasThermalConstants.
public double Density_gdcm3 { get; set; }
Property Value
Density_gdm3
Density in g/m³.
public double Density_gdm3 { get; set; }
Property Value
Density_gdmm3
Density in g/mm³.
public double Density_gdmm3 { get; set; }
Property Value
ElasticModulus_GPa
Gets or sets the elastic modulus in gigapascals.
public double ElasticModulus_GPa { get; set; }
Property Value
HasThermalConstants
Whether the three thermal constants the thermal model reads are given: none of
HeatConductivity_WdmK, Density_gdcm3 and HeatCapacity_JdgK
is NaN. A material file without one of the elements reads it as NaN (not given) and no default
stands in; the thermal model then skips the material as it skips one that is missing, and
MaterialThermalConstantCheck names it (Material-ThermalConstants–NotGiven).
A constant that is given but not usable (0, negative, infinite) counts as given: the model runs
with it as it is, and the check names it apart. The three material classes implement it as
well: a default interface member is reachable through the interface type alone, and a cutter's
flute material and a workpiece's material are held by their class types.
public bool HasThermalConstants { get; }
Property Value
HeatCapacity_JdgK
Gets or sets the heat capacity in Joules per gram-Kelvin. NaN when the file the material was read from has no such element (not given); see HasThermalConstants.
public double HeatCapacity_JdgK { get; set; }
Property Value
HeatConductivity_WdmK
Gets or sets the heat transfer coefficient in Watts per meter-Kelvin. NaN when the file the material was read from has no such element (not given); see HasThermalConstants.
public double HeatConductivity_WdmK { get; set; }
Property Value
HeatConductivity_WdmmK
Heat transfer coefficient in W/(mm·K).
public double HeatConductivity_WdmmK { get; set; }
Property Value
Name
Gets or sets the name of the object.
public string Name { get; set; }
Property Value
Note
Gets or sets the descriptive note for the object.
public string Note { get; set; }
Property Value
PoissonRatio
public double PoissonRatio { get; set; }
Property Value
TensileStrength_MPa
Ultimate tensile strength in MPa — the stress at rupture.
public double TensileStrength_MPa { get; set; }
Property Value
ThermalExpansionCoefficient_dMK
public double ThermalExpansionCoefficient_dMK { get; set; }
Property Value
XName
Name for XML IO.
public static string XName { get; }
Property Value
YieldStrength_MPa
Yield strength in MPa — the stress at which the material starts to deform permanently. NaN (the default) when not known, and for materials without a yield point; the yielding stress ratio then rates the beam against TensileStrength_MPa.
public double YieldStrength_MPa { get; set; }
Property Value
YieldingStressLimit_MPa
The stress, in MPa, a beam section of this material is rated against in the yielding stress ratio (section stress ÷ this): the yield strength where the material yields, the rupture (tensile) strength where it does not — carbides and ceramics have no yield point — and NaN where the material does not know its strength, so the ratio reads NaN instead of a fake-safe 0. This default answers NaN; StructureMaterial and CutterMaterial answer from their strength members.
public double YieldingStressLimit_MPa { get; }
Property Value
Methods
Duplicate(params object[])
Creates a deep copy of the object, excluding any source file references.
public object Duplicate(params object[] res)
Parameters
resobject[]Optional parameters that may be needed during the duplication process
Returns
- object
A new instance that is a deep copy of the original object
MakeXmlSource(string, string, bool)
Creates an XML representation of the object. This method may also generate additional resources such as related files.
public virtual XElement MakeXmlSource(string baseDirectory, string relFile, bool exhibitionOnly)
Parameters
baseDirectorystringThe base directory for resolving relative paths
relFilestringThe relative file path for the XML source
exhibitionOnlyboolif true, the extended file creation is suppressed.
Returns
- XElement
An XML element representing the object's state
Remarks
For the demand of easy moving source folder (especially project folder) without configuration file path corruption, the relative file path is applied.
The baseDirectory is typically the folder at the nearest configuration file folder.
Since the folder can be moving with the configuration file.
Reg(XFactory)
Registers this type's deserializer with the given XFactory
and chains Reg(factory) on dependents. Idempotent.
public static void Reg(XFactory factory = null)
Parameters
factoryXFactory
ToXElement()
Get the XElement to represent the object.
public XElement ToXElement()