(* This program is free software; you can redistribute it and/or      *)
(* modify it under the terms of the GNU Lesser General Public License *)
(* as published by the Free Software Foundation; either version 2.1   *)
(* of the License, or (at your option) any later version.             *)
(*                                                                    *)
(* This program is distributed in the hope that it will be useful,    *)
(* but WITHOUT ANY WARRANTY; without even the implied warranty of     *)
(* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the      *)
(* GNU General Public License for more details.                       *)
(*                                                                    *)
(* You should have received a copy of the GNU Lesser General Public   *)
(* License along with this program; if not, write to the Free         *)
(* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA *)
(* 02110-1301 USA                                                     *)
Unset Standard Proposition Elimination Names.
Fixpoint rest (p r s n : nat) {struct n} : nat :=
match n with
| O => r
| S n' =>
match s with
| O => 0
| S O => rest p 0 p n'
| S s' => rest p (S r) s' n'
end
end.
Definition mod_ (m n : nat) : nat := rest n 0 n m.
Proof with trivial.
intro m; unfold mod_ in |- *; unfold rest in |- *...
Qed.
Definition trkrate (phi : Bank) : R :=
toDeg (g * (tand phi / v intruderSpeed)).
left; rewrite <- Ropp_0; apply Ropp_lt_gt_contravar; unfold toDeg in |- *;
repeat simple apply Rmult_lt_0_compat.
unfold MaxBank in |- *; unfold Rdiv in |- *; apply Rmult_lt_0_compat.
prove_sup.
apply Rinv_0_lt_compat; prove_sup.
unfold plat in |- *; prove_sup.
apply Rinv_0_lt_compat; apply PI_RGT_0.
Qed.

Lemma cond2_0 : (0 <= toDeg MaxBank)%R.