Drawing a cuve which start in (-2,-4) goes in (0,0) and then in (4,4)
Clash Royale CLAN TAG#URR8PPP
up vote
2
down vote
favorite
Hi I write this code but I don't understand why its not curve..
documentclass[12pt]report
begindocument
beginfigure [H]
begintikzpicture
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
draw (-2,-4) .. controls (0,0) and (0,0)..(5,5);
endtikzpicture
endfigure
enddocument
I need to do this thanks
where are the errors??
tikz-pgf
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
add a comment |Â
up vote
2
down vote
favorite
Hi I write this code but I don't understand why its not curve..
documentclass[12pt]report
begindocument
beginfigure [H]
begintikzpicture
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
draw (-2,-4) .. controls (0,0) and (0,0)..(5,5);
endtikzpicture
endfigure
enddocument
I need to do this thanks
where are the errors??
tikz-pgf
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I'd use three points and to the control points as relative polar coordinates,++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.
– daleif
25 mins ago
You need to put the lineusepackagetikz
in your preamble, and change the capital H to a small h inbeginfigure[H]
. That's what is preventing your current code from compiling!
– Thevesh Theva
24 mins ago
add a comment |Â
up vote
2
down vote
favorite
up vote
2
down vote
favorite
Hi I write this code but I don't understand why its not curve..
documentclass[12pt]report
begindocument
beginfigure [H]
begintikzpicture
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
draw (-2,-4) .. controls (0,0) and (0,0)..(5,5);
endtikzpicture
endfigure
enddocument
I need to do this thanks
where are the errors??
tikz-pgf
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Hi I write this code but I don't understand why its not curve..
documentclass[12pt]report
begindocument
beginfigure [H]
begintikzpicture
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
draw (-2,-4) .. controls (0,0) and (0,0)..(5,5);
endtikzpicture
endfigure
enddocument
I need to do this thanks
where are the errors??
tikz-pgf
tikz-pgf
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
asked 56 mins ago


