コード例 #1
0
        public AstValueMultivector SubspaceToMultivector(string subspaceName, Func <AstFrameBasisBlade, string> basisBladeToVarName)
        {
            var subspaceInfo = Subspace(subspaceName);

            if (subspaceInfo.IsNullOrInvalid())
            {
                return(null);
            }

            var pattern = GMacMultivectorBinding.Create(subspaceInfo);

            return(pattern.ToValue(basisBladeToVarName));
        }
コード例 #2
0
        public AstValueMultivector SubspaceToMultivector(string subspaceName, StringSequenceTemplate varNameTemplate)
        {
            var subspaceInfo = Subspace(subspaceName);

            if (subspaceInfo.IsNullOrInvalid())
            {
                return(null);
            }

            var pattern = GMacMultivectorBinding.Create(subspaceInfo);

            return(pattern.ToValue(varNameTemplate));
        }
コード例 #3
0
        public MvClassData(AstFrame frame, int id, string name)
        {
            ClassId      = id;
            ClassName    = name;
            Frame        = frame;
            ClassBinding = GMacMultivectorBinding.Create(frame.FrameMultivector);

            if (id < 1)
            {
                return;
            }

            foreach (var grade in ClassGrades)
            {
                ClassBinding.BindKVectorToVariables(grade);
            }
        }