SlideShare a Scribd company logo
1 of 18









       
    

    


    

    



type Expression =
                                    | Math of Expression list
                                     | Menclose of Expression list
                                    | Mrow of Expression list

                                    | Mi of string
                                     | MiNormal of string

                                    | Mo of string
                                     | Mtd of Expression list

                                    | Mtr of Expression list
                                     | Mn of string
        Mn(42)                       | Mroot of Expression * Expression
                                     | Mfrac of Expression * Expression
                                    | Msub of Expression * Expression
                                     | Msup of Expression * Expression
        Mi(
                                  (etc.)

              Mfrac(Mn(1),Mn(2))
    
              Mtd([…])
l e t c a s e s = R e f l e c t i o n . F S h a r p Typ e . G e t U n i o n C a s e s ( t yp e o f <E xp r e s s i o n >)
                   |> A r r a y. m ap ( f u n f - > ( f . N a me ,
                     R e f l e c t i o n .F S h a r p Va l u e . P r e C o mp u t e U n i o n C o n s t r u c to r ( f) ) )
                   |> M a p . o f A r r a y





        let ctor = cases.Item name
        (ctor parameters) :?> Expression

     
     


    0 (* sorry, supporting integrals is just too hard *)
   





   





   





   

    


    

         a*b*c


               
                    
                    
                
                     x*x
                     Math.Pow(x, n)
      <msub>
                     x_3__2
    <msup>
   






       






    
       Add,
               Mul   Div, Sqrt   Pow
        Sub




    

    

    
         | "E" | "ⅇ" | "e" when settings.EIsConstant
    
         | Mo(op) :: (UnitOfMeasureBraces(units) as uu) :: t

    
     let rec (|Simple|_|) = function
        | SimpleAndPhysical x -> Some x
        | Mrow(content) ->
          match content with
          | Simple h :: [] -> Some h
          | _ -> None
        | _ -> None

     let (<@>) (dictName:Map<_,_>) keyName =
        if dictName.ContainsKey keyName then dictName.[keyName]
        else keyName











                         Excel
    
              C#, F#              C++
              NMath              Boost

    
                        Web       iPad
       Code
                        Svc       apps
       


    
    

    
    
    

More Related Content

What's hot

Domain & range intro presentation
Domain & range intro presentationDomain & range intro presentation
Domain & range intro presentation
daldridge530
 
Limits
LimitsLimits
Limits
sarcia
 
5 4 function notation
5 4 function notation5 4 function notation
5 4 function notation
hisema01
 
Comp Of Functions 0922
Comp Of Functions 0922Comp Of Functions 0922
Comp Of Functions 0922
ingroy
 
2 1 polynomials
2 1 polynomials2 1 polynomials
2 1 polynomials
hisema01
 
Derivatives Lesson Oct 19
Derivatives Lesson  Oct 19Derivatives Lesson  Oct 19
Derivatives Lesson Oct 19
ingroy
 
Limits and continuity powerpoint
Limits and continuity powerpointLimits and continuity powerpoint
Limits and continuity powerpoint
canalculus
 

What's hot (20)

Lecture 15 - Array
Lecture 15 - ArrayLecture 15 - Array
Lecture 15 - Array
 
Math presentation on domain and range
Math presentation on domain and rangeMath presentation on domain and range
Math presentation on domain and range
 
Domain & range intro presentation
Domain & range intro presentationDomain & range intro presentation
Domain & range intro presentation
 
Abstract Algebra in 3 Hours
Abstract Algebra in 3 HoursAbstract Algebra in 3 Hours
Abstract Algebra in 3 Hours
 
Power Rule
Power RulePower Rule
Power Rule
 
Limits
LimitsLimits
Limits
 
Lecture 8 derivative rules
Lecture 8   derivative rulesLecture 8   derivative rules
Lecture 8 derivative rules
 
Limit and continuity
Limit and continuityLimit and continuity
Limit and continuity
 
The mobius function and the mobius inversion formula
The mobius function and the mobius inversion formulaThe mobius function and the mobius inversion formula
The mobius function and the mobius inversion formula
 
Bisection
BisectionBisection
Bisection
 
Bisection method
Bisection methodBisection method
Bisection method
 
5 4 function notation
5 4 function notation5 4 function notation
5 4 function notation
 
Comp Of Functions 0922
Comp Of Functions 0922Comp Of Functions 0922
Comp Of Functions 0922
 
Limit and continuity (2)
Limit and continuity (2)Limit and continuity (2)
Limit and continuity (2)
 
NumPy
NumPyNumPy
NumPy
 
2 1 polynomials
2 1 polynomials2 1 polynomials
2 1 polynomials
 
Introduction to numpy Session 1
Introduction to numpy Session 1Introduction to numpy Session 1
Introduction to numpy Session 1
 
Derivatives Lesson Oct 19
Derivatives Lesson  Oct 19Derivatives Lesson  Oct 19
Derivatives Lesson Oct 19
 
Limit and continuty final
Limit and continuty finalLimit and continuty final
Limit and continuty final
 
Limits and continuity powerpoint
Limits and continuity powerpointLimits and continuity powerpoint
Limits and continuity powerpoint
 

Similar to Domain Transformations

Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov VyacheslavSeminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
Vyacheslav Arbuzov
 
19. algorithms and-complexity
19. algorithms and-complexity19. algorithms and-complexity
19. algorithms and-complexity
showkat27
 
Can two fixpoint types in Mendler style unite?
Can two fixpoint types in Mendler style unite?Can two fixpoint types in Mendler style unite?
Can two fixpoint types in Mendler style unite?
Ki Yung Ahn
 
Types by Adform Research
Types by Adform ResearchTypes by Adform Research
Types by Adform Research
Vasil Remeniuk
 
Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)
IJERD Editor
 

