Exemplo n.º 1
0
        public static void Usage(StringBuilder sb)
        {
            string name = Aids.AspectName(PickAspect.PrimeGen);

            sb
            .WL()
            .WL(0, $"{name} (gen|bits|bitsimg) [options]")
            .WL(1, "--debug", "Show debug messages (implies -v)")
            .WL(1, "-v", "Show extra information")
            .WL()
            .WL(0, "gen", "Generates a sequence of prime numbers and outputs one per line")
            .WL(1, "-t (type)", "Type of generator to use (leave empty to list the types)")
            .WL(1, "-s (number)", "Starting number for the generator (default 2)")
            .WL(1, "-e (number)", "Ending number for the generator (default 100)")
            .WL(1, "-f (file)", "Optional text file to store primes")
            //.WL()
            //.WL(0,"bits"       ,"Generate array of bits with primes as 1s and composites as 0s")
            //.WL(1,"-t (type)"  ,"Type of generator to use (leave empty to list the types)")
            //.WL(1,"-s (number)","Starting number for the generator (default 2)")
            //.WL(1,"-e (number)","Ending number for the generator (default 100) or use -l")
            //.WL(1,"-l (size)"  ,"Target size of file. can specify K/M/G/T/E suffixes or use -e")
            //.WL(1,"-f (file)"  ,"File to store the bits")
            //.WL()
            //.WL(0,"bitsimg"    ,"Generate an image using the prime number bit array process")
            //.WL(1,"-t (type)"  ,"Type of generator to use (leave empty to list the types)")
            //.WL(1,"-s (number)","Starting number for the generator (default 2)")
            //.WL(1,"-d (w) (h)" ,"Dimensions of the image (width and height)")
            //.WL(1,"-c (number)","Bits per color between 1 and 48 (default 1)")
            //.WL(1,"-p (file)"  ,"Color palette file to use for coloring")
            //.WL(1,"-f (file)"  ,"File to store image")
            ;
        }
Exemplo n.º 2
0
        public static void Usage(StringBuilder sb)
        {
            string name = Aids.AspectName(PickAspect.Factors);

            sb
            .WL()
            .WL(0, $"{name} (number) [options]")
            .WL(1, "-m (method)", "Use another method (default Basic)")
            .WL()
            .WL(0, "Methods:")
            .PrintEnum <PickMethod>(1)
            ;
        }
Exemplo n.º 3
0
        public static void Usage(StringBuilder sb)
        {
            string name = Aids.AspectName(PickAspect.AltMat);

            sb
            .WL()
            .WL(0, $"{name} (function) [number] [options]")
            .WL(1, "Implementations of some math functions using various numeric methods")
            .WL(0, "Options:")
            .WL(1, "-b (number)", "Series start number")
            .WL(1, "-e (number)", "Series end number")
            .WL(1, "-s (number)", "Series step amount")
            .WL(1, "-a (number)", "Accuracy (for functions that support it)")
            .WL(1, "-io", "Print both input and output")
            .WL()
            .WL(0, "Functions:")
            ;
            ListFuntions(sb);
        }
Exemplo n.º 4
0
        public static void Usage(StringBuilder sb)
        {
            string name = Aids.AspectName(PickAspect.SequenceGen);

            sb
            .WL()
            .WL(0, $"{name} (sequence) [options]")
            .WL(1, "A set of algorithms that can continuously produce digits of infinite series")
            .WL(0, "Options:")
            .WL(1, "-b (number)", "Output number in given base (if generator supports it)")
            .WL(1, "-d (number)", "Number of digits to print (default 1000)")
            .WL(1, "-d-", "Keep printing numbers until process is killed")
            .WL(1, "-f (file)", "Write digits to a file instead of standard out")
            .WL(1, "-v", "Show progress bar and stats")
            .WL(1, "-n", "Insert newlines periodically")
            .WL(1, "-nw", "Number of characters between newlines (default 80)")
            .WL()
            .WL(0, "Sequences:")
            ;
            AppendSequences(sb);
        }