Package cc.redberry.core.combinatorics

Examples of cc.redberry.core.combinatorics.Symmetries


    private final Symmetries symmetries;
    private short[] diffIds = null;

    IndicesSymmetries(IndicesTypeStructure indicesTypeStructure) {
        this.indicesTypeStructure = indicesTypeStructure;
        this.symmetries = new Symmetries(indicesTypeStructure.size());
    }
View Full Code Here


    private final Symmetries symmetries;
    private short[] diffIds = null;

    IndicesSymmetries(IndicesTypeStructure indicesTypeStructure) {
        this.indicesTypeStructure = indicesTypeStructure;
        this.symmetries = new Symmetries(indicesTypeStructure.size());
    }
View Full Code Here

    public Tensor transform(Tensor tensor) {
        if (!tensor.getIndices().getFreeIndices().equalsIgnoreOrder(indices))
            return tensor;
        if (symmetries.isEmpty())
            return TensorNumber.createZERO();
        Symmetries tensorSymmetries = IndexMappingUtils.getSymmetriesFromMappings(indices, tensor, allowDiffStates);

        List<Tensor> generatedTensors = new ArrayList<>();
        List<Permutation> generatedPermutations = new ArrayList<>();
        OUT:
        for (Permutation permutation : symmetries) {
View Full Code Here

//        for (IndexMappingBufferImpl buffer : buffers)
//            symmetries.add(getSymmetryFromMapping(indices, buffer));
//        return symmetries;
//    }
    public static Symmetries getSymmetriesFromMappings(Indices indices, OutputPortUnsafe<IndexMappingBuffer> buffers) {
        Symmetries symmetries = new Symmetries(indices.size());
        IndexMappingBuffer buffer;
        while ((buffer = buffers.take()) != null)
            symmetries.add(getSymmetryFromMapping(indices, buffer));
        return symmetries;
    }
View Full Code Here

TOP

Related Classes of cc.redberry.core.combinatorics.Symmetries

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.