Similar to Domain Transformations (20)

Functional programming in f sharp
Functional programming in f sharpFunctional programming in f sharp
Functional programming in f sharp
 
Bayesian Defect Signal Analysis for Nondestructive Evaluation of Materials
Bayesian Defect Signal Analysis for Nondestructive Evaluation of MaterialsBayesian Defect Signal Analysis for Nondestructive Evaluation of Materials
Bayesian Defect Signal Analysis for Nondestructive Evaluation of Materials
 
Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov VyacheslavSeminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
Seminar PSU 09.04.2013 - 10.04.2013 MiFIT, Arbuzov Vyacheslav
 
19. algorithms and-complexity
19. algorithms and-complexity19. algorithms and-complexity
19. algorithms and-complexity
 
Array
ArrayArray
Array
 
Introduction to matlab
Introduction to matlabIntroduction to matlab
Introduction to matlab
 
Class 28: Entropy
Class 28: EntropyClass 28: Entropy
Class 28: Entropy
 
Python.pdf
Python.pdfPython.pdf
Python.pdf
 
mat lab introduction and basics to learn
mat lab introduction and basics to learnmat lab introduction and basics to learn
mat lab introduction and basics to learn
 
chap09alg.ppt for string matching algorithm
chap09alg.ppt for string matching algorithmchap09alg.ppt for string matching algorithm
chap09alg.ppt for string matching algorithm
 
19. Data Structures and Algorithm Complexity
19. Data Structures and Algorithm Complexity19. Data Structures and Algorithm Complexity
19. Data Structures and Algorithm Complexity
 
Numpy Talk at SIAM
Numpy Talk at SIAMNumpy Talk at SIAM
Numpy Talk at SIAM
 
Can two fixpoint types in Mendler style unite?
Can two fixpoint types in Mendler style unite?Can two fixpoint types in Mendler style unite?
Can two fixpoint types in Mendler style unite?
 
Applied machine learning for search engine relevance 3
Applied machine learning for search engine relevance 3Applied machine learning for search engine relevance 3
Applied machine learning for search engine relevance 3
 
Practical cats
Practical catsPractical cats
Practical cats
 
Chap09alg
Chap09algChap09alg
Chap09alg
 
Chap09alg
Chap09algChap09alg
Chap09alg
 
introduction to matlab.pptx
introduction to matlab.pptxintroduction to matlab.pptx
introduction to matlab.pptx
 
Types by Adform Research
Types by Adform ResearchTypes by Adform Research
Types by Adform Research
 
Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)Welcome to International Journal of Engineering Research and Development (IJERD)
Welcome to International Journal of Engineering Research and Development (IJERD)
 

More from Dmitri Nesteruk

Converting Managed Languages to C++
Converting Managed Languages to C++Converting Managed Languages to C++
Converting Managed Languages to C++
Dmitri Nesteruk
 
Dynamics CRM Data Integration
Dynamics CRM Data IntegrationDynamics CRM Data Integration
Dynamics CRM Data Integration
Dmitri Nesteruk
 
ReSharper Architecture & Extensions
ReSharper Architecture & ExtensionsReSharper Architecture & Extensions
ReSharper Architecture & Extensions
Dmitri Nesteruk
 

More from Dmitri Nesteruk (20)

