Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect generation of state names? #176

Open
sdwfrost opened this issue Aug 7, 2024 · 0 comments
Open

Incorrect generation of state names? #176

sdwfrost opened this issue Aug 7, 2024 · 0 comments

Comments

@sdwfrost
Copy link

sdwfrost commented Aug 7, 2024

I'm trying to replicate the '2 strain SIR' example from Evan and Micah's presentation way back. I know the following will result in shared parameters across the two strains, but why are the state names both I and not I_1 and I_2?

sir_uwd = @relation (S, I, R) where (S::Pop, I::Pop, R::Pop) begin
    infection(S, I, I, I)
    recovery(I, R)
end

sir_acst = oapply_typed(epi_lpn, sir_uwd, [, ])
sir_lpn = dom(sir_acst)

sir12_uwd = @relation (S, I₁, I₂, R) where (S::Pop, I₁::Pop, I₂::Pop, R::Pop) begin
    sir(S, I₁, R)
    sir(S, I₂, R)
end

sir2_smc = oapply(sir2_uwd, Dict(
    :sir => Open(sir_lpn)
))

sir2_lpn = apex(sir2_smc)

snames(sir2_lpn)

Output:

4-element Vector{Symbol}:
 :S
 :I
 :R
 :I
@jpfairbanks jpfairbanks transferred this issue from AlgebraicJulia/Catlab.jl Aug 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant