Open Lazersmoke opened 1 year ago
In my material LaSrCrO4, there is a lattice site where there is 50% of the time a La and 50% of the time a Sr. The .cif I have (attached) lists these both at the same site, but 0.5 occupancy. Sunny complains:
.cif
0.5
Sunny
Reference positions [0.0, 0.0, 0.359] and [0.0, 0.0, 0.359] are symmetry equivalent. Stacktrace: [1] error(s::String) @ Base .\error.jl:35 [2] crystal_from_symops(latvecs::StaticArraysCore.SMatrix{3, 3, Float64, 9}, positions::Vector{StaticArraysCore.SVector{3, Float64}}, types::Vector{String}, symops::Vector{Sunny.SymOp}, spacegroup::String; symprec::Float64) @ Sunny C:\Users\Sam\.julia\dev\Sunny\src\Symmetry\Crystal.jl:358 [3] crystal_from_symops @ C:\Users\Sam\.julia\dev\Sunny\src\Symmetry\Crystal.jl:341 [inlined] [4] Crystal(filename::String; symprec::Float64) @ Sunny C:\Users\Sam\.julia\dev\Sunny\src\Symmetry\Parsing.jl:168 [5] top-level scope @ In[54]:1
which is completely true, it should just make a Crystal with type "La/Sr" in this situation instead of complaining.
"La/Sr"
(Maybe related to #31 )
example_cif.zip
I like the error in the general case, because it forces people to think about what they want. Maybe we should allow "opt in" merging of sites:
Crystal("example.cif"; merge_sites=true)
In my material LaSrCrO4, there is a lattice site where there is 50% of the time a La and 50% of the time a Sr. The
.cif
I have (attached) lists these both at the same site, but0.5
occupancy.Sunny
complains:which is completely true, it should just make a Crystal with type
"La/Sr"
in this situation instead of complaining.(Maybe related to #31 )
example_cif.zip