isabelle


how to get isabelle to recognize an obvious conclusion


I'm trying to prove that the frontier, interior and exterior of a set are disjoint in isabelle. On the line I have marked '***', the fact that c \<inter> d = {} clearly follows from the previous line given the assumption at the start of the block, so how would I get isabelle to understand this?
theory Scratch
imports
"~~/src/HOL/Multivariate_Analysis/Topology_Euclidean_Space"
"~~/src/HOL/Probability/Sigma_Algebra"
begin
lemma boundary_disjoint: "disjoint {frontier S, interior S, interior (-S)}"
proof (rule disjointI)
fix c d assume sets:
"c \<in> {frontier S, interior S, interior (-S)}"
"d \<in> {frontier S, interior S, interior (-S)}"
and "c \<noteq> d"
show "c \<inter> d = {}"
proof cases
assume "c = frontier S \<and> d = interior S"
then show ?thesis using frontier_def by auto
next
assume "c = frontier S \<and> d = interior (-S)"
have "closure S \<inter> interior (-S) = {}" by (simp add: closure_interior)
hence "frontier S \<inter> interior (-S) = {}" using frontier_def by auto
*** then show ?thesis by auto
next
qed
qed
end
In Isar, you have to explicitly reference the facts you want to use. If you say that your goal follows from the previous line and the local assumption you made, you should give the assumption a name by writing assume A: "c = frontier S ∧ d = interior (-S)", and then you can prove your goal by with A have ?thesis by auto.
Why did I write have and not show? Well, there is another problem. You did a proof cases, but that uses the rule (P ⟹ Q) ⟹ (¬P ⟹ Q) ⟹ Q, i.e. it does a case distinction of the kind ‘Is P true or false?’. That is not what you want here.
One way to do your case distiction is by something like this:
from sets show "c ∩ d = {}"
proof (elim singletonE insertE)
insertE is an elimination rule for facts of the form x ∈ insert y A, and since {a,b,c} is just syntactic sugar for insert a (insert b (insert c A)), this is what you want. singletonE is similar, but specifically for x ∈ {y}; using singletonE instead of insertE means you do not get trivial cases with assumptions like x ∈ {}.
This gives you 9 cases, of which 3 are trivially solved by simp_all. The rest you have to prove yourself in Isar if you want to, but they can be solved quite easily by auto as well:
from sets and `c ≠ d` show "c ∩ d = {}"
by (auto simp: frontier_def closure_def interior_closure)

Related Links

Avoiding assumption with sledgehammer
Discriminant with Inequalities
Instances in locale declaration for Isabelle
How to interactively simplify a formula in a relational theory in Isabelle
Nonnegative Interval Integration
Widening the domain of a partial function
Automatically unfolding a record definition when accessor is used
Creating a datatype with inequalities in Isabelle
Isabelle Logic simple natural deduction test
Instantiating variables ending in a digit using where-attribute (Isabelle)
Using an existing definition in Isabelle/ Hol
Pending sort hypotheses
How can I use proved goals of locale interpretation to prove the remaining ones
Isabelle class obligation prove blue
Type declaration in Isabelle
Isabelle2016 and Proof General

Categories

HOME
sendgrid
twitter
testing
cookies
tizen
single-sign-on
onedrive
cplex
octobercms
maven-3
webpack-2
serverspec
wamp
flyway4
bs4
designer
reactive-cocoa
connection-string
viewport
swiftlint
tapestry
kvc
devops
cultureinfo
crystal-reports-2010
pepper
facebook-access-token
kannel
greendao
fluentvalidation
strncpy
primitive
fabric8
exuberant-ctags
wallpaper
atl
plsql-psp
swift3.0.2
code-search-engine
jna
graphenedb
unoconv
botbuilder
wso2carbon
dotcover
strptime
boost-multi-index
jxcore
composite-key
google-perftools
sqldf
sonarlint-vs
time-and-attendance
gridpane
mongocsharpdriver
storekit
pagedlist
hexdump
jmeter-maven-plugin
riak-cs
ionic
ibaction
processmodel
streambase
fscommand
relocation
id3v2
gulp-less
mesa
android-radiobutton
valuechangelistener
picturefill
typo3-neos
cos
shellexecute
eventual-consistency
xamlparseexception
type-equivalence
flashvars
http-unit
wsdl-2.0
e4x
funscript
broken-links
propertyeditor
multipage
nsdatecomponents
coercion
gdlib
jmock
lpeg
digest-authentication
thunderbird-lightning
zune
mdac
rtml
misv

Resources

Database Users
RDBMS discuss
Database Dev&Adm
javascript
java
csharp
php
android
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App