Tommaso Dellolmo
403
403
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
New contributor
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Tommaso Dellolmo is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
I'd use three points and to the control points as relative polar coordinates,++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.
– daleif
25 mins ago
You need to put the lineusepackagetikz
in your preamble, and change the capital H to a small h inbeginfigure[H]
. That's what is preventing your current code from compiling!
– Thevesh Theva
24 mins ago
add a comment |Â
I'd use three points and to the control points as relative polar coordinates,++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.
– daleif
25 mins ago
You need to put the lineusepackagetikz
in your preamble, and change the capital H to a small h inbeginfigure[H]
. That's what is preventing your current code from compiling!
– Thevesh Theva
24 mins ago
I'd use three points and to the control points as relative polar coordinates,
++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.– daleif
25 mins ago
I'd use three points and to the control points as relative polar coordinates,
++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.– daleif
25 mins ago
You need to put the line
usepackagetikz
in your preamble, and change the capital H to a small h in beginfigure[H]
. That's what is preventing your current code from compiling!– Thevesh Theva
24 mins ago
You need to put the line
usepackagetikz
in your preamble, and change the capital H to a small h in beginfigure[H]
. That's what is preventing your current code from compiling!– Thevesh Theva
24 mins ago
add a comment |Â
1 Answer
1
active
oldest
votes
up vote
5
down vote
There's certainly more powerful tools available. Nevertheless, here's a simple approach that renders:
Here's the code:
documentclass[12pt,border=6pt]standalone
usepackagetikz
usetikzlibrarycalc
begindocument
defaeAngleAB80
defaeAngleCD55
defaeANgleEF5
begintikzpicture[%%
%% control point/.style=inner sep=2pt,circle,draw=red,
control point/.style=inner sep=2pt,circle,
primary point/.style=inner sep=2pt,circle,draw=blue,
]
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
node[primary point] (P1) at (-2,-4) ;
node[primary point] (P2) at (0,0) ;
node[primary point] (P3) at (7,4) ;
node[control point] (C1) at ($(P1)+(aeAngleAB:10pt)$) ;
node[control point] (C2) at ($(P2)+(180+aeAngleCD:40pt)$) ;
node[control point] (C3) at ($(P2)+(aeAngleCD:110pt)$) ;
node[control point] (C4) at ($(P3)+(180+aeANgleEF:60pt)$) ;
%% path[dashed,magenta,draw] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
path[dashed,magenta] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
draw[blue] (P1) .. controls (C1) and (C2) .. (P2);
draw[blue] (P2) .. controls (C3) and (C4) .. (P3);
endtikzpicture
enddocument
Add draw=red
to the key control point
and add draw
to the path[dashed,magenta]
to see the interaction between control points and the graph
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading thetikz
package and wrong syntax for thefigure
environment.
– Thevesh Theva
20 mins ago
add a comment |Â
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
5
down vote
There's certainly more powerful tools available. Nevertheless, here's a simple approach that renders:
Here's the code:
documentclass[12pt,border=6pt]standalone
usepackagetikz
usetikzlibrarycalc
begindocument
defaeAngleAB80
defaeAngleCD55
defaeANgleEF5
begintikzpicture[%%
%% control point/.style=inner sep=2pt,circle,draw=red,
control point/.style=inner sep=2pt,circle,
primary point/.style=inner sep=2pt,circle,draw=blue,
]
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
node[primary point] (P1) at (-2,-4) ;
node[primary point] (P2) at (0,0) ;
node[primary point] (P3) at (7,4) ;
node[control point] (C1) at ($(P1)+(aeAngleAB:10pt)$) ;
node[control point] (C2) at ($(P2)+(180+aeAngleCD:40pt)$) ;
node[control point] (C3) at ($(P2)+(aeAngleCD:110pt)$) ;
node[control point] (C4) at ($(P3)+(180+aeANgleEF:60pt)$) ;
%% path[dashed,magenta,draw] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
path[dashed,magenta] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
draw[blue] (P1) .. controls (C1) and (C2) .. (P2);
draw[blue] (P2) .. controls (C3) and (C4) .. (P3);
endtikzpicture
enddocument
Add draw=red
to the key control point
and add draw
to the path[dashed,magenta]
to see the interaction between control points and the graph
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading thetikz
package and wrong syntax for thefigure
environment.
– Thevesh Theva
20 mins ago
add a comment |Â
up vote
5
down vote
There's certainly more powerful tools available. Nevertheless, here's a simple approach that renders:
Here's the code:
documentclass[12pt,border=6pt]standalone
usepackagetikz
usetikzlibrarycalc
begindocument
defaeAngleAB80
defaeAngleCD55
defaeANgleEF5
begintikzpicture[%%
%% control point/.style=inner sep=2pt,circle,draw=red,
control point/.style=inner sep=2pt,circle,
primary point/.style=inner sep=2pt,circle,draw=blue,
]
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
node[primary point] (P1) at (-2,-4) ;
node[primary point] (P2) at (0,0) ;
node[primary point] (P3) at (7,4) ;
node[control point] (C1) at ($(P1)+(aeAngleAB:10pt)$) ;
node[control point] (C2) at ($(P2)+(180+aeAngleCD:40pt)$) ;
node[control point] (C3) at ($(P2)+(aeAngleCD:110pt)$) ;
node[control point] (C4) at ($(P3)+(180+aeANgleEF:60pt)$) ;
%% path[dashed,magenta,draw] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
path[dashed,magenta] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
draw[blue] (P1) .. controls (C1) and (C2) .. (P2);
draw[blue] (P2) .. controls (C3) and (C4) .. (P3);
endtikzpicture
enddocument
Add draw=red
to the key control point
and add draw
to the path[dashed,magenta]
to see the interaction between control points and the graph
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading thetikz
package and wrong syntax for thefigure
environment.
– Thevesh Theva
20 mins ago
add a comment |Â
up vote
5
down vote
up vote
5
down vote
There's certainly more powerful tools available. Nevertheless, here's a simple approach that renders:
Here's the code:
documentclass[12pt,border=6pt]standalone
usepackagetikz
usetikzlibrarycalc
begindocument
defaeAngleAB80
defaeAngleCD55
defaeANgleEF5
begintikzpicture[%%
%% control point/.style=inner sep=2pt,circle,draw=red,
control point/.style=inner sep=2pt,circle,
primary point/.style=inner sep=2pt,circle,draw=blue,
]
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
node[primary point] (P1) at (-2,-4) ;
node[primary point] (P2) at (0,0) ;
node[primary point] (P3) at (7,4) ;
node[control point] (C1) at ($(P1)+(aeAngleAB:10pt)$) ;
node[control point] (C2) at ($(P2)+(180+aeAngleCD:40pt)$) ;
node[control point] (C3) at ($(P2)+(aeAngleCD:110pt)$) ;
node[control point] (C4) at ($(P3)+(180+aeANgleEF:60pt)$) ;
%% path[dashed,magenta,draw] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
path[dashed,magenta] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
draw[blue] (P1) .. controls (C1) and (C2) .. (P2);
draw[blue] (P2) .. controls (C3) and (C4) .. (P3);
endtikzpicture
enddocument
Add draw=red
to the key control point
and add draw
to the path[dashed,magenta]
to see the interaction between control points and the graph
There's certainly more powerful tools available. Nevertheless, here's a simple approach that renders:
Here's the code:
documentclass[12pt,border=6pt]standalone
usepackagetikz
usetikzlibrarycalc
begindocument
defaeAngleAB80
defaeAngleCD55
defaeANgleEF5
begintikzpicture[%%
%% control point/.style=inner sep=2pt,circle,draw=red,
control point/.style=inner sep=2pt,circle,
primary point/.style=inner sep=2pt,circle,draw=blue,
]
draw[-latex] (-2,0) -- (6,0) node[right] $Return%$;
draw[-latex] (0,-4) -- (0,6) node[above] $Utility$;
node[primary point] (P1) at (-2,-4) ;
node[primary point] (P2) at (0,0) ;
node[primary point] (P3) at (7,4) ;
node[control point] (C1) at ($(P1)+(aeAngleAB:10pt)$) ;
node[control point] (C2) at ($(P2)+(180+aeAngleCD:40pt)$) ;
node[control point] (C3) at ($(P2)+(aeAngleCD:110pt)$) ;
node[control point] (C4) at ($(P3)+(180+aeANgleEF:60pt)$) ;
%% path[dashed,magenta,draw] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
path[dashed,magenta] (P1) -- (C1) -- (C2) -- (P2) -- (C3) -- (C4) -- (P3);
draw[blue] (P1) .. controls (C1) and (C2) .. (P2);
draw[blue] (P2) .. controls (C3) and (C4) .. (P3);
endtikzpicture
enddocument
Add draw=red
to the key control point
and add draw
to the path[dashed,magenta]
to see the interaction between control points and the graph
answered 23 mins ago


