Package cc.redberry.core.tensorgenerator

Examples of cc.redberry.core.tensorgenerator.SymbolsGenerator.take()


                if (!tensorSubstitutions.containsKey(split.factor)) {
                    //map does not contains rule for current scalar (e.g. k_{i}*k^{i})
                    Tensor s;
                    //adding new rule for the scalar, e.g. k_{i}*k^{i} = scalar2
                    tensorSubstitutions.put(split.factor, s = generator.take());
                    //replacing this scalar with symbol
                    iterator.set(Tensors.multiply(s, split.summand));
                } else
                    //map is already contains rule for current scalar
                    //replacing this scalar with symbol from map
View Full Code Here


                Tensor[] scalars = ((Product) t).getContent().getScalars();
                for (Tensor scalar : scalars) {
                    if (!tensorSubstitutions.containsKey(scalar)) {
                        //map does not contains rule for current scalar (e.g. k_{i}*k^{i})
                        //adding new rule for the scalar, e.g. k_{i}*k^{i} = scalar2
                        tensorSubstitutions.put(scalar, generator.take());
                    }
                }
            }
        }

View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.