24 lines
589 B
C++
24 lines
589 B
C++
// SPDX-FileCopyrightText: 2024 Filip Leonarski, Paul Scherrer Institute <filip.leonarski@psi.ch>
|
|
// SPDX-License-Identifier: GPL-3.0-only
|
|
|
|
#pragma once
|
|
|
|
#include <ostream>
|
|
#include <optional>
|
|
#include <vector>
|
|
|
|
struct UnitCell {
|
|
float a;
|
|
float b;
|
|
float c;
|
|
float alpha;
|
|
float beta;
|
|
float gamma;
|
|
|
|
bool is_finite() const;
|
|
bool is_close(const UnitCell &ref, float dist_tolerance, float angle_tolerance_deg) const;
|
|
};
|
|
|
|
std::ostream &operator<<(std::ostream &output, const UnitCell &in);
|
|
std::optional<UnitCell> MeanUnitCell(const std::vector<UnitCell> &cells);
|