A.Ellett
35.2k1063163
35.2k1063163
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading thetikz
package and wrong syntax for thefigure
environment.
– Thevesh Theva
20 mins ago
add a comment |Â
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading thetikz
package and wrong syntax for thefigure
environment.
– Thevesh Theva
20 mins ago
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading the
tikz
package and wrong syntax for the figure
environment.– Thevesh Theva
20 mins ago
@Tommaso Dellolmo This is a great suggestion for how to get the result you want, but I just want to stress that your problems were caused by not loading the
tikz
package and wrong syntax for the figure
environment.– Thevesh Theva
20 mins ago
add a comment |Â
Tommaso Dellolmo is a new contributor. Be nice, and check out our Code of Conduct.
Tommaso Dellolmo is a new contributor. Be nice, and check out our Code of Conduct.
Tommaso Dellolmo is a new contributor. Be nice, and check out our Code of Conduct.
Tommaso Dellolmo is a new contributor. Be nice, and check out our Code of Conduct.
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f453911%2fdrawing-a-cuve-which-start-in-2-4-goes-in-0-0-and-then-in-4-4%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
I'd use three points and to the control points as relative polar coordinates,
++(30:1)
, then the control points are vectors at the end of the curve segments and by controlling the length and direction you control the curve. Just make sure that the two control points in and out of zero, are on the same line, but opposite directions.– daleif
25 mins ago
You need to put the line
usepackagetikz
in your preamble, and change the capital H to a small h inbeginfigure[H]
. That's what is preventing your current code from compiling!– Thevesh Theva
24 mins ago