Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F97869921
units.hpp
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Tue, Jan 7, 00:04
Size
666 B
Mime Type
text/x-c
Expires
Thu, Jan 9, 00:04 (2 d)
Engine
blob
Format
Raw Data
Handle
23424121
Attached To
rSPECMICP SpecMiCP / ReactMiCP
units.hpp
View Options
#ifndef SPECMICP_IO_UNITS_HPP
#define SPECMICP_IO_UNITS_HPP
#include <string>
#include "physics/units.hpp"
namespace specmicp {
namespace io {
std::string length_unit_to_string(units::LengthUnit length_u)
{
switch (length_u) {
case units::LengthUnit::meter:
return "m";
break;
case units::LengthUnit::decimeter:
return "dm";
break;
case units::LengthUnit::centimeter:
return "cm";
break;
}
}
std::string volume_unit_to_string(units::LengthUnit length_u)
{
return length_unit_to_string(length_u) + "^3";
}
} // end namespace io
} // end namespace specmicp
#endif // SPECMICP_IO_UNITS_HPP
Event Timeline
Log In to Comment