Good Ideas in Programming Languages
Good Ideas in Programming LanguagesGood Ideas in Programming Languages
Good Ideas in Programming Languages
 
Design Pattern Observations
Design Pattern ObservationsDesign Pattern Observations
Design Pattern Observations
 
CallSharp: Automatic Input/Output Matching in .NET
CallSharp: Automatic Input/Output Matching in .NETCallSharp: Automatic Input/Output Matching in .NET
CallSharp: Automatic Input/Output Matching in .NET
 
Design Patterns in Modern C++
Design Patterns in Modern C++Design Patterns in Modern C++
Design Patterns in Modern C++
 
C# Tricks
C# TricksC# Tricks
C# Tricks
 
Introduction to Programming Bots
Introduction to Programming BotsIntroduction to Programming Bots
Introduction to Programming Bots
 
Converting Managed Languages to C++
Converting Managed Languages to C++Converting Managed Languages to C++
Converting Managed Languages to C++
 
Monte Carlo C++
Monte Carlo C++Monte Carlo C++
Monte Carlo C++
 
Tpl DataFlow
Tpl DataFlowTpl DataFlow
Tpl DataFlow
 
YouTrack: Not Just an Issue Tracker
YouTrack: Not Just an Issue TrackerYouTrack: Not Just an Issue Tracker
YouTrack: Not Just an Issue Tracker
 
Проект X2C
Проект X2CПроект X2C
Проект X2C
 
Victor CG Erofeev - Metro UI
Victor CG Erofeev - Metro UIVictor CG Erofeev - Metro UI
Victor CG Erofeev - Metro UI
 
Developer Efficiency
Developer EfficiencyDeveloper Efficiency
Developer Efficiency
 
Distributed Development
Distributed DevelopmentDistributed Development
Distributed Development
 
Dynamics CRM Data Integration
Dynamics CRM Data IntegrationDynamics CRM Data Integration
Dynamics CRM Data Integration
 
ReSharper Presentation for NUGs
ReSharper Presentation for NUGsReSharper Presentation for NUGs
ReSharper Presentation for NUGs
 
ReSharper Architecture & Extensions
ReSharper Architecture & ExtensionsReSharper Architecture & Extensions
ReSharper Architecture & Extensions
 
Web mining
Web miningWeb mining
Web mining
 
Data mapping tutorial
Data mapping tutorialData mapping tutorial
Data mapping tutorial
 
Reactive Extensions
Reactive ExtensionsReactive Extensions
Reactive Extensions
 

Recently uploaded

Recently uploaded (20)

"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024AXA XL - Insurer Innovation Award Americas 2024
AXA XL - Insurer Innovation Award Americas 2024
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 

Domain Transformations

  • 1.
  • 3.       
  • 4. type Expression =  | Math of Expression list | Menclose of Expression list  | Mrow of Expression list  | Mi of string | MiNormal of string  | Mo of string | Mtd of Expression list  | Mtr of Expression list | Mn of string Mn(42) | Mroot of Expression * Expression | Mfrac of Expression * Expression  | Msub of Expression * Expression | Msup of Expression * Expression Mi(  (etc.) Mfrac(Mn(1),Mn(2))  Mtd([…])
  • 5. l e t c a s e s = R e f l e c t i o n . F S h a r p Typ e . G e t U n i o n C a s e s ( t yp e o f <E xp r e s s i o n >) |> A r r a y. m ap ( f u n f - > ( f . N a me , R e f l e c t i o n .F S h a r p Va l u e . P r e C o mp u t e U n i o n C o n s t r u c to r ( f) ) ) |> M a p . o f A r r a y   let ctor = cases.Item name  (ctor parameters) :?> Expression    0 (* sorry, supporting integrals is just too hard *)
  • 6.  
  • 7.  
  • 8.  
  • 9.      a*b*c 
  • 10.      x*x  Math.Pow(x, n)  <msub>  x_3__2 <msup>
  • 11.  
  • 12.
  • 13.   
  • 14. Add, Mul Div, Sqrt Pow Sub 
  • 15.     | "E" | "ⅇ" | "e" when settings.EIsConstant   | Mo(op) :: (UnitOfMeasureBraces(units) as uu) :: t    let rec (|Simple|_|) = function | SimpleAndPhysical x -> Some x | Mrow(content) -> match content with | Simple h :: [] -> Some h | _ -> None | _ -> None   let (<@>) (dictName:Map<_,_>) keyName = if dictName.ContainsKey keyName then dictName.[keyName] else keyName
  • 17.    Excel   C#, F# C++  NMath Boost  Web iPad  Code Svc apps
  • 18.        