Graphics, Figures & Tablesfilling a region

Information and discussion about graphics, figures & tables in LaTeX documents.
Post Reply
kent
Posts: 57
Joined: Thu Oct 20, 2016 3:41 pm

filling a region

Post by kent »

See the attached latex code where I would like to shade the region between the drawn parabola and ellipse.
Anybody knoes how to do this?
I have tried several combinations using \clip, \scope etc. without success.
Best regards,
Kent
Attachments
forum.tex
(1005 Bytes) Downloaded 305 times
forum.pdf
(3.88 KiB) Downloaded 210 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

filling a region

Post by Stefan Kottwitz »

Hi Kent,

start, filling between ellipse and parabola2, adding:

Code: Select all

Code, edit and compile here:
\begin{scope}
\clip (S) ellipse (\a cm and \b cm);
\filldraw[rotate=90,fill=yellow] (T) parabola (PP2) -- (9,0);
\end{scope}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Stefan
LaTeX.org admin
kent
Posts: 57
Joined: Thu Oct 20, 2016 3:41 pm

filling a region

Post by kent »

Stefan, thanks for help!
May be I was not precise enough to define what I wanted to achieve.
I want the shading to be as indicated in black in the attached file.
Kent
Attachments
image2017-11-02-191233.pdf
(51.41 KiB) Downloaded 202 times
User avatar
Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

filling a region

Post by Stefan Kottwitz »

Ok, then this should do it:

Code: Select all

Code, edit and compile here:
\begin{scope}
\clip (S) ellipse (\a cm and \b cm);
\filldraw[rotate=90,fill=yellow] (T) parabola (PP2) -- (-5,0);
\filldraw[rotate=90,fill=yellow] (T) parabola (PP) -- ( 5,0);
\end{scope}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
ellipse.png
ellipse.png (11.45 KiB) Viewed 2799 times
Stefan
LaTeX.org admin
kent
Posts: 57
Joined: Thu Oct 20, 2016 3:41 pm

filling a region

Post by kent »

Thank you very much!
Your support is highly appreciated.
Post Reply