Defining new Command in tkz-euclide

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
4
down vote

favorite












How to define a new command



tkzDefRelativePoint[#1,#2,#3](20:2)C


This command defines a point from #1 and takes the slope of the line #2 , #3 as x axis.



tkzDefRelativePoint[A,A,B](20:2)C


This command defines a point from A and takes the slope of the line A , B as x axis.



This is done here using



tkzFindSlopeAngle(A,B)
tkzGetAngletkzangle
beginscope[rotate=tkzangle]
tkzDefShiftPoint[A](20:2)C
endscope


MWE



documentclass[border=2pt]standalone
usepackage[usenames,dvipsnames,svgnames]xcolor
usepackagetkz-euclide
usetkzobjall
definecolorfondpaillecmyk0,0,0.1,0
pagecolorfondpaille
colorMaroon

begindocument
begintikzpicture
tkzInit[xmax=4, ymax=3]
tkzAxeXY
tkzGrid[color=orange]
tkzDefPoint(1,0)A
tkzDefPoint(3,2)B
tkzDefShiftPoint[A](20:2)C'
%
tkzFindSlopeAngle(A,B)
tkzGetAngletkzangle
beginscope[rotate=tkzangle]
tkzDefShiftPoint[A](20:2)C
endscope
%
%tkzDefRelativePoint[A,A,B](20:2)C
%
tkzDrawSegment(A,B)
tkzDrawSegment[color=red](A,C)

tkzDrawPoints(A,B,C,C')
tkzLabelPoints(A,B,C,C')
endtikzpicture

enddocument


enter image description here







share|improve this question
























    up vote
    4
    down vote

    favorite












    How to define a new command



    tkzDefRelativePoint[#1,#2,#3](20:2)C


    This command defines a point from #1 and takes the slope of the line #2 , #3 as x axis.



    tkzDefRelativePoint[A,A,B](20:2)C


    This command defines a point from A and takes the slope of the line A , B as x axis.



    This is done here using



    tkzFindSlopeAngle(A,B)
    tkzGetAngletkzangle
    beginscope[rotate=tkzangle]
    tkzDefShiftPoint[A](20:2)C
    endscope


    MWE



    documentclass[border=2pt]standalone
    usepackage[usenames,dvipsnames,svgnames]xcolor
    usepackagetkz-euclide
    usetkzobjall
    definecolorfondpaillecmyk0,0,0.1,0
    pagecolorfondpaille
    colorMaroon

    begindocument
    begintikzpicture
    tkzInit[xmax=4, ymax=3]
    tkzAxeXY
    tkzGrid[color=orange]
    tkzDefPoint(1,0)A
    tkzDefPoint(3,2)B
    tkzDefShiftPoint[A](20:2)C'
    %
    tkzFindSlopeAngle(A,B)
    tkzGetAngletkzangle
    beginscope[rotate=tkzangle]
    tkzDefShiftPoint[A](20:2)C
    endscope
    %
    %tkzDefRelativePoint[A,A,B](20:2)C
    %
    tkzDrawSegment(A,B)
    tkzDrawSegment[color=red](A,C)

    tkzDrawPoints(A,B,C,C')
    tkzLabelPoints(A,B,C,C')
    endtikzpicture

    enddocument


    enter image description here







    share|improve this question






















      up vote
      4
      down vote

      favorite









      up vote
      4
      down vote

      favorite











      How to define a new command



      tkzDefRelativePoint[#1,#2,#3](20:2)C


      This command defines a point from #1 and takes the slope of the line #2 , #3 as x axis.



      tkzDefRelativePoint[A,A,B](20:2)C


      This command defines a point from A and takes the slope of the line A , B as x axis.



      This is done here using



      tkzFindSlopeAngle(A,B)
      tkzGetAngletkzangle
      beginscope[rotate=tkzangle]
      tkzDefShiftPoint[A](20:2)C
      endscope


      MWE



      documentclass[border=2pt]standalone
      usepackage[usenames,dvipsnames,svgnames]xcolor
      usepackagetkz-euclide
      usetkzobjall
      definecolorfondpaillecmyk0,0,0.1,0
      pagecolorfondpaille
      colorMaroon

      begindocument
      begintikzpicture
      tkzInit[xmax=4, ymax=3]
      tkzAxeXY
      tkzGrid[color=orange]
      tkzDefPoint(1,0)A
      tkzDefPoint(3,2)B
      tkzDefShiftPoint[A](20:2)C'
      %
      tkzFindSlopeAngle(A,B)
      tkzGetAngletkzangle
      beginscope[rotate=tkzangle]
      tkzDefShiftPoint[A](20:2)C
      endscope
      %
      %tkzDefRelativePoint[A,A,B](20:2)C
      %
      tkzDrawSegment(A,B)
      tkzDrawSegment[color=red](A,C)

      tkzDrawPoints(A,B,C,C')
      tkzLabelPoints(A,B,C,C')
      endtikzpicture

      enddocument


      enter image description here







      share|improve this question












      How to define a new command



      tkzDefRelativePoint[#1,#2,#3](20:2)C


      This command defines a point from #1 and takes the slope of the line #2 , #3 as x axis.



      tkzDefRelativePoint[A,A,B](20:2)C


      This command defines a point from A and takes the slope of the line A , B as x axis.



      This is done here using



      tkzFindSlopeAngle(A,B)
      tkzGetAngletkzangle
      beginscope[rotate=tkzangle]
      tkzDefShiftPoint[A](20:2)C
      endscope


      MWE



      documentclass[border=2pt]standalone
      usepackage[usenames,dvipsnames,svgnames]xcolor
      usepackagetkz-euclide
      usetkzobjall
      definecolorfondpaillecmyk0,0,0.1,0
      pagecolorfondpaille
      colorMaroon

      begindocument
      begintikzpicture
      tkzInit[xmax=4, ymax=3]
      tkzAxeXY
      tkzGrid[color=orange]
      tkzDefPoint(1,0)A
      tkzDefPoint(3,2)B
      tkzDefShiftPoint[A](20:2)C'
      %
      tkzFindSlopeAngle(A,B)
      tkzGetAngletkzangle
      beginscope[rotate=tkzangle]
      tkzDefShiftPoint[A](20:2)C
      endscope
      %
      %tkzDefRelativePoint[A,A,B](20:2)C
      %
      tkzDrawSegment(A,B)
      tkzDrawSegment[color=red](A,C)

      tkzDrawPoints(A,B,C,C')
      tkzLabelPoints(A,B,C,C')
      endtikzpicture

      enddocument


      enter image description here









      share|improve this question











      share|improve this question




      share|improve this question










      asked Aug 14 at 9:17









      sandu

      3,15042351




      3,15042351




















          1 Answer
          1






          active

          oldest

          votes

















          up vote
          4
          down vote



          accepted










          Of course, in this case, the bracketed term is not "optional", but just part of the syntax.



          documentclass[border=2pt]standalone
          usepackage[usenames,dvipsnames,svgnames]xcolor
          usepackagetkz-euclide
          usetkzobjall
          definecolorfondpaillecmyk0,0,0.1,0
          pagecolorfondpaille
          colorMaroon
          deftkzDefRelativePoint[#1,#2,#3](#4)#5%
          tkzFindSlopeAngle(#2,#3)
          tkzGetAngletkzangle
          beginscope[rotate=tkzangle]
          tkzDefShiftPoint[#1](#4)#5
          endscope

          begindocument
          begintikzpicture
          tkzInit[xmax=4, ymax=3]
          tkzAxeXY
          tkzGrid[color=orange]
          tkzDefPoint(1,0)A
          tkzDefPoint(3,2)B
          tkzDefShiftPoint[A](20:2)C'
          %
          %tkzFindSlopeAngle(A,B)
          %tkzGetAngletkzangle
          %beginscope[rotate=tkzangle]
          %tkzDefShiftPoint[A](20:2)C
          %endscope
          %
          tkzDefRelativePoint[A,A,B](20:2)C
          %
          tkzDrawSegment(A,B)
          tkzDrawSegment[color=red](A,C)

          tkzDrawPoints(A,B,C,C')
          tkzLabelPoints(A,B,C,C')
          endtikzpicture

          enddocument





          share|improve this answer




















            Your Answer







            StackExchange.ready(function()
            var channelOptions =
            tags: "".split(" "),
            id: "85"
            ;
            initTagRenderer("".split(" "), "".split(" "), channelOptions);

            StackExchange.using("externalEditor", function()
            // Have to fire editor after snippets, if snippets enabled
            if (StackExchange.settings.snippets.snippetsEnabled)
            StackExchange.using("snippets", function()
            createEditor();
            );

            else
            createEditor();

            );

            function createEditor()
            StackExchange.prepareEditor(
            heartbeatType: 'answer',
            convertImagesToLinks: false,
            noModals: false,
            showLowRepImageUploadWarning: true,
            reputationToPostImages: null,
            bindNavPrevention: true,
            postfix: "",
            onDemand: true,
            discardSelector: ".discard-answer"
            ,immediatelyShowMarkdownHelp:true
            );



            );













             

            draft saved


            draft discarded


















            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f445982%2fdefining-new-command-in-tkz-euclide%23new-answer', 'question_page');

            );

            Post as a guest






























            1 Answer
            1






            active

            oldest

            votes








            1 Answer
            1






            active

            oldest

            votes









            active

            oldest

            votes






            active

            oldest

            votes








            up vote
            4
            down vote



            accepted










            Of course, in this case, the bracketed term is not "optional", but just part of the syntax.



            documentclass[border=2pt]standalone
            usepackage[usenames,dvipsnames,svgnames]xcolor
            usepackagetkz-euclide
            usetkzobjall
            definecolorfondpaillecmyk0,0,0.1,0
            pagecolorfondpaille
            colorMaroon
            deftkzDefRelativePoint[#1,#2,#3](#4)#5%
            tkzFindSlopeAngle(#2,#3)
            tkzGetAngletkzangle
            beginscope[rotate=tkzangle]
            tkzDefShiftPoint[#1](#4)#5
            endscope

            begindocument
            begintikzpicture
            tkzInit[xmax=4, ymax=3]
            tkzAxeXY
            tkzGrid[color=orange]
            tkzDefPoint(1,0)A
            tkzDefPoint(3,2)B
            tkzDefShiftPoint[A](20:2)C'
            %
            %tkzFindSlopeAngle(A,B)
            %tkzGetAngletkzangle
            %beginscope[rotate=tkzangle]
            %tkzDefShiftPoint[A](20:2)C
            %endscope
            %
            tkzDefRelativePoint[A,A,B](20:2)C
            %
            tkzDrawSegment(A,B)
            tkzDrawSegment[color=red](A,C)

            tkzDrawPoints(A,B,C,C')
            tkzLabelPoints(A,B,C,C')
            endtikzpicture

            enddocument





            share|improve this answer
























              up vote
              4
              down vote



              accepted










              Of course, in this case, the bracketed term is not "optional", but just part of the syntax.



              documentclass[border=2pt]standalone
              usepackage[usenames,dvipsnames,svgnames]xcolor
              usepackagetkz-euclide
              usetkzobjall
              definecolorfondpaillecmyk0,0,0.1,0
              pagecolorfondpaille
              colorMaroon
              deftkzDefRelativePoint[#1,#2,#3](#4)#5%
              tkzFindSlopeAngle(#2,#3)
              tkzGetAngletkzangle
              beginscope[rotate=tkzangle]
              tkzDefShiftPoint[#1](#4)#5
              endscope

              begindocument
              begintikzpicture
              tkzInit[xmax=4, ymax=3]
              tkzAxeXY
              tkzGrid[color=orange]
              tkzDefPoint(1,0)A
              tkzDefPoint(3,2)B
              tkzDefShiftPoint[A](20:2)C'
              %
              %tkzFindSlopeAngle(A,B)
              %tkzGetAngletkzangle
              %beginscope[rotate=tkzangle]
              %tkzDefShiftPoint[A](20:2)C
              %endscope
              %
              tkzDefRelativePoint[A,A,B](20:2)C
              %
              tkzDrawSegment(A,B)
              tkzDrawSegment[color=red](A,C)

              tkzDrawPoints(A,B,C,C')
              tkzLabelPoints(A,B,C,C')
              endtikzpicture

              enddocument





              share|improve this answer






















                up vote
                4
                down vote



                accepted







                up vote
                4
                down vote



                accepted






                Of course, in this case, the bracketed term is not "optional", but just part of the syntax.



                documentclass[border=2pt]standalone
                usepackage[usenames,dvipsnames,svgnames]xcolor
                usepackagetkz-euclide
                usetkzobjall
                definecolorfondpaillecmyk0,0,0.1,0
                pagecolorfondpaille
                colorMaroon
                deftkzDefRelativePoint[#1,#2,#3](#4)#5%
                tkzFindSlopeAngle(#2,#3)
                tkzGetAngletkzangle
                beginscope[rotate=tkzangle]
                tkzDefShiftPoint[#1](#4)#5
                endscope

                begindocument
                begintikzpicture
                tkzInit[xmax=4, ymax=3]
                tkzAxeXY
                tkzGrid[color=orange]
                tkzDefPoint(1,0)A
                tkzDefPoint(3,2)B
                tkzDefShiftPoint[A](20:2)C'
                %
                %tkzFindSlopeAngle(A,B)
                %tkzGetAngletkzangle
                %beginscope[rotate=tkzangle]
                %tkzDefShiftPoint[A](20:2)C
                %endscope
                %
                tkzDefRelativePoint[A,A,B](20:2)C
                %
                tkzDrawSegment(A,B)
                tkzDrawSegment[color=red](A,C)

                tkzDrawPoints(A,B,C,C')
                tkzLabelPoints(A,B,C,C')
                endtikzpicture

                enddocument





                share|improve this answer












                Of course, in this case, the bracketed term is not "optional", but just part of the syntax.



                documentclass[border=2pt]standalone
                usepackage[usenames,dvipsnames,svgnames]xcolor
                usepackagetkz-euclide
                usetkzobjall
                definecolorfondpaillecmyk0,0,0.1,0
                pagecolorfondpaille
                colorMaroon
                deftkzDefRelativePoint[#1,#2,#3](#4)#5%
                tkzFindSlopeAngle(#2,#3)
                tkzGetAngletkzangle
                beginscope[rotate=tkzangle]
                tkzDefShiftPoint[#1](#4)#5
                endscope

                begindocument
                begintikzpicture
                tkzInit[xmax=4, ymax=3]
                tkzAxeXY
                tkzGrid[color=orange]
                tkzDefPoint(1,0)A
                tkzDefPoint(3,2)B
                tkzDefShiftPoint[A](20:2)C'
                %
                %tkzFindSlopeAngle(A,B)
                %tkzGetAngletkzangle
                %beginscope[rotate=tkzangle]
                %tkzDefShiftPoint[A](20:2)C
                %endscope
                %
                tkzDefRelativePoint[A,A,B](20:2)C
                %
                tkzDrawSegment(A,B)
                tkzDrawSegment[color=red](A,C)

                tkzDrawPoints(A,B,C,C')
                tkzLabelPoints(A,B,C,C')
                endtikzpicture

                enddocument






                share|improve this answer












                share|improve this answer



                share|improve this answer










                answered Aug 14 at 10:18









                Steven B. Segletes

                146k9185387




                146k9185387



























                     

                    draft saved


                    draft discarded















































                     


                    draft saved


                    draft discarded














                    StackExchange.ready(
                    function ()
                    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f445982%2fdefining-new-command-in-tkz-euclide%23new-answer', 'question_page');

                    );

                    Post as a guest













































































                    Comments

                    Popular posts from this blog

                    What does second last employer means? [closed]

                    Installing NextGIS Connect into QGIS 3?

                    One-line joke