# How do I get rid of the default spacing at the top of the page, as I want to move all of my text up?

by Leorio   Last Updated January 19, 2018 01:23 AM

I want to move all of my text up, but I can't seem to control the spacing before my title. How do I proceed?

My Source code:

    \documentclass[10pt,a4paper]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage[french]{babel}
\usepackage{lipsum}
\usepackage{blindtext}
\usepackage{amssymb}
\usepackage{amsmath}

\begin{document}

\begin{center}
\Large
\textbf{Exercice no.1}
\end{center}

.................................................................................................................................................................................

\\
\\
\Large{a)}
\\
\\
\Large{$\lambda = 0$}\\
\\
\Large{$\Rightarrow y''= 0$}\\
\Large{$\Rightarrow {y=ax+b \quad (a,b\in\mathbb{R}) \quad} \quad \textrm{OU} \quad {y=0}$}\\
\\
\Large{Or, une fonction du premier degré est injective et, donc, ne respecte
pas les conditions initiales.}\\
\\
\Large{d'où $y=0$ est la seule solution possible.}\\
\\

.............................................................................................................................

\\
\\
\Large{b)}
\\
\\
\Large{$\lambda<0$}
\\
\\
\Large{$\Rightarrow y''-\lambda y = 0$}
\\
\Large{$\Rightarrow y = e^{rx} \quad \textrm{[ou y=0]}$}
\\
\Large{$\Rightarrow r^2 e^{rx} - \lambda e^{rx} = 0$}
\\
\Large{$\Rightarrow e^{rx}(r^2-\lambda)=0$}
\\
\Large{$\Rightarrow r^2-\lambda=0, \quad \textrm{car} \quad e^{rx}>0$}
\\
\Large{$\Rightarrow r=\pm\sqrt\lambda \quad \in \quad \mathbb{C/R}, \quad \textrm{car} \quad \lambda<0$}
\\
\Large{$\Rightarrow r=0 \pm i\sqrt{|{\lambda}|}$}
\\
\Large{$\Rightarrow y=k_1cos(\sqrt{|\lambda|}x)+ik_2sin(\sqrt{|\lambda|}x), \quad \textrm{car} \quad e^{0x}=1$}
\\
\\
\Large{Or, $y(0)=k_1\neq0, \quad car \quad k_1,k_2 \in \mathbb{R}/0,$}
\\
\Large{\qquad ce qui ne respecte donc pas les conditions initiales.}
\\
\\
\Large{d'où $y=0$ est la seule solution possible.}

\end{document}

Tags :

As posted, your code will not compile without errors. As pointed out in comments, it also suggests that you are trying to start using LaTeX without learning even the beginning basics of how it works. Please read one of the many brief introductions available as it will save you a lot of wasted time and effort, and many, many headaches, the largest and most gruesome of which will, by Sod's well-known Law, emerge mysteriously at the worst possible moment.

Here's a slightly improved version. I'm guessing that you are trying to emulate double-spacing of some kind. This isn't great in LaTeX, but setspace is at least minimally adequate. I've used enumitem so you can configure the list easily, improbably assumed that you are called 'Bob', introduced titling, a larger font size and, as suggested by Bernard, geometry. Delete the showframe option to remove the lines framing the page. These are just to show you the layout.

This is almost certainly not the best way to present the mathematics, but it is at least a considerable improvement, compiles (which is always a plus) and shouldn't complain too loudly about bad stuff.

\documentclass[10pt,a4paper,french,12pt]{article}
\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{amssymb}
\usepackage{amsmath}
\usepackage[showframe]{geometry}
\usepackage{titling,setspace}
\usepackage{enumitem,calc}
\pretitle{\begin{center}\Large\bfseries}
\posttitle{\end{center}}
\predate{}
\postdate{}
\setlength\droptitle{-30pt}
\title{Exercice no.1}
\author{Bob}
\date{}
\doublespacing
\begin{document}
\maketitle

\begin{enumerate}[label=\alph*), itemsep=20pt]
\item $\lambda = 0$

$\Rightarrow y''= 0$

$\Rightarrow {y=ax+b \quad (a,b\in\mathbb{R}) \quad} \quad \textrm{OU} \quad {y=0}$

Or, une fonction du premier degré est injective et, donc, ne respecte pas les conditions initiales.

d'où $y=0$ est la seule solution possible.

\item $\lambda<0$

$\Rightarrow y''-\lambda y = 0$

$\Rightarrow y = e^{rx} \quad \textrm{[ou y=0]}$

$\Rightarrow r^2 e^{rx} - \lambda e^{rx} = 0$

$\Rightarrow e^{rx}(r^2-\lambda)=0$

$\Rightarrow r^2-\lambda=0, \quad \textrm{car} \quad e^{rx}>0$

$\Rightarrow r=\pm\sqrt\lambda \quad \in \quad \mathbb{C/R}, \quad \textrm{car} \quad \lambda<0$

$\Rightarrow r=0 \pm i\sqrt{|{\lambda}|}$

$\Rightarrow y=k_1cos(\sqrt{|\lambda|}x)+ik_2sin(\sqrt{|\lambda|}x), \quad \textrm{car} \quad e^{0x}=1$

Or, $y(0)=k_1\neq0, \quad car \quad k_1,k_2 \in \mathbb{R}/0,$

\qquad ce qui ne respecte donc pas les conditions initiales.

d'où $y=0$ est la seule solution possible.
\end{enumerate}

\end{document}


cfr
January 19, 2018 03:39 AM