first order logic - How does 'elim' in Coq work on existential quantifier? -


i'm confused coq on way dealing existential quantification.

i have predicate p , assumption h

p : nat -> prop h : exists n, p n 

while current goal (whatever)

(some goal) 

if want instantiate n in h, do

elim h. 

however after elimination, current goal becomes

forall n, p n -> (some goal) 

it looks coq converts existential quantifier universal one. know (forall a, p -> q a) -> ((exists a, p a) -> q a) out of limited knowledge on first-order logic. reverse proposition seems incorrect. if 'forall' 1 , 'exists' 1 not equivalent, why coq such conversion?

does 'elim' in coq replace goal harder prove one? or please show why ((exists a, p a) -> q a) -> (forall a, p -> q a) holds in first-order logic?

maybe missing key goal:

forall n, p n -> (some goal) 

is read as:

forall n, (p n -> (some goal))

and not as:

(forall n, p n) -> (some goal) 

that is, goal given gives arbitrary n , proof p n, indeed proper way eliminate existential (you don't know value of witness since value makes p true, know there n , p n holds).

on contrary, latter provide function can build p n n pass it, indeed stronger statement 1 have.


Comments

Popular posts from this blog

python - TypeError: start must be a integer -

c# - DevExpress RepositoryItemComboBox BackColor property ignored -

django - Creating multiple model instances in DRF3 -