Create Example environment in Latex

In Latex we use various environment such as \begin{figure}, section, subsection, chapter etc. But LaTex does not have \begin{example}  builtin environment to create examples according to chapter counter. If we use \begin{example} without any package, then it will give error. So, you can create your own example or use {nthereom} package. Here is code.

\usepackage{chngcntr} %to use counter
\usepackage{authblk}  % for affiliation
\counterwithin{example}{chapter} % Change the format to chapter number.example number


%multple author with commom Affiliation
\author{Manpreet Kaur, Amritpal Singh, Monisha}
\affil{Guru Nanak Dev Engineering College, Ludhiana}       
\chapter{Footing Design}
\section{Numerical Examples}
  Stepped footing example. 
  Individual footing example

  Sloped footing example


OR  just add below package to use example environment with default counter.           


  Designs of footing.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s